mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-24 21:24:13 -08:00
adds translations
This commit is contained in:
parent
d01972bbe5
commit
d5c9fa823e
|
@ -69,7 +69,7 @@ class DepreciationsController extends Controller
|
|||
'numeric',
|
||||
function ($attribute, $value, $fail) use ($request) {
|
||||
if ($request->input('depreciation_type') == 'percent' && ($value < 0 || $value > 100)) {
|
||||
$fail('The depreciation minimum must be between 0 and 100 when depreciation type is percentage.');
|
||||
$fail(trans('validation.percent'));
|
||||
}
|
||||
},
|
||||
],
|
||||
|
@ -137,7 +137,7 @@ class DepreciationsController extends Controller
|
|||
'numeric',
|
||||
function ($attribute, $value, $fail) use ($request) {
|
||||
if ($request->input('depreciation_type') == 'percent' && ($value < 0 || $value > 100)) {
|
||||
$fail('The depreciation minimum must be between 0 and 100 when depreciation type is percentage.');
|
||||
$fail(trans('validation.percent'));
|
||||
}
|
||||
},
|
||||
],
|
||||
|
|
|
@ -72,6 +72,7 @@ return [
|
|||
'not_in' => 'The selected :attribute is invalid.',
|
||||
'numeric' => 'The :attribute must be a number.',
|
||||
'present' => 'The :attribute field must be present.',
|
||||
'percent' => 'The depreciation minimum must be between 0 and 100 when depreciation type is percentage.',
|
||||
'valid_regex' => 'That is not a valid regex. ',
|
||||
'regex' => 'The :attribute format is invalid.',
|
||||
'required' => 'The :attribute field is required.',
|
||||
|
|
Loading…
Reference in a new issue