Anfrage-Basisprozess inquiry.request mit Schablonen für Antwort und Gastkommunikation
Antwortart (Auskunft/Angebot) und Reservierung sind entkoppelt (neue Einstellung inquiry_answer; pre_reservation bleibt die Reservierungsstrategie). Anlass-bezogene Absender für Anreise-Information und Bewertungsbitte; Schablonen liefern Standardwerte unterhalb aller einstellbaren Ebenen. A1/A2 bleiben Voreinstellungen und Altfassungen. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
e40f8639b3
commit
221ce8ca81
51 files changed
+773
-73
No files matched your search
@@ -34,6 +34,21 @@ public static function caseTypes(): array
|
||||
return [CaseType::A1];
|
||||
}
|
||||
|
||||
public static function isLegacy(): bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
public static function composedBy(): ?string
|
||||
{
|
||||
return 'inquiry.request';
|
||||
}
|
||||
|
||||
public static function presetTemplates(): array
|
||||
{
|
||||
return ['inquiry_answer' => 'inquiry.information'];
|
||||
}
|
||||
|
||||
public static function fixes(): array
|
||||
{
|
||||
return ['pre_reservation' => false];
|
||||
|
||||
@@ -34,6 +34,21 @@ public static function caseTypes(): array
|
||||
return [CaseType::A1];
|
||||
}
|
||||
|
||||
public static function isLegacy(): bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
public static function composedBy(): ?string
|
||||
{
|
||||
return 'inquiry.request';
|
||||
}
|
||||
|
||||
public static function presetTemplates(): array
|
||||
{
|
||||
return ['inquiry_answer' => 'inquiry.binding_offer'];
|
||||
}
|
||||
|
||||
public static function fixes(): array
|
||||
{
|
||||
return ['pre_reservation' => true];
|
||||
|
||||
@@ -35,6 +35,21 @@ public static function caseTypes(): array
|
||||
return [CaseType::A2];
|
||||
}
|
||||
|
||||
public static function isLegacy(): bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
public static function composedBy(): ?string
|
||||
{
|
||||
return 'inquiry.request';
|
||||
}
|
||||
|
||||
public static function presetTemplates(): array
|
||||
{
|
||||
return ['inquiry_answer' => 'inquiry.information'];
|
||||
}
|
||||
|
||||
public static function fixes(): array
|
||||
{
|
||||
return ['pre_reservation' => false];
|
||||
|
||||
@@ -35,6 +35,21 @@ public static function caseTypes(): array
|
||||
return [CaseType::A2];
|
||||
}
|
||||
|
||||
public static function isLegacy(): bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
public static function composedBy(): ?string
|
||||
{
|
||||
return 'inquiry.request';
|
||||
}
|
||||
|
||||
public static function presetTemplates(): array
|
||||
{
|
||||
return ['inquiry_answer' => 'inquiry.binding_offer'];
|
||||
}
|
||||
|
||||
public static function fixes(): array
|
||||
{
|
||||
return ['pre_reservation' => true];
|
||||
|
||||
@@ -53,6 +53,11 @@ public static function isLegacy(): bool
|
||||
return true;
|
||||
}
|
||||
|
||||
public static function composedBy(): ?string
|
||||
{
|
||||
return 'external.booking';
|
||||
}
|
||||
|
||||
public static function presetTemplates(): array
|
||||
{
|
||||
return ['collection' => 'collection.own', 'contract_documents' => 'contract_docs.own'];
|
||||
|
||||
@@ -53,6 +53,11 @@ public static function isLegacy(): bool
|
||||
return true;
|
||||
}
|
||||
|
||||
public static function composedBy(): ?string
|
||||
{
|
||||
return 'external.booking';
|
||||
}
|
||||
|
||||
public static function presetTemplates(): array
|
||||
{
|
||||
return ['collection' => 'collection.portal', 'contract_documents' => 'contract_docs.own'];
|
||||
|
||||
@@ -53,6 +53,11 @@ public static function isLegacy(): bool
|
||||
return true;
|
||||
}
|
||||
|
||||
public static function composedBy(): ?string
|
||||
{
|
||||
return 'external.booking';
|
||||
}
|
||||
|
||||
public static function presetTemplates(): array
|
||||
{
|
||||
return ['collection' => 'collection.portal', 'contract_documents' => 'contract_docs.external'];
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
class ExternalBookingModel extends ProcessModel
|
||||
{
|
||||
/** Results the base process provides to the templates. */
|
||||
public const PROVIDES = ['case.recorded', 'guest.identified', 'binding.portal_total'];
|
||||
public const PROVIDES = ['case.recorded', 'guest.identified', 'binding.portal_total', 'price.known'];
|
||||
|
||||
public static function key(): string
|
||||
{
|
||||
@@ -76,6 +76,7 @@ public static function defaultTemplates(): array
|
||||
return [
|
||||
TemplateArea::Collection->value => 'collection.own',
|
||||
TemplateArea::ContractDocuments->value => 'contract_docs.own',
|
||||
TemplateArea::GuestCommunication->value => 'guest_comm.own',
|
||||
];
|
||||
}
|
||||
|
||||
@@ -93,8 +94,7 @@ public function steps(): array
|
||||
Step::slot(TemplateArea::Collection),
|
||||
Step::module('case.tasks'),
|
||||
Step::module('change.proposal'),
|
||||
Step::module('arrival.details'),
|
||||
Step::module('arrival.info'),
|
||||
Step::slot(TemplateArea::GuestCommunication),
|
||||
Step::module('guest.data_request'),
|
||||
Step::point(Point::BeforeStay),
|
||||
Step::module('stay'),
|
||||
|
||||
@@ -0,0 +1,135 @@
|
||||
<?php
|
||||
|
||||
namespace App\Process\Models;
|
||||
|
||||
use App\Enums\CaseType;
|
||||
use App\Enums\IntakeKind;
|
||||
use App\Enums\Responsibility;
|
||||
use App\Process\Templates\TemplateArea;
|
||||
|
||||
/**
|
||||
* The base process of a request (own website, portal inquiry, phone, e-mail) – the one course A1 and A2 shared, with
|
||||
* slots for how it is answered (information or binding offer), the contract documentation, the collection and the
|
||||
* guest communication. A1/A2 stay as presets, classification and for historical cases. The reservation is not part
|
||||
* of the answer template: the hold module and the reservation setting stay independent of it (docs/Prozessarchitektur/
|
||||
* SCHABLONENKATALOG.md §4.3).
|
||||
*/
|
||||
class InquiryRequestModel extends ProcessModel
|
||||
{
|
||||
/** Results the base process provides to the templates. */
|
||||
public const PROVIDES = ['case.recorded', 'guest.identified', 'availability.checked', 'price.known'];
|
||||
|
||||
public static function key(): string
|
||||
{
|
||||
return 'inquiry.request';
|
||||
}
|
||||
|
||||
public static function version(): int
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
public static function label(): string
|
||||
{
|
||||
return 'Anfrage';
|
||||
}
|
||||
|
||||
public static function description(): string
|
||||
{
|
||||
return 'Eine Anfrage – von der eigenen Webseite oder einem Portal. Sie wählen, womit Sie antworten (Auskunft oder verbindliches Angebot) und wer wem schreibt; Datenbeschaffung und Reservierung laufen unabhängig davon.';
|
||||
}
|
||||
|
||||
public static function caseTypes(): array
|
||||
{
|
||||
return [CaseType::A1, CaseType::A2];
|
||||
}
|
||||
|
||||
public static function intakes(): array
|
||||
{
|
||||
return [IntakeKind::Inquiry];
|
||||
}
|
||||
|
||||
public static function responsibilities(): Responsibilities
|
||||
{
|
||||
return Responsibilities::of(
|
||||
fixed: ['contract' => Responsibility::Landlord, 'collection' => Responsibility::Landlord, 'contract_documents' => Responsibility::Landlord],
|
||||
variable: [
|
||||
'guest_messages' => [Responsibility::Landlord, Responsibility::Portal],
|
||||
'supplementary_documents' => [Responsibility::Landlord, Responsibility::Nobody],
|
||||
'local_services' => [Responsibility::Landlord],
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
public static function providedResults(): array
|
||||
{
|
||||
return self::PROVIDES;
|
||||
}
|
||||
|
||||
public static function templateRestrictions(): array
|
||||
{
|
||||
return [
|
||||
'collection.portal' => 'Bei einer Anfrage schließen wir den Vertrag selbst (Annahme des Angebots) und kassieren selbst; Inkasso beim Portal gibt es nur bei bereits verbindlich gebuchten Portalbuchungen.',
|
||||
'contract_docs.external' => 'Bei einer Anfrage entsteht der Vertrag erst durch unser Angebot und die Annahme des Gastes; das Portal kann keine Vertragsunterlagen dafür bereitstellen.',
|
||||
];
|
||||
}
|
||||
|
||||
public static function defaultTemplates(): array
|
||||
{
|
||||
return [
|
||||
TemplateArea::InquiryAnswer->value => 'inquiry.binding_offer',
|
||||
TemplateArea::ContractDocuments->value => 'contract_docs.own',
|
||||
TemplateArea::Collection->value => 'collection.own',
|
||||
TemplateArea::GuestCommunication->value => 'guest_comm.own',
|
||||
];
|
||||
}
|
||||
|
||||
public function steps(): array
|
||||
{
|
||||
return [
|
||||
Step::module('intake.record'),
|
||||
Step::module('guest.details'),
|
||||
Step::point(Point::AfterGuestIdentified),
|
||||
Step::module('hold'),
|
||||
Step::module('availability.check'),
|
||||
Step::slot(TemplateArea::InquiryAnswer),
|
||||
Step::point(Point::BeforePriceFixing),
|
||||
Step::module('offer.binding'),
|
||||
Step::point(Point::BeforeBindingOffer),
|
||||
Step::module('offer.acceptance'),
|
||||
Step::point(Point::AfterBinding),
|
||||
Step::slot(TemplateArea::ContractDocuments),
|
||||
Step::module('channels.block'),
|
||||
Step::slot(TemplateArea::Collection),
|
||||
Step::module('case.tasks'),
|
||||
Step::module('change.proposal'),
|
||||
Step::slot(TemplateArea::GuestCommunication),
|
||||
Step::module('guest.data_request'),
|
||||
Step::point(Point::BeforeStay),
|
||||
Step::module('stay'),
|
||||
Step::module('review.request'),
|
||||
Step::point(Point::BeforeSettlement),
|
||||
Step::module('case.closure'),
|
||||
Step::module('case.settlement'),
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* The extension variants of the architecture proof (tester only), as on the former offer model.
|
||||
*
|
||||
* @return list<Variant>
|
||||
*/
|
||||
public function variants(): array
|
||||
{
|
||||
return [
|
||||
Variant::make('standard', 'Standard'),
|
||||
Variant::make('loyalty', 'Mit Stammgastrabatt (Architekturnachweis, nur im Prozess-Tester)')
|
||||
->testerOnly()
|
||||
->insert(Point::AfterGuestIdentified, 'guest.loyalty_status')
|
||||
->insert(Point::BeforePriceFixing, 'pricing.loyalty_discount'),
|
||||
Variant::make('address_check', 'Mit Anschriftsprüfung (Zusatzschritt, nur im Prozess-Tester)')
|
||||
->testerOnly()
|
||||
->insert(Point::AfterGuestIdentified, 'guest.address_check'),
|
||||
];
|
||||
}
|
||||
}
|
||||
@@ -85,6 +85,24 @@ public function slots(): array
|
||||
return array_values(array_map(fn (Step $step): TemplateArea => $step->slot, array_filter($this->steps(), fn (Step $step): bool => $step->isSlot())));
|
||||
}
|
||||
|
||||
/**
|
||||
* Templates a model does not take, with the business reason (template key => reason). Everything not listed fits.
|
||||
*
|
||||
* @return array<string, string>
|
||||
*/
|
||||
public static function templateRestrictions(): array
|
||||
{
|
||||
return [];
|
||||
}
|
||||
|
||||
/**
|
||||
* For a legacy model: the key of the base process whose template combination it reproduces.
|
||||
*/
|
||||
public static function composedBy(): ?string
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* The results the base course provides to the templates of its slots (see FunctionTemplate::requires()).
|
||||
*
|
||||
|
||||
Reference in new issue
Block a user