mirror of
https://github.com/snipe/snipe-it.git
synced 2025-01-13 06:47:46 -08:00
validation msg
This commit is contained in:
parent
72c118a70f
commit
d9c61fdb02
|
@ -169,8 +169,7 @@ class AssetModelsController extends Controller
|
||||||
$model->fieldset_id = $request->input('fieldset_id');
|
$model->fieldset_id = $request->input('fieldset_id');
|
||||||
|
|
||||||
if ($this->shouldAddDefaultValues($request->input())) {
|
if ($this->shouldAddDefaultValues($request->input())) {
|
||||||
if (!$this->assignCustomFieldsDefaultValues($model, $request->input('default_values'))){
|
if ($msg = !$this->assignCustomFieldsDefaultValues($model, $request->input('default_values'))){
|
||||||
//TODO: this needs to return the actual validation errors, will come back to this before opening PR
|
|
||||||
return redirect()->back()->withInput()->with('error', trans('admin/custom_fields/message.fieldset_default_value.error'));
|
return redirect()->back()->withInput()->with('error', trans('admin/custom_fields/message.fieldset_default_value.error'));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -105,6 +105,7 @@ return [
|
||||||
'gte' => [
|
'gte' => [
|
||||||
'numeric' => 'Value cannot be negative'
|
'numeric' => 'Value cannot be negative'
|
||||||
],
|
],
|
||||||
|
'checkboxes' => ':attribute contains invalid options.',
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Reference in a new issue