paginacja paragonow
This commit is contained in:
8
app.py
8
app.py
@@ -52,7 +52,7 @@ from functools import wraps
|
||||
from flask_session import Session
|
||||
from types import SimpleNamespace
|
||||
from pdf2image import convert_from_bytes
|
||||
|
||||
from urllib.parse import urlencode
|
||||
|
||||
# OCR
|
||||
import pytesseract
|
||||
@@ -2435,7 +2435,8 @@ def admin_receipts(id):
|
||||
return redirect(url_for("admin_panel"))
|
||||
|
||||
args_without_page = request.args.to_dict()
|
||||
args_without_page.pop('page', None)
|
||||
args_without_page.pop("page", None)
|
||||
query_string = urlencode(args_without_page)
|
||||
|
||||
return render_template(
|
||||
"admin/receipts.html",
|
||||
@@ -2445,10 +2446,11 @@ def admin_receipts(id):
|
||||
page=page,
|
||||
total_pages=total_pages,
|
||||
id=id,
|
||||
args_without_page=args_without_page,
|
||||
query_string=query_string
|
||||
)
|
||||
|
||||
|
||||
|
||||
@app.route("/admin/rotate_receipt/<int:receipt_id>")
|
||||
@login_required
|
||||
@admin_required
|
||||
|
Reference in New Issue
Block a user