'nullable|integer|exists:approval_forms,id', 'form_code' => 'nullable|string|exists:approval_forms,code', 'title' => 'nullable|string|max:200', 'content' => 'nullable|array', 'attachments' => 'nullable|array', 'attachments.*' => 'integer|exists:files,id', // 결재선 수정 지원 'steps' => 'nullable|array', 'steps.*.type' => "nullable|string|in:{$stepTypes}", 'steps.*.step_type' => "nullable|string|in:{$stepTypes}", 'steps.*.user_id' => 'nullable|integer|exists:users,id', 'steps.*.approver_id' => 'nullable|integer|exists:users,id', 'steps.*.step_order' => 'nullable|integer|min:1', ]; } public function messages(): array { return [ 'form_id.exists' => __('validation.exists', ['attribute' => '결재양식']), ]; } }