Dokumentenzusammenstellung und Vorlagensteuerung (Paket 3, Prozessarchitektur v0.10)
Deploy FeWo mit PipelineManager / deploy (push) Successful in 3m59s
Deploy FeWo mit PipelineManager / deploy (push) Successful in 3m59s
Eine Zusammenstellung vor jedem Dokument (Angebot, Bestaetigung, Buchungsunterlagen extern), Dokumentart je Vorgangsart, Freigaben fuer Vorlagen und Dokumentarten, Schutz vor unvereinbarten Bedingungen bei Portalbuchungen (E-004), kein doppelter Versand, Absicherung Hold 0 bis Paket 7, A6-Aufenthaltsbestaetigung vorbereitet. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
64248c09fa
commit
cf11c8a474
45 files changed
+2385
-144
No files matched your search
@@ -3,7 +3,7 @@
|
||||
namespace App\Process;
|
||||
|
||||
use App\Actions\AutoOffer;
|
||||
use App\Actions\ConfirmBooking;
|
||||
use App\Actions\SendBookingDocuments;
|
||||
use App\Enums\BookingStatus;
|
||||
use App\Enums\IntakeKind;
|
||||
use App\Enums\ProcessingMode;
|
||||
@@ -13,14 +13,15 @@
|
||||
|
||||
/**
|
||||
* Carries a case on by itself as far as its data allows – only when the case is handled automatically. What it may do
|
||||
* is what the landlord would do next anyway: send the offer of a request, or send the documents of a booking that is
|
||||
* binding on a portal once the guest's e-mail address and the price are known. Whatever stops it is returned in plain
|
||||
* is what the landlord would do next anyway: send the offer of a request, or send the documents of a binding booking
|
||||
* once their composition is complete and needs no confirmation (template released and, for portal bookings, confirmed
|
||||
* as the portal's terms). Whatever stops it is returned in plain
|
||||
* words; the case then shows it as a task. Never touches a case whose profile was taken over from the old data (the
|
||||
* automation did not exist for those cases before).
|
||||
*/
|
||||
class CaseAutomation
|
||||
{
|
||||
public function __construct(private AutoOffer $autoOffer, private ConfirmBooking $confirm) {}
|
||||
public function __construct(private AutoOffer $autoOffer, private SendBookingDocuments $documents) {}
|
||||
|
||||
/**
|
||||
* @return list<string> what keeps the case from going on automatically (empty: nothing to do or done)
|
||||
@@ -52,12 +53,7 @@ private function step(Booking $booking): array
|
||||
}
|
||||
|
||||
if ($booking->isBinding() && $booking->confirmation_sent_at === null && $booking->process()->documents() === Responsibility::Landlord && $booking->process()->origin !== 'migration') {
|
||||
$missing = $this->documentBlockers($booking);
|
||||
if ($missing !== []) {
|
||||
return $missing;
|
||||
}
|
||||
|
||||
return $this->confirm->deliver($booking) ? [] : ['Die Unterlagen konnten nicht versendet werden (siehe Postfach).'];
|
||||
return $this->documents->automatically($booking);
|
||||
}
|
||||
|
||||
return [];
|
||||
|
||||
Reference in new issue
Block a user