CoC Checks now optional

This commit is contained in:
2026-09-29 14:58:21 +02:00
parent a5e4e55df5
commit a43fd9cedf
12 changed files with 103 additions and 3 deletions
@@ -12,6 +12,12 @@ class CertificateOfConductionCheckCommand {
public function execute() : CertificateOfConductionCheckResponse {
$response = new CertificateOfConductionCheckResponse();
// Verlangt die Veranstaltung kein eFZ, entfällt die Prüfung -- ohne Aufruf der Prüf-API.
if (!$this->request->participant->event()->first()?->coc_check_required) {
$response->status = EfzStatus::EFZ_STATUS_NOT_REQUIRED;
return $response;
}
// Der Stamm ist optional (die Kurzanmeldung erhebt ihn nicht, in der Verwaltung kann er entfernt werden).
$localGroup = str_replace('Stamm ', '', $this->request->participant->localGroup()->first()?->name ?? '');