McGansWebsite/admin/application/models/Faculty_model.php
dotwingssoftware 6515996f87 20230121
Role, Employee, Department, Degree, Semester, Subject, Faculty Edit Completed
2023-01-21 19:11:47 +05:30

42 lines
853 B
PHP

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