recon/application/models/Admin_model.php
2023-04-17 10:43:50 +05:30

30 lines
768 B
PHP

<?php
class Admin_model extends CI_Model {
function __construct() {
parent::__construct();
}
function get_user($con = null){
if($con)
$this->db->where($con);
return $this->db->get('users');
}
function get_corp($con=null,$c_id = null,$is_active = null){
if($c_id)
$con['c_id'] = $c_id;
if($is_active)
$con['c_isactive'] = 1;
return $this->db->get_where('corporates',$con);
}
function get_airline($con=null,$a_id = null,$is_active = null){
if($a_id)
$con['a_id'] = $a_id;
if($is_active)
$con['is_active'] = 1;
return $this->db->get_where('airline_gstin',$con);
}
}