From e19433c46f4a112efc0a81904dbdabd9aa789324 Mon Sep 17 00:00:00 2001 From: "Jacob V. Rasmussen" Date: Wed, 19 Nov 2025 20:08:01 +0100 Subject: [PATCH] Remove name and email from expense and revenue lists This aligns all printouts of user real names. Some instances printed the email and some the UUID. The detail pages now always prints the real name, and the UUID. If the user does not have a real name, the UUID is shown as a fallback option, instead of presenting an empty cell. All real names have been removed from the economy app, and will only be shown in the backoffice app. --- .../templates/includes/expense_detail_panel.html | 12 +++++++----- .../templates/includes/expense_list_panel.html | 16 ++++++++++------ .../includes/reimbursement_detail_panel.html | 4 ++-- .../templates/includes/revenue_detail_panel.html | 10 ++++++---- .../templates/includes/revenue_list_panel.html | 8 ++++++-- 5 files changed, 31 insertions(+), 19 deletions(-) diff --git a/src/economy/templates/includes/expense_detail_panel.html b/src/economy/templates/includes/expense_detail_panel.html index c525a3447..8034228e1 100644 --- a/src/economy/templates/includes/expense_detail_panel.html +++ b/src/economy/templates/includes/expense_detail_panel.html @@ -2,10 +2,12 @@
Expense Details for {{ expense.pk }}
- - - - + {% if request.resolver_match.app_name == "backoffice" %} + + + + + {% endif %} @@ -28,7 +30,7 @@ - + diff --git a/src/economy/templates/includes/expense_list_panel.html b/src/economy/templates/includes/expense_list_panel.html index 31767e7b7..6ed214a52 100644 --- a/src/economy/templates/includes/expense_list_panel.html +++ b/src/economy/templates/includes/expense_list_panel.html @@ -8,9 +8,11 @@ {% endif %} - - {% if not reimbursement %} - + {% if request.resolver_match.app_name == "backoffice" %} + + {% if not reimbursement %} + + {% endif %} {% endif %} @@ -34,9 +36,11 @@ {% endif %} - - {% if not reimbursement %} - + {% if request.resolver_match.app_name == "backoffice" %} + + {% if not reimbursement %} + + {% endif %} {% endif %} diff --git a/src/economy/templates/includes/reimbursement_detail_panel.html b/src/economy/templates/includes/reimbursement_detail_panel.html index 3b2f05963..5c769d345 100644 --- a/src/economy/templates/includes/reimbursement_detail_panel.html +++ b/src/economy/templates/includes/reimbursement_detail_panel.html @@ -5,11 +5,11 @@
Created By{{ expense.user.profile.get_name }}
Created By{{ expense.user.profile.get_name }}
Amount {{ expense.amount }} DKK
Paid by BornHack?This expense was paid by {% if expense.paid_by_bornhack %}BornHack{% else %}{{ expense.user.profile.get_name }}, and will be reimbursed.{% endif %}This expense was paid by {% if expense.paid_by_bornhack %}BornHack{% elif request.resolver_match.app_name == "backoffice" %}{{ expense.user.profile.get_name }}, and will be reimbursed.{% else %}the creator of the expense{% endif %}
FilenameCampInvoice DateCreated ByPaid byCreated ByPaid byCreditor Amount{{ expense.camp.title }}{{ expense.invoice_date }}{{ expense.user.profile.get_name }}{% if expense.paid_by_bornhack %}BornHack{% else %}{{ expense.user.profile.get_name }}{% endif %}{{ expense.user.profile.get_name }}{% if expense.paid_by_bornhack %}BornHack{% else %}{{ expense.user.profile.get_name }}{% endif %}{{ expense.creditor.name }} {{ expense.amount }} DKK
- + - + diff --git a/src/economy/templates/includes/revenue_detail_panel.html b/src/economy/templates/includes/revenue_detail_panel.html index f80d9bc63..39350e108 100644 --- a/src/economy/templates/includes/revenue_detail_panel.html +++ b/src/economy/templates/includes/revenue_detail_panel.html @@ -2,10 +2,12 @@
Revenue Details for {{ revenue.pk }}
Reimbursement User{{ reimbursement.reimbursement_user }}{{ reimbursement.reimbursement_user.profile.get_name }}
Created By{{ reimbursement.user }}{{ reimbursement.user.profile.get_name }}
Total Amount
- - - - + {% if request.resolver_match.app_name == "backoffice" %} + + + + + {% endif %} diff --git a/src/economy/templates/includes/revenue_list_panel.html b/src/economy/templates/includes/revenue_list_panel.html index 1ce389265..702766aee 100644 --- a/src/economy/templates/includes/revenue_list_panel.html +++ b/src/economy/templates/includes/revenue_list_panel.html @@ -8,7 +8,9 @@ {% endif %} - + {% if request.resolver_match.app_name == "backoffice" %} + + {% endif %} @@ -25,7 +27,9 @@ {% endif %} - + {% if request.resolver_match.app_name == "backoffice" %} + + {% endif %}
Created By{{ revenue.user }}
Created By{{ revenue.user.profile.get_name }}
Amount {{ revenue.amount }} DKKCampInvoice DateCreated ByCreated ByDebtor Amount Description{{ revenue.camp.title }}{{ revenue.invoice_date }}{{ revenue.user.email }}{{ revenue.user.profile.get_name }}{{ revenue.debtor }} {{ revenue.amount }} DKK {{ revenue.description }}