diff --git a/.htaccess.sample b/.htaccess.sample new file mode 100644 index 00000000..57dfd443 --- /dev/null +++ b/.htaccess.sample @@ -0,0 +1,8 @@ +# If you want to hide 'index.php' from the URL, rename this file to '.htaccess' on your server +# Then change the following variable in /application/config/config.php +# $config['index_page'] = ''; + +RewriteEngine On +RewriteCond %{REQUEST_FILENAME} !-f +RewriteCond %{REQUEST_FILENAME} !-d +RewriteRule ^(.*)$ /index.php?/$1 [L] \ No newline at end of file diff --git a/application/controllers/Adif.php b/application/controllers/Adif.php index ca3b4fff..cbf2f52c 100644 --- a/application/controllers/Adif.php +++ b/application/controllers/Adif.php @@ -82,7 +82,14 @@ class adif extends CI_Controller { $this->load->model('adif_data'); - $data['qsos'] = $this->adif_data->export_custom($this->input->post('from'), $this->input->post('to')); + // Used for exporting QSOs not previously exported to LoTW + if ($this->input->post('exportLotw') == 1) { + $exportLotw = true; + } else { + $exportLotw = false; + } + + $data['qsos'] = $this->adif_data->export_custom($this->input->post('from'), $this->input->post('to'), $exportLotw); $this->load->view('adif/data/exportall', $data); diff --git a/application/controllers/Awards.php b/application/controllers/Awards.php index d1e4d9cf..ac9bde3a 100644 --- a/application/controllers/Awards.php +++ b/application/controllers/Awards.php @@ -346,6 +346,7 @@ class Awards extends CI_Controller { } $data['was_array'] = $this->was->get_was_array($bands, $postdata); + $data['was_summary'] = $this->was->get_was_summary(); // Render Page $data['page_title'] = "Awards - WAS (Worked all states)"; diff --git a/application/controllers/Backup.php b/application/controllers/Backup.php index b1bb3a5b..9859c6ab 100644 --- a/application/controllers/Backup.php +++ b/application/controllers/Backup.php @@ -4,14 +4,13 @@ class Backup extends CI_Controller { function __construct() { parent::__construct(); - - $this->load->model('user_model'); - if(!$this->user_model->authorize(2)) { $this->session->set_flashdata('notice', 'You\'re not allowed to do that!'); redirect('dashboard'); } } /* User Facing Links to Backup URLs */ public function index() { + $this->load->model('user_model'); + if(!$this->user_model->authorize(2)) { $this->session->set_flashdata('notice', 'You\'re not allowed to do that!'); redirect('dashboard'); } $data['page_title'] = "Backup"; diff --git a/application/controllers/Lotw.php b/application/controllers/Lotw.php index 0c4b332d..4064f27c 100644 --- a/application/controllers/Lotw.php +++ b/application/controllers/Lotw.php @@ -7,13 +7,13 @@ class Lotw extends CI_Controller { { parent::__construct(); $this->load->helper(array('form', 'url')); - - $this->load->model('user_model'); - if(!$this->user_model->authorize(2)) { $this->session->set_flashdata('notice', 'You\'re not allowed to do that!'); redirect('dashboard'); } } private function loadFromFile($filepath) { + $this->load->model('user_model'); + if(!$this->user_model->authorize(2)) { $this->session->set_flashdata('notice', 'You\'re not allowed to do that!'); redirect('dashboard'); } + // Figure out how we should be marking QSLs confirmed via LoTW $query = $query = $this->db->query('SELECT lotw_rcvd_mark FROM config'); $q = $query->row(); @@ -28,13 +28,14 @@ class Lotw extends CI_Controller { $this->adif_parser->initialize(); - $tableheaders = ""; + $tableheaders = "
"; $tableheaders .= ""; $tableheaders .= ""; $tableheaders .= ""; $tableheaders .= ""; $tableheaders .= ""; $tableheaders .= ""; + $tableheaders .= ""; $tableheaders .= ""; $tableheaders .= ""; $tableheaders .= ""; @@ -76,7 +77,13 @@ class Lotw extends CI_Controller { } } else { - $lotw_status = $this->logbook_model->lotw_update($time_on, $record['call'], $record['band'], $qsl_date, $record['qsl_rcvd']); + if (isset($record['state'])) { + $state = $record['state']; + } else { + $state = ""; + } + + $lotw_status = $this->logbook_model->lotw_update($time_on, $record['call'], $record['band'], $qsl_date, $record['qsl_rcvd'], $state); } @@ -86,6 +93,7 @@ class Lotw extends CI_Controller { $table .= ""; $table .= ""; $table .= ""; + $table .= ""; $table .= ""; $table .= ""; $table .= ""; @@ -107,6 +115,9 @@ class Lotw extends CI_Controller { } public function import() { + $this->load->model('user_model'); + if(!$this->user_model->authorize(2)) { $this->session->set_flashdata('notice', 'You\'re not allowed to do that!'); redirect('dashboard'); } + $data['page_title'] = "LoTW ADIF Import"; $config['upload_path'] = './uploads/'; @@ -192,6 +203,9 @@ class Lotw extends CI_Controller { } // end function public function export() { + $this->load->model('user_model'); + if(!$this->user_model->authorize(2)) { $this->session->set_flashdata('notice', 'You\'re not allowed to do that!'); redirect('dashboard'); } + $data['page_title'] = "LoTW .TQ8 Upload"; $config['upload_path'] = './uploads/'; diff --git a/application/controllers/Qrz.php b/application/controllers/Qrz.php index 52c2b9ad..d8d01d34 100644 --- a/application/controllers/Qrz.php +++ b/application/controllers/Qrz.php @@ -36,7 +36,7 @@ class Qrz extends CI_Controller { } } else { echo "No station_id's with a QRZ API Key found"; - log_message('info', "No station_id's with a QRZ API Key found"); + log_message('error', "No station_id's with a QRZ API Key found"); } } @@ -54,22 +54,38 @@ class Qrz extends CI_Controller { * Adif is build for each qso, and then uploaded, one at a time */ function mass_upload_qsos($station_id, $qrz_api_key) { - $i = 0; $data['qsos'] = $this->logbook_model->get_qrz_qsos($station_id); + $errormessages=array(); if ($data['qsos']) { foreach ($data['qsos'] as $qso) { $adif = $this->logbook_model->create_adif_from_data($qso); - $result = $this->logbook_model->push_qso_to_qrz($qrz_api_key, $adif); - if ($result) { + + if ($qso['COL_QRZCOM_QSO_UPLOAD_STATUS'] == 'M') { + $result = $this->logbook_model->push_qso_to_qrz($qrz_api_key, $adif, true); + } else { + $result = $this->logbook_model->push_qso_to_qrz($qrz_api_key, $adif); + } + + if ($result['status'] == 'OK') { $this->markqso($qso['COL_PRIMARY_KEY']); $i++; + } else { + log_message('error', 'QRZ upload failed for qso: Call: ' . $qso['COL_CALL'] . ' Band: ' . $qso['COL_BAND'] . ' Mode: ' . $qso['COL_MODE'] . ' Time: ' . $qso['COL_TIME_ON']); + log_message('error', 'QRZ upload failed with the following message: ' .$result['message']); + $errormessages[] = $result['message'] . ' Call: ' . $qso['COL_CALL'] . ' Band: ' . $qso['COL_BAND'] . ' Mode: ' . $qso['COL_MODE'] . ' Time: ' . $qso['COL_TIME_ON']; } } - return $i; + $result['status'] = 'OK'; + $result['count'] = $i; + $result['errormessages'] = $errormessages; + return $result; } else { - return $i; + $result['status'] = 'Error'; + $result['count'] = $i; + $result['errormessages'] = $errormessages; + return $result; } } @@ -111,18 +127,20 @@ class Qrz extends CI_Controller { $qrz_api_key = $this->logbook_model->exists_qrz_api_key($postData['station_id']); header('Content-type: application/json'); - if ($i = $this->mass_upload_qsos($postData['station_id'], $qrz_api_key)) { - + $result = $this->mass_upload_qsos($postData['station_id'], $qrz_api_key); + if ($result['status'] == 'OK') { $stationinfo = $this->stations->stations_with_qrz_api_key(); $info = $stationinfo->result(); $data['status'] = 'OK'; $data['info'] = $info; - $data['infomessage'] = $i . " QSOs are now uploaded to QRZ.com"; + $data['infomessage'] = $result['count'] . " QSOs are now uploaded to QRZ.com"; + $data['errormessages'] = $result['errormessages']; echo json_encode($data); } else { $data['status'] = 'Error'; $data['info'] = 'Error, no QSOs to upload found'; + $data['errormessages'] = $result['errormessages']; echo json_encode($data); } } diff --git a/application/controllers/Qso.php b/application/controllers/Qso.php index d7550233..4a4084dc 100755 --- a/application/controllers/Qso.php +++ b/application/controllers/Qso.php @@ -60,6 +60,7 @@ class QSO extends CI_Controller { $qso_data = array( 'start_date' => $this->input->post('start_date'), 'start_time' => $this->input->post('start_time'), + 'time_stamp' => time(), 'band' => $this->input->post('band'), 'freq' => $this->input->post('freq_display'), 'freq_rx' => $this->input->post('freq_display_rx'), diff --git a/application/controllers/User.php b/application/controllers/User.php index 7c1db98c..0a9e37be 100644 --- a/application/controllers/User.php +++ b/application/controllers/User.php @@ -52,7 +52,7 @@ class User extends CI_Controller { $data['user_callsign'] = $this->input->post('user_callsign'); $data['user_locator'] = $this->input->post('user_locator'); $data['user_timezone'] = $this->input->post('user_timezone'); - $this->load->view('user/add'); + $this->load->view('user/add', $data); } else { $this->load->view('user/add', $data); } @@ -88,7 +88,7 @@ class User extends CI_Controller { $data['user_lastname'] = $this->input->post('user_lastname'); $data['user_callsign'] = $this->input->post('user_callsign'); $data['user_locator'] = $this->input->post('user_locator'); - $this->load->view('user/add'); + $this->load->view('user/add', $data); $this->load->view('interface_assets/footer'); } } diff --git a/application/controllers/User_Logbooks.php b/application/controllers/User_Logbooks.php index 02e5cf20..08d5c6a8 100644 --- a/application/controllers/User_Logbooks.php +++ b/application/controllers/User_Logbooks.php @@ -16,4 +16,6 @@ class Logbooks extends CI_Controller { public function index() { echo 'Functions to come'; - } \ No newline at end of file + } + +} diff --git a/application/models/Adif_data.php b/application/models/Adif_data.php index 008af8a0..8b15e9f2 100644 --- a/application/models/Adif_data.php +++ b/application/models/Adif_data.php @@ -67,10 +67,9 @@ class adif_data extends CI_Model { return $this->db->get(); } - function export_custom($from, $to) { + function export_custom($from, $to, $exportLotw = false) { $this->load->model('stations'); $active_station_id = $this->stations->find_active(); - $this->db->select(''.$this->config->item('table_name').'.*, station_profile.*'); $this->db->from($this->config->item('table_name')); @@ -87,6 +86,10 @@ class adif_data extends CI_Model { $to = $to->format('Y-m-d'); $this->db->where("date(".$this->config->item('table_name').".COL_TIME_ON) <= '".$to."'"); } + if ($exportLotw) { + $this->db->where($this->config->item('table_name').".COL_LOTW_QSL_SENT != 'Y'"); + } + $this->db->order_by($this->config->item('table_name').".COL_TIME_ON", "ASC"); $this->db->join('station_profile', 'station_profile.station_id = '.$this->config->item('table_name').'.station_id'); diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index bee3c509..0b7cfcef 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -123,6 +123,7 @@ class Logbook_model extends CI_Model { 'COL_STATE' => trim($this->input->post('usa_state')), 'COL_SOTA_REF' => trim($this->input->post('sota_ref')), 'COL_DARC_DOK' => trim($this->input->post('darc_dok')), + 'COL_NOTES' => $this->input->post('notes'), ); $station_id = $this->input->post('station_profile'); @@ -335,7 +336,8 @@ class Logbook_model extends CI_Model { // Push qso to qrz if apikey is set if ($apikey = $this->exists_qrz_api_key($data['station_id'])) { $adif = $this->create_adif_from_data($data); - IF ($this->push_qso_to_qrz($apikey, $adif)) { + $result = $this->push_qso_to_qrz($apikey, $adif); + IF ($result['status'] == 'OK') { $data['COL_QRZCOM_QSO_UPLOAD_STATUS'] = 'Y'; $data['COL_QRZCOM_QSO_UPLOAD_DATE'] = date("Y-m-d H:i:s", strtotime("now")); } @@ -368,13 +370,17 @@ class Logbook_model extends CI_Model { * Function uploads a QSO to QRZ with the API given. * $adif contains a line with the QSO in the ADIF format. QSO ends with an */ - function push_qso_to_qrz($apikey, $adif) { + function push_qso_to_qrz($apikey, $adif, $replaceoption = false) { $url = 'http://logbook.qrz.com/api'; // TODO: Move this to database $post_data['KEY'] = $apikey; $post_data['ACTION'] = 'INSERT'; $post_data['ADIF'] = $adif; + if ($replaceoption) { + $post_data['OPTION'] = 'REPLACE'; + } + $ch = curl_init( $url ); curl_setopt( $ch, CURLOPT_POST, true); curl_setopt( $ch, CURLOPT_POSTFIELDS, $post_data); @@ -384,15 +390,20 @@ class Logbook_model extends CI_Model { $content = curl_exec($ch); if ($content){ - if (stristr($content,'RESULT=OK')) { - return true; + if (stristr($content,'RESULT=OK') || stristr($content,'RESULT=REPLACE')) { + $result['status'] = 'OK'; + return $result; } else { - return false; + $result['status'] = 'error'; + $result['message'] = $content; + return $result; } } if(curl_errno($ch)){ - return false; + $result['status'] = 'error'; + $result['message'] = 'Curl error: '. curl_errno($ch); + return $result; } curl_close($ch); } @@ -564,6 +575,7 @@ class Logbook_model extends CI_Model { 'COL_CQZ' => $this->input->post('cqz'), 'COL_SAT_NAME' => $this->input->post('sat_name'), 'COL_SAT_MODE' => $this->input->post('sat_mode'), + 'COL_NOTES' => $this->input->post('notes'), 'COL_QSLSDATE' => date('Y-m-d'), 'COL_QSLRDATE' => date('Y-m-d'), 'COL_QSL_SENT' => $this->input->post('qsl_sent'), @@ -1160,7 +1172,7 @@ class Logbook_model extends CI_Model { $CI->load->model('Stations'); $station_id = $CI->Stations->find_active(); - $query = $this->db->query('SELECT DISTINCT (COL_QSL_SENT) AS band, count(COL_QSL_SENT) AS count FROM '.$this->config->item('table_name').' WHERE station_id = '.$station_id.' AND COL_QSL_SENT = "Y" GROUP BY band'); + $query = $this->db->query('SELECT count(COL_QSL_SENT) AS count FROM '.$this->config->item('table_name').' WHERE station_id = '.$station_id.' AND COL_QSL_SENT = "Y"'); $row = $query->row(); @@ -1171,14 +1183,14 @@ class Logbook_model extends CI_Model { } } - /* Return total number of QSL Cards requested */ + /* Return total number of QSL Cards requested for printing - that means "requested" or "queued" */ function total_qsl_requested() { $CI =& get_instance(); $CI->load->model('Stations'); $station_id = $CI->Stations->find_active(); - $query = $this->db->query('SELECT DISTINCT (COL_QSL_SENT) AS band, count(COL_QSL_SENT) AS count FROM '.$this->config->item('table_name').' WHERE station_id = '.$station_id.' AND COL_QSL_SENT = "R" GROUP BY band'); + $query = $this->db->query('SELECT count(COL_QSL_SENT) AS count FROM '.$this->config->item('table_name').' WHERE station_id = '.$station_id.' AND COL_QSL_SENT in ("Q", "R")'); $row = $query->row(); @@ -1196,7 +1208,7 @@ class Logbook_model extends CI_Model { $CI->load->model('Stations'); $station_id = $CI->Stations->find_active(); - $query = $this->db->query('SELECT DISTINCT (COL_QSL_RCVD) AS band, count(COL_QSL_RCVD) AS count FROM '.$this->config->item('table_name').' WHERE station_id = '.$station_id.' AND COL_QSL_RCVD = "Y" GROUP BY band'); + $query = $this->db->query('SELECT count(COL_QSL_RCVD) AS count FROM '.$this->config->item('table_name').' WHERE station_id = '.$station_id.' AND COL_QSL_RCVD = "Y"'); $row = $query->row(); @@ -1300,12 +1312,22 @@ class Logbook_model extends CI_Model { } } - function lotw_update($datetime, $callsign, $band, $qsl_date, $qsl_status) { - $data = array( - 'COL_LOTW_QSLRDATE' => $qsl_date, - 'COL_LOTW_QSL_RCVD' => $qsl_status, - 'COL_LOTW_QSL_SENT' => 'Y' - ); + function lotw_update($datetime, $callsign, $band, $qsl_date, $qsl_status, $state) { + + if($state != "") { + $data = array( + 'COL_LOTW_QSLRDATE' => $qsl_date, + 'COL_LOTW_QSL_RCVD' => $qsl_status, + 'COL_LOTW_QSL_SENT' => 'Y', + 'COL_STATE' => $state + ); + } else { + $data = array( + 'COL_LOTW_QSLRDATE' => $qsl_date, + 'COL_LOTW_QSL_RCVD' => $qsl_status, + 'COL_LOTW_QSL_SENT' => 'Y' + ); + } $this->db->where('date_format(COL_TIME_ON, \'%Y-%m-%d %H:%i\') = "'.$datetime.'"'); $this->db->where('COL_CALL', $callsign); @@ -1565,7 +1587,7 @@ class Logbook_model extends CI_Model { // Sanitise TX_POWER if (isset($record['tx_pwr'])){ - $tx_pwr = filter_var($record['tx_pwr'],FILTER_SANITIZE_NUMBER_INT); + $tx_pwr = filter_var($record['tx_pwr'],FILTER_VALIDATE_FLOAT); }else{ $tx_pwr = NULL; } @@ -1862,7 +1884,6 @@ class Logbook_model extends CI_Model { 'COL_QSO_COMPLETE' => (!empty($record['qso_complete'])) ? $record['qso_complete'] : '', 'COL_QSO_DATE' => (!empty($record['qso_date'])) ? $record['qso_date'] : null, 'COL_QSO_DATE_OFF' => (!empty($record['qso_date_off'])) ? $record['qso_date_off'] : null, - 'COL_QSO_RANDOM' => (!empty($record['qso_random'])) ? $record['qso_random'] : null, 'COL_QTH' => (!empty($record['qth'])) ? $record['qth'] : '', 'COL_QTH_INTL' => (!empty($record['qth_intl'])) ? $record['qth_intl'] : '', 'COL_REGION' => (!empty($record['region'])) ? $record['region'] : '', @@ -1883,7 +1904,7 @@ class Logbook_model extends CI_Model { 'COL_SOTA_REF' => (!empty($record['sota_ref'])) ? $record['sota_ref'] : '', 'COL_SRX' => (!empty($record['srx'])) ? $record['srx'] : null, 'COL_SRX_STRING' => (!empty($record['srx_string'])) ? $record['srx_string'] : '', - 'COL_STATE' => (!empty($record['state'])) ? $record['state'] : '', + 'COL_STATE' => (!empty($record['state'])) ? strtoupper($record['state']) : '', 'COL_STATION_CALLSIGN' => (!empty($record['station_callsign'])) ? $record['station_callsign'] : '', 'COL_STX' => (!empty($record['stx'])) ? $record['stx'] : null, 'COL_STX_STRING' => (!empty($record['stx_string'])) ? $record['stx_string'] : '', @@ -1956,6 +1977,18 @@ class Logbook_model extends CI_Model { public function check_dxcc_table($call, $date){ $len = strlen($call); + $dxcc_exceptions = $this->db->select('`entity`, `adif`, `cqz`') + ->where('call', $call) + ->where('(start <= ', $date) + ->or_where('start is null)', NULL, false) + ->where('(end >= ', $date) + ->or_where('end is null)', NULL, false) + ->get('dxcc_exceptions'); + + if ($dxcc_exceptions->num_rows() > 0){ + $row = $dxcc_exceptions->row_array(); + return array($row['adif'], $row['entity'], $row['cqz']); + } // query the table, removing a character from the right until a match for ($i = $len; $i > 0; $i--){ //printf("searching for %s\n", substr($call, 0, $i)); @@ -1981,18 +2014,19 @@ class Logbook_model extends CI_Model { public function dxcc_lookup($call, $date){ $len = strlen($call); - - $this->db->where('call', $call); - $this->db->where('CURDATE() between start and end'); - - $query = $this->db->get('dxcc_exceptions'); + + $dxcc_exceptions = $this->db->select('`entity`, `adif`, `cqz`') + ->where('call', $call) + ->where('(start <= CURDATE()') + ->or_where('start is null', NULL, false) + ->where('end >= CURDATE()') + ->or_where('end is null)', NULL, false) + ->get('dxcc_exceptions'); - if ($query->num_rows() > 0){ - - $row = $query->row_array(); - - return $row; + if ($dxcc_exceptions->num_rows() > 0){ + $row = $dxcc_exceptions->row_array(); + return $row; } else { // query the table, removing a character from the right until a match for ($i = $len; $i > 0; $i--){ diff --git a/application/models/Was.php b/application/models/Was.php index 451e342d..0e63d42a 100644 --- a/application/models/Was.php +++ b/application/models/Was.php @@ -132,6 +132,39 @@ class was extends CI_Model { } } + /* + * Function gets worked and confirmed summary on each band on the active stationprofile + */ + function get_was_summary() { + $CI =& get_instance(); + $CI->load->model('Stations'); + $station_id = $CI->Stations->find_active(); + + $stateArray = explode(',', $this->stateString); + + $states = array(); // Used for keeping track of which states that are not worked + + $sql = "SELECT thcv.col_band, count(distinct thcv.col_state) as count, coalesce (cfmwas.count, 0) as cfmwas FROM " . $this->config->item('table_name') . " thcv"; + + $sql .= " left outer join ( + select col_band, count(distinct col_state) as count from " . $this->config->item('table_name') . " thcv"; + $sql .= " where station_id = " . $station_id; + $sql .= $this->addStateToQuery(); + + $sql .= " and (col_qsl_rcvd = 'Y' or col_lotw_qsl_rcvd = 'Y') + group by col_band"; + $sql .= ") cfmwas on thcv.col_band = cfmwas.col_band "; + + $sql .= " where station_id = " . $station_id; + + $sql .= $this->addStateToQuery(); + $sql .= " group by thcv.col_band order by thcv.col_band+0 desc"; + + $query = $this->db->query($sql); + + return $query->result(); + } + /* * Function returns all worked, but not confirmed states * $postdata contains data from the form, in this case Lotw or QSL are used diff --git a/application/views/adif/import.php b/application/views/adif/import.php index 66e0aa80..02c42272 100644 --- a/application/views/adif/import.php +++ b/application/views/adif/import.php @@ -39,8 +39,8 @@
- - + +
@@ -101,8 +101,16 @@
- - + + +
+
+
+
+
+
+ +
diff --git a/application/views/awards/cq/index.php b/application/views/awards/cq/index.php index 0597191d..65677eb7 100644 --- a/application/views/awards/cq/index.php +++ b/application/views/awards/cq/index.php @@ -143,11 +143,13 @@
+ '; foreach($bands as $band) { echo ''; @@ -157,6 +159,7 @@ '; foreach ($cq_array as $cq => $value) { // Fills the table with the data echo ' + '; foreach ($value as $key) { echo ''; diff --git a/application/views/awards/was/index.php b/application/views/awards/was/index.php index bcd79896..b6ec561d 100644 --- a/application/views/awards/was/index.php +++ b/application/views/awards/was/index.php @@ -69,10 +69,12 @@ + '; foreach($bands as $band) { echo ''; @@ -80,16 +82,47 @@ echo ''; + foreach ($was_array as $was => $value) { // Fills the table with the data echo ' + '; foreach ($value as $key) { echo ''; } echo ''; } - echo '
QSO DateCallModeLoTW QSL ReceivedDate LoTW ConfirmedStateLog StatusLoTW Status
".$record['mode']."".$record['qsl_rcvd']."".$qsl_date."".$state."QSO Record: ".$status."LoTW Record: ".$lotw_status."
# CQ Zone' . $band . '
' . $i++ . ' '. $cq .'' . $key . '
# State' . $band . '
' . $i++ . ' '. $was .'' . $key . '
'; + echo ' +

Summary

+ + + + '; + + foreach ($was_summary as $was) { // Fills the table with the data + echo ''; + } + + echo ' + + + + '; + + foreach ($was_summary as $was) { // Fills the table with the data + echo ''; + } + + echo ' + '; + foreach ($was_summary as $was) { // Fills the table with the data + echo ''; + } + + echo ' +
' . $was->col_band . '
Total worked' . $was->count . '
Total confirmed' . $was->cfmwas . '
+ '; } else { echo ''; diff --git a/application/views/eqsl/import.php b/application/views/eqsl/import.php index bc0adef8..d05c62d2 100644 --- a/application/views/eqsl/import.php +++ b/application/views/eqsl/import.php @@ -15,23 +15,29 @@ load->view('layout/messages'); ?> - - - - - - - - - -
Upload a file -

Upload the Exported ADIF file from eQSL from the Download Inbox page, to mark QSOs as confirmed on eQSL.

+ +
+ + +

+

Upload the Exported ADIF file from eQSL from the Download Inbox page, to mark QSOs as confirmed on eQSL.

Important Log files must have the file type .adi

-
Pull eQSL data for me -

Cloudlog will use the eQSL username and password stored in your user profile to download confirmations from eQSL for you. We will only download confirmations received since your last eQSL confirmed QSO.

-
- + + +

+ +
+ + +

Cloudlog will use the eQSL username and password stored in your user profile to download confirmations from eQSL for you. We will only download confirmations received since your last eQSL confirmed QSO.

+
+ + diff --git a/application/views/interface_assets/footer.php b/application/views/interface_assets/footer.php index 6b347416..da270af0 100644 --- a/application/views/interface_assets/footer.php +++ b/application/views/interface_assets/footer.php @@ -9,6 +9,10 @@ + + uri->segment(1) == "adif") { ?> @@ -529,10 +533,15 @@ $(document).on('change', 'input', function(){ // Set Map to Lat/Long it locator is not empty if($('#locator').val() == "") { + var redIcon = L.icon({ + iconUrl: icon_dot_url, + iconSize: [18, 18], // size of the icon + }); + markers.clearLayers(); - var marker = L.marker([result.dxcc.lat, result.dxcc.long]); - mymap.setZoom(8); - mymap.panTo([result.dxcc.lat, result.dxcc.long]); + var marker = L.marker([result.dxcc.lat, result.dxcc.long], {icon: redIcon}); + mymap.setZoom(8); + mymap.panTo([result.dxcc.lat, result.dxcc.long]); markers.addLayer(marker).addTo(mymap); } } @@ -724,15 +733,19 @@ $(document).on('change', 'input', function(){ $('#ituz').val(result.dxcc.ituz); + var redIcon = L.icon({ + iconUrl: icon_dot_url, + iconSize: [18, 18], // size of the icon + }); // Set Map to Lat/Long markers.clearLayers(); - mymap.setZoom(8); + mymap.setZoom(8); if (typeof result.latlng !== "undefined" && result.latlng !== false) { - var marker = L.marker([result.latlng[0], result.latlng[1]]); + var marker = L.marker([result.latlng[0], result.latlng[1]], {icon: redIcon}); mymap.panTo([result.latlng[0], result.latlng[1]]); } else { - var marker = L.marker([result.dxcc.lat, result.dxcc.long]); + var marker = L.marker([result.dxcc.lat, result.dxcc.long], {icon: redIcon}); mymap.panTo([result.dxcc.lat, result.dxcc.long]); } @@ -905,7 +918,12 @@ $(document).on('change', 'input', function(){ // Set Map to Lat/Long markers.clearLayers(); if (typeof result !== "undefined") { - var marker = L.marker([result[0], result[1]]); + var redIcon = L.icon({ + iconUrl: icon_dot_url, + iconSize: [18, 18], // size of the icon + }); + + var marker = L.marker([result[0], result[1]], {icon: redIcon}); mymap.setZoom(8); mymap.panTo([result[0], result[1]]); } @@ -1040,7 +1058,13 @@ $(document).on('change', 'input', function(){ id: 'mapbox.streets' }).addTo(mymap); - L.marker([lat,long]).addTo(mymap) + + var redIcon = L.icon({ + iconUrl: icon_dot_url, + iconSize: [18, 18], // size of the icon + }); + + L.marker([lat,long], {icon: redIcon}).addTo(mymap) .bindPopup(callsign); mymap.on('click', onMapClick); @@ -1361,6 +1385,12 @@ $(document).ready(function(){ uri->segment(1) == "qrz") { ?>