- CaseRequirements: Vor einem eigenen verbindlichen Angebot und vor der verbindlichen Bestätigung eines Buchungswunsches müssen Vor- und Nachname, E-Mail, vollständige Anschrift mit Land, Personenzahl und Zeitraum vorliegen – harter Blocker, auch von Hand (G2a, B3). Die Auskunft unter Vorbehalt bleibt ohne dieses Gate. - ContributeCaseFacts (S5): jede Angabe mit Herkunft und Ergebnis in case_facts; fehlend → übernommen, gleich → bestätigt, abweichend vom Gast → Prüfaufgabe (Kartei bleibt), Vermieterin maßgeblich, Zeitraum und Personen → Änderungswunsch; idempotent; danach einmal CaseAutomation. - ProvideGuestContact und Webformular nutzen den Fakteneingang. - Land als ISO-Code mit „Deutschland“ als änderbarem Formularstandard; guests.country ohne stillen Standardwert (B4). - Testdaten bestehender Tests um Anschriften ergänzt. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
39 lines
1.0 KiB
PHP
39 lines
1.0 KiB
PHP
<?php
|
|
|
|
namespace App\Enums;
|
|
|
|
use Filament\Support\Contracts\HasLabel;
|
|
|
|
/**
|
|
* Where a detail of a case came from (v0.11 common fact intake, S5).
|
|
*/
|
|
enum FactSource: string implements HasLabel
|
|
{
|
|
case WebsiteForm = 'website_form';
|
|
case GuestLink = 'guest_link';
|
|
case Email = 'email';
|
|
case PortalMail = 'portal_mail';
|
|
case Extraction = 'llm';
|
|
case Landlord = 'landlord';
|
|
|
|
public function getLabel(): string
|
|
{
|
|
return match ($this) {
|
|
self::WebsiteForm => 'Anfrageformular der Webseite',
|
|
self::GuestLink => 'Gast über den Ergänzungslink',
|
|
self::Email => 'E-Mail des Gastes',
|
|
self::PortalMail => 'Portal-Mail',
|
|
self::Extraction => 'aus einer Nachricht erkannt (KI)',
|
|
self::Landlord => 'von Ihnen eingetragen',
|
|
};
|
|
}
|
|
|
|
/**
|
|
* The landlord's own entry is authoritative; every other source only completes or is put to the landlord.
|
|
*/
|
|
public function isAuthoritative(): bool
|
|
{
|
|
return $this === self::Landlord;
|
|
}
|
|
}
|