Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 'slug' => 'unique:slugs,slug,id,morph_type,AppModelsProductCategory',
- 'slug' => 'unique:slugs,slug,id,morph_type,AppModelsProductCategory,morph_id,'.$category->id
- 'slug' => [
- Rule::unique('slugs', 'slug')
- ->where('morph_type', 'AppModelsProductCategory')
- ->where('morph_id', '<>', $category->id)
- ],
Add Comment
Please, Sign In to add comment