Admin: show the offer link (e.g. to share it, or on staging where mails go to the log)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Lars StommerandClaude Opus 5.5 committed 2026-10-22 21:46:34 +02:00
1 parent 6690beafe6
commit 7a6ee316cd
1 file changed
+12
@@ -105,6 +105,18 @@ protected function getHeaderActions(): array
fn () => $send->handle($this->record, $this->offerChanges($data)),
'Angebot gesendet',
)),
Action::make('offerLink')
->label('Angebotslink')
->icon(Heroicon::OutlinedLink)
->color('gray')
->visible(fn (): bool => $this->record->status === BookingStatus::OfferSent && $this->record->hold_expires_at?->isFuture())
->modalHeading('Link zum Angebot')
->modalDescription('Derselbe Link wie in der Angebots-E-Mail – z. B. zum Weitergeben per Messenger. Gültig bis zum Ende der Angebotsfrist.')
->schema([
TextInput::make('url')->label('Link')->default(fn (SendOffer $send): string => $send->offerUrl($this->record))->readOnly()->copyable(),
])
->modalSubmitAction(false)
->modalCancelActionLabel('Schließen'),
Action::make('offerPdf')
->label('Angebot (PDF)')
->icon(Heroicon::OutlinedDocumentText)