本文整理汇总了PHP中CI_Controller::setHeader方法的典型用法代码示例。如果您正苦于以下问题:PHP CI_Controller::setHeader方法的具体用法?PHP CI_Controller::setHeader怎么用?PHP CI_Controller::setHeader使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CI_Controller
的用法示例。
在下文中一共展示了CI_Controller::setHeader方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: showTime
public function showTime($empID, $from = "hrworktime")
{
$userID = getUserIDByEmpID($empID);
$this->load->model("WorkTime_Model", "worktime");
$this->load->model("Common_Model", "common");
$data = array();
$data["topic"] = "ตรวจสอบเวลา เข้า-ออก";
$data["returner"] = $from == "hrworktime" ? site_url("hr/Employee") : "";
$data["beforeEmpID"] = 'ของ ';
$data["empID"] = $empID;
$data["ddlMonth"] = $this->common->getMonth1To12();
$data["ddlYear"] = $this->common->getYearForDropDown();
$data["vddlMonth"] = 0;
$data["vddlYear"] = 0;
if ($_POST) {
$data["vddlMonth"] = $this->input->post("ddlMonth");
$data["vddlYear"] = $this->input->post("ddlYear");
}
$config = array();
$config["total_rows"] = $this->worktime->countAll($userID);
$this->pagination->initialize($config);
$page = $this->uri->segment(3) ? $this->uri->segment(3) : 0;
$data["query"] = $this->worktime->getList($userID, $this->pagination->per_page, $page, $data["vddlYear"], $data["vddlMonth"]);
$data["linksPaging"] = $this->pagination->create_links();
if ($data["returner"] != "") {
parent::setHeader("ตรวจสอบเวลา เข้า-ออก " . $empID);
} else {
parent::setHeader("ตรวจสอบเวลา เข้า-ออก");
}
$this->load->view("hr/Employee/WorkTime.php", $data);
parent::setFooter();
}
示例2: search_old
public function search_old()
{
$empID = "";
$userID = 0;
//ส่ง userid = 0 คือคนที่ไม่มีหัวหน้าให้ส่งเรื่องโดยตรงถึง HR ได้เลย
if ($_POST) {
$empID = $this->input->post("txtEmpID");
if ($empID != "") {
$userID = getUserIDByEmpID($empID);
if ($userID == 0) {
swalc('ไม่พบรหัสพนักงานนี้', '', 'error');
$userID = -1;
}
}
}
$searchKeyword = "";
$searchType = "";
$config = array();
$config["total_rows"] = $this->leave->hr_count_all($userID, $searchType, $searchKeyword);
$this->pagination->initialize($config);
$page = $this->uri->segment(4) ? $this->uri->segment(4) : 0;
$data = array();
$query = $this->leave->getListForVerify($userID, $this->pagination->per_page, $page, $searchType, $searchKeyword);
$data["query"] = $query;
$data["empID"] = $empID;
parent::setHeader("ตรวจสอบใบลา");
$this->load->view("hr/Leave/verifylist", $data);
parent::setFooter();
}
示例3: search
public function search($emp_id = "0", $year = 0, $month = 0)
{
$user_id = 0;
if ($emp_id !== "0") {
$emp_detail = getEmployeeDetail($emp_id);
$user_id = $emp_detail["UserID"];
}
//pagination
$config = array();
$config['total_rows'] = $this->otpaylog->headman_count_all($this->user_id, $user_id, $year, $month);
$this->pagination->initialize($config);
$page = $this->uri->segment(7) ? $this->uri->segment(7) : 0;
//get data
$query = $this->otpaylog->headman_get_list($this->pagination->per_page, $page, $this->user_id, $user_id, $year, $month);
//set data
$data = array();
$data["query"] = $query->result_array();
$data["ddlTeam"] = get_team_for_dropdownlist($this->user_id);
$data["value_team"] = $emp_id;
$data["ddlMonth"] = $this->common->getMonth1To12("thai");
$data["value_month"] = $month;
$data["ddlYear"] = $this->common->getYearForDropDown("thai");
$data["value_year"] = $year;
//load view
parent::setHeader("รายงานการทำงานล่วงเวลาผู้ใต้บังคับบัญชา", "OT");
$this->load->view("headman/Ot/report_list.php", $data);
parent::setFooter();
}
示例4: show
public function show()
{
$data = array();
$data["topicPage"] = "";
parent::setHeader("รายงานการลา", "Report");
$this->load->view("report/leave", $data);
parent::setFooter();
}
示例5: show
public function show()
{
$data = array();
$data["chartData"] = $this->makeChartList(0);
$data["topicPage"] = "แผนผังองค์กร";
parent::setHeader($data["topicPage"]);
$this->load->view("company/Organization", $data);
parent::setFooter();
}
示例6: detail
public function detail($reqID)
{
$query = $this->requestemp->getDetail($reqID);
$data = array();
$data["query"] = $query;
$data["reqID"] = $reqID;
parent::setHeader("รายละเอียดคำร้องขอเพิ่มบุคคลากร");
$this->load->view("headman/Request/Employeedetail", $data);
parent::setFooter();
}
示例7: search
public function search($keyword = "")
{
$keyword = urldecode($keyword);
$data = array();
$data["query"] = $this->empheadman->get_team_list_by_headman_user_id($this->user_id, $keyword);
$data["value_keyword"] = $keyword;
parent::setHeader("รายชื่อทีมของคุณ", "Headman");
$this->load->view("headman/Yourteam", $data);
parent::setFooter();
}
示例8: history
public function history($year = 0)
{
if ($year == 0) {
$year = date("Y");
}
$config = array('user_id' => $this->user_id, 'year' => $year);
$empsal = new Employeesalary($config);
$data = array('history' => $empsal->history_salary(), 'year' => $year);
parent::setHeader("ประวัติการจ่ายเงินเดือน", "Salary");
$this->load->view("Userprofile/Usersalaryhistory", $data);
parent::setFooter();
}
示例9: defaults
public function defaults()
{
$this->load->model("News_model");
$this->load->model("Employees_model");
# 3 = ข่าวด่วน
$query = $this->News_model->get_list(4, 0, 3);
# limit 4,0
$query_new_emp = $this->Employees_model->get_latest_new_employee();
$data["query_news_alert"] = $query->result_array();
$data["query_new_emp"] = $query_new_emp->result_array();
parent::setHeader("", "", FALSE);
$this->load->view("home", $data);
parent::setFooter();
}
示例10: show
public function show()
{
$data = array();
$data["content"] = "";
$query = $this->configuration->getDetailByNameEnglish("Regulations");
if ($query->num_rows() > 0) {
$query = $query->result_array();
$query = $query[0];
$data["content"] = $query["CFDesc"];
}
parent::setHeader("กฎเกณฑ์-ข้อบังคับ");
$this->load->view("hr/Regulation", $data);
parent::setFooter();
}
示例11: show
public function show()
{
$this->load->model("Holiday_model");
$year = $date("Y");
$topicPage = $this->lang->line("title_page_holiday");
$titleMenuCompany = $this->lang->line("title_menu_company");
$query = $this->Holiday_model->getList($year);
$query = $query->result_array();
$data = array();
$data["ajaxUrl"] = "Holiday/feed";
$data["topicPage"] = $topicPage;
$data["query"] = $query;
parent::setHeader($topicPage, $titleMenuCompany);
$this->load->view("company/Holiday", $data);
parent::setFooter();
}
示例12: add
public function add()
{
if ($_POST) {
$this->_save();
exit;
}
$query = $this->headman->get_team_list_by_headman_user_id($this->user_id);
$query = $query->result_array();
$data = array();
$data["form_url"] = site_url("headman/Sendotinsteadteam/save");
$data["dropdown_team"] = $this->convert_array_to_dropdown($query, "UserID", "EmpFullnameThai");
$data["value_team"] = 0;
parent::setHeader("ส่งใบคำขอทำงานล่วงเวลาแทน", "Headman");
$this->load->view("headman/Ot/send_instead_add", $data);
parent::setFooter();
}
示例13: search
public function search($keyword = "")
{
$keyword = urldecode($keyword);
$config = array();
$config['total_rows'] = $this->news->count_all($this->newstype_id, $keyword);
$config['uri_segment'] = $this->page_segment;
$this->load->library('pagination', $config);
$page = $this->uri->segment($this->page_segment) ? $this->uri->segment($this->page_segment) : 0;
$query = $this->news->get_list($this->pagination->per_page, $page, $this->newstype_id, $keyword);
$query = $query->result_array();
$data = array();
$data["query"] = $query;
parent::setHeader("รายการกิจกรรม", "Activity");
$this->load->view("News/news_list.php", $data);
parent::setFooter();
}
示例14: detail
public function detail($messageID)
{
$query = $this->message->getDetail($messageID);
if ($query->num_rows() > 0) {
$query = $query->row_array();
$subject = $query["MSubject"];
$data = array();
$data["query"] = $query;
$data["queryReply"] = $this->message->getListReply($messageID);
$data["MID"] = $messageID;
parent::setHeader($subject, "Message");
$this->load->view("Message/Detail", $data);
parent::setFooter();
} else {
redirect("Message");
}
}
示例15: detail
public function detail($otpay_id)
{
//get detail ot pay log
$query_pay = $this->otpaylog->get_detail_by_id($otpay_id);
$query_pay = $query_pay->row_array();
//get detail ot
$query_ot = $this->ot->hr_get_list_report_detail($query_pay["otpay_user_id"], $query_pay["otpay_year"], $query_pay["otpay_month"]);
$query_ot = $query_ot->result_array();
//set data
$data = array();
$data["query_pay"] = $query_pay;
$data["query_ot"] = $query_ot;
$data["emp_detail"] = getEmployeeDetailByUserID($query_pay["otpay_user_id"]);
//load view
parent::setHeader("รายละเอียดรายงานทำงานล่วงเวลา", "HR");
$this->load->view("hr/Overtime/Report_detail.php", $data);
parent::setFooter();
}