From 2db7892e1f6dd7f3b9f2ac2c3315b4d3986654b2 Mon Sep 17 00:00:00 2001 From: Lind <159945592+MrAlLind@users.noreply.github.com> Date: Thu, 23 Jan 2025 20:45:07 +0100 Subject: [PATCH] Made it possible to reteroactively mark/unmark a recipt as digital (#219) Co-authored-by: alfredfl --- expenses/views.py | 1 + templates/expenses/edit.html | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/expenses/views.py b/expenses/views.py index 514d89f..9540de4 100644 --- a/expenses/views.py +++ b/expenses/views.py @@ -124,6 +124,7 @@ def edit_expense(request, pk): expense.description = request.POST['description'] expense.expense_date = request.POST['expense_date'] + expense.is_digital = 'is-digital' in request.POST expense.save() new_ids = [] diff --git a/templates/expenses/edit.html b/templates/expenses/edit.html index 795c25e..cee0a09 100644 --- a/templates/expenses/edit.html +++ b/templates/expenses/edit.html @@ -60,6 +60,24 @@ +
+ + + + +
+ +
+

Klicka i denna om originalformatet av kvittot är digitalt.

+

Kvittodelar