Merge branch '4779-call-set-planned_downtimes-no-se-muestra' into 'develop'
Added date control See merge request artica/pandorafms!2794
This commit is contained in:
commit
febe54e3c8
|
@ -796,6 +796,11 @@ function planned_downtimes_created($values)
|
||||||
'return' => false,
|
'return' => false,
|
||||||
'message' => __('Not created. Error inserting data').'. '.__('There is no group with such id'),
|
'message' => __('Not created. Error inserting data').'. '.__('There is no group with such id'),
|
||||||
];
|
];
|
||||||
|
} else if (!$values['date_from'] || !$values['date_to']) {
|
||||||
|
return [
|
||||||
|
'return' => false,
|
||||||
|
'message' => __('Not created. Error inserting data').'. '.__('Date is wrong formatted'),
|
||||||
|
];
|
||||||
} else {
|
} else {
|
||||||
if (trim(io_safe_output($values['name'])) != '') {
|
if (trim(io_safe_output($values['name'])) != '') {
|
||||||
if (!$check) {
|
if (!$check) {
|
||||||
|
|
Loading…
Reference in New Issue