Make projects depend on templates

This commit is contained in:
2026-05-25 01:41:27 +00:00
parent 58d2edcacd
commit 5e6426067a
19 changed files with 281 additions and 14 deletions
+1 -1
View File
@@ -85,7 +85,7 @@ class StoreProjectRequest extends FormRequest
Rule::requiredIf(fn (): bool => $this->input('creation_mode') === 'template'),
'nullable',
'integer',
Rule::exists('project_templates', 'id'),
Rule::exists('project_templates', 'id')->where(fn ($query) => $query->where('is_published', true)),
],
'copy_areas' => ['nullable', 'array'],
'copy_areas.*' => [