Adding Clublog and PropMode to Timeline-Analytics

This commit is contained in:
int2001
2024-08-22 05:15:12 +00:00
parent a5a5d0bc91
commit 952b56ee65
2 changed files with 81 additions and 77 deletions

View File

@@ -3,16 +3,14 @@ defined('BASEPATH') OR exit('No direct script access allowed');
class Timeline extends CI_Controller {
function __construct()
{
function __construct() {
parent::__construct();
$this->load->model('user_model');
if(!$this->user_model->authorize(2)) { $this->session->set_flashdata('error', __("You're not allowed to do that!")); redirect('dashboard'); }
}
public function index()
{
public function index() {
// Render Page
$data['page_title'] = __("Timeline");
@@ -25,6 +23,13 @@ class Timeline extends CI_Controller {
$band = 'All';
}
if ($this->input->post('propmode') != NULL) {
$propmode = $this->input->post('propmode');
}
else {
$propmode = 'All';
}
if ($this->input->post('mode') != NULL) {
$mode = $this->input->post('mode');
}
@@ -53,6 +58,13 @@ class Timeline extends CI_Controller {
$lotw = '0';
}
if ($this->input->post('clublog') != NULL) {
$clublog = $this->input->post('clublog');
}
else {
$clublog = '0';
}
if ($this->input->post('eqsl') != NULL) {
$eqsl = $this->input->post('eqsl');
}
@@ -65,7 +77,7 @@ class Timeline extends CI_Controller {
$data['modes'] = $this->modes->active();
$data['timeline_array'] = $this->Timeline_model->get_timeline($band, $mode, $award, $qsl, $lotw, $eqsl);
$data['timeline_array'] = $this->Timeline_model->get_timeline($band, $mode, $propmode, $award, $qsl, $lotw, $eqsl, $clublog);
$data['worked_bands'] = $this->bands->get_worked_bands();
$data['bandselect'] = $band;
$data['modeselect'] = $mode;