Ejemplo n.º 1
0
 function contact_info_save($id = '', $page = '')
 {
     $data['page_name'] = '<b>Save Training Contact Information</b>';
     $data['msg'] = '';
     $this->load->helper('list_box');
     $contact = new Training_contact();
     $data['contact'] = $contact->get_by_id($id);
     if (Input::get('op')) {
         $contact->contact_name = Input::get('contact_name');
         $contact->contact_co = Input::get('contact_co');
         $contact->contact_address = Input::get('contact_address');
         $contact->contact_city = Input::get('contact_city');
         $contact->contact_phone = Input::get('contact_phone');
         $contact->contact_fax = Input::get('contact_fax');
         $contact->contact_email = Input::get('contact_email');
         $contact->contact_specialty = Input::get('contact_specialty');
         $contact->contact_type_id = Input::get('contact_type_id');
         $contact->save();
         Session::flash('msg', 'Training Contact Information saved!');
         return Redirect::to('training_manage/contact_info/' . $page, 'refresh');
     }
     $data['selected'] = $contact->contact_type_id;
     $data['main_content'] = 'contact_info_save';
     return View::make('includes/template', $data);
 }