Remotely/Server/Pages/_IndexNotLoggedIn.cshtml

40 lines
1.1 KiB
Plaintext

@inject Remotely.Server.Services.ApplicationConfig AppConfig
@inject Remotely.Server.Services.DataService DataService
@model IndexModel
@{
var organizationCount = DataService.GetOrganizationCount();
var registrationAvailable = AppConfig.MaxOrganizationCount < 0 || organizationCount < AppConfig.MaxOrganizationCount;
}
<div class="text-center mt-5" style="margin-bottom:150px">
<h1 id="remotelyHeader">
</h1>
<div class="lead">
Welcome. Please log in@(registrationAvailable ? " or register" : "").
</div>
<div class="mt-5">
<a href="~/Identity/Account/Login" class="btn btn-primary btn-lg">
Login
</a>
@if (registrationAvailable)
{
<br />
<br />
<a href="~/Identity/Account/Register" class="btn btn-secondary btn-lg">
Register
</a>
}
</div>
</div>
<script>
require.config({
paths: {
"App": "out"
}
});
require(["App"], function (remotely) {
remotely.App.Pages.IndexNotLoggedIn.Init();
});
</script>