本文整理汇总了PHP中MY_Controller::core_doctor_view方法的典型用法代码示例。如果您正苦于以下问题:PHP MY_Controller::core_doctor_view方法的具体用法?PHP MY_Controller::core_doctor_view怎么用?PHP MY_Controller::core_doctor_view使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MY_Controller
的用法示例。
在下文中一共展示了MY_Controller::core_doctor_view方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: redirect
function check_pat($id, $type = false)
{
##ตรวจ
if ($id == false) {
$ref = $this->input->server('HTTP_REFERER', TRUE);
redirect($ref, 'location');
}
$data['check'][] = $this->general_model->get_row('check_pat', "check_id = {$id} ");
##
$data['check_id'] = $id;
$pat_id = $data['check'][0]['pat_id'];
$data['pat_id'] = $pat_id;
$data['pat'] = $this->general_model->get_row('patients', "pat_id = {$pat_id}");
$data['met'] = $this->general_model->get_row('meet', "check_id = {$id} order by met_id desc limit 1");
// $tool_more = $this->general_model->get_field('*', 'tool_more', 'check_id = '.$id .' order by mr_id desc limit 1');
// $data['tool_more'] = reset($tool_more);
// var_dump($data['check']);die();
if ($data['check'][0] == false) {
$ref = $this->input->server('HTTP_REFERER', TRUE);
?>
<meta charset="utf-8">
<script type="text/javascript">
var url = '<?php
echo $ref;
?>
';
if (confirm("ยังไม่ได้รับการตรวจ ในบริการนี้ !") == true) {
window.location.href = url;
} else {
window.location.href = url;
}
</script>
<?php
}
$data['pat'] = $this->general_model->get_row('patients', "pat_id = {$data['check'][0]['pat_id']}");
$data['evol'][] = $this->general_model->get_row('evolution', "pat_id = {$data['check'][0]['pat_id']} and check_id = {$data['check'][0]['check_id']}");
##ดึงเฉพาะล่าสุด
$data['order_tools'] = $this->general_model->get('order_tools', "check_id = {$data['check'][0]['check_id']}");
##ดึงเฉพาะล่าสุด
if ($type == 'check_pat_before') {
parent::core_doctor_view('pat/check_pat_before', $data);
} elseif ($type == 'check_pat_after') {
parent::core_doctor_view('pat/check_pat_after', $data);
} elseif ($type == 'evol') {
parent::core_doctor_view('pat/evol', $data);
} else {
parent::core_doctor_view('pat/check_pat', $data);
}
}
示例2:
function list_in_group($pat_id, $group_id)
{
$pat_id = $pat_id;
$data['group_id'] = $group_id;
$data['pat_id'] = $pat_id;
$data['pat'] = $this->general_model->get_row('patients', "pat_id = {$pat_id}");
$sql = "SELECT * \n FROM order_tools t1\n INNER JOIN tools_set t2\n on t1.tool_id = t2.tool_id\n RIGHT JOIN tools_group t3\n on t2.tool_group_id = t3.tool_group_id\n where \n pat_id = {$pat_id}\n AND \n t3.tool_group_id = {$group_id}\n ";
$data['order_tools'] = $this->general_model->Query1($sql);
// var_dump($order_tools);die();
// $data['order_tools'] = $this->general_model->get_all('order_tools', "check_id = {$check_id}");
parent::core_doctor_view('tools/list_tool_in_group', $data);
}
示例3: redirect
function query_check_evol($id = false, $check_id = false)
{
##id ผู้ผ่วย เลือกค่าตรวจล่าสุดมา
if ($id == false) {
redirect('doctor');
}
$data['pat'] = $this->general_model->get_row('patients', "pat_id = {$id}");
$data['check'][] = $this->general_model->get_row('check_pat', "pat_id = {$id} order by check_id DESC limit 1");
$data['evol'][] = $this->general_model->get_row('evolution', "pat_id = {$id} and check_id = {$data['check'][0]['check_id']}");
##ดึงเฉพาะล่าสุด
$data['order_tools'] = $this->general_model->get_row('order_tools', "check_id = {$data['check'][0]['check_id']}");
##ดึงเฉพาะล่าสุด
if ($this->input->post()) {
$post = $this->input->post();
$post['pat_id'] = $data['pat']['pat_id'];
$post['check_id'] = $data['check'][0]['check_id'];
unset($post['submit']);
$this->general_model->insert('evolution', $post);
$evol_id = $this->db->insert_id();
$param['check_status'] = 'ประเมิณเรียบร้อยแล้ว';
//var_dump($param['check_status']);die();
$this->general_model->update('check_pat', $param, "check_id = {$data['check'][0]['check_id']}");
redirect(base_url() . 'doctor/check_evol/' . $id, '');
exit;
}
parent::core_doctor_view('doctor/evol_add_edit', $data);
}