Schablonenkomposition: Basisprozess external.booking mit Platz für Finanz- und Dokumentenschablonen
Vier Schablonen (Eigenes/Portal-Inkasso, Eigene/Externe Vertragsdokumentation) in app/Process/Templates, TemplateComposer prüft Ergebnisse, Verantwortlichkeiten, Ausschlüsse und harte Modulabhängigkeiten. Der Plan friert die Schablonenversionen ein. A3–A5 bleiben als Voreinstellungen; die vierte Kombination (eigenes Inkasso + externe Unterlagen) ist darstellbar. Konfigurator-Logik und ConfigureChannelProcess kennen die Schablonenwahl. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
381720763c
commit
e95ba4f986
24 files changed
+1666
-37
No files matched your search
@@ -0,0 +1,49 @@
|
||||
<?php
|
||||
|
||||
namespace App\Process\Templates;
|
||||
|
||||
use App\Enums\ProcessSetting;
|
||||
|
||||
/**
|
||||
* A functional area of a process where a model offers a slot for a function template. Each area answers one business
|
||||
* decision and stands for exactly one result of the process (so the same result is never produced twice).
|
||||
*/
|
||||
enum TemplateArea: string
|
||||
{
|
||||
case Collection = 'collection';
|
||||
case ContractDocuments = 'contract_documents';
|
||||
|
||||
public function label(): string
|
||||
{
|
||||
return match ($this) {
|
||||
self::Collection => 'Finanzabwicklung (Inkasso)',
|
||||
self::ContractDocuments => 'Vertragsdokumentation',
|
||||
};
|
||||
}
|
||||
|
||||
public function question(): string
|
||||
{
|
||||
return match ($this) {
|
||||
self::Collection => 'Wer zieht das Geld des Gastes ein?',
|
||||
self::ContractDocuments => 'Wer stellt dem Gast die Vertragsunterlagen bereit?',
|
||||
};
|
||||
}
|
||||
|
||||
/** The process result every template of this area provides – exactly once per process. */
|
||||
public function result(): string
|
||||
{
|
||||
return match ($this) {
|
||||
self::Collection => 'money.collection_handled',
|
||||
self::ContractDocuments => 'contract.documented',
|
||||
};
|
||||
}
|
||||
|
||||
/** The responsibility setting the chosen template fixes. */
|
||||
public function setting(): ProcessSetting
|
||||
{
|
||||
return match ($this) {
|
||||
self::Collection => ProcessSetting::Payments,
|
||||
self::ContractDocuments => ProcessSetting::Documents,
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user