diff --git a/pandora_console/include/ajax/notifications.ajax.php b/pandora_console/include/ajax/notifications.ajax.php new file mode 100644 index 0000000000..36ea95900d --- /dev/null +++ b/pandora_console/include/ajax/notifications.ajax.php @@ -0,0 +1,57 @@ + notifications_set_user_label_status( + $source, + $user, + $label, + $value + ), + ] + ); + + echo $json; + return; +} diff --git a/pandora_console/operation/users/user_edit_notifications.php b/pandora_console/operation/users/user_edit_notifications.php index 309439dfe7..a6dfdb1821 100644 --- a/pandora_console/operation/users/user_edit_notifications.php +++ b/pandora_console/operation/users/user_edit_notifications.php @@ -36,28 +36,6 @@ require_once $config['homedir'].'/include/functions_notifications.php'; $headerTitle = __('User notifications'); require $config['homedir'].'/operation/users/user_edit_header.php'; -if (get_parameter('change_label', 0)) { - $label = get_parameter('label', ''); - $source = get_parameter('source', 0); - $user = get_parameter('user', ''); - $value = get_parameter('value', 0) ? 1 : 0; - - // Update the label value. - ob_clean(); - echo json_encode( - [ - 'result' => notifications_set_user_label_status( - $source, - $user, - $label, - $value - ), - ] - ); - return; -} - - echo '