Initial Commit für das Grundgerüst der Anwendung, bestehend aus der Dev-Container Konfiguration, der Docker und docker-Compose Definitionen sowie der Verzeichnisse App_Server für die Backend-Programme sowie Client für die browserseitigen GUI-Komponenten
This commit is contained in:
1 parent
10549934ea
commit
1ba78992a6
63 files changed
+5410
No files matched your search
@@ -0,0 +1,33 @@
|
||||
from flask import current_app as app, render_template, jsonify
|
||||
from datetime import datetime
|
||||
from flask_login import login_required
|
||||
|
||||
|
||||
@app.route("/")
|
||||
@app.route("/index.html")
|
||||
def index():
|
||||
scriptfile = "{0}_{1}.js".format(app.config["PROJEKTNAME"], app.config["APPVERSION"])
|
||||
if app.config["DEBUG"] is False:
|
||||
scriptfile = scriptfile.replace(".js", ".min.js")
|
||||
return render_template(
|
||||
"index.html",
|
||||
apptitle = app.config["PROJEKTNAME"],
|
||||
scriptfile = scriptfile
|
||||
)
|
||||
|
||||
@app.route("/xhr/health-check")
|
||||
def health_check():
|
||||
zeit = datetime.now().isoformat()
|
||||
result = {
|
||||
'result': "success",
|
||||
'time': zeit,
|
||||
'server': "n/a", #_server,
|
||||
'projectname': "n/a", #_projektname,
|
||||
'clientappversion': "N/A" #_version
|
||||
}
|
||||
return result # https://flask.palletsprojects.com/en/3.0.x/quickstart/#about-responses
|
||||
|
||||
@app.route("/xhr/getinfo")
|
||||
@login_required
|
||||
def get_info():
|
||||
return {"info": "pustekuchen"}
|
||||
Reference in new issue
Block a user