From 2a1aaf82f297ea0e0eb760c221b6a4dc0118a798 Mon Sep 17 00:00:00 2001 From: Andreas <6977712+AndreasK79@users.noreply.github.com> Date: Thu, 25 Jan 2024 11:22:25 +0100 Subject: [PATCH] Now preselects active location --- application/controllers/Logbookadvanced.php | 6 ++++++ application/views/logbookadvanced/index.php | 5 ++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/application/controllers/Logbookadvanced.php b/application/controllers/Logbookadvanced.php index 87ad45a08..d2d4e95a3 100644 --- a/application/controllers/Logbookadvanced.php +++ b/application/controllers/Logbookadvanced.php @@ -46,6 +46,11 @@ class Logbookadvanced extends CI_Controller { $data['options'] = $userOptions[0]->option_value; } + $active_station_id = $this->stations->find_active(); + $station_profile = $this->stations->profile($active_station_id); + + + $pageData = []; $pageData['datePlaceholder'] = 'DD/MM/YYYY'; $pageData['deOptions'] = $deOptions; @@ -54,6 +59,7 @@ class Logbookadvanced extends CI_Controller { $pageData['iotaarray'] = $this->logbook_model->fetchIota(); $pageData['sats'] = $this->bands->get_worked_sats(); $pageData['station_profile'] = $this->stations->all_of_user(); + $pageData['active_station_info'] = $station_profile->row(); $pageData['bands'] = $this->bands->get_worked_bands(); diff --git a/application/views/logbookadvanced/index.php b/application/views/logbookadvanced/index.php index 96163713e..2d8f4fd94 100644 --- a/application/views/logbookadvanced/index.php +++ b/application/views/logbookadvanced/index.php @@ -394,7 +394,10 @@ $options = json_decode($options);