app/Api/V1/Requests/CreateAllGoodsRequest.php
/**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
Get the validation rules that apply to the request.
@return array
Get the validation rules that apply to the request . @return array
public function rules()
    {
        return [
            'name' => 'required',
            'short_description' => 'required',
            'category_id' => 'required|exists:categories,id',
            'properties' => 'json|nullable'
        ];
    }
public function rules ( ) { return [ 'name' => 'required' , 'short_description' => 'required' , 'category_id' => 'required|exists:categories,id' , 'properties' => 'json|nullable' ] ; }
Get the validation rules that apply to the request.
Get the validation rules that apply to the request .