1
0
Fork 0
mirror of https://github.com/Lynnesbian/FediBooks/ synced 2024-11-05 08:08:59 +00:00
FediBooks/webui.py

33 lines
718 B
Python
Raw Normal View History

from flask import Flask, render_template, session
2019-08-27 10:36:54 +00:00
app = Flask(__name__)
app.secret_key = "debug key"
2019-08-27 10:36:54 +00:00
@app.route("/")
def hello():
session['userid'] = 1
if 'userid' in session:
return render_template("home.html")
else:
return render_template("front_page.html")
2019-08-29 01:15:47 +00:00
@app.route("/welcome")
def welcome():
return render_template("welcome.html")
@app.route("/login")
def show_login_page():
2019-08-29 05:08:11 +00:00
return render_template("login.html", signup = False)
@app.route("/signup")
def show_signup_page():
return render_template("login.html", signup = True)
2019-08-29 13:51:31 +00:00
2019-08-30 03:56:28 +00:00
@app.route("/settings")
def settings():
return render_template("settings.html")
2019-08-29 13:51:31 +00:00
@app.route("/bot/edit/<id>")
def bot_edit(id):
return render_template("bot_edit.html")