From 31c4d14d5c2af07326c0b6f1bf4bdfa906f77e42 Mon Sep 17 00:00:00 2001 From: int2001 Date: Mon, 7 Aug 2023 13:39:35 +0000 Subject: [PATCH] Prevent QSO being updated twice or more when LoTW-Cnf arrives --- application/models/Logbook_model.php | 1 + 1 file changed, 1 insertion(+) diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index 34953757..0a9f9916 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -2725,6 +2725,7 @@ class Logbook_model extends CI_Model { $this->db->where('date_format(COL_TIME_ON, \'%Y-%m-%d %H:%i\') = "'.$datetime.'"'); $this->db->where('COL_CALL', $callsign); $this->db->where('COL_BAND', $band); + $this->db->where('COL_LOTW_QSL_RCVD !=', $qsl_status); // Prevent QSO from beeing updated twice (or more) $this->db->where('COL_STATION_CALLSIGN', $station_callsign); $this->db->update($this->config->item('table_name'), $data);