From ecaba0768eda16bcf2f5c82b605581aaea11c43a Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Thu, 29 Oct 2020 16:45:09 +0000 Subject: [PATCH] [eQSL] Fixes issue of Sat name/mode not being sent. Fixes #675 --- application/controllers/Eqsl.php | 10 +++++----- application/models/Logbook_model.php | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/application/controllers/Eqsl.php b/application/controllers/Eqsl.php index 0323ec9b..3be8507e 100644 --- a/application/controllers/Eqsl.php +++ b/application/controllers/Eqsl.php @@ -409,18 +409,18 @@ class eqsl extends CI_Controller { } // adding sat name if it isn't blank - if ($qsl['COL_SAT_NAME'] = ''){ + if ($qsl['COL_SAT_NAME'] != ''){ $adif .= "%3C"; $adif .= "SAT%5FNAME"; $adif .= "%3A"; $adif .= strlen($qsl['COL_SAT_NAME']); $adif .= "%3E"; - $adif .= $qsl['COL_SAT_NAME']; + $adif .= str_replace('-', '%2D', $qsl['COL_SAT_NAME']); $adif .= "%20"; } // adding sat mode if it isn't blank - if ($qsl['COL_SAT_MODE'] = ''){ + if ($qsl['COL_SAT_MODE'] != ''){ $adif .= "%3C"; $adif .= "SAT%5FMODE"; $adif .= "%3A"; @@ -430,7 +430,7 @@ class eqsl extends CI_Controller { $adif .= "%20"; } - if ($qsl['eqslqthnickname'] = ''){ + if ($qsl['eqslqthnickname'] != ''){ $adif .= "%3C"; $adif .= "APP%5FEQSL%5FQTH%5FNICKNAME"; $adif .= "%3A"; @@ -441,7 +441,7 @@ class eqsl extends CI_Controller { } // adding sat mode if it isn't blank - if ($qsl['station_gridsquare'] = ''){ + if ($qsl['station_gridsquare'] != ''){ $adif .= "%3C"; $adif .= "MY%5FGRIDSQUARE"; $adif .= "%3A"; diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index 4b00a9da..a24caf1c 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -1475,7 +1475,7 @@ class Logbook_model extends CI_Model { // Show all QSOs we need to send to eQSL function eqsl_not_yet_sent() { - $this->db->select('station_profile.*, '.$this->config->item('table_name').'.COL_PRIMARY_KEY, '.$this->config->item('table_name').'.COL_TIME_ON, '.$this->config->item('table_name').'.COL_CALL, '.$this->config->item('table_name').'.COL_MODE, '.$this->config->item('table_name').'.COL_SUBMODE, '.$this->config->item('table_name').'.COL_BAND, '.$this->config->item('table_name').'.COL_COMMENT, '.$this->config->item('table_name').'.COL_RST_SENT, '.$this->config->item('table_name').'.COL_PROP_MODE'); + $this->db->select('station_profile.*, '.$this->config->item('table_name').'.COL_PRIMARY_KEY, '.$this->config->item('table_name').'.COL_TIME_ON, '.$this->config->item('table_name').'.COL_CALL, '.$this->config->item('table_name').'.COL_MODE, '.$this->config->item('table_name').'.COL_SUBMODE, '.$this->config->item('table_name').'.COL_BAND, '.$this->config->item('table_name').'.COL_COMMENT, '.$this->config->item('table_name').'.COL_RST_SENT, '.$this->config->item('table_name').'.COL_PROP_MODE, '.$this->config->item('table_name').'.COL_SAT_NAME, '.$this->config->item('table_name').'.COL_SAT_MODE'); $this->db->from('station_profile'); $this->db->join($this->config->item('table_name'),'station_profile.station_id = '.$this->config->item('table_name').'.station_id AND station_profile.eqslqthnickname != ""','left'); $this->db->where($this->config->item('table_name').'.COL_EQSL_QSL_SENT !=', 'Y');