From 2b66189590e32a9faeb113446c4883d4b64333ed Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Thu, 10 Feb 2022 14:45:00 +0100 Subject: [PATCH 01/12] #112 WIP: Restructure CompensationAction * changes action_type from ForeignKey into M2M * adds migration * changes form widget * WIP: changes rendering on detail view of compensation * TEST NOT CHECKED YET! --- compensation/forms/modalForms.py | 8 ++-- compensation/managers.py | 11 ------ .../migrations/0004_auto_20220210_1402.py | 39 +++++++++++++++++++ compensation/models/action.py | 10 +---- compensation/models/compensation.py | 2 +- .../detail/compensation/includes/actions.html | 6 ++- .../detail/eco_account/includes/actions.html | 6 ++- .../ema/detail/includes/actions.html | 6 ++- 8 files changed, 61 insertions(+), 27 deletions(-) create mode 100644 compensation/migrations/0004_auto_20220210_1402.py diff --git a/compensation/forms/modalForms.py b/compensation/forms/modalForms.py index 804ebad4..90b0b64c 100644 --- a/compensation/forms/modalForms.py +++ b/compensation/forms/modalForms.py @@ -405,7 +405,7 @@ class NewActionModalForm(BaseModalForm): """ from compensation.models import UnitChoices - action_type = forms.ModelChoiceField( + action_type = forms.ModelMultipleChoiceField( label=_("Action Type"), label_suffix="", required=True, @@ -415,7 +415,7 @@ class NewActionModalForm(BaseModalForm): is_leaf=True, code_lists__in=[CODELIST_COMPENSATION_ACTION_ID], ), - widget=autocomplete.ModelSelect2( + widget=autocomplete.ModelSelect2Multiple( url="codes-compensation-action-autocomplete", attrs={ "data-placeholder": _("Action"), @@ -496,7 +496,7 @@ class EditCompensationActionModalForm(NewActionModalForm): self.action = kwargs.pop("action", None) super().__init__(*args, **kwargs) form_data = { - "action_type": self.action.action_type, + "action_type": self.action.action_type.all(), "action_type_details": self.action.action_type_details.all(), "amount": self.action.amount, "unit": self.action.unit, @@ -506,7 +506,7 @@ class EditCompensationActionModalForm(NewActionModalForm): def save(self): action = self.action - action.action_type = self.cleaned_data.get("action_type", None) + action.action_type.set(self.cleaned_data.get("action_type", [])) action.action_type_details.set(self.cleaned_data.get("action_type_details", [])) action.amount = self.cleaned_data.get("amount", None) action.unit = self.cleaned_data.get("unit", None) diff --git a/compensation/managers.py b/compensation/managers.py index c97cd518..b496eb1e 100644 --- a/compensation/managers.py +++ b/compensation/managers.py @@ -8,17 +8,6 @@ Created on: 14.10.21 from django.db import models -class CompensationActionManager(models.Manager): - """ Holds default db fetch setting for this model type - - """ - def get_queryset(self): - return super().get_queryset().select_related( - "action_type", - "action_type__parent" - ) - - class CompensationStateManager(models.Manager): """ Holds default db fetch setting for this model type diff --git a/compensation/migrations/0004_auto_20220210_1402.py b/compensation/migrations/0004_auto_20220210_1402.py new file mode 100644 index 00000000..44d43cbe --- /dev/null +++ b/compensation/migrations/0004_auto_20220210_1402.py @@ -0,0 +1,39 @@ +# Generated by Django 3.1.3 on 2022-02-10 13:02 + +from django.db import migrations, models + + +def migrate_actions(apps, schema_editor): + CompensationAction = apps.get_model('compensation', 'CompensationAction') + actions = CompensationAction.objects.all() + + for action in actions: + action_type = action.action_type or [] + action.action_type_tmp.set(action_type) + action.save() + + +class Migration(migrations.Migration): + + dependencies = [ + ('codelist', '0001_initial'), + ('compensation', '0003_auto_20220202_0846'), + ] + + operations = [ + migrations.AddField( + model_name='compensationaction', + name='action_type_tmp', + field=models.ManyToManyField(blank=True, limit_choices_to={'code_lists__in': [1026], 'is_archived': False, 'is_selectable': True}, related_name='_compensationaction_action_type_+', to='codelist.KonovaCode'), + ), + migrations.RunPython(migrate_actions), + migrations.RemoveField( + model_name='compensationaction', + name='action_type', + ), + migrations.RenameField( + model_name='compensationaction', + old_name='action_type_tmp', + new_name='action_type', + ) + ] diff --git a/compensation/models/action.py b/compensation/models/action.py index a5579159..e54f53d3 100644 --- a/compensation/models/action.py +++ b/compensation/models/action.py @@ -10,9 +10,7 @@ from django.utils.translation import gettext_lazy as _ from codelist.models import KonovaCode from codelist.settings import CODELIST_COMPENSATION_ACTION_ID, CODELIST_COMPENSATION_ACTION_DETAIL_ID -from compensation.managers import CompensationActionManager from konova.models import BaseResource -from konova.utils.message_templates import COMPENSATION_ACTION_REMOVED class UnitChoices(models.TextChoices): @@ -31,10 +29,8 @@ class CompensationAction(BaseResource): """ Compensations include actions like planting trees, refreshing rivers and so on. """ - action_type = models.ForeignKey( + action_type = models.ManyToManyField( KonovaCode, - on_delete=models.SET_NULL, - null=True, blank=True, limit_choices_to={ "code_lists__in": [CODELIST_COMPENSATION_ACTION_ID], @@ -57,10 +53,8 @@ class CompensationAction(BaseResource): unit = models.CharField(max_length=100, null=True, blank=True, choices=UnitChoices.choices) comment = models.TextField(blank=True, null=True, help_text="Additional comment") - objects = CompensationActionManager() - def __str__(self): - return f"{self.action_type} | {self.amount} {self.unit}" + return f"{self.action_type.all()} | {self.amount} {self.unit}" @property def unit_humanize(self): diff --git a/compensation/models/compensation.py b/compensation/models/compensation.py index 4dd2b4c2..7a10aa0b 100644 --- a/compensation/models/compensation.py +++ b/compensation/models/compensation.py @@ -104,12 +104,12 @@ class AbstractCompensation(BaseObject, GeoReferencedMixin): with transaction.atomic(): user_action = UserActionLogEntry.get_created_action(user) comp_action = CompensationAction.objects.create( - action_type=form_data["action_type"], amount=form_data["amount"], unit=form_data["unit"], comment=form_data["comment"], created=user_action, ) + comp_action.action_type.set(form_data.get("action_type", [])) comp_action_details = form_data["action_type_details"] comp_action.action_type_details.set(comp_action_details) self.actions.add(comp_action) diff --git a/compensation/templates/compensation/detail/compensation/includes/actions.html b/compensation/templates/compensation/detail/compensation/includes/actions.html index 33037ecf..18e9304b 100644 --- a/compensation/templates/compensation/detail/compensation/includes/actions.html +++ b/compensation/templates/compensation/detail/compensation/includes/actions.html @@ -47,7 +47,11 @@ {% for action in actions %} - {{ action.action_type }} + {% if action.action_type_details.count > 0 %}
{% for detail in action.action_type_details.all %} diff --git a/compensation/templates/compensation/detail/eco_account/includes/actions.html b/compensation/templates/compensation/detail/eco_account/includes/actions.html index add698e0..092c5e8d 100644 --- a/compensation/templates/compensation/detail/eco_account/includes/actions.html +++ b/compensation/templates/compensation/detail/eco_account/includes/actions.html @@ -46,7 +46,11 @@ {% for action in actions %} - {{ action.action_type }} + {% if action.action_type_details.count > 0 %}
{% for detail in action.action_type_details.all %} diff --git a/ema/templates/ema/detail/includes/actions.html b/ema/templates/ema/detail/includes/actions.html index 02772b36..9d91caf0 100644 --- a/ema/templates/ema/detail/includes/actions.html +++ b/ema/templates/ema/detail/includes/actions.html @@ -44,7 +44,11 @@ {% for action in obj.actions.all %} - {{ action.action_type }} + {% if action.action_type_details.count > 0 %}
{% for detail in action.action_type_details.all %} From afb78fa670303834637e0769620a1e4f369929f3 Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Fri, 11 Feb 2022 08:43:21 +0100 Subject: [PATCH 02/12] #112 Migration enhance * fixes bug in migration * adds check to migration which raises error before data loss might happen --- compensation/migrations/0004_auto_20220210_1402.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/compensation/migrations/0004_auto_20220210_1402.py b/compensation/migrations/0004_auto_20220210_1402.py index 44d43cbe..7cc8126c 100644 --- a/compensation/migrations/0004_auto_20220210_1402.py +++ b/compensation/migrations/0004_auto_20220210_1402.py @@ -9,9 +9,12 @@ def migrate_actions(apps, schema_editor): for action in actions: action_type = action.action_type or [] - action.action_type_tmp.set(action_type) + action.action_type_tmp.set([action_type]) action.save() + if not action.action_type_tmp.count() > 0: + raise ValueError("Migration of actions did not work! Stoped before data loss!") + class Migration(migrations.Migration): From 62e452c62567064f047e81940487e80131567094 Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Fri, 11 Feb 2022 14:13:42 +0100 Subject: [PATCH 03/12] WIP: CompensationAction using jstree --- compensation/forms/modalForms.py | 20 ++++++--- .../detail/compensation/view.html | 5 +++ .../compensation/detail/eco_account/view.html | 5 +++ ema/templates/ema/detail/view.html | 5 +++ intervention/inputs.py | 15 +++++++ .../widgets/checkbox-tree-select-base.html | 45 +++++++++++++++++++ .../widgets/checkbox-tree-select-content.html | 9 ++++ konova/urls.py | 4 +- konova/views.py | 24 ++++++++++ templates/form/scripts/jstree-scripts.html | 2 + 10 files changed, 126 insertions(+), 8 deletions(-) create mode 100644 konova/templates/konova/widgets/checkbox-tree-select-base.html create mode 100644 konova/templates/konova/widgets/checkbox-tree-select-content.html create mode 100644 templates/form/scripts/jstree-scripts.html diff --git a/compensation/forms/modalForms.py b/compensation/forms/modalForms.py index 90b0b64c..20ff5ddc 100644 --- a/compensation/forms/modalForms.py +++ b/compensation/forms/modalForms.py @@ -11,12 +11,14 @@ from django import forms from django.contrib import messages from django.http import HttpRequest, HttpResponseRedirect from django.shortcuts import render +from django.urls import reverse from django.utils.translation import pgettext_lazy as _con, gettext_lazy as _ from codelist.models import KonovaCode from codelist.settings import CODELIST_BIOTOPES_ID, CODELIST_COMPENSATION_ACTION_ID, CODELIST_BIOTOPES_EXTRA_CODES_ID, \ CODELIST_COMPENSATION_ACTION_DETAIL_ID from compensation.models import CompensationDocument, EcoAccountDocument +from intervention.inputs import TreeSelectMultiple from konova.contexts import BaseContext from konova.forms import BaseModalForm, NewDocumentModalForm, RemoveModalForm from konova.models import DeadlineType @@ -411,15 +413,11 @@ class NewActionModalForm(BaseModalForm): required=True, help_text=_("Select the action type"), queryset=KonovaCode.objects.filter( - is_archived=False, - is_leaf=True, code_lists__in=[CODELIST_COMPENSATION_ACTION_ID], + is_archived=False, ), - widget=autocomplete.ModelSelect2Multiple( - url="codes-compensation-action-autocomplete", - attrs={ - "data-placeholder": _("Action"), - } + widget=TreeSelectMultiple( + url=None, ), ) action_type_details = forms.ModelMultipleChoiceField( @@ -482,6 +480,14 @@ class NewActionModalForm(BaseModalForm): super().__init__(*args, **kwargs) self.form_title = _("New action") self.form_caption = _("Insert data for the new action") + url = reverse("codes-action-children") + self.fields["action_type"].widget.attrs = { + "url": url, + } + + def is_valid(self): + super_valid = super().is_valid() + return super_valid def save(self): action = self.instance.add_action(self) diff --git a/compensation/templates/compensation/detail/compensation/view.html b/compensation/templates/compensation/detail/compensation/view.html index 3f843c0a..17f79bc8 100644 --- a/compensation/templates/compensation/detail/compensation/view.html +++ b/compensation/templates/compensation/detail/compensation/view.html @@ -2,6 +2,11 @@ {% load i18n l10n static fontawesome_5 humanize ksp_filters %} {% block head %} + {% comment %} + Needed for custom Checkbox Tree Select Widget + {% endcomment %} + {% include 'form/scripts/jstree-scripts.html' %} + {% comment %} dal documentation (django-autocomplete-light) states using form.media for adding needed scripts. This does not work properly with modal forms, as the scripts are not loaded properly inside the modal. diff --git a/compensation/templates/compensation/detail/eco_account/view.html b/compensation/templates/compensation/detail/eco_account/view.html index f276f931..132e0b61 100644 --- a/compensation/templates/compensation/detail/eco_account/view.html +++ b/compensation/templates/compensation/detail/eco_account/view.html @@ -2,6 +2,11 @@ {% load i18n l10n static fontawesome_5 humanize %} {% block head %} + {% comment %} + Needed for custom Checkbox Tree Select Widget + {% endcomment %} + {% include 'form/scripts/jstree-scripts.html' %} + {% comment %} dal documentation (django-autocomplete-light) states using form.media for adding needed scripts. This does not work properly with modal forms, as the scripts are not loaded properly inside the modal. diff --git a/ema/templates/ema/detail/view.html b/ema/templates/ema/detail/view.html index 32ddd66b..cdab570d 100644 --- a/ema/templates/ema/detail/view.html +++ b/ema/templates/ema/detail/view.html @@ -2,6 +2,11 @@ {% load i18n l10n static fontawesome_5 humanize %} {% block head %} + {% comment %} + Needed for custom Checkbox Tree Select Widget + {% endcomment %} + {% include 'form/scripts/jstree-scripts.html' %} + {% comment %} dal documentation (django-autocomplete-light) states using form.media for adding needed scripts. This does not work properly with modal forms, as the scripts are not loaded properly inside the modal. diff --git a/intervention/inputs.py b/intervention/inputs.py index 2e84edc5..9cf8e5ab 100644 --- a/intervention/inputs.py +++ b/intervention/inputs.py @@ -1,4 +1,5 @@ from django import forms +from django.urls import reverse class DummyFilterInput(forms.HiddenInput): @@ -30,3 +31,17 @@ class GenerateInput(forms.TextInput): """ template_name = "konova/widgets/generate-content-input.html" + + +class TreeSelectMultiple(forms.SelectMultiple): + """ Provides multiple selection of parent-child data + + """ + template_name = "konova/widgets/checkbox-tree-select-base.html" + url = None + + def __init__(self, *args, **kwargs): + self.url = kwargs.pop("url", None) + if self.url: + self.url = reverse(self.url) + super().__init__(*args, **kwargs) diff --git a/konova/templates/konova/widgets/checkbox-tree-select-base.html b/konova/templates/konova/widgets/checkbox-tree-select-base.html new file mode 100644 index 00000000..793ab83f --- /dev/null +++ b/konova/templates/konova/widgets/checkbox-tree-select-base.html @@ -0,0 +1,45 @@ + +
+
+ + + + \ No newline at end of file diff --git a/konova/templates/konova/widgets/checkbox-tree-select-content.html b/konova/templates/konova/widgets/checkbox-tree-select-content.html new file mode 100644 index 00000000..13b3a34d --- /dev/null +++ b/konova/templates/konova/widgets/checkbox-tree-select-content.html @@ -0,0 +1,9 @@ +{% load l10n %} + +
    + {% for code in codes %} +
  • + {{code.long_name}} +
  • + {% endfor %} +
