Remove Privacy page, clean up some css, add jacknet login link
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
d7c38191ce
commit
868291c135
|
@ -6,5 +6,21 @@
|
||||||
|
|
||||||
<div class="text-center">
|
<div class="text-center">
|
||||||
<h1 class="display-4">Welcome</h1>
|
<h1 class="display-4">Welcome</h1>
|
||||||
<p>Learn about <a href="https://docs.microsoft.com/aspnet/core">building Web apps with ASP.NET Core</a>.</p>
|
<div class="container-fluid">
|
||||||
</div>
|
@if (User.Identity == null || !User.Identity.IsAuthenticated)
|
||||||
|
{
|
||||||
|
|
||||||
|
<h2>Please log in</h2>
|
||||||
|
<a asp-page="/UserHome" style="display: inline-block;">
|
||||||
|
<span style="white-space: nowrap;display: flex;">
|
||||||
|
Login with
|
||||||
|
<img style="no-repeat;width: 6em;background-size: contain;background-position: center;margin-left: 10px;" src="~/static/JackNet-auth-logo-orange.svg"></img>
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
<p>You're already logged in, please use the <a asp-area="" asp-page="/UserHome">User</a> tab to see your devices.</p>
|
||||||
|
}
|
||||||
|
</div>
|
||||||
|
|
|
@ -1,8 +0,0 @@
|
||||||
@page
|
|
||||||
@model PrivacyModel
|
|
||||||
@{
|
|
||||||
ViewData["Title"] = "Privacy Policy";
|
|
||||||
}
|
|
||||||
<h1>@ViewData["Title"]</h1>
|
|
||||||
|
|
||||||
<p>Use this page to detail your site's privacy policy.</p>
|
|
|
@ -1,19 +0,0 @@
|
||||||
using Microsoft.AspNetCore.Mvc;
|
|
||||||
using Microsoft.AspNetCore.Mvc.RazorPages;
|
|
||||||
|
|
||||||
namespace ManagementPage.Pages
|
|
||||||
{
|
|
||||||
public class PrivacyModel : PageModel
|
|
||||||
{
|
|
||||||
private readonly ILogger<PrivacyModel> _logger;
|
|
||||||
|
|
||||||
public PrivacyModel(ILogger<PrivacyModel> logger)
|
|
||||||
{
|
|
||||||
_logger = logger;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void OnGet()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -23,16 +23,16 @@
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link text-dark" asp-area="" asp-page="/Index">Home</a>
|
<a class="nav-link text-dark" asp-area="" asp-page="/Index">Home</a>
|
||||||
</li>
|
</li>
|
||||||
<li class="nav-item">
|
@if (User.Identity != null && User.Identity.IsAuthenticated)
|
||||||
<a class="nav-link text-dark" asp-area="" asp-page="/Privacy">Privacy</a>
|
{
|
||||||
</li>
|
<li class="nav-item">
|
||||||
<li class="nav-item">
|
<a class="nav-link text-dark" asp-area="" asp-page="/UserHome">User</a>
|
||||||
<a class="nav-link text-dark" asp-area="" asp-page="/UserHome">User</a>
|
</li>
|
||||||
</li>
|
}
|
||||||
</ul>
|
</ul>
|
||||||
@if (User.Identity != null && User.Identity.IsAuthenticated)
|
@if (User.Identity != null && User.Identity.IsAuthenticated)
|
||||||
{
|
{
|
||||||
<ul class="navbar-nav flex-grow-1">
|
<ul class="navbar-nav flex-grow-1" style="justify-content: right">
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link text-dark" asp-area="" asp-page="/logout">Logout</a>
|
<a class="nav-link text-dark" asp-area="" asp-page="/logout">Logout</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
|
@ -6,31 +6,34 @@
|
||||||
|
|
||||||
<h3>Hi @Model.name</h3>
|
<h3>Hi @Model.name</h3>
|
||||||
<hr></hr>
|
<hr></hr>
|
||||||
<div class="card-deck row row-cols-1 row-cols-md-3 g-4">
|
<div class="container-fluid">
|
||||||
@foreach (var item in @Model.data)
|
<div class="card-deck row row-cols-1 row-cols-md-3 g-4">
|
||||||
{
|
@foreach (var item in @Model.data)
|
||||||
<div class="card" style="width: 18rem;">
|
{
|
||||||
<div class="card-body">
|
<div class="card" style="width: 18rem;">
|
||||||
<h5 class="card-title">@item.Name</h5>
|
<div class="card-body">
|
||||||
<p class="card-text">
|
<h5 class="card-title">@item.Name</h5>
|
||||||
<h4>Current conditions:</h4>
|
<p class="card-text">
|
||||||
<div>Temperature @Model.currentEnvironment[@item.ApiID].Temperature</div>
|
<h4>Current conditions:</h4>
|
||||||
<div>Humidity @Model.currentEnvironment[@item.ApiID].Humidity</div>
|
<div>Temperature @Model.currentEnvironment[@item.ApiID].Temperature</div>
|
||||||
</p>
|
<div>Humidity @Model.currentEnvironment[@item.ApiID].Humidity</div>
|
||||||
<a class="btn btn-primary" asp-area="" asp-page="/DevicePage" asp-route-id="@((UInt64)item.ApiID)">Details</a>
|
</p>
|
||||||
|
<a class="btn btn-primary" asp-area="" asp-page="/DevicePage" asp-route-id="@((UInt64)item.ApiID)">Details</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
}
|
||||||
}
|
|
||||||
|
|
||||||
<div class="card text-center" style="width: 18rem;">
|
<div class="card text-center" style="width: 18rem;">
|
||||||
<div class="card-body ">
|
<div class="card-body d-flex flex-column">
|
||||||
<h5 class="card-title">New Item</h5>
|
<h5 class="card-title">New Item</h5>
|
||||||
<p class="card-text">Register a new device</p>
|
<p class="card-text">Register a new device</p>
|
||||||
<button type="button" class="btn btn-primary oi oi-plus" data-bs-toggle="modal" data-bs-target="#devicemodal"></button>
|
<div class="mt-auto">
|
||||||
|
<button type="button" class="btn btn-primary oi oi-plus" data-bs-toggle="modal" data-bs-target="#devicemodal"></button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="modal fade" id="devicemodal" tabindex="-1" aria-labelledby="deviceModalLabel" aria-hidden="true">
|
<div class="modal fade" id="devicemodal" tabindex="-1" aria-labelledby="deviceModalLabel" aria-hidden="true">
|
||||||
<div class="modal-dialog">
|
<div class="modal-dialog">
|
||||||
<div class="modal-content">
|
<div class="modal-content">
|
||||||
|
|
File diff suppressed because one or more lines are too long
After Width: | Height: | Size: 23 KiB |
Loading…
Reference in New Issue