Skip to content
Permalink
Browse files
restructure
  • Loading branch information
memica committed Mar 5, 2020
1 parent 6624808 commit 740c0504e7c09984cf59c49f2f38f7519748b262
Show file tree
Hide file tree
Showing 21 changed files with 41 additions and 60 deletions.
@@ -2,11 +2,11 @@ from .index import index_bl
from .main import main_bl
from .map import map_bl
from .login import login_bl
from .account import acc_bl
from .profile import prof_bl

def init_app(app):
app.register_blueprint(index_bl)
app.register_blueprint(main_bl, url_prefix="/main")
app.register_blueprint(map_bl, url_prefix="/map")
app.register_blueprint(login_bl, url_prefix="/login")
app.register_blueprint(acc_bl, url_prefix="/profile")
app.register_blueprint(prof_bl, url_prefix="/profile")
@@ -8,17 +8,17 @@ login_bl = Blueprint('login', __name__)
def index():
if request.method == "POST":
print(request.form)
return render_template("login_index.html")
return render_template("login/index.html")

@login_bl.route("/create_account", methods = ["GET", "POST"])
def create_account():
if request.method == "POST":
print(request.form)
return render_template("login_create.html", today = datetime.today().strftime('%Y-%m-%d'))
return render_template("login/create.html", today = datetime.today().strftime('%Y-%m-%d'))


@login_bl.route("/forgot_password", methods = ["GET", "POST"])
def forgot_password():
if request.method == "POST":
print(request.form)
return render_template("login_forgot.html")
return render_template("login/forgot.html")
@@ -6,7 +6,7 @@ main_bl = Blueprint('main', __name__)
@main_bl.route("/")
def index():
session['username'] = "JC"
return render_template("main_index.html", locations = data_getter.get_locations_for(session['username']))
return render_template("main/index.html", locations = data_getter.get_locations_for(session['username']))

@main_bl.route("/logout")
def logout():
@@ -5,6 +5,6 @@ map_bl = Blueprint('map', __name__)

@map_bl.route("/", methods = ["GET", "POST"])
def index():
return render_template("map_index.html",
return render_template("map/index.html",
locations = data_getter.get_map_locations_for(session['username']),
dates = data_getter.get_map_location_dates(session['username']))
@@ -1,8 +1,8 @@
from flask import Blueprint, render_template, request, url_for, escape, redirect, session
from app.functions.data_tools import data_getter

acc_bl = Blueprint('acc', __name__)
prof_bl = Blueprint('prof', __name__)

@acc_bl.route("/", methods = ["GET", "POST"])
@prof_bl.route("/", methods = ["GET", "POST"])
def index():
return render_template("account_index.html")
return render_template("profile/index.html")
@@ -52,25 +52,4 @@
}
.content_main {
grid-area: c_main;
}
.table_main {
width: 100%;
border-width: 0;
}
.table_title {
margin: 1vh;
font-size: 4vw;
}
.table_main th {
margin: 1vh;
padding: 1vh;
font-size: 2vw;
}
.table_main td {
text-align: center;
font-size: 1.4vw;
margin: 0.3vh;
}
.table_main tr:nth-child(even) {
background-color: #3EA4E8;
}
File renamed without changes.
@@ -0,0 +1,21 @@
.table_main {
width: 100%;
border-width: 0;
}
.table_title {
margin: 1vh;
font-size: 4vw;
}
.table_main th {
margin: 1vh;
padding: 1vh;
font-size: 2vw;
}
.table_main td {
text-align: center;
font-size: 1.4vw;
margin: 0.3vh;
}
.table_main tr:nth-child(even) {
background-color: #3EA4E8;
}
File renamed without changes.
Empty file.
File renamed without changes.

This file was deleted.

@@ -7,7 +7,7 @@

<!-- CSS -->
{% block basecss %}
<link href="{{ url_for('static', filename='css/main_index.css') }}" rel="stylesheet" />
<link href="{{ url_for('static', filename='css/base_page.css') }}" rel="stylesheet" />
{% block css %}{% endblock %}
{% endblock %}

@@ -9,7 +9,7 @@

<!-- CSS -->
{% block basecss %}
<link href="{{ url_for('static', filename='css/login_create.css') }}" rel="stylesheet" />
<link href="{{ url_for('static', filename='css/login/create.css') }}" rel="stylesheet" />
{% endblock %}

<!-- BODY -->
@@ -9,7 +9,7 @@

<!-- CSS -->
{% block basecss %}
<link href="{{ url_for('static', filename='css/login_forgot.css') }}" rel="stylesheet" />
<link href="{{ url_for('static', filename='css/login/forgot.css') }}" rel="stylesheet" />
{% endblock %}

<!-- BODY -->
@@ -9,7 +9,7 @@

<!-- CSS -->
{% block basecss %}
<link href="{{ url_for('static', filename='css/login_index.css') }}" rel="stylesheet" />
<link href="{{ url_for('static', filename='css/login/index.css') }}" rel="stylesheet" />
{% endblock %}

<!-- BODY -->
@@ -37,10 +37,10 @@
<button class="login_button" type="submit">Login</button>
</div>
<div class="fpass_area">
<a href="{{url_for('login.forgot_password')}}">Forgot password?</a>
<a class="fpass_text" href="{{url_for('login.forgot_password')}}">Forgot password?</a>
</div>
<div class="cacc_area">
<a href="{{url_for('login.create_account')}}">Create Account</a>
<a class="cacc_text" href="{{url_for('login.create_account')}}">Create Account</a>
</div>
</div>
</form>
@@ -9,7 +9,7 @@

<!-- CSS -->
{% block css %}
<link href="{{ url_for('static', filename='css/main_index.css') }}" rel="stylesheet" />
<link href="{{ url_for('static', filename='css/main/index.css') }}" rel="stylesheet" />
{% endblock %}

<!-- BUTTON -->
@@ -6,15 +6,15 @@
{% block js %}

<script src="https://openlayers.org/en/v4.6.5/build/ol.js" type="text/javascript"></script>
<script type="text/javascript" src="{{ url_for('static', filename='js/test.js') }}"></script>
<script type="text/javascript" src="{{ url_for('static', filename='js/map/test.js') }}"></script>

{% endblock %}

<!-- CSS -->
{% block css %}

<link rel="stylesheet" href="https://openlayers.org/en/v4.6.5/css/ol.css" type="text/css">
<link href="{{ url_for('static', filename='css/map_index.css') }}" rel="stylesheet" />
<link rel="stylesheet" type="text/css" href="https://openlayers.org/en/v4.6.5/css/ol.css"/>
<link rel="stylesheet" href="{{ url_for('static', filename='css/map/index.css') }}"/>

{% endblock %}

0 comments on commit 740c050

Please sign in to comment.