\ No newline at end of file diff --git a/konova/urls.py b/konova/urls.py index 68256e7a..734be3cd 100644 --- a/konova/urls.py +++ b/konova/urls.py @@ -23,7 +23,7 @@ from konova.autocompletes import EcoAccountAutocomplete, \ ShareUserAutocomplete, BiotopeExtraCodeAutocomplete, CompensationActionDetailCodeAutocomplete from konova.settings import SSO_SERVER, SSO_PUBLIC_KEY, SSO_PRIVATE_KEY, DEBUG from konova.sso.sso import KonovaSSOClient -from konova.views import logout_view, home_view +from konova.views import logout_view, home_view, get_konova_code_action_children sso_client = KonovaSSOClient(SSO_SERVER, SSO_PUBLIC_KEY, SSO_PRIVATE_KEY) urlpatterns = [ @@ -40,6 +40,8 @@ urlpatterns = [ path('analysis/', include("analysis.urls")), path('api/', include("api.urls")), + path("codes/comp/action/children", get_konova_code_action_children, name="codes-action-children"), + # Autocomplete paths for all apps path("atcmplt/eco-accounts", EcoAccountAutocomplete.as_view(), name="accounts-autocomplete"), path("atcmplt/interventions", InterventionAutocomplete.as_view(), name="interventions-autocomplete"), diff --git a/konova/views.py b/konova/views.py index 2a4c8ad5..2eac8b20 100644 --- a/konova/views.py +++ b/konova/views.py @@ -9,9 +9,12 @@ from django.contrib.auth import logout from django.contrib.auth.decorators import login_required from django.http import HttpRequest, FileResponse from django.shortcuts import redirect, render, get_object_or_404 +from django.template.loader import render_to_string from django.utils import timezone from django.utils.translation import gettext_lazy as _ +from codelist.models import KonovaCode +from codelist.settings import CODELIST_COMPENSATION_ACTION_ID from compensation.models import Compensation, EcoAccount from intervention.models import Intervention from konova.contexts import BaseContext @@ -124,3 +127,24 @@ def get_500_view(request: HttpRequest): """ context = BaseContext.context return render(request, "500.html", context, status=500) + + +@login_required +def get_konova_code_action_children(request: HttpRequest): + template = "konova/widgets/checkbox-tree-select-content.html" + _id = request.GET.get("id", None) + if _id == "#": + # Return all! + codes = KonovaCode.objects.filter( + code_lists__in=[CODELIST_COMPENSATION_ACTION_ID], + parent=None, + ) + else: + codes = KonovaCode.objects.filter( + code_lists__in=[CODELIST_COMPENSATION_ACTION_ID], + parent__id=_id, + ) + context = { + "codes": codes + } + return render(request, template, context) \ No newline at end of file diff --git a/templates/form/scripts/jstree-scripts.html b/templates/form/scripts/jstree-scripts.html new file mode 100644 index 00000000..c9367609 --- /dev/null +++ b/templates/form/scripts/jstree-scripts.html @@ -0,0 +1,2 @@ + + \ No newline at end of file From d04d02380f6ec763ff24fe61babd2aa2e6c9344b Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Fri, 11 Feb 2022 16:21:44 +0100 Subject: [PATCH 04/12] WIP: #112 Restructure CompensationAction --- compensation/forms/modalForms.py | 2 +- .../widgets/checkbox-tree-select-base.html | 26 ++++--------------- 2 files changed, 6 insertions(+), 22 deletions(-) diff --git a/compensation/forms/modalForms.py b/compensation/forms/modalForms.py index 20ff5ddc..6dc0c98e 100644 --- a/compensation/forms/modalForms.py +++ b/compensation/forms/modalForms.py @@ -22,7 +22,7 @@ from intervention.inputs import TreeSelectMultiple from konova.contexts import BaseContext from konova.forms import BaseModalForm, NewDocumentModalForm, RemoveModalForm from konova.models import DeadlineType -from konova.utils.message_templates import FORM_INVALID, ADDED_COMPENSATION_STATE, ADDED_DEADLINE, \ +from konova.utils.message_templates import FORM_INVALID, ADDED_COMPENSATION_STATE, \ ADDED_COMPENSATION_ACTION, PAYMENT_EDITED, COMPENSATION_STATE_EDITED, COMPENSATION_ACTION_EDITED, DEADLINE_EDITED diff --git a/konova/templates/konova/widgets/checkbox-tree-select-base.html b/konova/templates/konova/widgets/checkbox-tree-select-base.html index 793ab83f..6a10ff02 100644 --- a/konova/templates/konova/widgets/checkbox-tree-select-base.html +++ b/konova/templates/konova/widgets/checkbox-tree-select-base.html @@ -1,18 +1,14 @@ -
-
- - +
+ \ No newline at end of file From 95856c9ee94cdb999b48d245f5cea0026081d88e Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Tue, 15 Feb 2022 10:48:01 +0100 Subject: [PATCH 05/12] #112 CompensationAction Tree * implements generic HTML based and Django compatible TreeView * enhances listing of CompensationActions on DetailView --- codelist/models.py | 20 ++ compensation/forms/modalForms.py | 34 ++- .../detail/compensation/includes/actions.html | 20 +- .../detail/compensation/view.html | 4 - .../detail/eco_account/includes/actions.html | 20 +- .../compensation/detail/eco_account/view.html | 4 - .../ema/detail/includes/actions.html | 20 +- ema/templates/ema/detail/view.html | 5 - intervention/inputs.py | 49 +++- .../widgets/checkbox-tree-select-base.html | 29 --- .../widgets/checkbox-tree-select-content.html | 9 - .../konova/widgets/checkbox-tree-select.html | 23 ++ konova/urls.py | 4 +- konova/views.py | 21 -- locale/de/LC_MESSAGES/django.mo | Bin 37463 -> 37523 bytes locale/de/LC_MESSAGES/django.po | 235 +++++++++--------- templates/form/scripts/jstree-scripts.html | 2 - 17 files changed, 246 insertions(+), 253 deletions(-) delete mode 100644 konova/templates/konova/widgets/checkbox-tree-select-base.html delete mode 100644 konova/templates/konova/widgets/checkbox-tree-select-content.html create mode 100644 konova/templates/konova/widgets/checkbox-tree-select.html delete mode 100644 templates/form/scripts/jstree-scripts.html diff --git a/codelist/models.py b/codelist/models.py index d5be5b10..de7a2100 100644 --- a/codelist/models.py +++ b/codelist/models.py @@ -65,6 +65,26 @@ class KonovaCode(models.Model): ret_val += ", " + self.parent.long_name return ret_val + def add_children(self): + """ Adds all children (resurcively until leaf) as .children to the KonovaCode + + Returns: + code (KonovaCode): The manipulated KonovaCode instance + """ + if self.is_leaf: + return None + + children = KonovaCode.objects.filter( + code_lists__in=self.code_lists.all(), + parent=self + ).order_by( + "long_name" + ) + self.children = children + for child in children: + child.add_children() + return self + class KonovaCodeList(models.Model): """ diff --git a/compensation/forms/modalForms.py b/compensation/forms/modalForms.py index 6dc0c98e..a8d38aa2 100644 --- a/compensation/forms/modalForms.py +++ b/compensation/forms/modalForms.py @@ -11,14 +11,13 @@ from django import forms from django.contrib import messages from django.http import HttpRequest, HttpResponseRedirect from django.shortcuts import render -from django.urls import reverse from django.utils.translation import pgettext_lazy as _con, gettext_lazy as _ from codelist.models import KonovaCode from codelist.settings import CODELIST_BIOTOPES_ID, CODELIST_COMPENSATION_ACTION_ID, CODELIST_BIOTOPES_EXTRA_CODES_ID, \ CODELIST_COMPENSATION_ACTION_DETAIL_ID from compensation.models import CompensationDocument, EcoAccountDocument -from intervention.inputs import TreeSelectMultiple +from intervention.inputs import CompensationActionTreeCheckboxSelectMultiple from konova.contexts import BaseContext from konova.forms import BaseModalForm, NewDocumentModalForm, RemoveModalForm from konova.models import DeadlineType @@ -407,18 +406,13 @@ class NewActionModalForm(BaseModalForm): """ from compensation.models import UnitChoices - action_type = forms.ModelMultipleChoiceField( + action_type = forms.MultipleChoiceField( label=_("Action Type"), label_suffix="", required=True, help_text=_("Select the action type"), - queryset=KonovaCode.objects.filter( - code_lists__in=[CODELIST_COMPENSATION_ACTION_ID], - is_archived=False, - ), - widget=TreeSelectMultiple( - url=None, - ), + choices=[], + widget=CompensationActionTreeCheckboxSelectMultiple(), ) action_type_details = forms.ModelMultipleChoiceField( label=_("Action Type detail"), @@ -480,14 +474,16 @@ class NewActionModalForm(BaseModalForm): super().__init__(*args, **kwargs) self.form_title = _("New action") self.form_caption = _("Insert data for the new action") - url = reverse("codes-action-children") - self.fields["action_type"].widget.attrs = { - "url": url, - } - - def is_valid(self): - super_valid = super().is_valid() - return super_valid + choices =KonovaCode.objects.filter( + code_lists__in=[CODELIST_COMPENSATION_ACTION_ID], + is_archived=False, + is_leaf=True, + ).values_list("id", flat=True) + choices = [ + (choice, choice) + for choice in choices + ] + self.fields["action_type"].choices = choices def save(self): action = self.instance.add_action(self) @@ -502,7 +498,7 @@ class EditCompensationActionModalForm(NewActionModalForm): self.action = kwargs.pop("action", None) super().__init__(*args, **kwargs) form_data = { - "action_type": self.action.action_type.all(), + "action_type": list(self.action.action_type.values_list("id", flat=True)), "action_type_details": self.action.action_type_details.all(), "amount": self.action.amount, "unit": self.action.unit, diff --git a/compensation/templates/compensation/detail/compensation/includes/actions.html b/compensation/templates/compensation/detail/compensation/includes/actions.html index 18e9304b..87f49141 100644 --- a/compensation/templates/compensation/detail/compensation/includes/actions.html +++ b/compensation/templates/compensation/detail/compensation/includes/actions.html @@ -47,17 +47,15 @@ {% for action in actions %} -
    - {% for type in action.action_type.all %} -
  • {{type}}
  • - {% endfor %} -
- {% if action.action_type_details.count > 0 %} -
- {% for detail in action.action_type_details.all %} - {{detail.long_name}} - {% endfor %} - {% endif %} + {% for type in action.action_type.all %} +
{{type.parent.parent.long_name}} {% fa5_icon 'angle-right' %} {{type.parent.long_name}} {% fa5_icon 'angle-right' %} {{type.long_name}}
+
+ {% endfor %} + {% for detail in action.action_type_details.all %} + {{detail.long_name}} + {% empty %} + {% trans 'No action type details' %} + {% endfor %} {{ action.amount|floatformat:2|intcomma }} {{ action.unit_humanize }} diff --git a/compensation/templates/compensation/detail/compensation/view.html b/compensation/templates/compensation/detail/compensation/view.html index 17f79bc8..c5ff41d6 100644 --- a/compensation/templates/compensation/detail/compensation/view.html +++ b/compensation/templates/compensation/detail/compensation/view.html @@ -2,10 +2,6 @@ {% load i18n l10n static fontawesome_5 humanize ksp_filters %} {% block head %} - {% comment %} - Needed for custom Checkbox Tree Select Widget - {% endcomment %} - {% include 'form/scripts/jstree-scripts.html' %} {% comment %} dal documentation (django-autocomplete-light) states using form.media for adding needed scripts. diff --git a/compensation/templates/compensation/detail/eco_account/includes/actions.html b/compensation/templates/compensation/detail/eco_account/includes/actions.html index 092c5e8d..8ae7c8fd 100644 --- a/compensation/templates/compensation/detail/eco_account/includes/actions.html +++ b/compensation/templates/compensation/detail/eco_account/includes/actions.html @@ -46,17 +46,15 @@ {% for action in actions %} -
    - {% for type in action.action_type.all%} -
  • {{type.long_name}}
  • - {% endfor %} -
- {% if action.action_type_details.count > 0 %} -
- {% for detail in action.action_type_details.all %} - {{detail.long_name}} - {% endfor %} - {% endif %} + {% for type in action.action_type.all %} +
{{type.parent.parent.long_name}} {% fa5_icon 'angle-right' %} {{type.parent.long_name}} {% fa5_icon 'angle-right' %} {{type.long_name}}
+
+ {% endfor %} + {% for detail in action.action_type_details.all %} + {{detail.long_name}} + {% empty %} + {% trans 'No action type details' %} + {% endfor %} {{ action.amount|floatformat:2|intcomma }} {{ action.unit_humanize }} diff --git a/compensation/templates/compensation/detail/eco_account/view.html b/compensation/templates/compensation/detail/eco_account/view.html index 132e0b61..288b971d 100644 --- a/compensation/templates/compensation/detail/eco_account/view.html +++ b/compensation/templates/compensation/detail/eco_account/view.html @@ -2,10 +2,6 @@ {% load i18n l10n static fontawesome_5 humanize %} {% block head %} - {% comment %} - Needed for custom Checkbox Tree Select Widget - {% endcomment %} - {% include 'form/scripts/jstree-scripts.html' %} {% comment %} dal documentation (django-autocomplete-light) states using form.media for adding needed scripts. diff --git a/ema/templates/ema/detail/includes/actions.html b/ema/templates/ema/detail/includes/actions.html index 9d91caf0..0c352c11 100644 --- a/ema/templates/ema/detail/includes/actions.html +++ b/ema/templates/ema/detail/includes/actions.html @@ -44,17 +44,15 @@ {% for action in obj.actions.all %} -
    - {% for type in action.action_type.all%} -
  • {{type}}
  • - {% endfor %} -
- {% if action.action_type_details.count > 0 %} -
- {% for detail in action.action_type_details.all %} - {{detail.long_name}} - {% endfor %} - {% endif %} + {% for type in action.action_type.all %} +
{{type.parent.parent.long_name}} {% fa5_icon 'angle-right' %} {{type.parent.long_name}} {% fa5_icon 'angle-right' %} {{type.long_name}}
+
+ {% endfor %} + {% for detail in action.action_type_details.all %} + {{detail.long_name}} + {% empty %} + {% trans 'No action type details' %} + {% endfor %} {{ action.amount|floatformat:2|intcomma }} {{ action.unit_humanize }} diff --git a/ema/templates/ema/detail/view.html b/ema/templates/ema/detail/view.html index cdab570d..32ddd66b 100644 --- a/ema/templates/ema/detail/view.html +++ b/ema/templates/ema/detail/view.html @@ -2,11 +2,6 @@ {% load i18n l10n static fontawesome_5 humanize %} {% block head %} - {% comment %} - Needed for custom Checkbox Tree Select Widget - {% endcomment %} - {% include 'form/scripts/jstree-scripts.html' %} - {% comment %} dal documentation (django-autocomplete-light) states using form.media for adding needed scripts. This does not work properly with modal forms, as the scripts are not loaded properly inside the modal. diff --git a/intervention/inputs.py b/intervention/inputs.py index 9cf8e5ab..34fe0434 100644 --- a/intervention/inputs.py +++ b/intervention/inputs.py @@ -1,5 +1,6 @@ from django import forms -from django.urls import reverse +from codelist.models import KonovaCode +from codelist.settings import CODELIST_COMPENSATION_ACTION_ID class DummyFilterInput(forms.HiddenInput): @@ -33,15 +34,49 @@ class GenerateInput(forms.TextInput): template_name = "konova/widgets/generate-content-input.html" -class TreeSelectMultiple(forms.SelectMultiple): +class TreeCheckboxSelectMultiple(forms.CheckboxSelectMultiple): """ Provides multiple selection of parent-child data """ - template_name = "konova/widgets/checkbox-tree-select-base.html" - url = None + template_name = "konova/widgets/checkbox-tree-select.html" + + class meta: + abstract = True + + +class KonovaCodeTreeCheckboxSelectMultiple(TreeCheckboxSelectMultiple): + """ Provides multiple selection of KonovaCodes + + """ + filter = None def __init__(self, *args, **kwargs): - self.url = kwargs.pop("url", None) - if self.url: - self.url = reverse(self.url) + self.code_list = kwargs.pop("code_list", None) + self.filter = kwargs.pop("filter", {}) super().__init__(*args, **kwargs) + + def get_context(self, name, value, attrs): + context = super().get_context(name, value, attrs) + codes = KonovaCode.objects.filter( + **self.filter, + ) + codes = [ + parent_code.add_children() + for parent_code in codes + ] + context["codes"] = codes + return context + + +class CompensationActionTreeCheckboxSelectMultiple(KonovaCodeTreeCheckboxSelectMultiple): + """ Provides multiple selection of CompensationActions + + """ + filter = None + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self.filter = { + "code_lists__in": [CODELIST_COMPENSATION_ACTION_ID], + "parent": None, + } \ No newline at end of file diff --git a/konova/templates/konova/widgets/checkbox-tree-select-base.html b/konova/templates/konova/widgets/checkbox-tree-select-base.html deleted file mode 100644 index 6a10ff02..00000000 --- a/konova/templates/konova/widgets/checkbox-tree-select-base.html +++ /dev/null @@ -1,29 +0,0 @@ - -
- - - \ No newline at end of file diff --git a/konova/templates/konova/widgets/checkbox-tree-select-content.html b/konova/templates/konova/widgets/checkbox-tree-select-content.html deleted file mode 100644 index 13b3a34d..00000000 --- a/konova/templates/konova/widgets/checkbox-tree-select-content.html +++ /dev/null @@ -1,9 +0,0 @@ -{% load l10n %} - -
    - {% for code in codes %} -
  • - {{code.long_name}} -
  • - {% endfor %} -
\ No newline at end of file diff --git a/konova/templates/konova/widgets/checkbox-tree-select.html b/konova/templates/konova/widgets/checkbox-tree-select.html new file mode 100644 index 00000000..5b40d3f1 --- /dev/null +++ b/konova/templates/konova/widgets/checkbox-tree-select.html @@ -0,0 +1,23 @@ +{% load l10n fontawesome_5 %} + +
+ {% for code in codes %} +
+ + {% if not code.is_leaf %} +
+ {% with code.children as codes %} + {% include 'konova/widgets/checkbox-tree-select.html' %} + {% endwith %} +
+ {% endif %} +
+ {% endfor %} +
\ No newline at end of file diff --git a/konova/urls.py b/konova/urls.py index 734be3cd..68256e7a 100644 --- a/konova/urls.py +++ b/konova/urls.py @@ -23,7 +23,7 @@ from konova.autocompletes import EcoAccountAutocomplete, \ ShareUserAutocomplete, BiotopeExtraCodeAutocomplete, CompensationActionDetailCodeAutocomplete from konova.settings import SSO_SERVER, SSO_PUBLIC_KEY, SSO_PRIVATE_KEY, DEBUG from konova.sso.sso import KonovaSSOClient -from konova.views import logout_view, home_view, get_konova_code_action_children +from konova.views import logout_view, home_view sso_client = KonovaSSOClient(SSO_SERVER, SSO_PUBLIC_KEY, SSO_PRIVATE_KEY) urlpatterns = [ @@ -40,8 +40,6 @@ urlpatterns = [ path('analysis/', include("analysis.urls")), path('api/', include("api.urls")), - path("codes/comp/action/children", get_konova_code_action_children, name="codes-action-children"), - # Autocomplete paths for all apps path("atcmplt/eco-accounts", EcoAccountAutocomplete.as_view(), name="accounts-autocomplete"), path("atcmplt/interventions", InterventionAutocomplete.as_view(), name="interventions-autocomplete"), diff --git a/konova/views.py b/konova/views.py index 2eac8b20..f3c53f01 100644 --- a/konova/views.py +++ b/konova/views.py @@ -127,24 +127,3 @@ def get_500_view(request: HttpRequest): """ context = BaseContext.context return render(request, "500.html", context, status=500) - - -@login_required -def get_konova_code_action_children(request: HttpRequest): - template = "konova/widgets/checkbox-tree-select-content.html" - _id = request.GET.get("id", None) - if _id == "#": - # Return all! - codes = KonovaCode.objects.filter( - code_lists__in=[CODELIST_COMPENSATION_ACTION_ID], - parent=None, - ) - else: - codes = KonovaCode.objects.filter( - code_lists__in=[CODELIST_COMPENSATION_ACTION_ID], - parent__id=_id, - ) - context = { - "codes": codes - } - return render(request, template, context) \ No newline at end of file diff --git a/locale/de/LC_MESSAGES/django.mo b/locale/de/LC_MESSAGES/django.mo index 99058358253ae1eb76a6a5f21466ae886d82ccaf..e9a94ccb374f1fcb49ae6b60cf0df3131a61819d 100644 GIT binary patch delta 10418 zcmYk?3w)1t|HtubvyHJCTWm9I%!VDDkL7F*TbNno5H&W!95;r0>%xs26X}<7h>#LV z4ryf}x2TkqM7PMTq;wD!9n{_b_1^XA@$Y)v-=3e(_d0x!*Y(@oeV^Up?|a7I{WLsa zmBaC~pX1cU(_xOY$=`97#j4hEY9u*M80TuDkGw&$<1E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olI|CO?n{5{GB;?F4jh_jZFw>Q@< zBQIy->BO&(W2R2|50o5}KgIjxp87i9)>)2$=A=7uJn=YOM44skH{*QD73$8LIzrd6 zg?tauH7rKaFJ(t@EJeQ$%|RVQ@K?$$JLOM4hEedH3MZOV)>CSdKcVy|{*3ZDMaKy| zOSwio2*W5{i0@K@DIw%7DFZ0qQf5%9P)>2qbr3fu=!LuRpS$q{MZA}?i2NPOr^Ib3ItrL;&S50wpj~Z^Bref_q%>tE$un$- w@8S;Ur!ke{OOd^KY&3ZVDvwgU$eU39O}uBjdu;LI+Y^!(SKoeP, YEAR. # -#: compensation/filters.py:122 compensation/forms/modalForms.py:35 -#: compensation/forms/modalForms.py:46 compensation/forms/modalForms.py:62 -#: compensation/forms/modalForms.py:355 compensation/forms/modalForms.py:471 +#: compensation/filters.py:122 compensation/forms/modalForms.py:37 +#: compensation/forms/modalForms.py:48 compensation/forms/modalForms.py:64 +#: compensation/forms/modalForms.py:357 compensation/forms/modalForms.py:469 #: intervention/forms/forms.py:54 intervention/forms/forms.py:156 #: intervention/forms/forms.py:168 intervention/forms/modalForms.py:127 #: intervention/forms/modalForms.py:140 intervention/forms/modalForms.py:153 @@ -26,7 +26,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-02-10 13:31+0100\n" +"POT-Creation-Date: 2022-02-15 10:08+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -45,7 +45,7 @@ msgid "To" msgstr "Bis" #: analysis/forms.py:47 compensation/forms/forms.py:77 -#: compensation/templates/compensation/detail/eco_account/view.html:58 +#: compensation/templates/compensation/detail/eco_account/view.html:59 #: compensation/templates/compensation/report/eco_account/report.html:16 #: compensation/utils/quality.py:100 ema/templates/ema/detail/view.html:49 #: ema/templates/ema/report/report.html:16 ema/utils/quality.py:26 @@ -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:455 +#: compensation/forms/modalForms.py:453 #: compensation/templates/compensation/detail/eco_account/includes/deductions.html:34 #: intervention/templates/intervention/detail/includes/deductions.html:31 msgid "Amount" @@ -137,7 +137,7 @@ msgstr "Zuständigkeitsbereich" #: analysis/templates/analysis/reports/includes/intervention/compensated_by.html:8 #: analysis/templates/analysis/reports/includes/intervention/laws.html:17 #: compensation/tables.py:40 -#: compensation/templates/compensation/detail/compensation/view.html:63 +#: compensation/templates/compensation/detail/compensation/view.html:64 #: intervention/tables.py:39 #: intervention/templates/intervention/detail/view.html:68 #: user/models/user_action.py:20 @@ -153,9 +153,9 @@ msgstr "Geprüft" #: analysis/templates/analysis/reports/includes/intervention/laws.html:20 #: analysis/templates/analysis/reports/includes/old_data/amount.html:18 #: compensation/tables.py:46 compensation/tables.py:222 -#: compensation/templates/compensation/detail/compensation/view.html:77 +#: compensation/templates/compensation/detail/compensation/view.html:78 #: compensation/templates/compensation/detail/eco_account/includes/deductions.html:31 -#: compensation/templates/compensation/detail/eco_account/view.html:44 +#: compensation/templates/compensation/detail/eco_account/view.html:45 #: ema/tables.py:44 ema/templates/ema/detail/view.html:35 #: intervention/tables.py:45 #: intervention/templates/intervention/detail/view.html:82 @@ -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:193 +#: compensation/forms/modalForms.py:195 #: 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 @@ -239,14 +239,14 @@ msgstr "Kompensationsart" #: analysis/templates/analysis/reports/includes/intervention/compensated_by.html:15 #: analysis/templates/analysis/reports/includes/old_data/amount.html:29 -#: compensation/templates/compensation/detail/compensation/view.html:19 +#: compensation/templates/compensation/detail/compensation/view.html:20 #: konova/templates/konova/includes/quickstart/compensations.html:4 #: templates/navbars/navbar.html:28 msgid "Compensation" msgstr "Kompensation" #: analysis/templates/analysis/reports/includes/intervention/compensated_by.html:21 -#: compensation/forms/modalForms.py:75 +#: compensation/forms/modalForms.py:77 msgid "Payment" msgstr "Zahlung" @@ -293,7 +293,7 @@ msgstr "Eingriff" #: analysis/templates/analysis/reports/includes/old_data/amount.html:34 #: compensation/tables.py:266 -#: compensation/templates/compensation/detail/eco_account/view.html:19 +#: compensation/templates/compensation/detail/eco_account/view.html:20 #: intervention/forms/modalForms.py:322 intervention/forms/modalForms.py:329 #: konova/templates/konova/includes/quickstart/ecoaccounts.html:4 #: templates/navbars/navbar.html:34 @@ -327,9 +327,9 @@ msgstr "Automatisch generiert" #: compensation/forms/forms.py:44 compensation/tables.py:30 #: compensation/tables.py:202 #: compensation/templates/compensation/detail/compensation/includes/documents.html:28 -#: compensation/templates/compensation/detail/compensation/view.html:31 +#: compensation/templates/compensation/detail/compensation/view.html:32 #: compensation/templates/compensation/detail/eco_account/includes/documents.html:28 -#: compensation/templates/compensation/detail/eco_account/view.html:31 +#: compensation/templates/compensation/detail/eco_account/view.html:32 #: compensation/templates/compensation/report/compensation/report.html:12 #: compensation/templates/compensation/report/eco_account/report.html:12 #: ema/tables.py:34 ema/templates/ema/detail/includes/documents.html:28 @@ -352,8 +352,8 @@ msgstr "Aussagekräftiger Titel" msgid "Compensation XY; Location ABC" msgstr "Kompensation XY; Flur ABC" -#: compensation/forms/forms.py:57 compensation/forms/modalForms.py:61 -#: compensation/forms/modalForms.py:354 compensation/forms/modalForms.py:470 +#: compensation/forms/forms.py:57 compensation/forms/modalForms.py:63 +#: compensation/forms/modalForms.py:356 compensation/forms/modalForms.py:468 #: 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:34 @@ -371,13 +371,13 @@ msgstr "Kompensation XY; Flur ABC" msgid "Comment" msgstr "Kommentar" -#: compensation/forms/forms.py:59 compensation/forms/modalForms.py:472 +#: compensation/forms/forms.py:59 compensation/forms/modalForms.py:470 #: intervention/forms/forms.py:182 msgid "Additional comment" msgstr "Zusätzlicher Kommentar" #: compensation/forms/forms.py:93 -#: compensation/templates/compensation/detail/eco_account/view.html:62 +#: compensation/templates/compensation/detail/eco_account/view.html:63 #: compensation/templates/compensation/report/eco_account/report.html:20 #: compensation/utils/quality.py:102 ema/templates/ema/detail/view.html:53 #: ema/templates/ema/report/report.html:20 ema/utils/quality.py:28 @@ -422,7 +422,7 @@ msgid "" msgstr "Optional: Handelt es sich um eine Kohärenzsicherungsmaßnahme?" #: compensation/forms/forms.py:156 -#: compensation/templates/compensation/detail/compensation/view.html:35 +#: compensation/templates/compensation/detail/compensation/view.html:36 #: compensation/templates/compensation/report/compensation/report.html:16 msgid "compensates intervention" msgstr "kompensiert Eingriff" @@ -448,7 +448,7 @@ msgid "The amount that can be used for deductions" msgstr "Die für Abbuchungen zur Verfügung stehende Menge" #: compensation/forms/forms.py:328 -#: compensation/templates/compensation/detail/eco_account/view.html:66 +#: compensation/templates/compensation/detail/eco_account/view.html:67 #: compensation/utils/quality.py:72 msgid "Agreement date" msgstr "Vereinbarungsdatum" @@ -469,73 +469,73 @@ msgstr "Ökokonto XY; Flur ABC" msgid "Edit Eco-Account" msgstr "Ökokonto bearbeiten" -#: compensation/forms/modalForms.py:36 +#: compensation/forms/modalForms.py:38 msgid "in Euro" msgstr "in Euro" -#: compensation/forms/modalForms.py:45 +#: compensation/forms/modalForms.py:47 #: intervention/templates/intervention/detail/includes/payments.html:31 msgid "Due on" msgstr "Fällig am" -#: compensation/forms/modalForms.py:48 +#: compensation/forms/modalForms.py:50 msgid "Due on which date" msgstr "Zahlung wird an diesem Datum erwartet" -#: compensation/forms/modalForms.py:63 compensation/forms/modalForms.py:356 +#: compensation/forms/modalForms.py:65 compensation/forms/modalForms.py:358 #: intervention/forms/modalForms.py:154 konova/forms.py:395 msgid "Additional comment, maximum {} letters" msgstr "Zusätzlicher Kommentar, maximal {} Zeichen" -#: compensation/forms/modalForms.py:76 +#: compensation/forms/modalForms.py:78 msgid "Add a payment for intervention '{}'" msgstr "Neue Ersatzzahlung zu Eingriff '{}' hinzufügen" -#: compensation/forms/modalForms.py:96 +#: compensation/forms/modalForms.py:98 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:157 compensation/forms/modalForms.py:169 +#: compensation/forms/modalForms.py:159 compensation/forms/modalForms.py:171 msgid "Biotope Type" msgstr "Biotoptyp" -#: compensation/forms/modalForms.py:160 +#: compensation/forms/modalForms.py:162 msgid "Select the biotope type" msgstr "Biotoptyp wählen" -#: compensation/forms/modalForms.py:174 compensation/forms/modalForms.py:186 +#: compensation/forms/modalForms.py:176 compensation/forms/modalForms.py:188 msgid "Biotope additional type" msgstr "Zusatzbezeichnung" -#: compensation/forms/modalForms.py:177 +#: compensation/forms/modalForms.py:179 msgid "Select an additional biotope type" msgstr "Zusatzbezeichnung wählen" -#: compensation/forms/modalForms.py:196 intervention/forms/modalForms.py:340 +#: compensation/forms/modalForms.py:198 intervention/forms/modalForms.py:340 msgid "in m²" msgstr "" -#: compensation/forms/modalForms.py:207 +#: compensation/forms/modalForms.py:209 msgid "New state" msgstr "Neuer Zustand" -#: compensation/forms/modalForms.py:208 +#: compensation/forms/modalForms.py:210 msgid "Insert data for the new state" msgstr "Geben Sie die Daten des neuen Zustandes ein" -#: compensation/forms/modalForms.py:215 konova/forms.py:193 +#: compensation/forms/modalForms.py:217 konova/forms.py:193 msgid "Object removed" msgstr "Objekt entfernt" -#: compensation/forms/modalForms.py:326 +#: compensation/forms/modalForms.py:328 msgid "Deadline Type" msgstr "Fristart" -#: compensation/forms/modalForms.py:329 +#: compensation/forms/modalForms.py:331 msgid "Select the deadline type" msgstr "Fristart wählen" -#: compensation/forms/modalForms.py:338 +#: compensation/forms/modalForms.py:340 #: 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,101 +543,75 @@ msgstr "Fristart wählen" msgid "Date" msgstr "Datum" -#: compensation/forms/modalForms.py:341 +#: compensation/forms/modalForms.py:343 msgid "Select date" msgstr "Datum wählen" -#: compensation/forms/modalForms.py:368 +#: compensation/forms/modalForms.py:370 msgid "New deadline" msgstr "Neue Frist" -#: compensation/forms/modalForms.py:369 +#: compensation/forms/modalForms.py:371 msgid "Insert data for the new deadline" msgstr "Geben Sie die Daten der neuen Frist ein" -#: compensation/forms/modalForms.py:409 +#: compensation/forms/modalForms.py:411 msgid "Action Type" msgstr "Maßnahmentyp" -#: compensation/forms/modalForms.py:412 +#: compensation/forms/modalForms.py:414 msgid "Select the action type" msgstr "Maßnahmentyp wählen" -#: compensation/forms/modalForms.py:421 -#: 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:39 -#: compensation/templates/compensation/detail/compensation/includes/states-after.html:41 -#: compensation/templates/compensation/detail/compensation/includes/states-before.html:41 -#: compensation/templates/compensation/detail/eco_account/includes/actions.html:39 -#: compensation/templates/compensation/detail/eco_account/includes/deadlines.html:38 -#: compensation/templates/compensation/detail/eco_account/includes/deductions.html:41 -#: compensation/templates/compensation/detail/eco_account/includes/documents.html:38 -#: compensation/templates/compensation/detail/eco_account/includes/states-after.html:41 -#: compensation/templates/compensation/detail/eco_account/includes/states-before.html:41 -#: ema/templates/ema/detail/includes/actions.html:38 -#: ema/templates/ema/detail/includes/deadlines.html:38 -#: ema/templates/ema/detail/includes/documents.html:38 -#: ema/templates/ema/detail/includes/states-after.html:40 -#: ema/templates/ema/detail/includes/states-before.html:40 -#: intervention/templates/intervention/detail/includes/compensations.html:38 -#: intervention/templates/intervention/detail/includes/deductions.html:39 -#: intervention/templates/intervention/detail/includes/documents.html:39 -#: intervention/templates/intervention/detail/includes/payments.html:39 -#: intervention/templates/intervention/detail/includes/revocation.html:43 -#: templates/log.html:10 -msgid "Action" -msgstr "Aktionen" - -#: compensation/forms/modalForms.py:426 compensation/forms/modalForms.py:438 +#: compensation/forms/modalForms.py:424 compensation/forms/modalForms.py:436 msgid "Action Type detail" msgstr "Zusatzmerkmal" -#: compensation/forms/modalForms.py:429 +#: compensation/forms/modalForms.py:427 msgid "Select the action type detail" msgstr "Zusatzmerkmal wählen" -#: compensation/forms/modalForms.py:443 +#: compensation/forms/modalForms.py:441 msgid "Unit" msgstr "Einheit" -#: compensation/forms/modalForms.py:446 +#: compensation/forms/modalForms.py:444 msgid "Select the unit" msgstr "Einheit wählen" -#: compensation/forms/modalForms.py:458 +#: compensation/forms/modalForms.py:456 msgid "Insert the amount" msgstr "Menge eingeben" -#: compensation/forms/modalForms.py:483 +#: compensation/forms/modalForms.py:481 msgid "New action" msgstr "Neue Maßnahme" -#: compensation/forms/modalForms.py:484 +#: compensation/forms/modalForms.py:482 msgid "Insert data for the new action" msgstr "Geben Sie die Daten der neuen Maßnahme ein" -#: compensation/models/action.py:22 +#: compensation/models/action.py:20 msgid "cm" msgstr "" -#: compensation/models/action.py:23 +#: compensation/models/action.py:21 msgid "m" msgstr "" -#: compensation/models/action.py:24 +#: compensation/models/action.py:22 msgid "km" msgstr "" -#: compensation/models/action.py:25 +#: compensation/models/action.py:23 msgid "m²" msgstr "" -#: compensation/models/action.py:26 +#: compensation/models/action.py:24 msgid "ha" msgstr "" -#: compensation/models/action.py:27 +#: compensation/models/action.py:25 msgid "Pieces" msgstr "Stück" @@ -685,9 +659,9 @@ msgid "Checked on {} by {}" msgstr "Am {} von {} geprüft worden" #: compensation/tables.py:160 -#: compensation/templates/compensation/detail/compensation/view.html:80 +#: compensation/templates/compensation/detail/compensation/view.html:81 #: compensation/templates/compensation/detail/eco_account/includes/deductions.html:58 -#: compensation/templates/compensation/detail/eco_account/view.html:47 +#: compensation/templates/compensation/detail/eco_account/view.html:48 #: ema/tables.py:131 ema/templates/ema/detail/view.html:38 #: intervention/tables.py:157 #: intervention/templates/intervention/detail/view.html:85 @@ -710,7 +684,7 @@ msgid "Access not granted" msgstr "Nicht freigegeben - Datensatz nur lesbar" #: compensation/tables.py:212 -#: compensation/templates/compensation/detail/eco_account/view.html:35 +#: compensation/templates/compensation/detail/eco_account/view.html:36 #: konova/templates/konova/widgets/progressbar.html:3 msgid "Available" msgstr "Verfügbar" @@ -750,15 +724,45 @@ msgctxt "Compensation" msgid "Amount" msgstr "Menge" -#: compensation/templates/compensation/detail/compensation/includes/actions.html:66 -#: compensation/templates/compensation/detail/eco_account/includes/actions.html:65 -#: ema/templates/ema/detail/includes/actions.html:63 +#: 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:39 +#: compensation/templates/compensation/detail/compensation/includes/states-after.html:41 +#: compensation/templates/compensation/detail/compensation/includes/states-before.html:41 +#: compensation/templates/compensation/detail/eco_account/includes/actions.html:39 +#: compensation/templates/compensation/detail/eco_account/includes/deadlines.html:38 +#: compensation/templates/compensation/detail/eco_account/includes/deductions.html:41 +#: compensation/templates/compensation/detail/eco_account/includes/documents.html:38 +#: compensation/templates/compensation/detail/eco_account/includes/states-after.html:41 +#: compensation/templates/compensation/detail/eco_account/includes/states-before.html:41 +#: ema/templates/ema/detail/includes/actions.html:38 +#: ema/templates/ema/detail/includes/deadlines.html:38 +#: ema/templates/ema/detail/includes/documents.html:38 +#: ema/templates/ema/detail/includes/states-after.html:40 +#: ema/templates/ema/detail/includes/states-before.html:40 +#: intervention/templates/intervention/detail/includes/compensations.html:38 +#: intervention/templates/intervention/detail/includes/deductions.html:39 +#: intervention/templates/intervention/detail/includes/documents.html:39 +#: intervention/templates/intervention/detail/includes/payments.html:39 +#: intervention/templates/intervention/detail/includes/revocation.html:43 +#: templates/log.html:10 +msgid "Action" +msgstr "Aktionen" + +#: compensation/templates/compensation/detail/compensation/includes/actions.html:57 +#: compensation/templates/compensation/detail/eco_account/includes/actions.html:56 +msgid "No action type details" +msgstr "Keine Zusatzmerkmale" + +#: compensation/templates/compensation/detail/compensation/includes/actions.html:68 +#: compensation/templates/compensation/detail/eco_account/includes/actions.html:67 +#: ema/templates/ema/detail/includes/actions.html:67 msgid "Edit action" msgstr "Maßnahme bearbeiten" -#: compensation/templates/compensation/detail/compensation/includes/actions.html:69 -#: compensation/templates/compensation/detail/eco_account/includes/actions.html:68 -#: ema/templates/ema/detail/includes/actions.html:66 +#: compensation/templates/compensation/detail/compensation/includes/actions.html:71 +#: compensation/templates/compensation/detail/eco_account/includes/actions.html:70 +#: ema/templates/ema/detail/includes/actions.html:70 msgid "Remove action" msgstr "Maßnahme entfernen" @@ -924,50 +928,50 @@ msgstr "Neuen Ausgangszustand hinzufügen" msgid "Missing surfaces according to states after: " msgstr "Fehlende Flächenmengen laut Zielzustand: " -#: compensation/templates/compensation/detail/compensation/view.html:43 +#: compensation/templates/compensation/detail/compensation/view.html:44 msgid "Is CEF compensation" msgstr "Ist CEF Maßnahme" -#: compensation/templates/compensation/detail/compensation/view.html:46 -#: compensation/templates/compensation/detail/compensation/view.html:56 +#: compensation/templates/compensation/detail/compensation/view.html:47 +#: compensation/templates/compensation/detail/compensation/view.html:57 #: venv/lib/python3.7/site-packages/django/forms/widgets.py:710 msgid "Yes" msgstr "Ja" -#: compensation/templates/compensation/detail/compensation/view.html:48 -#: compensation/templates/compensation/detail/compensation/view.html:58 +#: compensation/templates/compensation/detail/compensation/view.html:49 +#: compensation/templates/compensation/detail/compensation/view.html:59 #: venv/lib/python3.7/site-packages/django/forms/widgets.py:711 msgid "No" msgstr "Nein" -#: compensation/templates/compensation/detail/compensation/view.html:53 +#: compensation/templates/compensation/detail/compensation/view.html:54 msgid "Is Coherence keeping compensation" msgstr "Ist Kohärenzsicherungsmaßnahme" -#: compensation/templates/compensation/detail/compensation/view.html:70 +#: compensation/templates/compensation/detail/compensation/view.html:71 #: intervention/templates/intervention/detail/view.html:75 msgid "Checked on " msgstr "Geprüft am " -#: compensation/templates/compensation/detail/compensation/view.html:70 -#: compensation/templates/compensation/detail/compensation/view.html:84 +#: compensation/templates/compensation/detail/compensation/view.html:71 +#: compensation/templates/compensation/detail/compensation/view.html:85 #: compensation/templates/compensation/detail/eco_account/includes/deductions.html:56 -#: compensation/templates/compensation/detail/eco_account/view.html:51 +#: compensation/templates/compensation/detail/eco_account/view.html:52 #: ema/templates/ema/detail/view.html:42 #: intervention/templates/intervention/detail/view.html:75 #: intervention/templates/intervention/detail/view.html:89 msgid "by" msgstr "von" -#: compensation/templates/compensation/detail/compensation/view.html:84 -#: compensation/templates/compensation/detail/eco_account/view.html:51 +#: compensation/templates/compensation/detail/compensation/view.html:85 +#: compensation/templates/compensation/detail/eco_account/view.html:52 #: ema/templates/ema/detail/view.html:42 #: intervention/templates/intervention/detail/view.html:89 msgid "Recorded on " msgstr "Verzeichnet am" -#: compensation/templates/compensation/detail/compensation/view.html:91 -#: compensation/templates/compensation/detail/eco_account/view.html:74 +#: compensation/templates/compensation/detail/compensation/view.html:92 +#: compensation/templates/compensation/detail/eco_account/view.html:75 #: compensation/templates/compensation/report/compensation/report.html:24 #: compensation/templates/compensation/report/eco_account/report.html:41 #: ema/templates/ema/detail/view.html:61 @@ -977,8 +981,8 @@ msgstr "Verzeichnet am" msgid "Last modified" msgstr "Zuletzt bearbeitet" -#: compensation/templates/compensation/detail/compensation/view.html:99 -#: compensation/templates/compensation/detail/eco_account/view.html:82 +#: compensation/templates/compensation/detail/compensation/view.html:100 +#: compensation/templates/compensation/detail/eco_account/view.html:83 #: ema/templates/ema/detail/view.html:76 intervention/forms/modalForms.py:56 #: intervention/templates/intervention/detail/view.html:116 msgid "Shared with" @@ -1037,14 +1041,14 @@ msgstr "Abbuchung bearbeiten" msgid "Remove Deduction" msgstr "Abbuchung entfernen" -#: compensation/templates/compensation/detail/eco_account/view.html:34 +#: compensation/templates/compensation/detail/eco_account/view.html:35 msgid "No surface deductable" msgstr "Keine Flächenmenge für Abbuchungen eingegeben. Bitte bearbeiten." -#: compensation/templates/compensation/detail/eco_account/view.html:57 -#: compensation/templates/compensation/detail/eco_account/view.html:61 -#: compensation/templates/compensation/detail/eco_account/view.html:65 -#: compensation/templates/compensation/detail/eco_account/view.html:69 +#: compensation/templates/compensation/detail/eco_account/view.html:58 +#: compensation/templates/compensation/detail/eco_account/view.html:62 +#: compensation/templates/compensation/detail/eco_account/view.html:66 +#: compensation/templates/compensation/detail/eco_account/view.html:70 #: ema/templates/ema/detail/view.html:48 ema/templates/ema/detail/view.html:52 #: ema/templates/ema/detail/view.html:56 #: intervention/templates/intervention/detail/view.html:30 @@ -1060,7 +1064,7 @@ msgstr "Keine Flächenmenge für Abbuchungen eingegeben. Bitte bearbeiten." msgid "Missing" msgstr "fehlt" -#: compensation/templates/compensation/detail/eco_account/view.html:70 +#: compensation/templates/compensation/detail/eco_account/view.html:71 #: compensation/templates/compensation/report/eco_account/report.html:24 #: ema/templates/ema/detail/view.html:57 #: ema/templates/ema/report/report.html:24 @@ -1976,7 +1980,7 @@ msgstr "{} wurde erfolgreich vom Nutzer {} geprüft! {}" msgid "missing" msgstr "fehlt" -#: konova/views.py:96 templates/navbars/navbar.html:16 +#: konova/views.py:99 templates/navbars/navbar.html:16 msgid "Home" msgstr "Home" @@ -3993,9 +3997,6 @@ msgstr "" #~ msgid "General data edited" #~ msgstr "Allgemeine Daten bearbeitet" -#~ msgid "Action type details" -#~ msgstr "Zusatzmerkmale" - #~ msgid "On registered data edited" #~ msgstr "Wenn meine freigegebenen Daten bearbeitet wurden" diff --git a/templates/form/scripts/jstree-scripts.html b/templates/form/scripts/jstree-scripts.html deleted file mode 100644 index c9367609..00000000 --- a/templates/form/scripts/jstree-scripts.html +++ /dev/null @@ -1,2 +0,0 @@ - - \ No newline at end of file From c0de1ae28d5331b692b0816eca501c1fb22b184a Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Tue, 15 Feb 2022 10:56:49 +0100 Subject: [PATCH 06/12] #112 AbstractCompensation rendering enhancements * minor changes to detail view rendering of EMA, Compensation and EcoAccount --- .../compensation/includes/states-after.html | 14 +-- .../compensation/includes/states-before.html | 14 +-- .../eco_account/includes/states-after.html | 14 +-- .../eco_account/includes/states-before.html | 14 +-- .../ema/detail/includes/states-after.html | 14 +-- .../ema/detail/includes/states-before.html | 14 +-- locale/de/LC_MESSAGES/django.mo | Bin 37523 -> 37589 bytes locale/de/LC_MESSAGES/django.po | 91 +++++++++--------- 8 files changed, 90 insertions(+), 85 deletions(-) diff --git a/compensation/templates/compensation/detail/compensation/includes/states-after.html b/compensation/templates/compensation/detail/compensation/includes/states-after.html index 2c95ca1a..7faa0f1e 100644 --- a/compensation/templates/compensation/detail/compensation/includes/states-after.html +++ b/compensation/templates/compensation/detail/compensation/includes/states-after.html @@ -48,13 +48,13 @@ {% for state in after_states %} - {{ state.biotope_type }} - {% if state.biotope_type_details.count > 0 %} -
- {% for detail in state.biotope_type_details.all %} - {{detail.long_name}} - {% endfor %} - {% endif %} + {{ state.biotope_type.parent.long_name }} {% fa5_icon 'angle-right' %} {{ state.biotope_type.long_name }} ({{state.biotope_type.short_name}}) +
+ {% for detail in state.biotope_type_details.all %} + {{detail.long_name}} + {% empty %} + {% trans 'No biotope type details' %} + {% endfor %} {{ state.surface|floatformat:2 }} m² diff --git a/compensation/templates/compensation/detail/compensation/includes/states-before.html b/compensation/templates/compensation/detail/compensation/includes/states-before.html index d2ba3697..23faed43 100644 --- a/compensation/templates/compensation/detail/compensation/includes/states-before.html +++ b/compensation/templates/compensation/detail/compensation/includes/states-before.html @@ -48,13 +48,13 @@ {% for state in before_states %} - {{ state.biotope_type }} - {% if state.biotope_type_details.count > 0 %} -
- {% for detail in state.biotope_type_details.all %} - {{detail.long_name}} - {% endfor %} - {% endif %} + {{ state.biotope_type.parent.long_name }} {% fa5_icon 'angle-right' %} {{ state.biotope_type.long_name }} ({{state.biotope_type.short_name}}) +
+ {% for detail in state.biotope_type_details.all %} + {{detail.long_name}} + {% empty %} + {% trans 'No biotope type details' %} + {% endfor %} {{ state.surface|floatformat:2 }} m² diff --git a/compensation/templates/compensation/detail/eco_account/includes/states-after.html b/compensation/templates/compensation/detail/eco_account/includes/states-after.html index bead6f2b..4fce2f0f 100644 --- a/compensation/templates/compensation/detail/eco_account/includes/states-after.html +++ b/compensation/templates/compensation/detail/eco_account/includes/states-after.html @@ -48,13 +48,13 @@ {% for state in after_states %} - {{ state.biotope_type }} - {% if state.biotope_type_details.count > 0 %} -
- {% for detail in state.biotope_type_details.all %} - {{detail.long_name}} - {% endfor %} - {% endif %} + {{ state.biotope_type.parent.long_name }} {% fa5_icon 'angle-right' %} {{ state.biotope_type.long_name }} ({{state.biotope_type.short_name}}) +
+ {% for detail in state.biotope_type_details.all %} + {{detail.long_name}} + {% empty %} + {% trans 'No biotope type details' %} + {% endfor %} {{ state.surface|floatformat:2 }} m² diff --git a/compensation/templates/compensation/detail/eco_account/includes/states-before.html b/compensation/templates/compensation/detail/eco_account/includes/states-before.html index c19b4049..1c6311cb 100644 --- a/compensation/templates/compensation/detail/eco_account/includes/states-before.html +++ b/compensation/templates/compensation/detail/eco_account/includes/states-before.html @@ -48,13 +48,13 @@ {% for state in before_states %} - {{ state.biotope_type }} - {% if state.biotope_type_details.count > 0 %} -
- {% for detail in state.biotope_type_details.all %} - {{detail.long_name}} - {% endfor %} - {% endif %} + {{ state.biotope_type.parent.long_name }} {% fa5_icon 'angle-right' %} {{ state.biotope_type.long_name }} ({{state.biotope_type.short_name}}) +
+ {% for detail in state.biotope_type_details.all %} + {{detail.long_name}} + {% empty %} + {% trans 'No biotope type details' %} + {% endfor %} {{ state.surface|floatformat:2 }} m² diff --git a/ema/templates/ema/detail/includes/states-after.html b/ema/templates/ema/detail/includes/states-after.html index e09f4ba5..56e87be1 100644 --- a/ema/templates/ema/detail/includes/states-after.html +++ b/ema/templates/ema/detail/includes/states-after.html @@ -46,13 +46,13 @@ {% for state in after_states %} - {{ state.biotope_type }} - {% if state.biotope_type_details.count > 0 %} -
- {% for detail in state.biotope_type_details.all %} - {{detail.long_name}} - {% endfor %} - {% endif %} + {{ state.biotope_type.parent.long_name }} {% fa5_icon 'angle-right' %} {{ state.biotope_type.long_name }} ({{state.biotope_type.short_name}}) +
+ {% for detail in state.biotope_type_details.all %} + {{detail.long_name}} + {% empty %} + {% trans 'No biotope type details' %} + {% endfor %} {{ state.surface|floatformat:2 }} m² diff --git a/ema/templates/ema/detail/includes/states-before.html b/ema/templates/ema/detail/includes/states-before.html index 1369829b..2fd7c359 100644 --- a/ema/templates/ema/detail/includes/states-before.html +++ b/ema/templates/ema/detail/includes/states-before.html @@ -46,13 +46,13 @@ {% for state in before_states %} - {{ state.biotope_type }} - {% if state.biotope_type_details.count > 0 %} -
- {% for detail in state.biotope_type_details.all %} - {{detail.long_name}} - {% endfor %} - {% endif %} + {{ state.biotope_type.parent.long_name }} {% fa5_icon 'angle-right' %} {{ state.biotope_type.long_name }} ({{state.biotope_type.short_name}}) +
+ {% for detail in state.biotope_type_details.all %} + {{detail.long_name}} + {% empty %} + {% trans 'No biotope type details' %} + {% endfor %} {{ state.surface|floatformat:2 }} m² diff --git a/locale/de/LC_MESSAGES/django.mo b/locale/de/LC_MESSAGES/django.mo index e9a94ccb374f1fcb49ae6b60cf0df3131a61819d..cbbff8e8beb3e75746f17607296ed15d29eb4fd1 100644 GIT binary patch delta 10433 zcmYk?2Y63s|Htu@kVNd2B}gKO7zq(#l*Aq(X6#rMiU?w_{_NPn&!$HIc1y)Bj}dCr zRu#2(Y0WB+)`RE&{^Z=Qr{}u9Uf=sZ3*E!BF0=}wZY+hvF#>hpCd`X_jK@*;UB+O% zYwF!9T2^7og)u*dVgc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?y`FwR~>eUM)d^h-|mo0Dy|D_+3IIWvc% z<1G1Fe77XyRkrJj$cIw$$v0po{+seE@h_B##Oaiui05N_$|d6QlsAe0IzH1ocMlay zDC?K~&VB7TMPAn~)< z^l#Tk5Jyt_Qm8 zV)?z~UsLvykEU!T-bQ(pvW~ouUH2q;ZHpHX|8=}$b;?gsmRo)kzauZBZ}vr<ov6M{Wx3Q3-znvaM9h2}I%9k$XpL`y(FxU!?4&=s1ceD4!Egz#5bR#NSY2DOJh4Q^rw_Qx;PiQ{LxX z$wAzSU^u>tSG7j}pe&;#Qt>dF8N~7JNvcsck=(>Ad;nhwyjHJ4Mm4g(AKNTXqw)wPoV*L=W#Z!9 Ul~NnT?H, YEAR. # -#: compensation/filters.py:122 compensation/forms/modalForms.py:37 -#: compensation/forms/modalForms.py:48 compensation/forms/modalForms.py:64 -#: compensation/forms/modalForms.py:357 compensation/forms/modalForms.py:469 +#: compensation/filters.py:122 compensation/forms/modalForms.py:36 +#: compensation/forms/modalForms.py:47 compensation/forms/modalForms.py:63 +#: compensation/forms/modalForms.py:356 compensation/forms/modalForms.py:463 #: intervention/forms/forms.py:54 intervention/forms/forms.py:156 #: intervention/forms/forms.py:168 intervention/forms/modalForms.py:127 #: intervention/forms/modalForms.py:140 intervention/forms/modalForms.py:153 @@ -26,7 +26,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2022-02-15 10:08+0100\n" +"POT-Creation-Date: 2022-02-15 10:53+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \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:453 +#: compensation/forms/modalForms.py:447 #: 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:195 +#: compensation/forms/modalForms.py:194 #: 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 @@ -246,7 +246,7 @@ msgid "Compensation" msgstr "Kompensation" #: analysis/templates/analysis/reports/includes/intervention/compensated_by.html:21 -#: compensation/forms/modalForms.py:77 +#: compensation/forms/modalForms.py:76 msgid "Payment" msgstr "Zahlung" @@ -352,8 +352,8 @@ msgstr "Aussagekräftiger Titel" msgid "Compensation XY; Location ABC" msgstr "Kompensation XY; Flur ABC" -#: compensation/forms/forms.py:57 compensation/forms/modalForms.py:63 -#: compensation/forms/modalForms.py:356 compensation/forms/modalForms.py:468 +#: compensation/forms/forms.py:57 compensation/forms/modalForms.py:62 +#: compensation/forms/modalForms.py:355 compensation/forms/modalForms.py:462 #: 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:34 @@ -371,7 +371,7 @@ msgstr "Kompensation XY; Flur ABC" msgid "Comment" msgstr "Kommentar" -#: compensation/forms/forms.py:59 compensation/forms/modalForms.py:470 +#: compensation/forms/forms.py:59 compensation/forms/modalForms.py:464 #: intervention/forms/forms.py:182 msgid "Additional comment" msgstr "Zusätzlicher Kommentar" @@ -469,73 +469,73 @@ msgstr "Ökokonto XY; Flur ABC" msgid "Edit Eco-Account" msgstr "Ökokonto bearbeiten" -#: compensation/forms/modalForms.py:38 +#: compensation/forms/modalForms.py:37 msgid "in Euro" msgstr "in Euro" -#: compensation/forms/modalForms.py:47 +#: compensation/forms/modalForms.py:46 #: intervention/templates/intervention/detail/includes/payments.html:31 msgid "Due on" msgstr "Fällig am" -#: compensation/forms/modalForms.py:50 +#: compensation/forms/modalForms.py:49 msgid "Due on which date" msgstr "Zahlung wird an diesem Datum erwartet" -#: compensation/forms/modalForms.py:65 compensation/forms/modalForms.py:358 +#: compensation/forms/modalForms.py:64 compensation/forms/modalForms.py:357 #: intervention/forms/modalForms.py:154 konova/forms.py:395 msgid "Additional comment, maximum {} letters" msgstr "Zusätzlicher Kommentar, maximal {} Zeichen" -#: compensation/forms/modalForms.py:78 +#: compensation/forms/modalForms.py:77 msgid "Add a payment for intervention '{}'" msgstr "Neue Ersatzzahlung zu Eingriff '{}' hinzufügen" -#: compensation/forms/modalForms.py:98 +#: compensation/forms/modalForms.py:97 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:159 compensation/forms/modalForms.py:171 +#: compensation/forms/modalForms.py:158 compensation/forms/modalForms.py:170 msgid "Biotope Type" msgstr "Biotoptyp" -#: compensation/forms/modalForms.py:162 +#: compensation/forms/modalForms.py:161 msgid "Select the biotope type" msgstr "Biotoptyp wählen" -#: compensation/forms/modalForms.py:176 compensation/forms/modalForms.py:188 +#: compensation/forms/modalForms.py:175 compensation/forms/modalForms.py:187 msgid "Biotope additional type" msgstr "Zusatzbezeichnung" -#: compensation/forms/modalForms.py:179 +#: compensation/forms/modalForms.py:178 msgid "Select an additional biotope type" msgstr "Zusatzbezeichnung wählen" -#: compensation/forms/modalForms.py:198 intervention/forms/modalForms.py:340 +#: compensation/forms/modalForms.py:197 intervention/forms/modalForms.py:340 msgid "in m²" msgstr "" -#: compensation/forms/modalForms.py:209 +#: compensation/forms/modalForms.py:208 msgid "New state" msgstr "Neuer Zustand" -#: compensation/forms/modalForms.py:210 +#: compensation/forms/modalForms.py:209 msgid "Insert data for the new state" msgstr "Geben Sie die Daten des neuen Zustandes ein" -#: compensation/forms/modalForms.py:217 konova/forms.py:193 +#: compensation/forms/modalForms.py:216 konova/forms.py:193 msgid "Object removed" msgstr "Objekt entfernt" -#: compensation/forms/modalForms.py:328 +#: compensation/forms/modalForms.py:327 msgid "Deadline Type" msgstr "Fristart" -#: compensation/forms/modalForms.py:331 +#: compensation/forms/modalForms.py:330 msgid "Select the deadline type" msgstr "Fristart wählen" -#: compensation/forms/modalForms.py:340 +#: compensation/forms/modalForms.py:339 #: 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,51 +543,51 @@ msgstr "Fristart wählen" msgid "Date" msgstr "Datum" -#: compensation/forms/modalForms.py:343 +#: compensation/forms/modalForms.py:342 msgid "Select date" msgstr "Datum wählen" -#: compensation/forms/modalForms.py:370 +#: compensation/forms/modalForms.py:369 msgid "New deadline" msgstr "Neue Frist" -#: compensation/forms/modalForms.py:371 +#: compensation/forms/modalForms.py:370 msgid "Insert data for the new deadline" msgstr "Geben Sie die Daten der neuen Frist ein" -#: compensation/forms/modalForms.py:411 +#: compensation/forms/modalForms.py:410 msgid "Action Type" msgstr "Maßnahmentyp" -#: compensation/forms/modalForms.py:414 +#: compensation/forms/modalForms.py:413 msgid "Select the action type" msgstr "Maßnahmentyp wählen" -#: compensation/forms/modalForms.py:424 compensation/forms/modalForms.py:436 +#: compensation/forms/modalForms.py:418 compensation/forms/modalForms.py:430 msgid "Action Type detail" msgstr "Zusatzmerkmal" -#: compensation/forms/modalForms.py:427 +#: compensation/forms/modalForms.py:421 msgid "Select the action type detail" msgstr "Zusatzmerkmal wählen" -#: compensation/forms/modalForms.py:441 +#: compensation/forms/modalForms.py:435 msgid "Unit" msgstr "Einheit" -#: compensation/forms/modalForms.py:444 +#: compensation/forms/modalForms.py:438 msgid "Select the unit" msgstr "Einheit wählen" -#: compensation/forms/modalForms.py:456 +#: compensation/forms/modalForms.py:450 msgid "Insert the amount" msgstr "Menge eingeben" -#: compensation/forms/modalForms.py:481 +#: compensation/forms/modalForms.py:475 msgid "New action" msgstr "Neue Maßnahme" -#: compensation/forms/modalForms.py:482 +#: compensation/forms/modalForms.py:476 msgid "Insert data for the new action" msgstr "Geben Sie die Daten der neuen Maßnahme ein" @@ -751,18 +751,19 @@ msgstr "Aktionen" #: compensation/templates/compensation/detail/compensation/includes/actions.html:57 #: compensation/templates/compensation/detail/eco_account/includes/actions.html:56 +#: ema/templates/ema/detail/includes/actions.html:54 msgid "No action type details" msgstr "Keine Zusatzmerkmale" #: compensation/templates/compensation/detail/compensation/includes/actions.html:68 #: compensation/templates/compensation/detail/eco_account/includes/actions.html:67 -#: ema/templates/ema/detail/includes/actions.html:67 +#: ema/templates/ema/detail/includes/actions.html:65 msgid "Edit action" msgstr "Maßnahme bearbeiten" #: compensation/templates/compensation/detail/compensation/includes/actions.html:71 #: compensation/templates/compensation/detail/eco_account/includes/actions.html:70 -#: ema/templates/ema/detail/includes/actions.html:70 +#: ema/templates/ema/detail/includes/actions.html:68 msgid "Remove action" msgstr "Maßnahme entfernen" @@ -892,7 +893,7 @@ msgid "Biotope type" msgstr "Biotoptyp" #: compensation/templates/compensation/detail/compensation/includes/states-after.html:62 -#: compensation/templates/compensation/detail/compensation/includes/states-before.html:62 +#: compensation/templates/compensation/detail/compensation/includes/states-before.html:64 #: compensation/templates/compensation/detail/eco_account/includes/states-after.html:62 #: compensation/templates/compensation/detail/eco_account/includes/states-before.html:62 #: ema/templates/ema/detail/includes/states-after.html:60 @@ -901,7 +902,7 @@ msgid "Edit state" msgstr "Zustand bearbeiten" #: compensation/templates/compensation/detail/compensation/includes/states-after.html:65 -#: compensation/templates/compensation/detail/compensation/includes/states-before.html:65 +#: compensation/templates/compensation/detail/compensation/includes/states-before.html:67 #: compensation/templates/compensation/detail/eco_account/includes/states-after.html:65 #: compensation/templates/compensation/detail/eco_account/includes/states-before.html:65 #: ema/templates/ema/detail/includes/states-after.html:63 @@ -928,6 +929,10 @@ msgstr "Neuen Ausgangszustand hinzufügen" msgid "Missing surfaces according to states after: " msgstr "Fehlende Flächenmengen laut Zielzustand: " +#: compensation/templates/compensation/detail/compensation/includes/states-before.html:57 +msgid "No biotope type details" +msgstr "Keine Zusatzbezeichnungen" + #: compensation/templates/compensation/detail/compensation/view.html:44 msgid "Is CEF compensation" msgstr "Ist CEF Maßnahme" From 4be26fbc226d005f0171fbb79800efb2f6140799 Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Tue, 15 Feb 2022 11:32:20 +0100 Subject: [PATCH 07/12] #112 CompensationAction explanation * updates the help_text for action_type on NewActionModalForm to give a better explanation --- compensation/forms/modalForms.py | 2 +- locale/de/LC_MESSAGES/django.mo | Bin 37589 -> 37895 bytes locale/de/LC_MESSAGES/django.po | 31 ++++++++++++++++++++++--------- 3 files changed, 23 insertions(+), 10 deletions(-) diff --git a/compensation/forms/modalForms.py b/compensation/forms/modalForms.py index a8d38aa2..cdcc26e9 100644 --- a/compensation/forms/modalForms.py +++ b/compensation/forms/modalForms.py @@ -410,7 +410,7 @@ class NewActionModalForm(BaseModalForm): label=_("Action Type"), label_suffix="", required=True, - help_text=_("Select the action type"), + help_text=_("An action can consist of multiple different action types. All the selected action types are expected to be performed according to the amount and unit below on this form."), choices=[], widget=CompensationActionTreeCheckboxSelectMultiple(), ) diff --git a/locale/de/LC_MESSAGES/django.mo b/locale/de/LC_MESSAGES/django.mo index cbbff8e8beb3e75746f17607296ed15d29eb4fd1..87e1e03a5d6b5139726bf84ca2cdc849f3fe98fe 100644 GIT binary patch delta 10588 zcmY+}3w+LX|Httk8n!vljA>jpY_l12TIQ^A%b0|m%WRkJVkg@*bLi~x z%K5f9jgFlwf=;aDc?f9SH6wo)WQI) zhGD1y#$s)3k9t3)jgOloqp8r0reiQZkDB>r)X4XtR^%Ag#h*|e{f+9NVq3?lfx)PT zn_?&?VnZB+>ZcI(UNLIGD}1(M1M0=CsDXTdTG}J1hL59OyntHTKTrd@gAZU}J2T@N zs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CP9)pH*^&0@y7ns9mOE0uMeL$Hh}b~>B{7#+PPwDKZW-mbY(Aa* z_3^E(Q#q5EZ_EG1yZTY}A-QR<9%@f|QLaS(0WM5y5LT${C9+I=)?VzSQ{GMCDh3eM z(o(`ogx`358bgWG#P^(SNqkO3QU0AsO3MiIcYh`uMr|pg8~JU*p9rQLM+_lO6SIh_ z#CM#_I>?)l^ut~F2*(j~i4v4w5+4%fDbL5($7dvUi2Bse)X&TX5*@9qv&i=liz#;_ zJ|}NS=*VHOIg4RLhN*T^$QzIc6aONAhE1>+?nE7f3|W81|C1LoS!Y}E4i--m\n" "Language-Team: LANGUAGE \n" @@ -560,8 +560,13 @@ msgid "Action Type" msgstr "Maßnahmentyp" #: compensation/forms/modalForms.py:413 -msgid "Select the action type" -msgstr "Maßnahmentyp wählen" +msgid "" +"An action can consist of multiple different action types. All the selected " +"action types are expected to be performed according to the amount and unit " +"below on this form." +msgstr "" +"Eine Maßnahme kann aus mehreren verschiedenen Maßnahmentypen bestehen. Alle hier gewählten " +"Einträge sollen mit der weiter unten angegebenen Einheit und Menge umgesetzt werden. " #: compensation/forms/modalForms.py:418 compensation/forms/modalForms.py:430 msgid "Action Type detail" @@ -892,8 +897,17 @@ msgstr "Fehlende Flächenmengen laut Ausgangszustand: " msgid "Biotope type" msgstr "Biotoptyp" +#: compensation/templates/compensation/detail/compensation/includes/states-after.html:56 +#: compensation/templates/compensation/detail/compensation/includes/states-before.html:56 +#: compensation/templates/compensation/detail/eco_account/includes/states-after.html:56 +#: compensation/templates/compensation/detail/eco_account/includes/states-before.html:56 +#: ema/templates/ema/detail/includes/states-after.html:54 +#: ema/templates/ema/detail/includes/states-before.html:54 +msgid "No biotope type details" +msgstr "Keine Zusatzbezeichnungen" + #: compensation/templates/compensation/detail/compensation/includes/states-after.html:62 -#: compensation/templates/compensation/detail/compensation/includes/states-before.html:64 +#: compensation/templates/compensation/detail/compensation/includes/states-before.html:62 #: compensation/templates/compensation/detail/eco_account/includes/states-after.html:62 #: compensation/templates/compensation/detail/eco_account/includes/states-before.html:62 #: ema/templates/ema/detail/includes/states-after.html:60 @@ -902,7 +916,7 @@ msgid "Edit state" msgstr "Zustand bearbeiten" #: compensation/templates/compensation/detail/compensation/includes/states-after.html:65 -#: compensation/templates/compensation/detail/compensation/includes/states-before.html:67 +#: compensation/templates/compensation/detail/compensation/includes/states-before.html:65 #: compensation/templates/compensation/detail/eco_account/includes/states-after.html:65 #: compensation/templates/compensation/detail/eco_account/includes/states-before.html:65 #: ema/templates/ema/detail/includes/states-after.html:63 @@ -929,10 +943,6 @@ msgstr "Neuen Ausgangszustand hinzufügen" msgid "Missing surfaces according to states after: " msgstr "Fehlende Flächenmengen laut Zielzustand: " -#: compensation/templates/compensation/detail/compensation/includes/states-before.html:57 -msgid "No biotope type details" -msgstr "Keine Zusatzbezeichnungen" - #: compensation/templates/compensation/detail/compensation/view.html:44 msgid "Is CEF compensation" msgstr "Ist CEF Maßnahme" @@ -3993,6 +4003,9 @@ msgstr "" msgid "Unable to connect to qpid with SASL mechanism %s" msgstr "" +#~ msgid "Select the action type" +#~ msgstr "Maßnahmentyp wählen" + #~ msgid "No revocation" #~ msgstr "Kein Widerspruch" From 6d5e2b8d1508bf753f934eb23016aaa0f96414d9 Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Tue, 15 Feb 2022 13:23:15 +0100 Subject: [PATCH 08/12] #112 TreeWidget JS * adds visual support on (de-)selecting checkboxes * adds same support on initialization of checked checkboxes e.g. on edit forms --- .../widgets/checkbox-tree-select-content.html | 21 +++++++ .../konova/widgets/checkbox-tree-select.html | 63 ++++++++++++------- 2 files changed, 62 insertions(+), 22 deletions(-) create mode 100644 konova/templates/konova/widgets/checkbox-tree-select-content.html diff --git a/konova/templates/konova/widgets/checkbox-tree-select-content.html b/konova/templates/konova/widgets/checkbox-tree-select-content.html new file mode 100644 index 00000000..9bf57253 --- /dev/null +++ b/konova/templates/konova/widgets/checkbox-tree-select-content.html @@ -0,0 +1,21 @@ +{% load l10n fontawesome_5 %} + +{% for code in codes %} +
+ + {% if not code.is_leaf %} +
+ {% with code.children as codes %} + {% include 'konova/widgets/checkbox-tree-select-content.html' %} + {% endwith %} +
+ {% endif %} +
+{% endfor %} \ No newline at end of file diff --git a/konova/templates/konova/widgets/checkbox-tree-select.html b/konova/templates/konova/widgets/checkbox-tree-select.html index 5b40d3f1..ddcc60c0 100644 --- a/konova/templates/konova/widgets/checkbox-tree-select.html +++ b/konova/templates/konova/widgets/checkbox-tree-select.html @@ -1,23 +1,42 @@ -{% load l10n fontawesome_5 %} +
+ {% include 'konova/widgets/checkbox-tree-select-content.html' %} +
-
- {% for code in codes %} -
- - {% if not code.is_leaf %} -
- {% with code.children as codes %} - {% include 'konova/widgets/checkbox-tree-select.html' %} - {% endwith %} -
- {% endif %} -
- {% endfor %} -
\ No newline at end of file + \ No newline at end of file From 1ea5b4fc39b33a5b6a503cd5e70833c3e957c663 Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Tue, 15 Feb 2022 14:35:49 +0100 Subject: [PATCH 09/12] # 112 Search input for TreeWidget * adds search input field for js-filtering by input --- .../konova/widgets/checkbox-tree-select.html | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/konova/templates/konova/widgets/checkbox-tree-select.html b/konova/templates/konova/widgets/checkbox-tree-select.html index ddcc60c0..3129be8a 100644 --- a/konova/templates/konova/widgets/checkbox-tree-select.html +++ b/konova/templates/konova/widgets/checkbox-tree-select.html @@ -1,3 +1,9 @@ +{% load i18n %} + +
+ +
+
{% include 'konova/widgets/checkbox-tree-select-content.html' %}
@@ -31,6 +37,22 @@ toggleSelectedCssClass(this); } + function searchInputHandler(event){ + var elem = $(this); + var val = elem.val() + var allTreeElements = $(".tree-element") + var allTreeElementsContain = $(".tree-element:contains(" + val + ")") + if(val.length > 0){ + allTreeElements.hide() + allTreeElementsContain.show() + }else{ + allTreeElements.show() + } + } + + // Add event listener on search input + $("#tree-search-input").keyup(searchInputHandler) + // Add event listener on changed checkboxes $(".tree-input").change(changeHandler); From a160f3fe6ca1caeb4082d7c526ec03c04403b883 Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Tue, 15 Feb 2022 15:33:25 +0100 Subject: [PATCH 10/12] #112 Autocomplete enhancements * enhances filtering for Autocomplete -> parent_parent will be searched for match as well * adds rendering of parent_parent group for BiotopeAutocomplete * enhances ordering of registration office autocomplete --- konova/autocompletes.py | 49 +++++++++++++++++++++++++++++- konova/static/css/konova.css | 13 ++++++-- konova/utils/message_templates.py | 2 +- locale/de/LC_MESSAGES/django.mo | Bin 37895 -> 37936 bytes locale/de/LC_MESSAGES/django.po | 20 +++++++----- 5 files changed, 73 insertions(+), 11 deletions(-) diff --git a/konova/autocompletes.py b/konova/autocompletes.py index 3a79ab68..b07e2088 100644 --- a/konova/autocompletes.py +++ b/konova/autocompletes.py @@ -5,7 +5,12 @@ Contact: michel.peltriaux@sgdnord.rlp.de Created on: 07.12.20 """ +import collections + from dal_select2.views import Select2QuerySetView, Select2GroupQuerySetView +from django.core.exceptions import ImproperlyConfigured + +from konova.utils.message_templates import UNGROUPED from user.models import User from django.db.models import Q @@ -139,6 +144,8 @@ class KonovaCodeAutocomplete(Select2GroupQuerySetView): q_or |= Q(short_name__icontains=keyword) q_or |= Q(parent__long_name__icontains=keyword) q_or |= Q(parent__short_name__icontains=keyword) + q_or |= Q(parent__parent__long_name__icontains=keyword) + q_or |= Q(parent__parent__short_name__icontains=keyword) _filter.add(q_or, Q.AND) qs = qs.filter(_filter).distinct() return qs @@ -214,6 +221,41 @@ class BiotopeCodeAutocomplete(KonovaCodeAutocomplete): def get_result_label(self, result): return f"{result.long_name} ({result.short_name})" + def get_results(self, context): + """Return the options grouped by a common related model. + + Raises ImproperlyConfigured if self.group_by_name is not configured + """ + if not self.group_by_related: + raise ImproperlyConfigured("Missing group_by_related.") + + super_groups = collections.OrderedDict() + + object_list = context['object_list'] + + for result in object_list: + group = result.parent if result.parent else None + group_name = f"{group.long_name} ({group.short_name})" if group else UNGROUPED + super_group = result.parent.parent if result.parent else None + super_group_name = f"{super_group.long_name} ({super_group.short_name})" if super_group else UNGROUPED + super_groups.setdefault(super_group_name, {}) + super_groups[super_group_name].setdefault(group_name, []) + super_groups[super_group_name][group_name].append(result) + + return [{ + 'id': None, + 'text': super_group, + 'children': [{ + "id": None, + "text": group, + "children": [{ + 'id': self.get_result_value(result), + 'text': self.get_result_label(result), + 'selected_text': self.get_selected_result_label(result), + } for result in results] + } for group, results in groups.items()] + } for super_group, groups in super_groups.items()] + class BiotopeExtraCodeAutocomplete(KonovaCodeAutocomplete): """ @@ -284,6 +326,11 @@ class RegistrationOfficeCodeAutocomplete(KonovaCodeAutocomplete): self.c = CODELIST_REGISTRATION_OFFICE_ID super().__init__(*args, **kwargs) + def order_by(self, qs): + return qs.order_by( + "parent__long_name" + ) + class ConservationOfficeCodeAutocomplete(KonovaCodeAutocomplete): """ @@ -297,4 +344,4 @@ class ConservationOfficeCodeAutocomplete(KonovaCodeAutocomplete): super().__init__(*args, **kwargs) def get_result_label(self, result): - return f"{result.long_name} ({result.short_name})" \ No newline at end of file + return f"{result.long_name} ({result.short_name})" diff --git a/konova/static/css/konova.css b/konova/static/css/konova.css index 709d3eb3..7e7f3fd1 100644 --- a/konova/static/css/konova.css +++ b/konova/static/css/konova.css @@ -242,15 +242,24 @@ Similar to bootstraps 'shadow-lg' .select2-results__option--highlighted{ background-color: var(--rlp-red) !important; } +/* .select2-container--default .select2-results__group{ background-color: var(--rlp-gray-light); } .select2-container--default .select2-results__option .select2-results__option{ - padding-left: 2em !important; + padding-left: 1em !important; +} + + */ +.select2-results__options--nested{ + padding-left: 1em !important; } .select2-container--default .select2-results > .select2-results__options{ max-height: 500px !important; } +/* .select2-container--default .select2-results__option .select2-results__option{ padding-left: 2em; -} \ No newline at end of file +} + + */ \ No newline at end of file diff --git a/konova/utils/message_templates.py b/konova/utils/message_templates.py index c7a2be00..5809b3b6 100644 --- a/konova/utils/message_templates.py +++ b/konova/utils/message_templates.py @@ -7,7 +7,7 @@ Created on: 02.08.21 """ from django.utils.translation import gettext_lazy as _ - +UNGROUPED = _("Ungrouped") FORM_INVALID = _("There was an error on this form.") PARAMS_INVALID = _("Invalid parameters") INTERVENTION_INVALID = _("There are errors in this intervention.") diff --git a/locale/de/LC_MESSAGES/django.mo b/locale/de/LC_MESSAGES/django.mo index 87e1e03a5d6b5139726bf84ca2cdc849f3fe98fe..022e9e1a728d186a0e8be95eee8ae29ea5928bee 100644 GIT binary patch delta 8795 zcmYkNxNCIL<%g)ap1*8ahrW_nM+hJuky?X5(?3fsZzFoW6J#M`6oM z$LWbHaTeaf`Z%dE_pl6W;vuZ%I9}%@gy-})V@-vvyE;#~6cO zVI90^@Bhyl($oZ8A5*#C1l7MER>LQen4G84kNKT9DZGd8peF9#%&c@UYK0?E6Hmry zT!?}A9){yaRL1tAGW3=8N322pqODh=`u}O`QO(J}IwnzIo1BK2i2YHSn1cQ|57W>^ zt$aHw#m6xM%dNj+0QJCZ)2|lRqFxu3flO3@?XWg>%_jdEpoj(?l5waNm0~2WK&^Z$ zD)Mho8M%Z?{jaD1Lt2;#qA-kl3ToVzSQopY&hs$TJTId9z1xEPE8_QU!zNV69jHJK zqcU_3HSiTw$0}56eOj7;g0VXFSk#K+ZF_Un%JWbeeF!zq5Y!fq^-@p(Q?NVE!W=w| z^DuylIxa?a{0Azqk5K{aM@?`9wbF7_fPbI@uinbkgHZECSnFXVb#Dp<4bT=fQ8!d% z15pDEMNRmOy+0MT_X|*axdgQ(tL*(v7)AXHd;cWryK)(8qi<_7ab2Xp*J(mQ1GYzX z?22hP1ho|}VIy2->j$uq`e{_kGuxO2G()X050$BIsBs6O7Ep`|bdq(>y>|BhH456Z z)uba*;{l;P}PDTa(ItJRG{my4(>p0*>Tj0E~7H@A56e%9nCl? zsI6;*T427l0JTLuI(qG%(V&zLMNKpcwFS?k+NYrgco}sjUPax16BWSUQK?>uTF^Sw z1lv*1?MB_-iwfuv>X3ftwS`NlGw?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vME>% z7o$%5Dh$Jos6hAF>))VX51gier&~--oeSh|1iL z*bc)NnbV(*mFbVSPPD$hi2UoqR0g#3nfAh5Q~-ZL1-1;e!@t_=A6hqHAmbZR&u>HB z|C#OYNA36k>d+mx<3FM9`(+XJR{+1+3wKZx-a{=Iu-Hr-jJhujn_w+$iXE^yj={G0 zSKB{}3Mlj~^O}a^lk{^?-y^G0Z_7?UjaVATFb>Nw0V7;vI_eAzz(gE|&2RzgFnx~I z@f_;DQro|S9{Reb`SdfGf%AOIX~*N^eB5I(^}>Fmp?dub&$z$G_yTv+`q52{9TWHs zt>4|{u?@nm(<wbfoHIlCLR@O}M4#t?J0Wqh=dxSINTC~*l|DTQYKV#q`M)7G)`zv=rO5Kh> z)4TkCw\n" "Language-Team: LANGUAGE \n" @@ -565,8 +565,9 @@ msgid "" "action types are expected to be performed according to the amount and unit " "below on this form." msgstr "" -"Eine Maßnahme kann aus mehreren verschiedenen Maßnahmentypen bestehen. Alle hier gewählten " -"Einträge sollen mit der weiter unten angegebenen Einheit und Menge umgesetzt werden. " +"Eine Maßnahme kann aus mehreren verschiedenen Maßnahmentypen bestehen. Alle " +"hier gewählten Einträge sollen mit der weiter unten angegebenen Einheit und " +"Menge umgesetzt werden. " #: compensation/forms/modalForms.py:418 compensation/forms/modalForms.py:430 msgid "Action Type detail" @@ -1765,6 +1766,11 @@ msgstr "Neu" msgid "Show" msgstr "Anzeigen" +#: konova/templates/konova/widgets/checkbox-tree-select.html:4 +#: templates/generic_index.html:56 +msgid "Search" +msgstr "Suchen" + #: konova/templates/konova/widgets/generate-content-input.html:6 msgid "Generate new" msgstr "Neu generieren" @@ -1805,6 +1811,10 @@ msgstr "{} - Freigegebene Daten geprüft" msgid "Request for new API token" msgstr "Anfrage für neuen API Token" +#: konova/utils/message_templates.py:10 +msgid "Ungrouped" +msgstr "Ohne Zuordnung" + #: konova/utils/message_templates.py:11 msgid "There was an error on this form." msgstr "Es gab einen Fehler im Formular." @@ -2270,10 +2280,6 @@ msgstr "Neu" msgid "Search for keywords" msgstr "Nach Schlagwörtern suchen" -#: templates/generic_index.html:56 -msgid "Search" -msgstr "Suchen" - #: templates/generic_index.html:57 msgid "Start search" msgstr "Starte Suche" From ed27d8d589fd298be47bf835c56a605a96048753 Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Wed, 16 Feb 2022 08:26:24 +0100 Subject: [PATCH 11/12] #112 Order enhancement * enhances ordering for action details and biotope details --- konova/autocompletes.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/konova/autocompletes.py b/konova/autocompletes.py index b07e2088..432df614 100644 --- a/konova/autocompletes.py +++ b/konova/autocompletes.py @@ -188,7 +188,7 @@ class CompensationActionDetailCodeAutocomplete(KonovaCodeAutocomplete): def order_by(self, qs): return qs.order_by( - "parent__long_name" + "long_name" ) @@ -281,7 +281,7 @@ class BiotopeExtraCodeAutocomplete(KonovaCodeAutocomplete): qs (QuerySet): The ordered queryset """ return qs.order_by( - "parent__long_name", + "long_name", ) def get_result_label(self, result): From 91185ef847c02d68bd9f2f91248747bdd429d07f Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Wed, 16 Feb 2022 08:31:18 +0100 Subject: [PATCH 12/12] #112 Tree filter case insensitive search * adds case insensitive search for TreeWidget --- konova/templates/konova/widgets/checkbox-tree-select.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/konova/templates/konova/widgets/checkbox-tree-select.html b/konova/templates/konova/widgets/checkbox-tree-select.html index 3129be8a..c2b107cc 100644 --- a/konova/templates/konova/widgets/checkbox-tree-select.html +++ b/konova/templates/konova/widgets/checkbox-tree-select.html @@ -41,7 +41,11 @@ var elem = $(this); var val = elem.val() var allTreeElements = $(".tree-element") - var allTreeElementsContain = $(".tree-element:contains(" + val + ")") + var allTreeElementsContain = $(".tree-element").filter(function(){ + var reg = new RegExp(val, "i"); + return reg.test($(this).text()); + } + ); if(val.length > 0){ allTreeElements.hide() allTreeElementsContain.show()