snapshot: preserve form and app shell alignment before component unification

This commit is contained in:
Md Bayazid Bostame
2026-03-27 23:43:00 +01:00
parent 930f28522b
commit 631886a763
41 changed files with 1198 additions and 695 deletions

View File

@@ -1,7 +1,7 @@
from collections import OrderedDict
from django import forms
from django.utils.text import slugify
from django.utils.translation import get_language
from django.utils.translation import get_language, gettext_lazy as _
from .models import FormConditionalRuleConfig, FormCustomFieldConfig, FormCustomSectionConfig, FormFieldConfig, FormSectionConfig
@@ -62,15 +62,15 @@ DEFAULT_FIELD_ORDER = {
ONBOARDING_PAGE_ORDER = ['stammdaten', 'vertrag', 'itsetup', 'abschluss']
OFFBOARDING_PAGE_ORDER = ['mitarbeitende', 'austritt', 'abschluss']
ONBOARDING_PAGE_LABELS = {
'stammdaten': '1. Stammdaten',
'vertrag': '2. Vertrag',
'itsetup': '3. IT-Setup',
'abschluss': '4. Abschluss',
'stammdaten': _('1. Stammdaten'),
'vertrag': _('2. Vertrag'),
'itsetup': _('3. IT-Setup'),
'abschluss': _('4. Abschluss'),
}
OFFBOARDING_PAGE_LABELS = {
'mitarbeitende': '1. Mitarbeitende',
'austritt': '2. Austritt',
'abschluss': '3. Abschluss',
'mitarbeitende': _('1. Mitarbeitende'),
'austritt': _('2. Austritt'),
'abschluss': _('3. Abschluss'),
}
CORE_SECTION_LABELS = {
'onboarding': ONBOARDING_PAGE_LABELS,
@@ -500,7 +500,7 @@ def apply_form_field_config(form_type: str, form) -> None:
FORM_PRESETS = {
'onboarding': {
'standard': {
'label': 'Standard',
'label': _('Standard'),
'sections': {
'stammdaten': True,
'vertrag': True,
@@ -510,7 +510,7 @@ FORM_PRESETS = {
'fields': {},
},
'lean': {
'label': 'Lean',
'label': _('Lean'),
'sections': {
'stammdaten': True,
'vertrag': True,
@@ -531,7 +531,7 @@ FORM_PRESETS = {
},
},
'it_heavy': {
'label': 'IT-heavy',
'label': _('IT-heavy'),
'sections': {
'stammdaten': True,
'vertrag': True,
@@ -553,7 +553,7 @@ FORM_PRESETS = {
},
'offboarding': {
'standard': {
'label': 'Standard',
'label': _('Standard'),
'sections': {
'mitarbeitende': True,
'austritt': True,
@@ -562,7 +562,7 @@ FORM_PRESETS = {
'fields': {},
},
'lean': {
'label': 'Lean',
'label': _('Lean'),
'sections': {
'mitarbeitende': True,
'austritt': True,
@@ -575,7 +575,7 @@ FORM_PRESETS = {
},
},
'hr_heavy': {
'label': 'HR-heavy',
'label': _('HR-heavy'),
'sections': {
'mitarbeitende': True,
'austritt': True,