#86 Edit deductions

* adds support for editing deductions
* adds tests
* improves major base test logic
This commit is contained in:
2022-02-09 14:49:56 +01:00
parent 78b4dce64d
commit 59f28fbf12
20 changed files with 524 additions and 290 deletions

View File

@@ -5,7 +5,7 @@
#
#: compensation/filters.py:122 compensation/forms/modalForms.py:35
#: compensation/forms/modalForms.py:46 compensation/forms/modalForms.py:62
#: compensation/forms/modalForms.py:329 compensation/forms/modalForms.py:422
#: compensation/forms/modalForms.py:332 compensation/forms/modalForms.py:425
#: intervention/forms/forms.py:54 intervention/forms/forms.py:156
#: intervention/forms/forms.py:168 intervention/forms/modalForms.py:124
#: intervention/forms/modalForms.py:137 intervention/forms/modalForms.py:150
@@ -26,7 +26,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-02-09 09:50+0100\n"
"POT-Creation-Date: 2022-02-09 12:52+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -95,7 +95,7 @@ msgstr ""
#: analysis/templates/analysis/reports/includes/eco_account/amount.html:3
#: analysis/templates/analysis/reports/includes/intervention/amount.html:3
#: analysis/templates/analysis/reports/includes/old_data/amount.html:3
#: compensation/forms/modalForms.py:406
#: compensation/forms/modalForms.py:409
#: compensation/templates/compensation/detail/eco_account/includes/deductions.html:34
#: intervention/templates/intervention/detail/includes/deductions.html:31
msgid "Amount"
@@ -213,7 +213,7 @@ msgstr "Abbuchungen"
#: analysis/templates/analysis/reports/includes/eco_account/deductions.html:9
#: analysis/templates/analysis/reports/includes/eco_account/deductions.html:11
#: compensation/forms/modalForms.py:190
#: compensation/forms/modalForms.py:193
#: compensation/templates/compensation/detail/compensation/includes/states-after.html:36
#: compensation/templates/compensation/detail/compensation/includes/states-before.html:36
#: compensation/templates/compensation/detail/eco_account/includes/states-after.html:36
@@ -353,7 +353,7 @@ msgid "Compensation XY; Location ABC"
msgstr "Kompensation XY; Flur ABC"
#: compensation/forms/forms.py:57 compensation/forms/modalForms.py:61
#: compensation/forms/modalForms.py:328 compensation/forms/modalForms.py:421
#: compensation/forms/modalForms.py:331 compensation/forms/modalForms.py:424
#: compensation/templates/compensation/detail/compensation/includes/actions.html:35
#: compensation/templates/compensation/detail/compensation/includes/deadlines.html:34
#: compensation/templates/compensation/detail/compensation/includes/documents.html:31
@@ -371,7 +371,7 @@ msgstr "Kompensation XY; Flur ABC"
msgid "Comment"
msgstr "Kommentar"
#: compensation/forms/forms.py:59 compensation/forms/modalForms.py:423
#: compensation/forms/forms.py:59 compensation/forms/modalForms.py:426
#: intervention/forms/forms.py:182
msgid "Additional comment"
msgstr "Zusätzlicher Kommentar"
@@ -457,7 +457,7 @@ msgstr "Vereinbarungsdatum"
msgid "When did the parties agree on this?"
msgstr "Wann wurde dieses Ökokonto offiziell vereinbart?"
#: compensation/forms/forms.py:354 compensation/views/eco_account.py:103
#: compensation/forms/forms.py:354 compensation/views/eco_account.py:105
msgid "New Eco-Account"
msgstr "Neues Ökokonto"
@@ -482,7 +482,7 @@ msgstr "Fällig am"
msgid "Due on which date"
msgstr "Zahlung wird an diesem Datum erwartet"
#: compensation/forms/modalForms.py:63 compensation/forms/modalForms.py:330
#: compensation/forms/modalForms.py:63 compensation/forms/modalForms.py:333
#: intervention/forms/modalForms.py:151 konova/forms.py:393
msgid "Additional comment, maximum {} letters"
msgstr "Zusätzlicher Kommentar, maximal {} Zeichen"
@@ -495,47 +495,47 @@ msgstr "Neue Ersatzzahlung zu Eingriff '{}' hinzufügen"
msgid "If there is no date you can enter, please explain why."
msgstr "Falls Sie kein Datum angeben können, erklären Sie bitte weshalb."
#: compensation/forms/modalForms.py:154 compensation/forms/modalForms.py:166
#: compensation/forms/modalForms.py:157 compensation/forms/modalForms.py:169
msgid "Biotope Type"
msgstr "Biotoptyp"
#: compensation/forms/modalForms.py:157
#: compensation/forms/modalForms.py:160
msgid "Select the biotope type"
msgstr "Biotoptyp wählen"
#: compensation/forms/modalForms.py:171 compensation/forms/modalForms.py:183
#: compensation/forms/modalForms.py:174 compensation/forms/modalForms.py:186
msgid "Biotope additional type"
msgstr "Zusatzbezeichnung"
#: compensation/forms/modalForms.py:174
#: compensation/forms/modalForms.py:177
msgid "Select an additional biotope type"
msgstr "Zusatzbezeichnung wählen"
#: compensation/forms/modalForms.py:193 intervention/forms/modalForms.py:313
#: compensation/forms/modalForms.py:196 intervention/forms/modalForms.py:313
msgid "in m²"
msgstr ""
#: compensation/forms/modalForms.py:204
#: compensation/forms/modalForms.py:207
msgid "New state"
msgstr "Neuer Zustand"
#: compensation/forms/modalForms.py:205
#: compensation/forms/modalForms.py:208
msgid "Insert data for the new state"
msgstr "Geben Sie die Daten des neuen Zustandes ein"
#: compensation/forms/modalForms.py:212 konova/forms.py:191
#: compensation/forms/modalForms.py:215 konova/forms.py:191
msgid "Object removed"
msgstr "Objekt entfernt"
#: compensation/forms/modalForms.py:300
#: compensation/forms/modalForms.py:303
msgid "Deadline Type"
msgstr "Fristart"
#: compensation/forms/modalForms.py:303
#: compensation/forms/modalForms.py:306
msgid "Select the deadline type"
msgstr "Fristart wählen"
#: compensation/forms/modalForms.py:312
#: compensation/forms/modalForms.py:315
#: compensation/templates/compensation/detail/compensation/includes/deadlines.html:31
#: compensation/templates/compensation/detail/eco_account/includes/deadlines.html:31
#: ema/templates/ema/detail/includes/deadlines.html:31
@@ -543,27 +543,27 @@ msgstr "Fristart wählen"
msgid "Date"
msgstr "Datum"
#: compensation/forms/modalForms.py:315
#: compensation/forms/modalForms.py:318
msgid "Select date"
msgstr "Datum wählen"
#: compensation/forms/modalForms.py:342
#: compensation/forms/modalForms.py:345
msgid "New deadline"
msgstr "Neue Frist"
#: compensation/forms/modalForms.py:343
#: compensation/forms/modalForms.py:346
msgid "Insert data for the new deadline"
msgstr "Geben Sie die Daten der neuen Frist ein"
#: compensation/forms/modalForms.py:360
#: compensation/forms/modalForms.py:363
msgid "Action Type"
msgstr "Maßnahmentyp"
#: compensation/forms/modalForms.py:363
#: compensation/forms/modalForms.py:366
msgid "Select the action type"
msgstr "Maßnahmentyp wählen"
#: compensation/forms/modalForms.py:372
#: compensation/forms/modalForms.py:375
#: compensation/templates/compensation/detail/compensation/includes/actions.html:40
#: compensation/templates/compensation/detail/compensation/includes/deadlines.html:39
#: compensation/templates/compensation/detail/compensation/includes/documents.html:36
@@ -589,31 +589,31 @@ msgstr "Maßnahmentyp wählen"
msgid "Action"
msgstr "Aktionen"
#: compensation/forms/modalForms.py:377 compensation/forms/modalForms.py:389
#: compensation/forms/modalForms.py:380 compensation/forms/modalForms.py:392
msgid "Action Type detail"
msgstr "Zusatzmerkmal"
#: compensation/forms/modalForms.py:380
#: compensation/forms/modalForms.py:383
msgid "Select the action type detail"
msgstr "Zusatzmerkmal wählen"
#: compensation/forms/modalForms.py:394
#: compensation/forms/modalForms.py:397
msgid "Unit"
msgstr "Einheit"
#: compensation/forms/modalForms.py:397
#: compensation/forms/modalForms.py:400
msgid "Select the unit"
msgstr "Einheit wählen"
#: compensation/forms/modalForms.py:409
#: compensation/forms/modalForms.py:412
msgid "Insert the amount"
msgstr "Menge eingeben"
#: compensation/forms/modalForms.py:434
#: compensation/forms/modalForms.py:437
msgid "New action"
msgstr "Neue Maßnahme"
#: compensation/forms/modalForms.py:435
#: compensation/forms/modalForms.py:438
msgid "Insert data for the new action"
msgstr "Geben Sie die Daten der neuen Maßnahme ein"
@@ -992,7 +992,7 @@ msgid "Recorded on"
msgstr "Verzeichnet am"
#: compensation/templates/compensation/detail/eco_account/includes/deductions.html:65
#: intervention/templates/intervention/detail/includes/deductions.html:60
#: intervention/templates/intervention/detail/includes/deductions.html:63
msgid "Remove Deduction"
msgstr "Abbuchung entfernen"
@@ -1084,63 +1084,63 @@ msgstr "Kompensationen - Übersicht"
msgid "Compensation {} edited"
msgstr "Kompensation {} bearbeitet"
#: compensation/views/compensation.py:159 compensation/views/eco_account.py:161
#: compensation/views/compensation.py:159 compensation/views/eco_account.py:163
#: ema/views.py:230 intervention/views.py:305
msgid "Edit {}"
msgstr "Bearbeite {}"
#: compensation/views/compensation.py:238 compensation/views/eco_account.py:317
#: compensation/views/compensation.py:238 compensation/views/eco_account.py:347
#: ema/views.py:191 intervention/views.py:483
msgid "Log"
msgstr "Log"
#: compensation/views/compensation.py:487 compensation/views/eco_account.py:590
#: ema/views.py:477 intervention/views.py:601
#: compensation/views/compensation.py:487 compensation/views/eco_account.py:620
#: ema/views.py:477 intervention/views.py:629
msgid "Report {}"
msgstr "Bericht {}"
#: compensation/views/eco_account.py:60
#: compensation/views/eco_account.py:62
msgid "Eco-account - Overview"
msgstr "Ökokonten - Übersicht"
#: compensation/views/eco_account.py:93
#: compensation/views/eco_account.py:95
msgid "Eco-Account {} added"
msgstr "Ökokonto {} hinzugefügt"
#: compensation/views/eco_account.py:151
#: compensation/views/eco_account.py:153
msgid "Eco-Account {} edited"
msgstr "Ökokonto {} bearbeitet"
#: compensation/views/eco_account.py:264
#: compensation/views/eco_account.py:266
msgid "Eco-account removed"
msgstr "Ökokonto entfernt"
#: compensation/views/eco_account.py:338 ema/views.py:272
#: intervention/views.py:554
#: compensation/views/eco_account.py:368 ema/views.py:272
#: intervention/views.py:582
msgid "{} unrecorded"
msgstr "{} entzeichnet"
#: compensation/views/eco_account.py:338 ema/views.py:272
#: intervention/views.py:554
#: compensation/views/eco_account.py:368 ema/views.py:272
#: intervention/views.py:582
msgid "{} recorded"
msgstr "{} verzeichnet"
#: compensation/views/eco_account.py:663 ema/views.py:543
#: compensation/views/eco_account.py:693 ema/views.py:543
#: intervention/views.py:380
msgid "{} has already been shared with you"
msgstr "{} wurde bereits für Sie freigegeben"
#: compensation/views/eco_account.py:668 ema/views.py:548
#: compensation/views/eco_account.py:698 ema/views.py:548
#: intervention/views.py:385
msgid "{} has been shared with you"
msgstr "{} ist nun für Sie freigegeben"
#: compensation/views/eco_account.py:675 ema/views.py:555
#: compensation/views/eco_account.py:705 ema/views.py:555
#: intervention/views.py:392
msgid "Share link invalid"
msgstr "Freigabelink ungültig"
#: compensation/views/eco_account.py:698 ema/views.py:578
#: compensation/views/eco_account.py:728 ema/views.py:578
#: intervention/views.py:415
msgid "Share settings updated"
msgstr "Freigabe Einstellungen aktualisiert"
@@ -1337,7 +1337,7 @@ msgstr "Neue Abbuchung"
msgid "Enter the information for a new deduction from a chosen eco-account"
msgstr "Geben Sie die Informationen für eine neue Abbuchung ein."
#: intervention/forms/modalForms.py:366
#: intervention/forms/modalForms.py:381
msgid ""
"Eco-account {} is not recorded yet. You can only deduct from recorded "
"accounts."
@@ -1345,7 +1345,7 @@ msgstr ""
"Ökokonto {} ist noch nicht verzeichnet. Abbuchungen können nur von "
"verzeichneten Ökokonten erfolgen."
#: intervention/forms/modalForms.py:379
#: intervention/forms/modalForms.py:391
msgid ""
"The account {} has not enough surface for a deduction of {} m². There are "
"only {} m² left"
@@ -1373,6 +1373,10 @@ msgstr "Ökokonto gelöscht! Abbuchung ungültig!"
msgid "Eco-account not recorded! Deduction invalid!"
msgstr "Ökokonto nicht verzeichnet! Abbuchung ungültig!"
#: intervention/templates/intervention/detail/includes/deductions.html:60
msgid "Edit Deduction"
msgstr "Abbuchung bearbeiten"
#: intervention/templates/intervention/detail/includes/payments.html:8
#: intervention/templates/intervention/report/report.html:73
msgid "Payments"
@@ -1464,7 +1468,7 @@ msgstr "{} entfernt"
msgid "Check performed"
msgstr "Prüfung durchgeführt"
#: intervention/views.py:559
#: intervention/views.py:587
msgid "There are errors on this intervention:"
msgstr "Es liegen Fehler in diesem Eingriff vor:"
@@ -1824,74 +1828,94 @@ msgid "State removed"
msgstr "Zustand gelöscht"
#: konova/utils/message_templates.py:33
msgid "State edited"
msgstr "Zustand bearbeitet"
#: konova/utils/message_templates.py:34
msgid "State added"
msgstr "Zustand hinzugefügt"
#: konova/utils/message_templates.py:36
#: konova/utils/message_templates.py:37
msgid "Action added"
msgstr "Maßnahme hinzugefügt"
#: konova/utils/message_templates.py:37
#: konova/utils/message_templates.py:38
msgid "Action edited"
msgstr "Maßnahme bearbeitet"
#: konova/utils/message_templates.py:39
msgid "Action removed"
msgstr "Maßnahme entfernt"
#: konova/utils/message_templates.py:40
#: konova/utils/message_templates.py:42
msgid "Deduction added"
msgstr "Abbuchung hinzugefügt"
#: konova/utils/message_templates.py:41
#: konova/utils/message_templates.py:43
msgid "Deduction edited"
msgstr "Abbuchung bearbeitet"
#: konova/utils/message_templates.py:44
msgid "Deduction removed"
msgstr "Abbuchung entfernt"
#: konova/utils/message_templates.py:44
#: konova/utils/message_templates.py:47
msgid "Deadline added"
msgstr "Frist/Termin hinzugefügt"
#: konova/utils/message_templates.py:45
#: konova/utils/message_templates.py:48
msgid "Deadline edited"
msgstr "Frist/Termin bearbeitet"
#: konova/utils/message_templates.py:49
msgid "Deadline removed"
msgstr "Frist/Termin gelöscht"
#: konova/utils/message_templates.py:48
#: konova/utils/message_templates.py:52
msgid "Payment added"
msgstr "Zahlung hinzugefügt"
#: konova/utils/message_templates.py:49
#: konova/utils/message_templates.py:53
msgid "Payment edited"
msgstr "Zahlung bearbeitet"
#: konova/utils/message_templates.py:50
#: konova/utils/message_templates.py:54
msgid "Payment removed"
msgstr "Zahlung gelöscht"
#: konova/utils/message_templates.py:53
#: konova/utils/message_templates.py:57
msgid "Revocation added"
msgstr "Widerspruch hinzugefügt"
#: konova/utils/message_templates.py:54
#: konova/utils/message_templates.py:58
msgid "Revocation edited"
msgstr "Widerspruch bearbeitet"
#: konova/utils/message_templates.py:59
msgid "Revocation removed"
msgstr "Widerspruch entfernt"
#: konova/utils/message_templates.py:57
#: konova/utils/message_templates.py:62
msgid "Document '{}' deleted"
msgstr "Dokument '{}' gelöscht"
#: konova/utils/message_templates.py:58
#: konova/utils/message_templates.py:63
msgid "Document added"
msgstr "Dokument hinzugefügt"
#: konova/utils/message_templates.py:61
#: konova/utils/message_templates.py:66
msgid "Edited general data"
msgstr "Allgemeine Daten bearbeitet"
#: konova/utils/message_templates.py:62
#: konova/utils/message_templates.py:67
msgid "Added deadline"
msgstr "Frist/Termin hinzugefügt"
#: konova/utils/message_templates.py:65
#: konova/utils/message_templates.py:70
msgid "Geometry conflict detected with {}"
msgstr "Geometriekonflikt mit folgenden Einträgen erkannt: {}"
#: konova/utils/message_templates.py:68
#: konova/utils/message_templates.py:73
msgid "This intervention has {} revocations"
msgstr "Dem Eingriff liegen {} Widersprüche vor"