ent 9722 expired license warning PM

This commit is contained in:
edu.corral 2022-11-03 15:42:13 +01:00
parent fb4b42e6c5
commit 1994db7f5c
1 changed files with 54 additions and 0 deletions

View File

@ -549,6 +549,33 @@ if ($create_user) {
$password_new = '';
$password_confirm = '';
$new_user = true;
} else {
$pm = db_get_value_filter('pandora_management', 'tperfil', ['id_perfil' => $profile2]);
if ((int) $pm === 1) {
$user_source = db_get_value_filter(
'id_source',
'tnotification_source_user',
[
'id_source' => $notification['id'],
'id_user' => $id,
]
);
if ($user_source === false) {
$notificationSources = db_get_all_rows_filter('tnotification_source', [], 'id');
foreach ($notificationSources as $notification) {
if ((int) $notification['id'] === 1 || (int) $notification['id'] === 5) {
@db_process_sql_insert(
'tnotification_source_user',
[
'id_source' => $notification['id'],
'id_user' => $id,
]
);
}
}
}
}
}
ui_print_result_message(
@ -845,6 +872,33 @@ if ($add_profile && empty($json_profile)) {
$return = profile_create_user_profile($id2, $profile2, $group2, false, $tags, $no_hierarchy);
if ($return === false) {
$is_err = true;
} else {
$pm = db_get_value_filter('pandora_management', 'tperfil', ['id_perfil' => $profile2]);
if ((int) $pm === 1) {
$user_source = db_get_value_filter(
'id_source',
'tnotification_source_user',
[
'id_source' => $notification['id'],
'id_user' => $id,
]
);
if ($user_source === false) {
$notificationSources = db_get_all_rows_filter('tnotification_source', [], 'id');
foreach ($notificationSources as $notification) {
if ((int) $notification['id'] === 1 || (int) $notification['id'] === 5) {
@db_process_sql_insert(
'tnotification_source_user',
[
'id_source' => $notification['id'],
'id_user' => $id,
]
);
}
}
}
}
}
ui_print_result_message(