S16 postgresql opslag added
All checks were successful
Build, test and publish / verify (push) Successful in 7m31s

This commit is contained in:
2026-11-04 17:10:25 +01:00
parent f59cad115a
commit 694bf3fa86
89 changed files with 3087 additions and 252 deletions

View File

@@ -174,6 +174,8 @@ import { DialogFrame } from './dialog-frame';
})
export class EntityEditor implements OnInit {
readonly target = input.required<EditorTarget>();
readonly revision = input<number>();
private originalRevision?: number;
readonly schoolId = input<number>();
readonly shows = input<Show[]>([]);
readonly closed = output<void>();
@@ -207,6 +209,7 @@ export class EntityEditor implements OnInit {
return `${labels[this.target().kind]} ${this.target().value ? 'bewerken' : 'toevoegen'}`;
}
ngOnInit(): void {
this.originalRevision = this.revision();
const target = this.target();
if (!target.value) return;
if (target.kind === 'group') {
@@ -298,13 +301,14 @@ export class EntityEditor implements OnInit {
let request: Observable<unknown>;
switch (target.kind) {
case 'school':
request = this.api.saveSchool({ name: this.name.trim() }, id);
request = this.api.saveSchool({ name: this.name.trim() }, id, this.originalRevision);
break;
case 'dancer':
request = this.api.saveDancer(
schoolId!,
{ name: this.name.trim(), birthDate: this.date },
id,
this.originalRevision,
);
break;
case 'group':
@@ -318,6 +322,7 @@ export class EntityEditor implements OnInit {
styles: this.selectedStyles,
},
id,
this.originalRevision,
);
break;
case 'show':
@@ -329,6 +334,7 @@ export class EntityEditor implements OnInit {
preferredDayParts: this.preferredDayParts,
},
id,
this.originalRevision,
);
break;
}