S18 Added OR Tools rules for scheduling show
All checks were successful
Build, test and publish / verify (push) Successful in 6m12s

This commit is contained in:
2026-11-03 11:03:47 +01:00
parent c965f9b41d
commit a7f7730ea0
48 changed files with 2262 additions and 256 deletions

View File

@@ -151,6 +151,7 @@
</section>
}
@case ('dancers') {
<app-coach-editor [data]="context" (changed)="reload()" />
<div class="section-heading">
<div>
<h2>Dansers</h2>
@@ -350,6 +351,15 @@
</div>
<div class="show-details">
<h3>{{ show.name }}</h3>
<p>
{{ show.finalized ? 'Definitief' : 'Concept' }} · x = {{ show.preferredDayParts }}
</p>
@for (violation of show.violations; track $index) {
<p class="alert error">{{ violation }}</p>
}
<button type="button" class="button secondary" (click)="scheduleEditing.set(show)">
Indeling en volgorde bewerken
</button>
<p>{{ dateRange(show) }}</p>
@for (part of show.dayParts; track $index) {
<p>{{ part.date }} · {{ part.type }}: {{ groupNamesFor(part.danceGroupIds) }}</p>
@@ -357,7 +367,7 @@
<p role="status">
{{
scheduleValid(show)
? 'Planning voldoet aan alle optredensaantallen.'
? 'Planning voldoet aan alle harde regels.'
: 'Geen geldige planning. Plan de groepen opnieuw in.'
}}
</p>
@@ -365,7 +375,10 @@
type="button"
class="button primary"
[disabled]="
scheduling().includes(show.id) || !context.groups.length || !show.dayParts.length
scheduling().includes(show.id) ||
!context.groups.length ||
!show.dayParts.length ||
show.preferredDayParts > show.dayParts.length
"
(click)="schedule(show)"
>
@@ -426,6 +439,15 @@
(saved)="saved()"
/>
}
@if (scheduleEditing(); as show) {
<app-schedule-editor
[show]="show"
[groups]="context.groups"
[schoolId]="context.school.id"
(closed)="scheduleEditing.set(null)"
(saved)="reload()"
/>
}
@if (members(); as group) {
<app-group-members
[group]="group"