kopia lustrzana https://github.com/magicbug/Cloudlog
[Welcome] Might fix bug
rodzic
1ff1e541f6
commit
c08257beaa
|
@ -31,7 +31,6 @@ class Welcome extends CI_Controller {
|
|||
$this->load->model('note');
|
||||
$data['NumberOfNotes'] = $this->note->CountAllNotes();
|
||||
|
||||
|
||||
if($data['CountAllStationLocations'] == 0 || $data['NumberOfStationLogbooks'] == 0 || $data['NumberOfAPIKeys'] > 0 || $data['NumberOfNotes'] > 0) {
|
||||
// load views
|
||||
$this->load->view('interface_assets/mini_header', $data);
|
||||
|
|
|
@ -9,7 +9,9 @@ class Logbooks_model extends CI_Model {
|
|||
|
||||
function CountAllStationLogbooks() {
|
||||
// count all logbooks
|
||||
return $this->db->count_all('station_logbooks');
|
||||
$this->db->where('user_id !=', NULL);
|
||||
$query = $this->db->get('station_logbooks');
|
||||
return $query->num_rows();
|
||||
}
|
||||
|
||||
function add() {
|
||||
|
|
|
@ -157,10 +157,9 @@ class Stations extends CI_Model {
|
|||
}
|
||||
|
||||
function CountAllStationLocations() {
|
||||
// count all logbooks
|
||||
// where user_id is not NULL
|
||||
$this->db->where('user_id !=', NULL);
|
||||
return $this->db->count_all('station_logbooks');
|
||||
$query = $this->db->get('station_profile');
|
||||
return $query->num_rows();
|
||||
}
|
||||
|
||||
function set_active($current, $new) {
|
||||
|
|
Ładowanie…
Reference in New Issue