From f1926ffd990d1a8e8839ea51b9f27b392c589472 Mon Sep 17 00:00:00 2001 From: Dita Aji Pratama Date: Thu, 26 Sep 2024 12:38:31 +0700 Subject: [PATCH] Route dashboard --- app/handler.py | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/app/handler.py b/app/handler.py index b3268d3..9c5ba20 100644 --- a/app/handler.py +++ b/app/handler.py @@ -117,6 +117,33 @@ def index(): else: redirect('/') +@app.route('/dashboard') +def index(): + params = { + "mako" : { + "website" : template_dashboard.main(directory.page["dashboard"], "dashboard") + } + } + return dashboard_dashboard.dashboard().html(params) + +@app.route('/dashboard/roles') +def index(): + params = { + "mako" : { + "website" : template_dashboard.main(directory.page["dashboard"], "roles") + } + } + return dashboard_roles.roles().html(params) + +@app.route('/dashboard/users') +def index(): + params = { + "mako" : { + "website" : template_dashboard.main(directory.page["dashboard"], "users") + } + } + return dashboard_users.users().html(params) + @app.route('/api/auth/registration/register/', method='POST') def index(roles): try: