Admin-Bereich "Newsletter-Listen" (Plan dev/_tickets/entwicklungsplan- newsletter-listen.md): Berater und Kunden nach Filtern zusammenstellen, als Liste speichern und wieder laden, Export als XLSX/CSV. Jeder Export wird protokolliert (newsletter_list_exports). Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
35 lines
809 B
PHP
35 lines
809 B
PHP
<?php
|
|
|
|
namespace App\Http\Requests\Newsletter;
|
|
|
|
/**
|
|
* Speichern einer Filterkombination unter einem Namen. Erbt die Filter-Regeln.
|
|
*/
|
|
class StoreNewsletterListRequest extends NewsletterListFilterRequest
|
|
{
|
|
/**
|
|
* @return array<string, array<int, mixed>>
|
|
*/
|
|
public function rules(): array
|
|
{
|
|
return parent::rules() + [
|
|
'name' => ['required', 'string', 'max:120'],
|
|
];
|
|
}
|
|
|
|
/**
|
|
* @return array<string, string>
|
|
*/
|
|
public function messages(): array
|
|
{
|
|
return parent::messages() + [
|
|
'name.required' => __('newsletter.validation.name'),
|
|
'name.max' => __('newsletter.validation.name'),
|
|
];
|
|
}
|
|
|
|
public function listName(): string
|
|
{
|
|
return trim((string) $this->validated('name'));
|
|
}
|
|
}
|