feat: Refactor CPuls entity and related resources; enhance localization, update layouts, and improve validation logic
This commit is contained in:
@@ -15,7 +15,8 @@
|
||||
"Bereit",
|
||||
"In Review",
|
||||
"Teilweise abgeschlossen",
|
||||
"Abgeschlossen"
|
||||
"Abgeschlossen",
|
||||
"Finalisiert"
|
||||
],
|
||||
"default": "Neu",
|
||||
"required": true,
|
||||
@@ -26,7 +27,8 @@
|
||||
"Bereit": "success",
|
||||
"In Review": "warning",
|
||||
"Teilweise abgeschlossen": "info",
|
||||
"Abgeschlossen": "success"
|
||||
"Abgeschlossen": "success",
|
||||
"Finalisiert": "danger"
|
||||
}
|
||||
},
|
||||
"syncStatus": {
|
||||
@@ -66,24 +68,6 @@
|
||||
"notStorable": false,
|
||||
"isCustom": true
|
||||
},
|
||||
"finalisiert": {
|
||||
"type": "bool",
|
||||
"default": false,
|
||||
"readOnly": true,
|
||||
"isCustom": true,
|
||||
"tooltip": true
|
||||
},
|
||||
"finalisierungsGrund": {
|
||||
"type": "enum",
|
||||
"options": [
|
||||
"Erstes Team",
|
||||
"Manuell",
|
||||
"Automatisch"
|
||||
],
|
||||
"readOnly": true,
|
||||
"isCustom": true,
|
||||
"tooltip": true
|
||||
},
|
||||
"finalisiertAm": {
|
||||
"type": "datetime",
|
||||
"readOnly": true,
|
||||
@@ -95,6 +79,17 @@
|
||||
"readOnly": true,
|
||||
"isCustom": true
|
||||
},
|
||||
"mandantMitteilung": {
|
||||
"type": "bool",
|
||||
"default": false,
|
||||
"isCustom": true,
|
||||
"tooltip": true
|
||||
},
|
||||
"mandantMitteilungText": {
|
||||
"type": "text",
|
||||
"isCustom": true,
|
||||
"tooltip": true
|
||||
},
|
||||
"createdAt": {
|
||||
"type": "datetime",
|
||||
"readOnly": true
|
||||
@@ -117,10 +112,6 @@
|
||||
"type": "link",
|
||||
"entity": "User",
|
||||
"isCustom": true
|
||||
},
|
||||
"teams": {
|
||||
"type": "linkMultiple",
|
||||
"isCustom": true
|
||||
}
|
||||
},
|
||||
"links": {
|
||||
@@ -180,11 +171,8 @@
|
||||
"syncStatus": {
|
||||
"columns": ["syncStatus"]
|
||||
},
|
||||
"finalisiert": {
|
||||
"columns": ["finalisiert"]
|
||||
},
|
||||
"createdAt": {
|
||||
"columns": ["createdAt"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,12 +4,14 @@
|
||||
"type": "varchar",
|
||||
"notStorable": true,
|
||||
"select": {
|
||||
"select": "CONCAT:(team.name, ' - ', puls.name)"
|
||||
"select": "CONCAT:(team.name, ' - ', puls.name)",
|
||||
"leftJoins": ["team", "puls"]
|
||||
},
|
||||
"orderBy": {
|
||||
"order": [
|
||||
["team.name", "{direction}"]
|
||||
]
|
||||
],
|
||||
"leftJoins": ["team"]
|
||||
}
|
||||
},
|
||||
"puls": {
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
{
|
||||
"beforeSaveApiScript": "// Verhindere Abschluss bei unclean Status\nif (\n (status == 'Abgeschlossen' || entity\\isAttributeChanged('status'))\n && syncStatus == 'unclean'\n) {\n recordService\\throwBadRequest('Puls kann nicht abgeschlossen werden: Neue Dokumente vorhanden (Status: unclean). Bitte warten Sie auf die KI-Analyse.');\n}\n\n// Verhindere Änderungen an finalisiertem Puls\nif (\n finalisiert == true\n && entity\\isAttributeChanged('finalisiert') == false\n && (entity\\isAttributeChanged('status') || entity\\isAttributeChanged('syncStatus'))\n) {\n recordService\\throwBadRequest('Puls ist finalisiert. Neue Dokumente erzeugen automatisch einen neuen Block.');\n}"
|
||||
"beforeSaveApiScript": "// Verhindere Abschluss bei unclean Status\nif (\n entity\\isAttributeChanged('status') &&\n status == 'Abgeschlossen' &&\n syncStatus == 'unclean'\n) {\n recordService\\throwBadRequest('Puls kann nicht abgeschlossen werden: Neue Dokumente vorhanden (Status: unclean). Bitte warten Sie auf die KI-Analyse.');\n}\n\n// Verhindere Änderungen an finalisiertem Puls\nif (\n status == 'Finalisiert' &&\n !entity\\isAttributeChanged('status') &&\n (entity\\isAttributeChanged('syncStatus'))\n) {\n recordService\\throwBadRequest('Puls ist finalisiert. Neue Dokumente erzeugen automatisch einen neuen Block.');\n}"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user