コード例 #1
0
ファイル: edit_employee.php プロジェクト: ittiwat/dpf_project
 function edit_employee($id)
 {
     $data = array('name_eng' => $this->input->post('name_eng'), 'lastname_eng' => $this->input->post('lastname_eng'), 'name_thai' => $this->input->post('name_thai'), 'lastname_thai' => $this->input->post('lastname_thai'), 'id_card' => $this->input->post('id_card'), 'address' => $this->input->post('address'), 'amphur' => $this->input->post('amphur'), 'locality' => $this->input->post('locality'), 'province' => $this->input->post('province'), 'postcode' => $this->input->post('postcode'), 'tel' => $this->input->post('tel'), 'position_eng' => $this->input->post('position_eng'), 'position_thai' => $this->input->post('position_thai'), 'salary' => $this->input->post('salary'), 'raisesalary' => $this->input->post('raisesalary'));
     $firstday = $this->input->post('firstday');
     $data['firstday'] = date_eng_to_data($firstday);
     $lastday = $this->input->post('lastday');
     $data['lastday'] = date_eng_to_data($lastday);
     $this->db->where("id", $id)->update('employee', $data);
 }
コード例 #2
0
function get_selected($id)
{
    $ci = get_model();
    $data['id'] = $id;
    $data['address'] = $ci->input->post('address_com');
    $date = $ci->input->post('date');
    $date = date_eng_to_data($date);
    $data['date'] = date_to_pdf($date);
    $data['name_manager'] = $ci->input->post('name_manager');
    $data['name_manager2'] = $ci->input->post('name_manager2');
    $data['witness'] = $ci->input->post('witness');
    $data['witness2'] = $ci->input->post('witness2');
    $data['position_manager'] = $ci->input->post('position_manager');
    $data['faction'] = $ci->input->post('faction');
    return $data;
}