pull/3018/head
Peter Goodhall 2024-03-18 14:25:30 +00:00
rodzic 237f679674
commit 6dde203bf5
2 zmienionych plików z 14 dodań i 8 usunięć

Wyświetl plik

@ -5,13 +5,17 @@ class Qsl_model extends CI_Model {
$CI->load->model('logbooks_model');
$logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook'));
$this->db->select('*');
$this->db->from($this->config->item('table_name'));
$this->db->join('qsl_images', 'qsl_images.qsoid = ' . $this->config->item('table_name') . '.col_primary_key');
$this->db->where_in('station_id', $logbooks_locations_array);
$this->db->order_by("id", "desc");
return $this->db->get();
if (is_array($logbooks_locations_array) && !empty($logbooks_locations_array)) {
$this->db->select('*');
$this->db->from($this->config->item('table_name'));
$this->db->join('qsl_images', 'qsl_images.qsoid = ' . $this->config->item('table_name') . '.col_primary_key');
$this->db->where_in('station_id', $logbooks_locations_array);
$this->db->order_by("id", "desc");
return $this->db->get();
} else {
return false;
}
}
function getQslForQsoId($id) {

Wyświetl plik

@ -18,7 +18,7 @@
$custom_date_format = $this->config->item('qso_date_format');
}
if (is_array($qslarray->result())) {
if ($qslarray !== FALSE && is_array($qslarray->result())) {
echo '<table style="width:100%" class="qsltable table table-sm table-bordered table-hover table-striped table-condensed">
<thead>
<tr>
@ -57,6 +57,8 @@
}
echo '</tbody></table>';
} else {
echo '<div class="alert alert-warning" role="alert">No QSL Cards Found.</div>';
}
?>