Merge branch 'dev' into menu_sorted

This commit is contained in:
HB9HIL
2024-05-02 22:21:35 +02:00
committed by GitHub
62 changed files with 1588 additions and 1036 deletions

View File

@@ -255,9 +255,12 @@ class Awards extends CI_Controller {
$this->load->view('interface_assets/footer', $footerData);
}
public function jcc () {
public function jcc () {
$footerData = [];
$footerData['scripts'] = ['assets/js/sections/jcc.js'];
$footerData['scripts'] = [
'assets/js/sections/jcc.js?' . filemtime(realpath(__DIR__ . "/../../assets/js/sections/jcc.js")),
'assets/js/sections/jccmap.js?' . filemtime(realpath(__DIR__ . "/../../assets/js/sections/jccmap.js"))
];
$this->load->model('jcc_model');
$this->load->model('modes');
@@ -354,6 +357,14 @@ class Awards extends CI_Controller {
return;
}
public function jcc_cities() {
$this->load->model('Jcc_model');
$data = $this->Jcc_model->jccCities();
header('Content-Type: application/json');
echo json_encode($data, JSON_PRETTY_PRINT);
}
public function vucc() {
$this->load->model('vucc');
$this->load->model('bands');
@@ -1463,6 +1474,41 @@ class Awards extends CI_Controller {
echo json_encode($newdxcc);
}
/*
function jcc_map
This displays the DXCC map
*/
public function jcc_map() {
$this->load->model('jcc_model');
$this->load->model('bands');
$bands[] = $this->security->xss_clean($this->input->post('band'));
$postdata['qsl'] = $this->input->post('qsl') == 0 ? NULL: 1;
$postdata['lotw'] = $this->input->post('lotw') == 0 ? NULL: 1;
$postdata['eqsl'] = $this->input->post('eqsl') == 0 ? NULL: 1;
$postdata['qrz'] = $this->input->post('qrz') == 0 ? NULL: 1;
$postdata['worked'] = $this->input->post('worked') == 0 ? NULL: 1;
$postdata['confirmed'] = $this->input->post('confirmed') == 0 ? NULL: 1;
$postdata['notworked'] = $this->input->post('notworked') == 0 ? NULL: 1;
$postdata['band'] = $this->security->xss_clean($this->input->post('band'));
$postdata['mode'] = $this->security->xss_clean($this->input->post('mode'));
$jcc_wkd = $this->jcc_model->fetch_jcc_wkd($postdata);
$jcc_cnfm = $this->jcc_model->fetch_jcc_cnfm($postdata);
$jccs = [];
foreach ($jcc_wkd as $jcc) {
$jccs[$jcc->COL_CNTY] = array(1, 0);
}
foreach ($jcc_cnfm as $jcc) {
$jccs[$jcc->COL_CNTY][1] = 1;
}
header('Content-Type: application/json');
echo json_encode($jccs);
}
/*
function iota
This displays the IOTA map

View File

@@ -15,65 +15,66 @@ class Contesting extends CI_Controller {
if(!$this->user_model->authorize(2)) { $this->session->set_flashdata('notice', 'You\'re not allowed to do that!'); redirect('dashboard'); }
}
public function index() {
$this->load->model('cat');
$this->load->model('stations');
$this->load->model('modes');
public function index() {
$this->load->model('cat');
$this->load->model('stations');
$this->load->model('modes');
$this->load->model('contesting_model');
$this->load->model('bands');
$data['my_gridsquare'] = $this->stations->find_gridsquare();
$data['radios'] = $this->cat->radios();
$data['modes'] = $this->modes->active();
$data['radios'] = $this->cat->radios();
$data['modes'] = $this->modes->active();
$data['contestnames'] = $this->contesting_model->getActivecontests();
$data['bands'] = $this->bands->get_user_bands_for_qso_entry();
$this->load->library('form_validation');
$this->form_validation->set_rules('start_date', 'Date', 'required');
$this->form_validation->set_rules('start_time', 'Time', 'required');
$this->form_validation->set_rules('callsign', 'Callsign', 'required');
$this->form_validation->set_rules('start_date', 'Date', 'required');
$this->form_validation->set_rules('start_time', 'Time', 'required');
$this->form_validation->set_rules('callsign', 'Callsign', 'required');
$data['page_title'] = "Contest Logging";
$this->load->view('interface_assets/header', $data);
$this->load->view('contesting/index');
$this->load->view('interface_assets/footer');
}
}
public function getSessionQsos() {
$this->load->model('Contesting_model');
public function getSessionQsos() {
session_write_close();
$this->load->model('Contesting_model');
$qso = $this->input->post('qso');
$qso = $this->input->post('qso');
header('Content-Type: application/json');
echo json_encode($this->Contesting_model->getSessionQsos($qso));
}
}
public function getSession() {
$this->load->model('Contesting_model');
session_write_close();
$this->load->model('Contesting_model');
header('Content-Type: application/json');
header('Content-Type: application/json');
echo json_encode($this->Contesting_model->getSession());
}
}
public function deleteSession() {
$this->load->model('Contesting_model');
$this->load->model('Contesting_model');
$qso = $this->input->post('qso');
$qso = $this->input->post('qso');
$data = $this->Contesting_model->deleteSession($qso);
$data = $this->Contesting_model->deleteSession($qso);
return json_encode($data);
}
return json_encode($data);
}
public function setSession() {
$this->load->model('Contesting_model');
$this->Contesting_model->setSession();
return json_encode("ok");
}
$this->load->model('Contesting_model');
$this->Contesting_model->setSession();
header('Content-Type: application/json');
echo json_encode($this->Contesting_model->getSession());
}
public function create() {
$this->load->model('Contesting_model');
@@ -82,13 +83,10 @@ class Contesting extends CI_Controller {
$this->form_validation->set_rules('name', 'Contest Name', 'required');
$this->form_validation->set_rules('adifname', 'Adif Contest Name', 'required');
if ($this->form_validation->run() == FALSE)
{
if ($this->form_validation->run() == FALSE) {
$data['page_title'] = "Create Mode";
$this->load->view('contesting/create', $data);
}
else
{
} else {
$this->Contesting_model->add();
}
}
@@ -190,7 +188,7 @@ class Contesting extends CI_Controller {
header('Content-Type: application/json');
if ($result && $result->num_rows()) {
$timeb4=substr($result->row()->b4,0,5);
$custom_date_format = $this->session->userdata('user_date_format');
$custom_date_format = $this->session->userdata('user_date_format');
$abstimeb4=date($custom_date_format, strtotime($result->row()->COL_TIME_OFF)).' '.date('H:i',strtotime($result->row()->COL_TIME_OFF));
echo json_encode(array('message' => 'Worked at '.$abstimeb4.' ('.$timeb4.' ago) before'));
}

View File

@@ -524,10 +524,11 @@ class Lotw extends CI_Controller {
$state = "";
}
// Present only if the QSLing station specified a single valid grid square value in its station location uploaded to LoTW.
$qsl_gridsquare = "";
if (isset($record['gridsquare'])) {
$qsl_gridsquare = $record['gridsquare'];
} else {
$qsl_gridsquare = "";
if (strlen($record['gridsquare']) > strlen($status[2]) || substr(strtoupper($status[2]), 0, 4) != substr(strtoupper($record['gridsquare']), 0, 4)) {
$qsl_gridsquare = $record['gridsquare'];
}
}
if (isset($record['vucc_grids'])) {

View File

@@ -21,6 +21,46 @@ class Qrz extends CI_Controller {
$this->config->load('config');
}
/*
* API Key Status Test
*/
public function qrz_apitest() {
$apikey = xss_clean($this->input->post('APIKEY'));
$url = 'http://logbook.qrz.com/api'; // TODO: Move this to database
$post_data['KEY'] = $apikey;
$post_data['ACTION'] = 'STATUS';
$ch = curl_init( $url );
curl_setopt( $ch, CURLOPT_POST, true);
curl_setopt( $ch, CURLOPT_POSTFIELDS, $post_data);
curl_setopt( $ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt( $ch, CURLOPT_HEADER, 0);
curl_setopt( $ch, CURLOPT_CONNECTTIMEOUT, 20);
curl_setopt( $ch, CURLOPT_RETURNTRANSFER, true);
$content = curl_exec($ch);
curl_close($ch);
if ($content){
if (stristr($content,'RESULT=OK')) {
$result['status'] = 'OK';
$result['message'] = $content;
}
else {
$result['status'] = 'Failed';
$result['message'] = $content;
}
}
if(curl_errno($ch)){
$result['status'] = 'error';
$result['message'] = 'Curl error: '. curl_errno($ch);
}
header('Content-Type: application/json');
echo json_encode($result);
}
/*
* Upload QSO to QRZ.com
* When called from the url wavelog/qrz/upload, the function loops through all station_id's with a qrz api key defined.
@@ -36,12 +76,14 @@ class Qrz extends CI_Controller {
if ($station_ids) {
foreach ($station_ids as $station) {
$qrz_api_key = $station->qrzapikey;
if($this->mass_upload_qsos($station->station_id, $qrz_api_key, true)) {
echo "QSOs have been uploaded to QRZ.com.";
log_message('info', 'QSOs have been uploaded to QRZ.com.');
} else{
echo "No QSOs found for upload.";
log_message('info', 'No QSOs found for upload.');
if ($station->qrzrealtime>=0) {
if($this->mass_upload_qsos($station->station_id, $qrz_api_key, true)) {
echo "QSOs have been uploaded to QRZ.com. for station_id ".$station->station_id;
} else{
echo "No QSOs found for upload and station_id ".$station->station_id;
}
} else {
echo "Station ".$station->station_id." disabled for upload to QRZ.com.";
}
}
} else {
@@ -84,11 +126,11 @@ class Qrz extends CI_Controller {
$i++;
$result['status'] = 'OK';
} elseif ( ($result['status']=='error') && (substr($result['message'],0,11) == 'STATUS=AUTH')) {
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']);
log_message('error', 'QRZ upload stopped for Station_ID: ' .$station_id);
log_message('error', 'QRZ upload failed for qso for Station_ID '.$station_id.' // Call: ' . $qso->COL_CALL . ' Band: ' . $qso->COL_BAND . ' Mode: ' . $qso->COL_MODE . ' Time: ' . $qso->COL_TIME_ON . ' // Message: '.$result['message']);
$errormessages[] = $result['message'] . ' Call: ' . $qso->COL_CALL . ' Band: ' . $qso->COL_BAND . ' Mode: ' . $qso->COL_MODE . ' Time: ' . $qso->COL_TIME_ON;
$result['status'] = 'Error';
$sql = 'update station_profile set qrzrealtime = -1 where station_id = ?';
$this->db->query($sql,$station_id);
break; /* If key is invalid, immediate stop syncing for more QSOs of this station */
} 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);
@@ -148,21 +190,27 @@ class Qrz extends CI_Controller {
$this->load->model('logbook_model');
$result = $this->logbook_model->exists_qrz_api_key($postData['station_id']);
$qrz_api_key = $result->qrzapikey;
$qrz_enabled = $result->qrzrealtime;
header('Content-type: application/json');
$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();
if ($qrz_enabled>=0) {
$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'] = $result['count'] . " QSOs are now uploaded to QRZ.com";
$data['errormessages'] = $result['errormessages'];
echo json_encode($data);
$data['status'] = 'OK';
$data['info'] = $info;
$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 found to upload.';
$data['errormessages'] = $result['errormessages'];
echo json_encode($data);
}
} else {
$data['status'] = 'Error';
$data['info'] = 'Error: No QSOs found to upload.';
$data['errormessages'] = $result['errormessages'];
$data['status']='QRZ Disabled for station'.$this->security->xss_clean($postData['station_id']);
echo json_encode($data);
}
}

View File

@@ -15,7 +15,9 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Работени';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Потвърдени';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = 'Необходими';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "共确认";
$lang['awards_cq_page_title'] = "CQ 杂志 WAZ 奖状";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = '已通联';
$lang['general_word_worked_not_confirmed'] = "已通联未确认";
$lang['general_word_not_worked'] = "未通联";
$lang['general_word_confirmed'] = '已确认';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "确认";
$lang['general_word_needed'] = '待通联';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = '你没有电台日志。 请前往<a href
$lang['hams_at_no_activations_found'] = '未找到即将进行的激活。 请稍后再回来查看。';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Spojeno';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Potvrzeno';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = 'Potřebuje se';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Gewerkt';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Bevestigd';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = 'Nodig';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -9,6 +9,7 @@ $lang['awards_show_not_worked'] = "Show not worked";
$lang['awards_qsl_type'] = "Show QSO with QSL Type";
$lang['awards_show_cq_map'] = "Show CQ Zone Map";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
$lang['awards_summary'] = "Summary";
$lang['awards_total'] = "Total";
$lang['awards_total_worked'] = "Total worked";

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Worked';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Confirmed';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = 'Needed';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Workittu';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Kuitattu';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = 'Tarvittu';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total \"confirmés\"";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = "Réalisés";
$lang['general_word_worked_not_confirmed'] = "Réalisés non confirmés";
$lang['general_word_not_worked'] = "Non réalisés";
$lang['general_word_confirmed'] = "Confirmés";
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = "Demandés";
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = "Vous n'avez pas de journal de travail pou
$lang['hams_at_no_activations_found'] = "Aucune activation à venir trouvée. Veuillez revenir plus tard.";
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "fr-FR";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Message (QSLMSG) par défaut";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Vous pouvez définir un message par défaut qui sera renseigné et envoyé pour chaque QSO pour ce lieu station.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -16,7 +16,8 @@ $lang['awards_total_confirmed'] = "Gesamt bestätigt";
$lang['awards_cq_page_title'] = "Diplome - CQ Magazin WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_itu_map'] = "Zeige Karte der ITU-Zonen";
$lang['awards_show_jcc_map'] = "Zeige Karte der JCCs";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Gearbeitet';
$lang['general_word_worked_not_confirmed'] = "Gearbeitet, nicht bestätigt";
$lang['general_word_not_worked'] = "Nicht gearbeitet";
$lang['general_word_confirmed'] = 'Bestätigt';
$lang['general_word_not_confirmed'] = "Nicht Bestätigt";
$lang['general_word_confirmation'] = "Bestätigung";
$lang['general_word_needed'] = 'Benötigt';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'Es wurde kein Stationslogbuch angelegt. K
$lang['hams_at_no_activations_found'] = 'Keine bevorstehenden Aktivierungen gefunden. Bitte später noch einmal vorbeischauen.';
$lang['gen_add_to_contest'] = "QSOs zu Contest hinzuf&uuml;gen";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "de-DE";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Standard QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Definiere eine Standard-Nachricht, welche für jedes QSO in diesem Stationsstandort an eQSL übertragen wird.";
$lang['station_location_qrz_subscription'] = 'Abonnement erforderlich';
$lang['station_location_qrz_hint'] = "Finde deinen 'QRZ Logbook API Key' in den <a href='https://logbook.qrz.com/logbook' target='_blank'>QRZ.com Logbuch Einstellungen";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbuch Echtzeit Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbuch Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Benutzername";
$lang['station_location_hrdlog_username_hint'] = "Der Benutzername mit dem du bei HRDlog.net registriert bist (normalerweise dein Rufzeichen).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Worked';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Επιβεβαιωμένο';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = 'Απαιτείται';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Lavorato';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Confermato';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = 'Necessario';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "it-IT";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Pracowane';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Potwierdzone';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = 'Wymagane';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Всего пожтверждено";
$lang['awards_cq_page_title'] = "Дипломы - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Сработано';
$lang['general_word_worked_not_confirmed'] = "Сработано, не подтверждено";
$lang['general_word_not_worked'] = "Не сработано";
$lang['general_word_confirmed'] = 'Подтверждено';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Пожтверждение";
$lang['general_word_needed'] = 'Необходимо';
@@ -237,5 +238,7 @@ $lang['dashboard_logbooks_warning'] = 'У вас нет аппаратного
$lang['hams_at_no_activations_found'] = 'не найдены предстоящие активации. Проверьте позже.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Требуется подписка';
$lang['station_location_qrz_hint'] = "Ваш ключ API находится на <a href='https://logbook.qrz.com/logbook' target='_blank'>странице настроек журнала QRZ.com";
$lang['station_location_qrz_realtime_upload'] = 'Загрузка в журнал QRZ.com в реальном времени';
$lang['station_location_qrz_realtime_upload'] = 'Загрузка в журнал QRZ.com';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_light'] = "Luz/Láser";
$lang['general_word_worked'] = 'Realizados';
$lang['general_word_worked_not_confirmed'] = "Trabajados no confirmados";
$lang['general_word_not_worked'] = "No logrados";
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmed'] = 'Confirmados';
$lang['general_word_confirmation'] = "Confirmación";
$lang['general_word_needed'] = 'Solicitadas';
@@ -237,5 +238,7 @@ $lang['dashboard_logbooks_warning'] = 'No tiene libro de guardias. ¡Haga clic <
$lang['hams_at_no_activations_found'] = 'No hay activaciones próximas. Por favor vuelve a revisar más tarde.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "es-ES";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "QSLMSG por Defecto";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Defina un mensaje por defecto que será añadido y enviado para cada QSO para esta localización de estación.";
$lang['station_location_qrz_subscription'] = 'Requiere Suscripción';
$lang['station_location_qrz_hint'] = "Encuentre su clave API en la <a href='https://logbook.qrz.com/logbook' target='_blank'>página de Configuración de libro de guardia en QRZ.com";
$lang['station_location_qrz_realtime_upload'] = 'Subida en Tiempo Real del Libro de Guardia a QRZ.com';
$lang['station_location_qrz_realtime_upload'] = 'Subida del Libro de Guardia a QRZ.com';
$lang['station_location_hrdlog_username'] = "Nombre de Usuario de HRDLog.net";
$lang['station_location_hrdlog_username_hint'] = "El nombre de usuario con el que se registró en HRDlog.net (usualmente su indicativo).";
$lang['station_location_hrdlog_code'] = "Código API de HRDLog.net";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_colors'] = "Colors";
$lang['general_word_light'] = "Light/Laser";
$lang['general_word_worked'] = 'Körda';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Bekräftade';
@@ -237,6 +238,8 @@ $lang['dashboard_locations_warning'] = 'You have no station locations. Go <a hre
$lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="'. site_url('stationsetup') . '">here</a> to create it!';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -17,6 +17,7 @@ $lang['awards_total_confirmed'] = "Total confirmed";
$lang['awards_cq_page_title'] = "Awards - CQ Magazine WAZ";
$lang['awards_itu_page_title'] = "Awards - ITU Zones";
$lang['awards_show_itu_map'] = "Show ITU Zone Map";
$lang['awards_show_jcc_map'] = "Show JCC Map";
/*
___________________________________________________________________________________________

View File

@@ -67,6 +67,7 @@ $lang['general_word_worked'] = 'Çalışılanlar';
$lang['general_word_worked_not_confirmed'] = "Worked not confirmed";
$lang['general_word_not_worked'] = "Not worked";
$lang['general_word_confirmed'] = 'Onaylanan';
$lang['general_word_not_confirmed'] = "Not Confirmed";
$lang['general_word_confirmation'] = "Confirmation";
$lang['general_word_needed'] = 'İstenenler';
@@ -237,4 +238,5 @@ $lang['dashboard_logbooks_warning'] = 'You have no station logbook. Go <a href="
$lang['hams_at_no_activations_found'] = 'No upcoming activations found. Please check back later.';
$lang['gen_add_to_contest'] = "Add QSOs to Contest";
$lang['general_word_realtime'] = "Realtime";
$lang['datatables_language'] = "en-GB";

View File

@@ -100,7 +100,7 @@ $lang['station_location_eqsl_defaultqslmsg'] = "Default QSLMSG";
$lang['station_location_eqsl_defaultqslmsg_hint'] = "Define a default message that will be populated and sent for each QSO for this station location.";
$lang['station_location_qrz_subscription'] = 'Subscription Required';
$lang['station_location_qrz_hint'] = "Find your API key on <a href='https://logbook.qrz.com/logbook' target='_blank'>the QRZ.com Logbook settings page";
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Realtime Upload';
$lang['station_location_qrz_realtime_upload'] = 'QRZ.com Logbook Upload';
$lang['station_location_hrdlog_username'] = "HRDLog.net Username";
$lang['station_location_hrdlog_username_hint'] = "The username you are registered with at HRDlog.net (usually your callsign).";
$lang['station_location_hrdlog_code'] = "HRDLog.net API Key";

View File

@@ -1,60 +1,56 @@
<?php
class Contesting_model extends CI_Model {
/*
* This function gets the QSOs to fill the "Contest Logbook" under the contesting form.
*/
function getSessionQsos($qso) {
$CI =& get_instance();
$CI->load->model('Stations');
$station_id = $CI->Stations->find_active();
/*
* This function gets the QSOs to fill the "Contest Logbook" under the contesting form.
*/
function getSessionQsos($qso) {
$this->load->model('Stations');
$station_id = $this->Stations->find_active();
$qsoarray = explode(',', $qso);
$qsoarray = explode(',', $qso);
$contestid = $qsoarray[2];
$date = DateTime::createFromFormat('d-m-Y H:i:s', $qsoarray[0]);
if ($date == false) $date = DateTime::createFromFormat('d-m-Y H:i', $qsoarray[0]);
$date = $date->format('Y-m-d H:i:s');
$contestid = $qsoarray[2];
$date = DateTime::createFromFormat('d-m-Y H:i:s', $qsoarray[0]);
if ($date == false) $date = DateTime::createFromFormat('d-m-Y H:i', $qsoarray[0]);
$date = $date->format('Y-m-d H:i:s');
$sql = "SELECT date_format(col_time_on, '%d-%m-%Y %H:%i:%s') as col_time_on, col_call, col_band, col_mode,
col_submode, col_rst_sent, col_rst_rcvd, coalesce(col_srx, '') col_srx, coalesce(col_srx_string, '') col_srx_string,
coalesce(col_stx, '') col_stx, coalesce(col_stx_string, '') col_stx_string, coalesce(col_gridsquare, '') col_gridsquare,
coalesce(col_vucc_grids, '') col_vucc_grids FROM " .
$this->config->item('table_name') .
" WHERE station_id = ? AND COL_TIME_ON >= ? AND COL_CONTEST_ID = ? ORDER BY COL_PRIMARY_KEY ASC";
$sql = "SELECT date_format(col_time_on, '%d-%m-%Y %H:%i:%s') as col_time_on, col_call, col_band, col_mode,
col_submode, col_rst_sent, col_rst_rcvd, coalesce(col_srx, '') col_srx, coalesce(col_srx_string, '') col_srx_string,
coalesce(col_stx, '') col_stx, coalesce(col_stx_string, '') col_stx_string, coalesce(col_gridsquare, '') col_gridsquare,
coalesce(col_vucc_grids, '') col_vucc_grids FROM " .
$this->config->item('table_name') .
" WHERE station_id = ? AND COL_TIME_ON >= ? AND COL_CONTEST_ID = ? ORDER BY COL_PRIMARY_KEY ASC";
$data = $this->db->query($sql,array($station_id, $date, $contestid));
return $data->result();
}
$data = $this->db->query($sql,array($station_id, $date, $contestid));
return $data->result();
}
function getSession() {
$CI =& get_instance();
$CI->load->model('Stations');
$station_id = $CI->Stations->find_active();
$this->load->model('Stations');
$station_id = $this->Stations->find_active();
$sql = "SELECT * from contest_session where station_id = " . $station_id;
$sql = "SELECT * from contest_session where station_id = " . $station_id;
$data = $this->db->query($sql);
return $data->row();
}
$data = $this->db->query($sql);
return $data->row();
}
function deleteSession() {
$CI =& get_instance();
$CI->load->model('Stations');
$station_id = $CI->Stations->find_active();
$this->load->model('Stations');
$station_id = $this->Stations->find_active();
$sql = "delete from contest_session where station_id = " . $station_id;
$sql = "delete from contest_session where station_id = " . $station_id;
$this->db->query($sql);
$this->db->query($sql);
return;
}
}
function setSession() {
$CI =& get_instance();
$CI->load->model('Stations');
$station_id = $CI->Stations->find_active();
$this->load->model('Stations');
$station_id = $this->Stations->find_active();
$qso = "";
@@ -74,9 +70,9 @@ class Contesting_model extends CI_Model {
'station_id' => $station_id,
);
$sql = "SELECT * from contest_session where station_id = " . $station_id;
$sql = "SELECT * from contest_session where station_id = " . $station_id;
$querydata = $this->db->query($sql);
$querydata = $this->db->query($sql);
if ($querydata->num_rows() == 0) {
$this->db->insert('contest_session', $data);
@@ -84,23 +80,23 @@ class Contesting_model extends CI_Model {
}
$result = $querydata->row();
$qsoarray = explode(',', $result->qso);
$qsoarray = explode(',', $result->qso);
if ($qsoarray[1] != "") {
$data['qso'] = $result->qso;
}
$this->updateSession($data, $station_id);
return;
}
}
function updateSession($data, $station_id) {
$this->db->where('station_id', $station_id);
$this->db->update('contest_session', $data);
}
}
function getActivecontests() {
function getActivecontests() {
$sql = "SELECT name, adifname FROM contest WHERE active = 1 ORDER BY name ASC";
@@ -208,15 +204,14 @@ class Contesting_model extends CI_Model {
}
function checkIfWorkedBefore($call, $band, $mode, $contest) {
$CI =& get_instance();
$CI->load->model('Stations');
$station_id = $CI->Stations->find_active();
$this->load->model('Stations');
$station_id = $this->Stations->find_active();
$contest_session = $this->getSession();
if ($contest_session && $contest_session->qso != "") {
$qsoarray = explode(',', $contest_session->qso);
$date = DateTime::createFromFormat('d-m-Y H:i:s', $qsoarray[0]);
if ($date == false) $date = DateTime::createFromFormat('d-m-Y H:i', $qsoarray[0]);
$date = $date->format('Y-m-d H:i:s');
@@ -231,49 +226,48 @@ class Contesting_model extends CI_Model {
$this->db->where("COL_MODE", xss_clean($mode));
$this->db->or_where("COL_SUBMODE", xss_clean($mode));
$this->db->group_end();
$this->db->order_by($this->config->item('table_name').".COL_TIME_ON", "DESC");
$this->db->order_by($this->config->item('table_name').".COL_TIME_ON", "DESC");
$query = $this->db->get($this->config->item('table_name'));
return $query;
}
return;
}
function export_custom($from, $to, $contest_id, $station_id) {
$this->db->select(''.$this->config->item('table_name').'.*, station_profile.*');
$this->db->from($this->config->item('table_name'));
$this->db->where($this->config->item('table_name').'.station_id', $station_id);
$this->db->select(''.$this->config->item('table_name').'.*, station_profile.*');
$this->db->from($this->config->item('table_name'));
$this->db->where($this->config->item('table_name').'.station_id', $station_id);
// If date is set, we format the date and add it to the where-statement
if ($from != 0) {
$from = DateTime::createFromFormat('Y-m-d', $from);
$from = $from->format('Y-m-d');
$this->db->where("date(".$this->config->item('table_name').".COL_TIME_ON) >= '".$from."'");
}
if ($to != 0) {
$to = DateTime::createFromFormat('Y-m-d', $to);
$to = $to->format('Y-m-d');
$this->db->where("date(".$this->config->item('table_name').".COL_TIME_ON) <= '".$to."'");
}
// If date is set, we format the date and add it to the where-statement
if ($from != 0) {
$from = DateTime::createFromFormat('Y-m-d', $from);
$from = $from->format('Y-m-d');
$this->db->where("date(".$this->config->item('table_name').".COL_TIME_ON) >= '".$from."'");
}
if ($to != 0) {
$to = DateTime::createFromFormat('Y-m-d', $to);
$to = $to->format('Y-m-d');
$this->db->where("date(".$this->config->item('table_name').".COL_TIME_ON) <= '".$to."'");
}
$this->db->where($this->config->item('table_name').'.COL_CONTEST_ID', $contest_id);
$this->db->order_by($this->config->item('table_name').".COL_TIME_ON", "ASC");
$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');
$this->db->join('station_profile', 'station_profile.station_id = '.$this->config->item('table_name').'.station_id');
return $this->db->get();
}
return $this->db->get();
}
function get_logged_contests2() {
$CI =& get_instance();
$CI->load->model('Stations');
$station_id = $CI->Stations->find_active();
$this->load->model('Stations');
$station_id = $this->Stations->find_active();
$sql = "select col_contest_id, min(date(col_time_on)) mindate, max(date(col_time_on)) maxdate, year(col_time_on) year, month(col_time_on) month
from " . $this->config->item('table_name') . "
where coalesce(COL_CONTEST_ID, '') <> ''
and station_id =" . $station_id;
from " . $this->config->item('table_name') . "
where coalesce(COL_CONTEST_ID, '') <> ''
and station_id =" . $station_id;
$sql .= " group by COL_CONTEST_ID , year(col_time_on), month(col_time_on) order by year(col_time_on) desc";
@@ -285,9 +279,9 @@ class Contesting_model extends CI_Model {
function get_logged_years($station_id) {
$sql = "select distinct year(col_time_on) year
from " . $this->config->item('table_name') . "
where coalesce(COL_CONTEST_ID, '') <> ''
and station_id =" . $station_id;
from " . $this->config->item('table_name') . "
where coalesce(COL_CONTEST_ID, '') <> ''
and station_id =" . $station_id;
$sql .= " order by year(col_time_on) desc";
@@ -298,27 +292,27 @@ class Contesting_model extends CI_Model {
function get_logged_contests($station_id, $year) {
$sql = "select distinct col_contest_id
from " . $this->config->item('table_name') . "
where coalesce(COL_CONTEST_ID, '') <> ''
and station_id =" . $station_id .
" and year(col_time_on) ='" . $year . "'";
from " . $this->config->item('table_name') . "
where coalesce(COL_CONTEST_ID, '') <> ''
and station_id =" . $station_id .
" and year(col_time_on) ='" . $year . "'";
$sql .= " order by COL_CONTEST_ID asc";
$data = $this->db->query($sql);
return $data->result();
}
return $data->result();
}
function get_contest_dates($station_id, $year, $contestid) {
$sql = "select distinct (date(col_time_on)) date
from " . $this->config->item('table_name') . "
where coalesce(COL_CONTEST_ID, '') <> ''
and station_id =" . $station_id .
" and year(col_time_on) ='" . $year . "' and col_contest_id ='" . $contestid . "'";
from " . $this->config->item('table_name') . "
where coalesce(COL_CONTEST_ID, '') <> ''
and station_id =" . $station_id .
" and year(col_time_on) ='" . $year . "' and col_contest_id ='" . $contestid . "'";
$data = $this->db->query($sql);
return $data->result();
return $data->result();
}
}

View File

@@ -29,6 +29,7 @@ class Dxcluster_model extends CI_Model {
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $dxcache_url);
curl_setopt($ch, CURLOPT_USERAGENT, 'Wavelog '.$this->optionslib->get_option('version').' DXLookup');
curl_setopt($ch, CURLOPT_TIMEOUT, 10);
curl_setopt($ch, CURLOPT_HEADER, false);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$jsonraw = curl_exec($ch);

File diff suppressed because it is too large Load Diff

View File

@@ -1875,7 +1875,7 @@ class Logbook_model extends CI_Model {
* Function returns all the station_id's with QRZ API Key's
*/
function get_station_id_with_qrz_api() {
$sql = 'select station_id, qrzapikey from station_profile
$sql = 'select station_id, qrzapikey, qrzrealtime from station_profile
where coalesce(qrzapikey, "") <> ""';
$query = $this->db->query($sql);
@@ -2085,7 +2085,6 @@ function check_if_callsign_worked_in_logbook($callsign, $StationLocationsArray =
$this->db->limit('2');
$query = $this->db->get($this->config->item('table_name'));
return $query->num_rows();
}
@@ -3184,7 +3183,7 @@ function check_if_callsign_worked_in_logbook($callsign, $StationLocationsArray =
function import_check($datetime, $callsign, $band, $mode, $station_callsign, $station_id = null) {
$mode=$this->get_main_mode_from_mode($mode);
$this->db->select('COL_PRIMARY_KEY, COL_TIME_ON, COL_CALL, COL_BAND');
$this->db->select('COL_PRIMARY_KEY, COL_TIME_ON, COL_CALL, COL_BAND, COL_GRIDSQUARE');
$this->db->where('COL_TIME_ON >= DATE_ADD(DATE_FORMAT("'.$datetime.'", \'%Y-%m-%d %H:%i\' ), INTERVAL -15 MINUTE )');
$this->db->where('COL_TIME_ON <= DATE_ADD(DATE_FORMAT("'.$datetime.'", \'%Y-%m-%d %H:%i\' ), INTERVAL 15 MINUTE )');
$this->db->where('COL_CALL', $callsign);
@@ -3201,9 +3200,9 @@ function check_if_callsign_worked_in_logbook($callsign, $StationLocationsArray =
if ($query->num_rows() > 0)
{
$ret = $query->row();
return ["Found", $ret->COL_PRIMARY_KEY];
return ["Found", $ret->COL_PRIMARY_KEY, $ret->COL_GRIDSQUARE];
} else {
return ["No Match", 0];
return ["No Match", 0, ''];
}
}

View File

@@ -1,3 +1,12 @@
<script>
var tileUrl="<?php echo $this->optionslib->get_option('option_map_tile_server');?>"
</script>
<style>
#jccmap {
height: calc(100vh - 480px) !important;
max-height: 900px !important;
}
</style>
<div class="container">
<!-- Award Info Box -->
<br>
@@ -98,7 +107,10 @@
<div class="col-md-10">
<button id="button2id" type="reset" name="button2id" class="btn btn-sm btn-warning">Reset</button>
<button id="button1id" type="submit" name="button1id" class="btn btn-sm btn-primary">Show</button>
<?php if ($jcc_array) {?>
<button type="button" onclick="load_jcc_map();" class="btn btn-info btn-sm"><i class="fas fa-globe-asia"></i> <?php echo lang('awards_show_jcc_map'); ?></button>
<button id="button3id" type="button" onclick="export_qsos();" name="button3id" class="btn btn-sm btn-info">Export</button>
<?php } ?>
</div>
</div>
@@ -109,10 +121,17 @@
<li class="nav-item">
<a class="nav-link active" id="table-tab" data-bs-toggle="tab" href="#table" role="tab" aria-controls="table" aria-selected="true">Results</a>
</li>
<li class="nav-item">
<a class="nav-link" onclick="load_jcc_map();" id="map-tab" data-bs-toggle="tab" href="#jccmaptab" role="tab" aria-controls="home" aria-selected="false"><?php echo lang('filter_map'); ?></a>
</li>
</ul>
<br />
<div class="tab-content" id="myTabContent">
<div class="tab-pane fade" id="jccmaptab" role="tabpanel" aria-labelledby="home-tab">
<br />
<div id="jccmap" class="map-leaflet" ></div>
</div>

View File

@@ -66,9 +66,16 @@
} ?>><?php echo $row->radio; ?></option>
<?php } ?>
</select>
<label class="my-1 me-2" for="cwnSelect">DXCC-Status</label>
<select class="form-select form-select-sm my-1 me-sm-2 w-auto" id="cwnSelect" name="dxcluster_cwn" aria-describedby="dxcluster_cwnHelp" required>
<option value="All"><?php echo lang('general_word_all'); ?></option>
<option value="wkd"><?php echo lang('general_word_worked'); ?></option>
<option value="cnf"><?php echo lang('general_word_confirmed'); ?></option>
<option value="ucnf"><?php echo lang('general_word_not_confirmed'); ?></option>
</select>
<label class="my-1 me-2" for="decontSelect">Spots de</label>
<select class="form-select form-select-sm my-1 me-sm-2 w-auto" id="decontSelect" name="dxcluster_decont" aria-describedby="dxcluster_decontHelp" required>
<option value="Any">*</option>
<option value="Any"><?php echo lang('general_word_all'); ?></option>
<option value="AF" <?php if ($this->optionslib->get_option('dxcluster_decont') == 'AF') {echo " selected";} ?>>Africa</option>
<option value="AN" <?php if ($this->optionslib->get_option('dxcluster_decont') == 'AN') {echo " selected";} ?>>Antarctica</option>
<option value="AS" <?php if ($this->optionslib->get_option('dxcluster_decont') == 'AS') {echo " selected";} ?>>Asia</option>
@@ -114,4 +121,4 @@
</div>
</div>
</div>
</div>

View File

@@ -227,14 +227,19 @@
<div class="row">
<div class="mb-3 col-sm-6">
<label for="qrzApiKey">QRZ.com Logbook API Key</label> <!-- This does not need Multilanguage Support -->
<input type="text" class="form-control" name="qrzapikey" pattern="^([A-F0-9]{4}-){3}[A-F0-9]{4}$" id="qrzApiKey" aria-describedby="qrzApiKeyHelp">
<div class="input-group">
<input type="text" class="form-control" name="qrzapikey" pattern="^([A-F0-9]{4}-){3}[A-F0-9]{4}$" id="qrzApiKey" aria-describedby="qrzApiKeyHelp">
<button class="btn btn-secondary" type="button" id="qrz_apitest_btn">Test API-Key</button>
</div>
<div class="alert mt-3" style="display: none;" id="qrz_apitest_msg"></div>
<small id="qrzApiKeyHelp" class="form-text text-muted"><?php echo lang("station_location_qrz_hint"); ?></a></small>
</div>
<div class="mb-3 col-sm-6">
<label for="qrzrealtime"><?php echo lang("station_location_qrz_realtime_upload"); ?></label>
<select class="form-select" id="qrzrealtime" name="qrzrealtime">
<option value="1"><?php echo lang("general_word_yes"); ?></option>
<option value="0" selected><?php echo lang("general_word_no"); ?></option>
<option value="-1" selected><?php echo lang("general_word_disabled"); ?></option>
<option value="1"><?php echo lang("general_word_realtime"); ?></option>
<option value="0"><?php echo lang("general_word_enabled"); ?></option>
</select>
</div>
</div>

View File

@@ -298,15 +298,20 @@
<div class="card-body">
<div class="mb-3">
<label for="qrzApiKey">QRZ.com Logbook API Key</label> <!-- This does not need Multilanguage Support -->
<input type="text" class="form-control" name="qrzapikey" pattern="^([A-F0-9]{4}-){3}[A-F0-9]{4}$" id="qrzApiKey" aria-describedby="qrzApiKeyHelp" value="<?php if(set_value('qrzapikey') != "") { echo set_value('qrzapikey'); } else { echo $my_station_profile->qrzapikey; } ?>">
<div class="input-group">
<input type="text" class="form-control" name="qrzapikey" pattern="^([A-F0-9]{4}-){3}[A-F0-9]{4}$" id="qrzApiKey" aria-describedby="qrzApiKeyHelp" value="<?php if(set_value('qrzapikey') != "") { echo set_value('qrzapikey'); } else { echo $my_station_profile->qrzapikey; } ?>">
<button class="btn btn-secondary" type="button" id="qrz_apitest_btn">Test API-Key</button>
</div>
<div class="alert mt-3" style="display: none;" id="qrz_apitest_msg"></div>
<small id="qrzApiKeyHelp" class="form-text text-muted"><?php echo lang("station_location_qrz_hint"); ?></a></small>
</div>
<div class="mb-3">
<label for="qrzrealtime"><?php echo lang("station_location_qrz_realtime_upload"); ?></label>
<select class="form-select" id="qrzrealtime" name="qrzrealtime">
<option value="1" <?php if ($my_station_profile->qrzrealtime == 1) { echo " selected =\"selected\""; } ?>><?php echo lang("general_word_yes"); ?></option>
<option value="0" <?php if ($my_station_profile->qrzrealtime == 0) { echo " selected =\"selected\""; } ?>><?php echo lang("general_word_no"); ?></option>
<option value="-1" <?php if ($my_station_profile->qrzrealtime == -1) { echo " selected =\"selected\""; } ?>><?php echo lang("general_word_disabled"); ?></option>
<option value="1" <?php if ($my_station_profile->qrzrealtime == 1) { echo " selected =\"selected\""; } ?>><?php echo lang("general_word_realtime"); ?></option>
<option value="0" <?php if ($my_station_profile->qrzrealtime == 0) { echo " selected =\"selected\""; } ?>><?php echo lang("general_word_enabled"); ?></option>
</select>
</div>
</div>

View File

@@ -35,7 +35,7 @@ $(function() {
return table;
}
function fill_list(band,de,maxAgeMinutes) {
function fill_list(band,de,maxAgeMinutes,cwn) {
// var table = $('.spottable').DataTable();
var table = get_dtable();
if ((band != '') && (band !== undefined)) {
@@ -48,9 +48,14 @@ $(function() {
table.page.len(50);
let oldtable=table.data();
table.clear();
let spots2render=0;
if (dxspots.length>0) {
dxspots.sort(SortByQrg);
dxspots.forEach((single) => {
if ((cwn == 'wkd') && (!(single.worked_dxcc))) { return; }
if ((cwn == 'cnf') && (!(single.cnfmd_dxcc))) { return; }
if ((cwn == 'ucnf') && ((single.cnfmd_dxcc))) { return; }
spots2render++;
var data=[];
if (single.cnfmd_dxcc) {
dxcc_wked_info="text-success";
@@ -117,6 +122,10 @@ $(function() {
table.clear();
table.draw();
}
if (spots2render == 0) {
table.clear();
table.draw();
}
});
} else {
table.clear();
@@ -145,17 +154,22 @@ $(function() {
var table=get_dtable();
table.order([1, 'asc']);
table.clear();
fill_list($('#band option:selected').val(), $('#decontSelect option:selected').val(),dxcluster_maxage);
setInterval(function () { fill_list($('#band option:selected').val(), $('#decontSelect option:selected').val(),dxcluster_maxage); },60000);
fill_list($('#band option:selected').val(), $('#decontSelect option:selected').val(),dxcluster_maxage,$('#cwnSelect option:selected').val());
setInterval(function () { fill_list($('#band option:selected').val(), $('#decontSelect option:selected').val(),dxcluster_maxage,$('#cwnSelect option:selected').val()); },60000);
$("#cwnSelect").on("change",function() {
table.clear();
fill_list($('#band option:selected').val(), $('#decontSelect option:selected').val(),dxcluster_maxage,$('#cwnSelect option:selected').val());
});
$("#decontSelect").on("change",function() {
table.clear();
fill_list($('#band option:selected').val(), $('#decontSelect option:selected').val(),dxcluster_maxage);
fill_list($('#band option:selected').val(), $('#decontSelect option:selected').val(),dxcluster_maxage,$('#cwnSelect option:selected').val());
});
$("#band").on("change",function() {
table.clear();
fill_list($('#band option:selected').val(), $('#decontSelect option:selected').val(),dxcluster_maxage);
fill_list($('#band option:selected').val(), $('#decontSelect option:selected').val(),dxcluster_maxage,$('#cwnSelect option:selected').val());
});
$("#spottertoggle").on("click", function() {

View File

@@ -252,6 +252,42 @@ function qso_edit(id) {
}
});
$('#vucc_grids').change(function(){
if ($(this).val().length >= 9) {
$.ajax({
url: base_url + 'index.php/logbook/searchbearing',
type: 'post',
data: {
grid: $(this).val(),
stationProfile: $('#stationProfile').val()
},
success: function(data) {
$('#locator_info').html(data).fadeIn("slow");
},
error: function() {
$('#locator_info').text("Error loading bearing!").fadeIn("slow");
},
});
$.ajax({
url: base_url + 'index.php/logbook/searchdistance',
type: 'post',
data: {
grid: $(this).val(),
stationProfile: $('#stationProfile').val()
},
success: function(data) {
document.getElementById("distance").value = data;
},
error: function() {
document.getElementById("distance").value = null;
},
});
} else if ($(this).val().length == 0) {
$('#locator_info').fadeOut("slow");
document.getElementById("distance").value = null;
}
});
$('#sota_ref_edit').selectize({
maxItems: 1,
closeAfterSelect: true,

View File

@@ -53,13 +53,13 @@ async function reset_contest_session() {
"columnDefs": [
{
"render": function ( data, type, row ) {
return pad(row[8],3);
return row[8] !== null && row[8] !== '' ? pad(row[8], 3) : '';
},
"targets" : 8
},
{
"render": function ( data, type, row ) {
return pad(row[9],3);
return row[9] !== null && row[9] !== '' ? pad(row[9], 3) : '';
},
"targets" : 9
}
@@ -94,10 +94,9 @@ async function setSession(formdata) {
processData: false,
contentType: false,
success: function (data) {
sessiondata=data;
}
});
sessiondata=await getSession(); // refresh Sessiondata
}
// realtime clock
@@ -166,7 +165,6 @@ document.onkeyup = function (e) {
reset_log_fields();
// Space to jump to either callsign or the various exchanges
} else if (e.which == 32) {
getCallbook();
var exchangetype = $("#exchangetype").val();
if (manual && $(document.activeElement).attr("id") == "start_time") {
@@ -378,10 +376,12 @@ if ($('#frequency').val() == "") {
/* on mode change */
$('#mode').change(function () {
if ($('#radio').val() == '0') {
$.get('qso/band_to_freq/' + $('#band').val() + '/' + $('.mode').val(), function (result) {
$('#frequency').val(result);
$('#frequency_rx').val("");
});
}
setRst($("#mode").val());
checkIfWorkedBefore();
});
@@ -389,10 +389,12 @@ $('#mode').change(function () {
/* Calculate Frequency */
/* on band change */
$('#band').change(function () {
if ($('#radio').val() == '0') {
$.get('qso/band_to_freq/' + $(this).val() + '/' + $('.mode').val(), function (result) {
$('#frequency').val(result);
$('#frequency_rx').val("");
});
}
checkIfWorkedBefore();
});
@@ -474,6 +476,7 @@ function logQso() {
if ($("#callsign").val().length > 0) {
$('.callsign-suggestions').text("");
$('#callsign_info').text("");
var table = $('.qsotable').DataTable();
var exchangetype = $("#exchangetype").val();
@@ -621,13 +624,13 @@ async function refresh_qso_table(data) {
"columnDefs": [
{
"render": function ( data, type, row ) {
return pad(row[8],3);
return row[8] !== null && row[8] !== '' ? pad(row[8], 3) : '';
},
"targets" : 8
},
{
"render": function ( data, type, row ) {
return pad(row[9],3);
return row[9] !== null && row[9] !== '' ? pad(row[9], 3) : '';
},
"targets" : 9
}
@@ -638,34 +641,33 @@ async function refresh_qso_table(data) {
table.clear();
var mode = '';
var data;
$.each(html, function () {
if (this.col_submode == null || this.col_submode == '') {
mode = this.col_mode;
} else {
mode = this.col_submode;
}
var data = [];
$.each(html, function () {
if (this.col_submode == null || this.col_submode == '') {
mode = this.col_mode;
} else {
mode = this.col_submode;
}
data = [[
this.col_time_on,
this.col_call,
this.col_band,
mode,
this.col_rst_sent,
this.col_rst_rcvd,
this.col_stx_string,
this.col_srx_string,
this.col_stx,
this.col_srx,
this.col_gridsquare,
this.col_vucc_grids
]];
data.push([
this.col_time_on,
this.col_call,
this.col_band,
mode,
this.col_rst_sent,
this.col_rst_rcvd,
this.col_stx_string,
this.col_srx_string,
this.col_stx,
this.col_srx,
this.col_gridsquare,
this.col_vucc_grids
]);
});
if (data.length > 0) {
table.rows.add(data).draw();
}
});
if (data.length > 0) {
table.rows.add(data).draw();
}
}
});

View File

@@ -0,0 +1,166 @@
var osmUrl = tileUrl;
function load_jcc_map() {
$('.nav-tabs a[href="#jccmaptab"]').tab('show');
$.ajax({
url: base_url + 'index.php/awards/jcc_map',
type: 'post',
data: {
band: $('#band2').val(),
mode: $('#mode').val(),
worked: +$('#worked').prop('checked'),
confirmed: +$('#confirmed').prop('checked'),
notworked: +$('#notworked').prop('checked'),
qsl: +$('#qsl').prop('checked'),
lotw: +$('#lotw').prop('checked'),
qrz: +$('#qrz').prop('checked'),
eqsl: +$('#eqsl').prop('checked'),
},
success: function(data) {
load_jcc_map2(data, worked, confirmed, notworked);
},
error: function() {
},
});
}
function load_jcc_map2(data, worked, confirmed, notworked) {
// If map is already initialized
var container = L.DomUtil.get('jccmap');
if(container != null){
container._leaflet_id = null;
container.remove();
$("#jccmaptab").append('<div id="jccmap" class="map-leaflet" ></div>');
}
var map = new L.Map('jccmap', {
fullscreenControl: true,
fullscreenControlOptions: {
position: 'topleft'
},
});
L.tileLayer(
osmUrl,
{
attribution: '&copy; <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, <a href="http://creativecommons.org/licenses/by-sa/2.0/">CC-BY-SA</a>',
maxZoom: 18
}
).addTo(map);
var notworkedcount = 0;
var confirmedcount = 0;
var workednotconfirmedcount = 0;
var jccstuff = {};
$.ajax({
dataType: "json",
url: base_url + 'index.php/awards/jcc_cities',
async: false,
success: function(result) {
for (var item in result) {
var name = item.toString();
jccstuff[name] = [result[item]['name'], result[item]['lat'], result[item]['lon']];
}
}
});
for (const [key, value] of Object.entries(jccstuff)) {
var D = [];
if (key in data) {
if (confirmed.checked == true) {
if (data[key][1] == 1) {
mapColor = 'green';
D['prefix'] = key;
D['name'] = value[0];
D['lat'] = value[1];
D['long'] = value[2];
addMarker(L, D, mapColor, map);
confirmedcount++;
continue;
}
}
if (worked.checked == true) {
mapColor = 'orange';
D['prefix'] = key;
D['name'] = value[0];
D['lat'] = value[1];
D['long'] = value[2];
addMarker(L, D, mapColor, map);
workednotconfirmedcount++;
}
} else {
if (notworked.checked == true) {
mapColor = 'red';
D['prefix'] = key;
D['name'] = value[0];
D['lat'] = value[1];
D['long'] = value[2];
addMarker(L, D, mapColor, map);
notworkedcount++;
}
}
};
/*Legend specific*/
var legend = L.control({ position: "topright" });
legend.onAdd = function(map) {
var div = L.DomUtil.create("div", "legend");
div.innerHTML += "<h4>Colors</h4>";
div.innerHTML += '<i style="background: green"></i><span>Confirmed ('+confirmedcount+')</span><br>';
div.innerHTML += '<i style="background: orange"></i><span>Worked not confirmed ('+workednotconfirmedcount+')</span><br>';
div.innerHTML += '<i style="background: red"></i><span>Not worked ('+notworkedcount+')</span><br>';
return div;
};
legend.addTo(map);
map.setView([37.460, 139.452], 5);
}
function addMarker(L, D, mapColor, map) {
var title = '<span><font style="color: ' +mapColor+ '; text-shadow: 1px 0 #fff, -1px 0 #fff, 0 1px #fff, 0 -1px #fff, 1px 1px #fff, -1px -1px #fff, 1px -1px #fff, -1px 1px #fff;font-size: 14px; font-weight: 900;">' + D['prefix'] + '</font></span>';
var myIcon = L.divIcon({className: 'my-div-icon', html: title});
const markerHtmlStyles = `
background-color: ${mapColor};
width: 1rem;
height: 1rem;
display: block;
position: relative;
border-radius: 3rem 3rem 0;
transform: rotate(45deg);
border: 1px solid #FFFFFF`
const icon = L.divIcon({
className: "my-custom-pin",
iconAnchor: [0, 24],
labelAnchor: [-6, 0],
popupAnchor: [0, -36],
html: `<span style="${markerHtmlStyles}" />`
})
L.marker(
[D['lat'], D['long']], {
icon: myIcon,
prefix: D['prefix'],
title: D['prefix'] + ' - ' + D['name'],
}
).addTo(map).on('click', onClick);
L.marker(
[D['lat'], D['long']], {
icon: icon,
prefix: D['prefix'],
title: D['prefix'] + ' - ' + D['name'],
}
).addTo(map).on('click', onClick);
}
function onClick(e) {
var marker = e.target;
displayContactsOnMap($("#jccmap"),marker.options.prefix, $('#band2').val(), 'All', 'All', $('#mode').val(), 'JCC');
}

View File

@@ -12,6 +12,41 @@ $(document).ready(function () {
$("#dxcc_id").change(function () {
updateStateDropdown('#dxcc_id', '#stateInputLabel', '#location_us_county', '#stationCntyInputEdit');
});
$('#qrz_apitest_btn').click(function(){
var apikey = $('#qrzApiKey').val();
var msg_div = $('#qrz_apitest_msg');
msg_div.hide();
msg_div.removeClass('alert-success alert-danger')
$.ajax({
url: base_url+'index.php/qrz/qrz_apitest',
type: 'POST',
data: {
'APIKEY': apikey
},
success: function(res) {
if(res.status == 'OK') {
msg_div.addClass('alert-success');
msg_div.text('Your API Key works. You are good to go!');
msg_div.show();
} else {
msg_div.addClass('alert-danger');
msg_div.text('Your API Key failed. Are you sure you have a valid QRZ subsription?');
msg_div.show();
$('#qrzrealtime').val(-1);
}
},
error: function(res) {
msg_div.addClass('alert-danger');
msg_div.text('ERROR: Something went wrong on serverside. We\'re sorry..');
msg_div.show();
},
});
});
}
});