function contact_type_delete($id = '', $page = '') { $contact = new Training_contact_type(); $contact->get_by_id($id); $contact->delete(); Session::flash('msg', 'Training Contact Type Deleted!'); return Redirect::to('training_manage/contact_type/' . $page, 'refresh'); }
</tr> <tr> <td width="9%"> </td> <td width="58%"> </td> <td width="33%"></td> </tr> </table> <table width="100%" border="0" class="type-one"> <tr class="type-one-header"> <th width="8%" bgcolor="#D6D6D6">ID</th> <th width="20%" bgcolor="#D6D6D6"><strong>Type</strong></th> <th width="63%" bgcolor="#D6D6D6">Description</th> <th width="9%" bgcolor="#D6D6D6"><strong>Actions</strong></th> </tr> <?php $c = new Training_contact_type(); ?> <?php foreach ($rows as $row) { ?> <?php $c->get_by_id($row->contact_type_id); ?> <?php $bg = $this->Helps->set_line_colors(); ?> <tr bgcolor="<?php echo $bg; ?> " onmouseover="this.bgColor = '<?php
function training_contact_type_options($training_type = '') { $this->load->model('training_contact_type'); $options = array(); $t = new Training_contact_type(); $types = $t->order_by('contact_type')->get(); $options[0] = '---ALL---'; foreach ($types as $type) { $options[$type->id] = $type->contact_type; } return $options; }