init
This commit is contained in:
74
backend/templates/html/index.html
Normal file
74
backend/templates/html/index.html
Normal file
@@ -0,0 +1,74 @@
|
||||
{% load static %}
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Home - Backend</title>
|
||||
<style>
|
||||
body {
|
||||
background-color: cadetblue;
|
||||
}
|
||||
|
||||
nav {
|
||||
font-family: sans-serif;
|
||||
padding: 1rem;
|
||||
}
|
||||
|
||||
nav ol {
|
||||
list-style-type: none;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
nav li {
|
||||
margin-bottom: 0.5rem;
|
||||
padding: 0.5em;
|
||||
}
|
||||
|
||||
nav a {
|
||||
text-decoration: none;
|
||||
color: #2c3e50;
|
||||
}
|
||||
|
||||
nav a:hover {
|
||||
color: #2980b9;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
{% if user.is_authenticated %}
|
||||
<h1>Logged as: {{user.username}} | Role: {{user.role}}</h1>
|
||||
{% endif %}
|
||||
|
||||
<nav>
|
||||
<ol>
|
||||
{% if user.is_authenticated %}
|
||||
<li style="background-color: greenyellow; width: max-content; "><a href="/logout/">Logout</a></li>
|
||||
{% else %}
|
||||
<li style="background-color: greenyellow; width: max-content; "><a href="/admin/">Login</a></li>
|
||||
{% endif %}
|
||||
|
||||
<li style="background-color: red; width: max-content; "><a href="/admin/">Admin</a></li>
|
||||
<h2>API (Rest UI)</h2>
|
||||
<li style="background-color: antiquewhite; width: max-content; "><a href="/account/">Account</a></li>
|
||||
<li style="background-color: antiquewhite; width: max-content; "><a href="/booking/">Booking</a></li>
|
||||
<h2>Swagger</h2>
|
||||
<!--<li style="background-color: limegreen; width: max-content; "><a href="/swagger.json">Swagger JSON</a></li>-->
|
||||
<!--<li style="background-color: limegreen; width: max-content; "><a href="/swagger.yaml">Swagger YAML</a></li>-->
|
||||
<li style="background-color: limegreen; width: max-content; "><a href="/swagger/">Swagger UI</a></li>
|
||||
<h2>Other UI</h2>
|
||||
<li style="background-color: thistle; width: max-content; "><a href="/redoc/">Redoc</a></li>
|
||||
|
||||
<h2>Test E-mail</h2>
|
||||
<label for="recipient">Recipient</label>
|
||||
<input type="text" name="recipient" id="email-recipient">
|
||||
<button id="sendEmailBtn">Send!</button>
|
||||
</ol>
|
||||
</nav>
|
||||
|
||||
<script src="{% static 'js/index.js' %}"></script>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
Reference in New Issue
Block a user