File: //home/cafsindia/hrms_allyindian_com/application_bk/controllers/Profile.php
<?php if ( ! defined('BASEPATH')) exit('No direct script is allowed');
require_once("Action_controller.php");
class Profile extends Action_controller{
public function __construct(){
parent::__construct('profile');
}
// LOAD PAGE QUICK LINK,FILTERS AND TABLE HEADERS
public function index(){
//query for offer_letter and profile picture for profile page
$company_query = 'SELECT display_appointment,hr_policy,display_offer FROM cw_company_information';
$company_info = $this->db->query("CALL sp_a_run ('SELECT','$company_query')");
$data['company_result'] = $company_info->result();
$company_info->next_result();
// Profile photo from employee master
$profile_query = 'SELECT profile_picture FROM cw_employees';
$profile_info = $this->db->query("CALL sp_a_run ('SELECT','$profile_query')");
$data['profile_result'] = $profile_info->result();
$profile_info->next_result();
// Other Policy Details
$policy_query = 'SELECT policy_title,policy_doc FROM cw_company_information_company_policies WHERE trans_status = 1';
$policy_info = $this->db->query("CALL sp_a_run ('SELECT','$policy_query')");
$data['policy_result'] = $policy_info->result();
$policy_info->next_result();
$this->load->view("$this->control_name/manage",$data);
}
}
?>