Compare commits
No commits in common. "b781ebe8cf1aaf3809d2e494fc44777aa9417060" and "860483152849172f76793dbad0c50a6228cc69d7" have entirely different histories.
b781ebe8cf
...
8604831528
1
.gitignore
vendored
1
.gitignore
vendored
@ -2,4 +2,3 @@ __pycache__/
|
|||||||
*.py[cod]
|
*.py[cod]
|
||||||
*$py.class
|
*$py.class
|
||||||
cache/
|
cache/
|
||||||
push_to_server.sh
|
|
11
app.py
11
app.py
@ -19,7 +19,6 @@ from flask import Flask
|
|||||||
from flask import render_template
|
from flask import render_template
|
||||||
from flask import url_for
|
from flask import url_for
|
||||||
from flask import request
|
from flask import request
|
||||||
from flask.helpers import make_response
|
|
||||||
|
|
||||||
# Fichiers locaux :
|
# Fichiers locaux :
|
||||||
import date_tools
|
import date_tools
|
||||||
@ -34,8 +33,7 @@ GLOBAL_CONTEXT = {} # Contexte constant pour les templates Jinja
|
|||||||
GLOBAL_CONTEXT["SOURCE"] = "https://forge.chapril.org/Wantoo/UniSquat_Python" # Le lien du code source
|
GLOBAL_CONTEXT["SOURCE"] = "https://forge.chapril.org/Wantoo/UniSquat_Python" # Le lien du code source
|
||||||
GLOBAL_CONTEXT["CREDITSLINK"] = "https://forge.chapril.org/Wantoo" # Le lien de l'organisation
|
GLOBAL_CONTEXT["CREDITSLINK"] = "https://forge.chapril.org/Wantoo" # Le lien de l'organisation
|
||||||
GLOBAL_CONTEXT["CREDITSNAME"] = "Wantoo" # Le nom de l'organisation
|
GLOBAL_CONTEXT["CREDITSNAME"] = "Wantoo" # Le nom de l'organisation
|
||||||
GLOBAL_CONTEXT["DEBUG"] = False # Fait en sorte que le logiciel soit un peu plus expressif
|
GLOBAL_CONTEXT["DEBUG"] = True # Fait en sorte que le logiciel soit un peu plus expressif
|
||||||
GLOBAL_CONTEXT["DOMAIN"] = "https://unisquat.alwaysdata.net" # Le domaine sur lequel est host l'instance
|
|
||||||
|
|
||||||
# Globales
|
# Globales
|
||||||
logs = [] # Stoque les différentes requêtes faite sur la route /free_rooms/, sous la forme {"timestamp":timestamp,"depts":[]}
|
logs = [] # Stoque les différentes requêtes faite sur la route /free_rooms/, sous la forme {"timestamp":timestamp,"depts":[]}
|
||||||
@ -312,13 +310,6 @@ def date_select() :
|
|||||||
|
|
||||||
return render_template("date-select.html", **context, **GLOBAL_CONTEXT)
|
return render_template("date-select.html", **context, **GLOBAL_CONTEXT)
|
||||||
|
|
||||||
@app.route("/sitemap.xml")
|
|
||||||
def sitemap():
|
|
||||||
sitemap_xml = render_template("sitemap.xml", **GLOBAL_CONTEXT)
|
|
||||||
response= make_response(sitemap_xml)
|
|
||||||
response.headers["Content-Type"] = "application/xml"
|
|
||||||
return response
|
|
||||||
|
|
||||||
|
|
||||||
@app.errorhandler(404)
|
@app.errorhandler(404)
|
||||||
def error(e):
|
def error(e):
|
||||||
|
@ -1,7 +0,0 @@
|
|||||||
data
|
|
||||||
static
|
|
||||||
templates
|
|
||||||
app.py
|
|
||||||
date_tools.py
|
|
||||||
objects.py
|
|
||||||
rooms_get.py
|
|
@ -1,18 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
|
|
||||||
<url>
|
|
||||||
<loc>{{DOMAIN}}</loc>
|
|
||||||
<changefreq>monthly</changefreq>
|
|
||||||
<priority>1</priority>
|
|
||||||
</url>
|
|
||||||
<url>
|
|
||||||
<loc>{{DOMAIN}}/app</loc>
|
|
||||||
<changefreq>monthly</changefreq>
|
|
||||||
<priority>1</priority>
|
|
||||||
</url>
|
|
||||||
<url>
|
|
||||||
<loc>{{DOMAIN}}/stats</loc>
|
|
||||||
<changefreq>daily</changefreq>
|
|
||||||
<priority>0.5</priority>
|
|
||||||
</url>
|
|
||||||
</urlset>
|
|
Loading…
Reference in New Issue
Block a user