|
|
|
@ -15,7 +15,7 @@ if ($_REQUEST['tab'] == 'delete_center_data') { |
|
|
|
|
if (!$res) { |
|
|
|
|
$sql = "DELETE FROM $tableSepeActions;"; |
|
|
|
|
$res = Database::query($sql); |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoCenter').Database::error(); |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoCenter'); |
|
|
|
|
echo json_encode(array("status" => "false", "content" => $content)); |
|
|
|
|
} else { |
|
|
|
|
$content = $plugin->get_lang('DeleteOk'); |
|
|
|
@ -28,7 +28,7 @@ if ($_REQUEST['tab'] == 'delete_action') { |
|
|
|
|
$sql = "DELETE FROM $tableSepeActions WHERE id = $id;"; |
|
|
|
|
$res = Database::query($sql); |
|
|
|
|
if (!$res) { |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoAction').Database::error(); |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoAction'); |
|
|
|
|
echo json_encode(array("status" => "false", "content" => $content)); |
|
|
|
|
} else { |
|
|
|
|
$content = $plugin->get_lang('DeleteOk'); |
|
|
|
@ -42,7 +42,7 @@ if ($_REQUEST['tab'] == 'delete_specialty') { |
|
|
|
|
$sql = "DELETE FROM $tableSepeSpecialty WHERE id = $id;"; |
|
|
|
|
$res = Database::query($sql); |
|
|
|
|
if (!$res) { |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoSpecialty').Database::error(); |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoSpecialty'); |
|
|
|
|
echo json_encode(array("status" => "false", "content" => $content)); |
|
|
|
|
} else { |
|
|
|
|
$content = $plugin->get_lang('DeleteOk'); |
|
|
|
@ -55,7 +55,7 @@ if ($_REQUEST['tab'] == 'delete_specialty_participant') { |
|
|
|
|
$sql = "DELETE FROM $tableSepeParticipantsSpecialty WHERE id = $id;"; |
|
|
|
|
$res = Database::query($sql); |
|
|
|
|
if (!$res) { |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoSpecialty').Database::error(); |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoSpecialty'); |
|
|
|
|
echo json_encode(array("status" => "false", "content" => $content)); |
|
|
|
|
} else { |
|
|
|
|
$content = $plugin->get_lang('DeleteOk'); |
|
|
|
@ -68,7 +68,7 @@ if ($_REQUEST['tab'] == 'delete_classroom') { |
|
|
|
|
$sql = "DELETE FROM $tableSepeSpecialtyClassroom WHERE id = $id;"; |
|
|
|
|
$res = Database::query($sql); |
|
|
|
|
if (!$res) { |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoSpecialtyClassroom').Database::error(); |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoSpecialtyClassroom'); |
|
|
|
|
echo json_encode(array("status" => "false", "content" => $content)); |
|
|
|
|
} else { |
|
|
|
|
$content = $plugin->get_lang('DeleteOk'); |
|
|
|
@ -87,7 +87,7 @@ if ($_REQUEST['tab'] == 'checkTutorEdit') { |
|
|
|
|
WHERE document_type='".$type."' AND document_number='".$number."' AND document_letter='".$letter."';"; |
|
|
|
|
$res = Database::query($sql); |
|
|
|
|
if (!$res) { |
|
|
|
|
$content = $plugin->get_lang('ProblemDataBase').Database::error(); |
|
|
|
|
$content = $plugin->get_lang('ProblemDataBase'); |
|
|
|
|
error_log(print_r($content, 1)); |
|
|
|
|
exit; |
|
|
|
|
} else { |
|
|
|
@ -106,7 +106,7 @@ if ($_REQUEST['tab'] == 'delete_tutor') { |
|
|
|
|
$sql = "DELETE FROM $tableSepeSpecialtyTutors WHERE id = $id;"; |
|
|
|
|
$res = Database::query($sql); |
|
|
|
|
if (!$res) { |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoSpecialtyTutor').Database::error(); |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoSpecialtyTutor'); |
|
|
|
|
echo json_encode(array("status" => "false", "content" => $content)); |
|
|
|
|
} else { |
|
|
|
|
$content = $plugin->get_lang('DeleteOk'); |
|
|
|
@ -126,7 +126,7 @@ if ($_REQUEST['tab'] == 'delete_participant') { |
|
|
|
|
$sql = "DELETE FROM $tableSepeParticipants WHERE id = $id;"; |
|
|
|
|
$res = Database::query($sql); |
|
|
|
|
if (!$res) { |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoParticipant').Database::error(); |
|
|
|
|
$content = $plugin->get_lang('ProblemToDeleteInfoParticipant'); |
|
|
|
|
echo json_encode(array("status" => "false", "content" => $content)); |
|
|
|
|
} else { |
|
|
|
|
$content = $plugin->get_lang('DeleteOk'); |
|
|
|
@ -139,7 +139,7 @@ if ($_REQUEST['tab'] == 'unlink_action') { |
|
|
|
|
$sql = "DELETE FROM $tableSepeCourseActions WHERE id = $id;"; |
|
|
|
|
$res = Database::query($sql); |
|
|
|
|
if (!$res) { |
|
|
|
|
$content = $plugin->get_lang('ProblemToDesvincularInfoAction').Database::error(); |
|
|
|
|
$content = $plugin->get_lang('ProblemToDesvincularInfoAction'); |
|
|
|
|
echo json_encode(array("status" => "false", "content" => $content)); |
|
|
|
|
} else { |
|
|
|
|
$content = $plugin->get_lang('DeleteOk'); |
|
|
|
|