From c4ad849fb3c4ccfde19779657defc2ef29fbf1be Mon Sep 17 00:00:00 2001 From: Anton Kamalov Date: Tue, 5 Nov 2024 22:56:32 +0300 Subject: [PATCH] =?UTF-8?q?=D0=98=D0=B7=D0=BC=D0=B5=D0=BD=D0=B5=D0=BD?= =?UTF-8?q?=D0=B8=D0=B5=20=D0=BF=D1=80=D0=B0=D0=B2=20=D0=B4=D0=BE=D1=81?= =?UTF-8?q?=D1=82=D1=83=D0=BF=D0=B0=20=D0=BA=20=D0=B1=D0=BB=D1=8E=D0=BF?= =?UTF-8?q?=D1=80=D0=B8=D0=BD=D1=82=D0=B0=D0=BC=20+=20=D0=B7=D0=B0=D0=B3?= =?UTF-8?q?=D0=BB=D1=83=D1=88=D0=BA=D0=B0=20=D0=B4=D0=BB=D1=8F=20=D0=BA?= =?UTF-8?q?=D0=B2=D0=B0=D1=80=D1=82=D0=B0=D0=BB=D1=8C=D0=BD=D0=BE=D0=B3?= =?UTF-8?q?=D0=BE=20=D0=BE=D1=82=D1=87=D0=B5=D1=82=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- App/Report/__init__.py | 10 +++++----- App/Report/templates/{quartely.html => quaterly.html} | 0 App/data/db_access.json | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) rename App/Report/templates/{quartely.html => quaterly.html} (100%) diff --git a/App/Report/__init__.py b/App/Report/__init__.py index 9dbf937..068da0c 100644 --- a/App/Report/__init__.py +++ b/App/Report/__init__.py @@ -1,9 +1,9 @@ from flask import request, Blueprint, render_template -from ..checker import check_auth +from checker import check_auth from os import path import json -with open(path.join(path.dirname(__file__), 'zapros_menu.json')) as f: +with open(path.join(path.dirname(__file__), 'reports.json')) as f: report_list = json.load(f) report_bp = Blueprint('report_bp', __name__, template_folder='templates') @@ -14,8 +14,8 @@ def menu(): if request.method == 'GET': return render_template('report_menu.html', options=report_list) -@report_bp.route('/quarterly', methods=['GET', 'POST']) +@report_bp.route('/quaterly', methods=['GET', 'POST']) @check_auth -def quarterly(): +def quaterly(): if request.method == 'GET': - return render_template('quarterly.html') + return render_template('quaterly.html') diff --git a/App/Report/templates/quartely.html b/App/Report/templates/quaterly.html similarity index 100% rename from App/Report/templates/quartely.html rename to App/Report/templates/quaterly.html diff --git a/App/data/db_access.json b/App/data/db_access.json index 0adc917..24d1e7e 100644 --- a/App/data/db_access.json +++ b/App/data/db_access.json @@ -1,5 +1,5 @@ { "Менеджер": ["auth_bp", "requests_bp"], - "Управляющий": ["auth_bp", "requests_bp"], - "Поставщик": ["auth_bp", "requests_bp", "waybill_bp"] + "Управляющий": ["auth_bp", "requests_bp", "report_bp"], + "Поставщик": ["auth_bp", "waybill_bp"] } \ No newline at end of file