|
|
@ -4627,7 +4627,6 @@ EOT; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
$question_list_answers = []; |
|
|
|
$question_list_answers = []; |
|
|
|
$media_list = []; |
|
|
|
|
|
|
|
$category_list = []; |
|
|
|
$category_list = []; |
|
|
|
$loadChoiceFromSession = false; |
|
|
|
$loadChoiceFromSession = false; |
|
|
|
$fromDatabase = true; |
|
|
|
$fromDatabase = true; |
|
|
@ -5987,15 +5986,24 @@ EOT; |
|
|
|
} |
|
|
|
} |
|
|
|
foreach ($notificationList as $attemptData) { |
|
|
|
foreach ($notificationList as $attemptData) { |
|
|
|
$skipNotification = false; |
|
|
|
$skipNotification = false; |
|
|
|
$skipNotificationList = isset($attemptData['skip_notification_if_user_in_extra_field']) ? $attemptData['skip_notification_if_user_in_extra_field'] : []; |
|
|
|
$skipNotificationList = isset($attemptData['send_notification_if_user_in_extra_field']) ? $attemptData['send_notification_if_user_in_extra_field'] : []; |
|
|
|
if (!empty($skipNotificationList)) { |
|
|
|
if (!empty($skipNotificationList)) { |
|
|
|
foreach ($skipNotificationList as $skipVariable => $skipValues) { |
|
|
|
foreach ($skipNotificationList as $skipVariable => $skipValues) { |
|
|
|
$userExtraFieldValue = $extraFieldValueUser->get_values_by_handler_and_field_variable( |
|
|
|
$userExtraFieldValue = $extraFieldValueUser->get_values_by_handler_and_field_variable( |
|
|
|
$studentId, |
|
|
|
$studentId, |
|
|
|
$skipVariable |
|
|
|
$skipVariable |
|
|
|
); |
|
|
|
); |
|
|
|
if (!empty($userExtraFieldValue) && isset($userExtraFieldValue['value'])) { |
|
|
|
|
|
|
|
if (in_array($userExtraFieldValue['value'], $skipValues)) { |
|
|
|
if (empty($userExtraFieldValue)) { |
|
|
|
|
|
|
|
$skipNotification = true; |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
if (isset($userExtraFieldValue['value'])) { |
|
|
|
|
|
|
|
if (!in_array($userExtraFieldValue['value'], $skipValues)) { |
|
|
|
|
|
|
|
$skipNotification = true; |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} else { |
|
|
|
$skipNotification = true; |
|
|
|
$skipNotification = true; |
|
|
|
break; |
|
|
|
break; |
|
|
|
} |
|
|
|
} |
|
|
|