mirror of
https://github.com/Doctorado-ML/beflask.git
synced 2025-08-16 15:45:51 +00:00
Begin with model
This commit is contained in:
30
app/templates/_nav.html
Normal file
30
app/templates/_nav.html
Normal file
@@ -0,0 +1,30 @@
|
||||
{% from 'bootstrap5/nav.html' import render_nav_item %}
|
||||
<nav class="navbar navbar-expand-sm navbar-light bg-light mb-4 justify-content-end">
|
||||
<div class="container">
|
||||
<button class="navbar-toggler"
|
||||
type="button"
|
||||
data-bs-toggle="collapse"
|
||||
data-bs-target="#navbarSupportedContent"
|
||||
aria-controls="navbarSupportedContent"
|
||||
aria-expanded="false"
|
||||
aria-label="Toggle navigation">
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
<div class="collapse navbar-collapse" id="navbarSupportedContent">
|
||||
<!-- Left side of navbar -->
|
||||
<ul class="navbar-nav me-auto">
|
||||
{{ render_nav_item('main.index', 'Home') }}
|
||||
</ul>
|
||||
<ul class="navbar-nav justify-content-end">
|
||||
{{ render_nav_item('results.select', 'Results') }}
|
||||
{{ render_nav_item('results.datasets', 'Datasets') }}
|
||||
{{ render_nav_item('main.config', 'Config') }}
|
||||
{% if current_user.is_authenticated %}
|
||||
{{ render_nav_item('main.logout', current_user.username + '(Logout) ') }}
|
||||
{% else %}
|
||||
{{ render_nav_item('main.login', 'Login') }}
|
||||
{% endif %}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
32
app/templates/base.html
Normal file
32
app/templates/base.html
Normal file
@@ -0,0 +1,32 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
{% block head %}
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport"
|
||||
content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||
{% block styles %}
|
||||
{{ bootstrap.load_css() }}
|
||||
<link rel="stylesheet" href="/css/elina.css">
|
||||
<link rel="stylesheet"
|
||||
href="{{ url_for('static', filename='css/main.css') }}">
|
||||
{% endblock %}
|
||||
<title>Benchmark</title>
|
||||
{% endblock %}
|
||||
</head>
|
||||
<body>
|
||||
{% include "_nav.html" %}
|
||||
{% with messages = get_flashed_messages() %}
|
||||
{% if messages %}
|
||||
{% for message in messages %}<div class="alert alert-info" role="alert">{{ message }}</div>{% endfor %}
|
||||
{% endif %}
|
||||
{% endwith %}
|
||||
<div class="container">
|
||||
{% block content %}{% endblock %}
|
||||
</div>
|
||||
</body>
|
||||
{% block jscript %}
|
||||
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
|
||||
{{ bootstrap.load_js() }}
|
||||
{% endblock %}
|
||||
</html>
|
5
app/templates/config.html
Normal file
5
app/templates/config.html
Normal file
@@ -0,0 +1,5 @@
|
||||
{% extends "base.html" %}
|
||||
{% block content %}
|
||||
<h1>Home</h1>
|
||||
<p>Welcome to the home page!</p>
|
||||
{% endblock content %}
|
13
app/templates/index.html
Normal file
13
app/templates/index.html
Normal file
@@ -0,0 +1,13 @@
|
||||
{% extends "base.html" %}
|
||||
{% block content %}
|
||||
{% if benchmarks %}
|
||||
<h5>Benchmarks</h5>
|
||||
<ul>
|
||||
{% for benchmark in benchmarks %}
|
||||
<li>
|
||||
<a href="">{{ benchmark.name }} {{ benchmark.folder }}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
{% endblock %}
|
6
app/templates/login.html
Normal file
6
app/templates/login.html
Normal file
@@ -0,0 +1,6 @@
|
||||
{% extends 'base.html' %}
|
||||
{% from 'bootstrap5/form.html' import render_form %}
|
||||
{% block content %}
|
||||
<h2>Login</h2>
|
||||
{{ render_form(form) }}
|
||||
{% endblock content %}
|
Reference in New Issue
Block a user