kopia lustrzana https://github.com/magicbug/Cloudlog
[API] Fixes issue where nullable vars was first
rodzic
9f94f99f46
commit
d02375fba6
|
@ -524,7 +524,7 @@ class API extends CI_Controller {
|
|||
// Search Logbook for callsign
|
||||
$this->load->model('logbook_model');
|
||||
|
||||
$result = $this->logbook_model->check_if_callsign_worked_in_logbook($logbooks_locations_array, $callsign, $band);
|
||||
$result = $this->logbook_model->check_if_callsign_worked_in_logbook($callsign, $logbooks_locations_array, $band);
|
||||
|
||||
http_response_code(201);
|
||||
if($result > 0)
|
||||
|
@ -597,7 +597,7 @@ class API extends CI_Controller {
|
|||
// Search Logbook for callsign
|
||||
$this->load->model('logbook_model');
|
||||
|
||||
$result = $this->logbook_model->check_if_grid_worked_in_logbook($logbooks_locations_array, $grid, $band);
|
||||
$result = $this->logbook_model->check_if_grid_worked_in_logbook($grid, $logbooks_locations_array, $band);
|
||||
|
||||
http_response_code(201);
|
||||
if($result > 0)
|
||||
|
|
|
@ -1389,7 +1389,7 @@ class Logbook_model extends CI_Model {
|
|||
|
||||
}
|
||||
|
||||
function check_if_callsign_worked_in_logbook($StationLocationsArray = null, $callsign, $band = null) {
|
||||
function check_if_callsign_worked_in_logbook($callsign, $StationLocationsArray = null, $band = null) {
|
||||
|
||||
if($StationLocationsArray == null) {
|
||||
$CI =& get_instance();
|
||||
|
@ -1409,14 +1409,14 @@ class Logbook_model extends CI_Model {
|
|||
// Where col_sat_name is not empty
|
||||
$this->db->where('COL_SAT_NAME !=', '');
|
||||
}
|
||||
|
||||
$this->db->limit('2');
|
||||
$query = $this->db->get($this->config->item('table_name'));
|
||||
|
||||
return $query->num_rows();
|
||||
|
||||
}
|
||||
|
||||
function check_if_grid_worked_in_logbook($StationLocationsArray = null, $grid, $band = null) {
|
||||
function check_if_grid_worked_in_logbook($grid, $StationLocationsArray = null, $band = null) {
|
||||
|
||||
if($StationLocationsArray == null) {
|
||||
$CI =& get_instance();
|
||||
|
@ -1436,6 +1436,7 @@ class Logbook_model extends CI_Model {
|
|||
// Where col_sat_name is not empty
|
||||
$this->db->where('COL_SAT_NAME !=', '');
|
||||
}
|
||||
$this->db->limit('2');
|
||||
|
||||
$query = $this->db->get($this->config->item('table_name'));
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue