From 48ec45708aed835d616a19c65efa5b69646cee52 Mon Sep 17 00:00:00 2001 From: Anton Kamalov Date: Thu, 24 Oct 2024 12:08:00 +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=D1=81=D1=82=D1=80=D1=83=D0=BA=D1=82=D1=83=D1=80?= =?UTF-8?q?=D1=8B=20=D0=B2=D1=8B=D0=B4=D0=B0=D1=87=D0=B8=20=D1=80=D0=B5?= =?UTF-8?q?=D0=B7=D1=83=D0=BB=D1=8C=D1=82=D0=B0=D1=82=D0=BE=D0=B2=20=D0=B7?= =?UTF-8?q?=D0=B0=D0=BF=D1=80=D0=BE=D1=81=D0=B0=20=D1=81=20=D0=BC=D0=B0?= =?UTF-8?q?=D1=82=D0=B5=D1=80=D0=B8=D0=B0=D0=BB=D0=B0=D0=BC=D0=B8=20=D0=B7?= =?UTF-8?q?=D0=B0=D0=B3=D0=BE=D1=82=D0=BE=D0=B2=D0=BE=D0=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- App/Requests/requests.py | 5 +++-- App/Requests/sql/zapros1.sql | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/App/Requests/requests.py b/App/Requests/requests.py index aa9e016..bbc3ba3 100644 --- a/App/Requests/requests.py +++ b/App/Requests/requests.py @@ -32,7 +32,8 @@ def sklad_zapros(): material = dict(request.form) zagotovki = route(session['db_config'], material, sql_provider, 'zapros1.sql') if zagotovki.status: - categories = ['Материал', 'Вес', 'Цена', 'Количество'] - return render_template('output.html', items=zagotovki.result, titles = categories, object='Заготовки на складе') + categories = ['Вес (в кг.)', 'Цена (в руб.)', 'Количество', 'Дата последнего обновления'] + header = f'Заготовки на складе из материала \'{material["material"]}\'' + return render_template('output.html', items=zagotovki.result, titles = categories, object=header) else: return zagotovki.error_message \ No newline at end of file diff --git a/App/Requests/sql/zapros1.sql b/App/Requests/sql/zapros1.sql index d07bc9d..d2986ef 100644 --- a/App/Requests/sql/zapros1.sql +++ b/App/Requests/sql/zapros1.sql @@ -1,3 +1,3 @@ -SELECT material, weight, price, count +SELECT weight, price, count, last_update FROM workpiece WHERE material = '${material}' \ No newline at end of file