|string> */ public function rules(): array { return [ // 'travel_type_id' => // [ // 'nullable', // 'exists:travel_types,id' // ], 'title' => [ 'required', 'string', 'max:200' ], // 'slug' => // ['nullable', 'string', // 'max:200', // 'regex:/^[a-z0-9-]+$/', // 'unique:tours,slug,' . $this->tour // ], // 'description' => // [ // 'nullable', // 'string' // ], // 'duration' => // [ // 'nullable', // 'string', // 'max:50' // ], // 'start_date' => // [ // 'nullable', // 'date' // ], // 'end_date' => // [ // 'nullable', // 'date', // 'after_or_equal:start_date' // ], 'price' => [ 'required', 'numeric', 'min:0' ], // 'capacity' => // [ // 'nullable', // 'integer', // 'min:0'], 'images' => [ 'nullable', 'array' ], 'images.*' => [ 'image', 'mimes:jpeg,png,jpg,webp', 'max:2048' ], 'status' => [ 'nullable', 'in:0,1' ], ]; } }