?
Current Path : /home1/savoy/www/savoyglobal.net/sgms/application/views/HR/ |
Linux gator3171.hostgator.com 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64 |
Current File : /home1/savoy/www/savoyglobal.net/sgms/application/views/HR/edit_employee.php |
<script language="javascript" type="text/javascript"> jQuery(document).ready(function() { suggestemployee('employee_reporting'); }); </script> <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); $this->load->view('documentreadyfunctions'); ?> <link href="<?=base_url()?>assets/css/tablesortnew.css" rel="stylesheet" type="text/css"> <div class="select-bar"> <label><img src="<?=base_url()?>assets/images/backbutton.png" title="Back" class="clickimage" onclick="viewdata('hr','viewinhrsearch','search_employee','view_employee','<?=$_SESSION['pagenum'];?>')" alt="Back" align = "center" width="25" height="25" /> </label> <span class="heading">Updating Employee</span> </div> <fieldset> <?php $employee_educational_qualification=$this->mastermodel->get_data('employee_educational_qualification',$viewinfo->employee_id ,'employee_id','employee_id'); $employee_professional_experience=$this->mastermodel->get_data(' employee_professional_experience',$viewinfo->employee_id ,'employee_id','employee_id'); $employee_additional_certification=$this->mastermodel->get_data('employee_additional_certification',$viewinfo->employee_id ,'employee_id','employee_id'); $attributes=array('id'=>'validateform','class'=>'customForm'); echo form_open('hr/addinhr/update_employee/view_employee/1',$attributes); $designation=$this->mastermodel->getdatas('designation','designation_id'); $department=$this->mastermodel->getdatas('department','department_id'); $grade=$this->mastermodel->getdatas('grade','grade_id'); $status=$this->mastermodel->getdatas('status','status_id'); $branch=$this->mastermodel->getdatas('branch','branch_id'); ?> <ul> <table class="sortnew"> <tr> <th colspan="2" style="text-align: center">Employee Information</th> </tr> <tr> <td>Employee No</td><td style="width:65%"><?php $data = array( 'name' => 'employee_no', 'id' => 'employee_no', 'class' =>'required', 'value' => $viewinfo->employee_no, 'readonly' => true ); echo form_input($data).form_error($data); ?></td> </tr> <tr> <td>Employee Name</td><td style="width:65%"><?php $data = array( 'name' => 'employee_name', 'id' => 'employee_name', 'class' =>'required', 'value' => $viewinfo->employee_name ); echo form_input($data).form_error($data); ?></td> </tr> <tr> <td>Gender</td><td style="width:65%"> <select name="employee_gender" id="employee_gender" class="required"> <option value="">Select</option> <option value="Male" <?php if($viewinfo->employee_gender=='Male'){echo "selected";} ?>>Male</option> <option value="Female" <?php if($viewinfo->employee_gender=='Female'){echo "selected";} ?>>Female</option> </select> </td> </tr> <tr> <td>Date of Birth</td><td style="width:65%"><?php $data = array( 'name' => 'employee_dob', 'id' => 'employee_dob', 'class' =>'required calfocus', 'value' => $this->mastermodel->convertdatenormalformat($viewinfo->employee_dob) ); echo form_input($data).form_error($data); ?></td> </tr> <tr> <td>Joining Date</td><td style="width:65%"><?php $data = array( 'name' => 'employee_joining_date', 'id' => 'employee_joining_date', 'class' =>'calfocus', 'value' => $this->mastermodel->convertdatenormalformat($viewinfo->employee_joining_date) ); echo form_input($data).form_error($data); ?></td> </tr> <tr> <td>Nationality</td><td style="width:65%"> <?php $data = array( 'name' => 'employee_nationality', 'id' => 'employee_nationality', 'value' => $viewinfo->employee_nationality ); echo form_input($data).form_error($data); ?></td> </tr> <tr> <td>Passport No</td><td style="width:65%"> <?php $data = array( 'name' => 'employee_passport_no', 'id' => 'employee_passport_no', 'value' => $viewinfo->employee_passport_no ); echo form_input($data).form_error($data); ?></td> </tr> <tr> <td>Visa Type</td><td style="width:65%"><?php $data = array( 'name' => 'employee_visa_type', 'id' => 'employee_visa_type', 'value' => $viewinfo->employee_visa_type ); echo form_input($data).form_error($data); ?></td> </tr> <tr> <td>Visa Expiry Date</td><td style="width:65%"> <?php $data = array( 'name' => 'employee_visa_expiry_date', 'id' => 'employee_visa_expiry_date', 'class' => 'calfocus', 'value' => $this->mastermodel->convertdatenormalformat($viewinfo->employee_visa_expiry_date) ); echo form_input($data).form_error($data); ?></td> </tr> <tr> <td>Labor Card No</td><td style="width:65%"><?php $data = array( 'name' => 'employee_labour_card_no', 'id' => 'employee_labour_card_no', 'value' => $viewinfo->employee_labour_card_no ); echo form_input($data).form_error($data); ?></td> </tr> <tr><td style="width:35%">Labor Card Expiry Date</td><td style="width:65%"><?php $data = array( 'name' => 'employee_labour_card_expiry_date', 'id' => 'employee_labour_card_expiry_date', 'class' => 'calfocus', 'value' => $this->mastermodel->convertdatenormalformat($viewinfo->employee_labour_card_expiry_date) ); echo form_input($data).form_error($data); ?></td></tr> <tr><td style="width:35%">Employee Device No</td><td style="width:65%"><?php $data = array( 'name' => 'device_no', 'id' => 'device_no', 'value' => $viewinfo->device_no, 'onchange' => "checkexistence('employee','device_no',this.value)" ); echo form_input($data).form_error($data); ?></td></tr> </table> <table class="sortnew"> <tr> <th colspan="2" style="text-align: center">Professional Information</th> </tr> <tr><td style="width:35%">Branch</td> <td style="width:65%"><select name="employee_branch_id" id="employee_branch_id" class="required"> <option value="">Select</option> <?php foreach($branch as $list) { ?> <option value="<?=$list['branch_id'];?>"<?php if($list['branch_id']==$viewinfo->employee_branch_id){echo "selected";} ?>><?=$list['branch_name'];?></option> <?php } ?> </select></td></tr> <tr><td style="width:35%">Designation</td><td style="width:65%"><select name="employee_designation_id" id="employee_designation_id" class="required"> <option value="">Select</option> <?php foreach($designation as $list) { ?> <option value="<?=$list['designation_id'];?>"<?php if($list['designation_id']==$viewinfo->employee_designation_id){echo "selected";} ?>><?=$list['designation_name'];?></option> <?php } ?> </select></td></tr> <tr><td style="width:35%">Department</td><td style="width:65%"><select name="employee_department_id" id="employee_department_id" class="required"> <option value="">Select</option> <?php foreach($department as $list) { ?> <option value="<?=$list['department_id'];?>"<?php if($list['department_id']==$viewinfo->employee_department_id){echo "selected";} ?>><?=$list['department_name'];?></option> <?php } ?> </select></td></tr> <tr><td style="width:35%">Grade</td><td style="width:65%"> <select name="employee_grade_id" id="employee_grade_id" class="required"> <option value="">Select</option> <?php foreach($grade as $list) { ?> <option value="<?=$list['grade_id'];?>" <?php if($list['grade_id']==$viewinfo->employee_grade_id){echo "selected";} ?> ><?=$list['grade_name'];?></option> <?php } ?> </select></td></tr> <tr><td style="width:35%">Status</td><td style="width:65%"><select name="employee_status_id" id="employee_status_id" class="required"> <option value="">Select</option> <?php foreach($status as $list) { ?> <option value="<?=$list['status_id'];?>" <?php if($list['status_id']==$viewinfo->employee_status_id){echo "selected";} ?> ><?=$list['status_name'];?></option> <?php } ?> </select></td></tr> <tr><td style="width:35%">Local Address</td><td style="width:65%"><?php $data = array( 'name' => 'employee_local_address', 'id' => 'employee_local_address', 'rows' => '10', 'cols' => '5', 'style' => 'width:80%', 'value' => $viewinfo->employee_local_address ); echo form_textarea($data).form_error($data); ?></td></tr> <tr><td style="width:35%">Permanent Address</td><td style="width:65%"> <?php $data = array( 'name' => 'employee_permanent_address', 'id' => 'employee_permanent_address', 'rows' => '10', 'cols' => '5', 'style' => 'width:80%', 'value' => $viewinfo->employee_permanent_address ); echo form_textarea($data).form_error($data); ?></td></tr> <tr><td style="width:35%">Contact No</td><td style="width:65%"><?php $data = array( 'name' => 'employee_contact_no', 'id' => 'employee_contact_no', 'class' =>'required', 'value' => $viewinfo->employee_contact_no ); echo form_input($data).form_error($data); ?></td></tr> <tr><td style="width:35%">Email</td><td style="width:65%"><?php $data = array( 'name' => 'employee_email', 'id' => 'employee_email', 'value' => $viewinfo->employee_email ); echo form_input($data).form_error($data); ?></td></tr> <tr> <td style="width:35%">Reporting to</td> <td style="width:65%"> <input type="text" name="employee_reporting" class="required" id="employee_reporting" value="<?=$this->mastermodel->getSingleFieldValue('employee','employee_name','employee_id',$viewinfo->employee_reporting_to);?>" /> <input type="hidden" name="employee_reporting_id" id="employee_reporting_id" value="<?=$viewinfo->employee_reporting_to;?>" /> </td> </tr> </table> <li> <li> <table class="sort" cellpadding="0" cellspacing="0" width="200px;"> <tr> <th>Course Name</th> <th>University</th> <th>Year of Passing</th> <th width="20%"> <input type="button" style="width:150px;" id="button2" value="Add More" class="addRow" title="Add Row"/> </th> </tr> <?php $i=0; foreach($employee_educational_qualification as $empqual) { $i++; ?> <tr> <td> <input type="text" name="course<?=$i;?>" value="<?=$empqual['course'];?>"/> <input type="hidden" name="employee_id<?=$i;?>" value="<?=$empqual['employee_id'];?>"/> </td> <td><input type="text" name="university<?=$i;?>" value="<?=$empqual['university'];?>"/></td> <td><input type="text" style="width:30px;" class="number" name="yearofpassing<?=$i;?>" value="<?=$empqual['yearofpassing'];?>"/></td> <td> <img style="float: right; vertical-align: top;"src="<?=base_url()?>assets/images/icons/close.png" alt="Delete Row" class="delRow clickimage" title="Delete Row"/> </td> </tr> <?php } ?> <tr> <td> <input type="text" name="course<?=$i;?>" value=""/> <input type="hidden" name="employee_id<?=$i;?>" value=""/> </td> <td><input type="text" name="university<?=$i;?>" value=""/></td> <td><input type="text" style="width:30px;" class="number" name="yearofpassing<?=$i;?>" value=""/></td> <td> <img style="float: right; vertical-align: top;"src="<?=base_url()?>assets/images/icons/close.png" alt="Delete Row" class="delRow clickimage" title="Delete Row"/> </td> </tr> </table> <input type="hidden" name="tab_name" value="employee_educational_qualification"/> <input type="hidden" name="tab_id" value="<?=$id;?>"/> </li> <li> <table class="sort" cellpadding="0" cellspacing="0" width="200px;"> <tr> <th>Employer Name</th> <th>Designation</th> <th>Period</th> <th width="20%"> <input type="button" style="width:150px;" id="button2" value="Add More" class="addRow" title="Add Row"/> </th> </tr> <?php $i=0; foreach($employee_professional_experience as $empexp) { $i++; ?> <tr> <td> <input type="text" name="employer<?=$i;?>" value="<?=$empexp['employer'];?>"/> <input type="hidden" name="employee_id<?=$i;?>" value="<?=$empexp['employee_id'];?>"/> </td> <td><input type="text" name="designation<?=$i;?>" value="<?=$empexp['designation'];?>"/></td> <td><input type="text" style="width:30px;" class="number" name="period<?=$i;?>" value="<?=$empexp['period'];?>"/></td> <td> <img style="float: right; vertical-align: top;"src="<?=base_url()?>assets/images/icons/close.png" alt="Delete Row" class="delRow clickimage" title="Delete Row"/> </td> </tr> <?php } ?> <tr> <td> <input type="text" name="employer<?=$i;?>" value=""/> <input type="hidden" name="employee_id<?=$i;?>" value=""/> </td> <td><input type="text" name="designation<?=$i;?>" value=""/></td> <td><input type="text" style="width:30px;" class="number" name="period<?=$i;?>" value=""/></td> <td> <img style="float: right; vertical-align: top;"src="<?=base_url()?>assets/images/icons/close.png" alt="Delete Row" class="delRow clickimage" title="Delete Row"/> </td> </tr> </table> <input type="hidden" name="tab_name" value="employee_professional_experience"/> <input type="hidden" name="tab_id" value="<?=$id;?>"/> </li> <li> <table class="sort" cellpadding="0" cellspacing="0" width="200px;"> <tr> <th>Course Name</th> <th>Institute</th> <th>Year of Passing</th> <th width="20%"> <input type="button" style="width:150px;" id="button2" value="Add More" class="addRow" title="Add Row"/> </th> </tr> <?php $i=0; foreach($employee_additional_certification as $empqualadd) { $i++; ?> <tr> <td> <input type="text" name="course_add<?=$i;?>" value="<?=$empqualadd['course'];?>"/> <input type="hidden" name="employee_id<?=$i;?>" value="<?=$empqualadd['employee_id'];?>"/> </td> <td><input type="text" name="institute<?=$i;?>" value="<?=$empqualadd['institute'];?>"/></td> <td><input type="text" style="width:30px;" class="number" name="year_passing<?=$i;?>" value="<?=$empqualadd['yearofpassing'];?>"/></td> <td> <img style="float: right; vertical-align: top;"src="<?=base_url()?>assets/images/icons/close.png" alt="Delete Row" class="delRow clickimage" title="Delete Row"/> </td> </tr> <?php } ?> <tr> <td> <input type="text" name="course_add<?=$i;?>" value=""/> <input type="hidden" name="employee_id<?=$i;?>" value=""/> </td> <td><input type="text" name="institute<?=$i;?>" value=""/></td> <td><input type="text" style="width:30px;" class="number" name="year_passing<?=$i;?>" value=""/></td> <td> <img style="float: right; vertical-align: top;"src="<?=base_url()?>assets/images/icons/close.png" alt="Delete Row" class="delRow clickimage" title="Delete Row"/> </td> </tr> </table> <input type="hidden" name="tab_name" value="employee_additional_certification"/> <input type="hidden" name="tab_id" value="<?=$id;?>"/> </li> <input type="hidden" name="employee_id" value="<?=$viewinfo->employee_id;?>"/> <input type="hidden" name="tab_name" value="employee"/> <li> <label for="submit"> </label> <button type="submit" id="submit" class="clickimage" onclick="addformdata('validateform')">Update</button> </li> </ul> <?php echo form_close();?> </fieldset>