feat: auto-booking services

addresses #869cfcptv
This commit is contained in:
Björn Fromme committed 2026-03-16 20:24:58 +01:00
1 parent 6d9265de0f
commit c510cbf590
19 files changed
+1829 -72

No files matched your search

+3
View File
@@ -29,6 +29,9 @@ class Service
#[Groups(['api:single', 'api:list'])]
public bool $mandatory = false;
#[Groups(['api:single', 'api:list'])]
public bool $autoBook = false;
#[Groups(['api:single', 'api:list'])]
public ?string $label = null;
+3
View File
@@ -148,6 +148,9 @@ class TravelParser extends AbstractParser
$service->id = $serviceId;
$service->subType = $serviceNode->attr('unterart');
$service->mandatory = $this->stringToBool($serviceNode->attr('pflicht'));
$autoBookValue = $serviceNode->attr('automatisch_buchen');
$service->autoBook = $this->stringToBool($autoBookValue)
|| 'true' === strtolower((string) $autoBookValue);
$service->dateFrom = $this->stringToDate($serviceNode->attr('termin'));
$service->dateTo = $this->stringToDate($serviceNode->attr('bis'));
$service->label = $this->getStringOrNullValue($serviceNode->filterXPath('//text'));