Убрано по причине "JSON"

This commit is contained in:
Anton Kamalov
2024-10-22 23:58:45 +03:00
parent f73da1f31b
commit 9db4a79364
3 changed files with 2 additions and 9 deletions

View File

@@ -13,9 +13,7 @@ app.register_blueprint(auth_bp, url_prefix='/auth')
@app.route('/')
def index():
with open(path.join(path.dirname(__file__), 'menu.json')) as f:
urls = json.load(f)
return render_template('main_menu.html', menu=urls, ses=session)
return render_template('main_menu.html', ses=session)
@app.route('/logout')
@check_auth

View File

@@ -1,3 +0,0 @@
[
{"name": "Меню запросов", "url": "requests_bp.sklad_zapros"}
]

View File

@@ -12,9 +12,7 @@
{% else %}
<a href="{{ url_for('auth_bp.auth') }}">Авторизация</a>
{% endif %}
{% for point in menu %}
<a href="{{ url_for(point['url']) }}">{{ point['name'] }}</a>
{% endfor %}
<a href="{{ url_for('requests_bp.requests') }}">Запросы</a>
</nav>
</body>
</html>