[Contests] Added buttons for activate/deactivate all

This commit is contained in:
Andreas
2021-10-23 19:44:41 +02:00
parent b324aba559
commit 93b6cba00e
4 changed files with 109 additions and 22 deletions

View File

@@ -134,4 +134,20 @@ class Contesting extends CI_Controller {
echo json_encode(array('message' => 'OK'));
return;
}
public function deactivateall() {
$this->load->model('Contesting_model');
$this->Contesting_model->deactivateall();
header('Content-Type: application/json');
echo json_encode(array('message' => 'OK'));
return;
}
public function activateall() {
$this->load->model('Contesting_model');
$this->Contesting_model->activateall();
header('Content-Type: application/json');
echo json_encode(array('message' => 'OK'));
return;
}
}