feat: show documents link only when applicable

This commit is contained in:
Björn Fromme
2025-01-27 17:08:43 +01:00
parent 971cf6d7a8
commit 7236f8641f
3 changed files with 14 additions and 7 deletions
+1 -1
View File
@@ -19,7 +19,7 @@ class Booking
public ?Travel $travelData = null;
public ?int $hotelId = null;
public ?string $hotelName = null;
public ?bool $document = null;
public bool $hasDocuments = false;
public ?float $payment = null;
public ?string $paymentId = null;
public ?string $paymentType = null;
+3 -1
View File
@@ -31,10 +31,12 @@ class BookingsParser extends AbstractParser
$booking->travelId = $this->getIntOrNullValue($node->filterXPath('//idreise'));
$booking->travelDate = $this
->stringToDate($this->getStringOrNullValue($node->filterXPath('//reisedatum')));
$booking->document = $this
$booking->hasDocuments = $this
->stringToBool($this->getStringOrNullValue($node->filterXPath('//reisedokument')));
$booking->payment = $this
->stringToFloat($this->getStringOrNullValue($node->filterXPath('//zahlung')));
$booking->hasDocuments = $this
->stringToBool($this->getStringOrNullValue($node->filterXPath('//reisedokument')));
$bookings[] = $booking;
});