McGansWebsite/admin/application/models/Department_model.php
dotwingssoftware e71c4c7872 20230111
20230111
2023-01-11 12:47:57 +05:30

32 lines
638 B
PHP

<?php
if (!defined('BASEPATH'))
exit('No direct script access allowed');
class Department_model extends CI_Model {
public function __construct() {
parent::__construct();
}
function dep_list()
{
$this->db->select('*');
$this->db->from('department');
$this->db->where(array('status'=>1));
$query = $this->db->get();
//echo $this->db->last_query();exit;
return $query;
}
function get_dep($id)
{
$this->db->select('*');
$this->db->from('department');
$this->db->where(array('status'=>1,'id'=>$id));
$query = $this->db->get();
//echo $this->db->last_query();exit;
return $query;
}
}