From fc78ac132df1828dc4fc28e1a79d48f6803786c0 Mon Sep 17 00:00:00 2001 From: HB9HIL Date: Fri, 24 May 2024 22:01:38 +0200 Subject: [PATCH] we can call qso_details_ajax instead --- application/controllers/Activators.php | 40 -------------------------- application/models/Logbook_model.php | 3 ++ assets/js/sections/activators.js | 12 ++++++-- 3 files changed, 13 insertions(+), 42 deletions(-) diff --git a/application/controllers/Activators.php b/application/controllers/Activators.php index b2d056a94..1ac45d956 100644 --- a/application/controllers/Activators.php +++ b/application/controllers/Activators.php @@ -45,44 +45,4 @@ class Activators extends CI_Controller $this->load->view('interface_assets/footer', $footerData); } - public function details() - { - $this->load->model('logbook_model'); - - $call = str_replace('"', "", $this->input->post("Callsign")); - $band = str_replace('"', "", $this->input->post("Band")); - $leogeo = str_replace('"', "", $this->input->post("LeoGeo")); - $data['results'] = $this->logbook_model->activator_details($call, $band, $leogeo); - $data['filter'] = "Call " . $call; - switch ($band) { - case 'All': - $data['page_title'] = "Log View All Bands"; - $data['filter'] .= " and Band All"; - break; - case 'SAT': - $data['page_title'] = "Log View SAT"; - $data['filter'] .= " and Band SAT"; - break; - default: - $data['page_title'] = "Log View Band"; - $data['filter'] .= " and Band " . $band; - break; - } - if ($band == "SAT") { - switch ($leogeo) { - case 'both': - $data['filter'] .= " and GEO/LEO"; - break; - case 'leo': - $data['filter'] .= " and LEO"; - break; - case 'geo': - $data['filter'] .= " and GEO"; - break; - } - } - - - $this->load->view('activators/details', $data); - } } diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index bffe90cb9..55a74f3ad 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -400,6 +400,9 @@ class Logbook_model extends CI_Model { $this->db->join('satellite', 'satellite.name = '.$this->config->item('table_name').'.col_sat_name', 'left outer'); } switch ($type) { + case 'CALL': + $this->db->where('COL_CALL', $searchphrase); + break; case 'DXCC': $this->db->where('COL_COUNTRY', $searchphrase); if ($band == 'SAT' && $type == 'DXCC') { diff --git a/assets/js/sections/activators.js b/assets/js/sections/activators.js index e026a78e7..f903b4479 100644 --- a/assets/js/sections/activators.js +++ b/assets/js/sections/activators.js @@ -35,9 +35,14 @@ function showHideLeoGeo(bandselect) { function displayActivatorsContacts(call, band, leogeo) { $.ajax({ - url: base_url + "index.php/activators/details", + url: base_url + "index.php/awards/qso_details_ajax", type: "post", - data: { Callsign: call, Band: band, LeoGeo: leogeo }, + data: { + Searchphrase: call, + Band: band, + Orbit: leogeo, + Type: 'CALL' + }, success: function (html) { BootstrapDialog.show({ title: lang_general_word_qso_data, @@ -47,6 +52,9 @@ function displayActivatorsContacts(call, band, leogeo) { message: html, onshown: function (dialog) { $('[data-bs-toggle="tooltip"]').tooltip(); + $('.table-responsive .dropdown-toggle').off('mouseenter').on('mouseenter', function () { + showQsoActionsMenu($(this).closest('.dropdown')); + }); }, buttons: [ {