?
Current Path : /home1/savoy/www/savoyglobal.net/drafthr/system/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/drafthr/system/application/views/HR/editstaffsalaryhr.php |
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');?> <?php /* * To change this template, choose Tools | Templates * and open the template in the editor. */ foreach($viewinfo as $updata) { $staffid =$updata['staffid']; $date = $updata['date']; $basicsalary = $updata['basicsalary']; $staffsalaryid=$updata['id']; $premiumtarget=$updata['premiumtarget']; } $stf=$this->mastermodel->get_data_srow('staffpersonaldetails',$staffid,'id'); $allowded=$this->mastermodel->get_data('staffsalaryallowdeduc',$staffsalaryid,'staffsalaryid'); $date=$this->mastermodel->convdatformat($date); $staffsalaryid=""; $data = $this->hrmodel->get_sal_data('staffsalary',$staffid,date("d-m-Y")); foreach ($data as $dpay) { $staffsalaryid = $dpay['id']; } $stf=$this->mastermodel->get_data_srow('staffpersonaldetails',$staffid,'id'); $stflea=$this->hrmodel->numcount_data('leaveallocation',$staffid,'staffid'); $leavalloc=$this->hrmodel->getstfleavallocs('leaveallocation',$staffid,'staffid'); foreach ($leavalloc as $lalloc) { $staffleaveid = $lalloc['id']; } $stfemp=$this->mastermodel->get_data_srow('staffemployeedetails',$staffid,'staffid'); $stfdes=$this->hrmodel->numcount_data('commissionsettings',$stfemp->designationid,'designationid'); ?> <div class="select-bar"> <label> <img src="<?=base_url()?>/assets/images/backbutton.png" title="Back" class="clickimage" onclick="loadstaff('<?=$_SESSION['pagenum']?>','<?=$_SESSION['searchoption']?>','<?=$_SESSION['searchtxt']?>')" alt="Back" align = "center" width="25" height="25" /></label> </div> <img src="<?=base_url()?>assets/images/leav_white.jpg" class = "clickimage" title="Leave" alt="Leave" align = "right" <?php if($stflea != 0){ ?> onclick="editstfleaveallocation(<?=$staffleaveid?>)" <?php } else { ?> onclick="alert('Leave not Set');" <?php } ?> /> <img src="<?=base_url()?>assets/images/com_white.jpg" class = "clickimage" title="Commission" alt="Commission" align = "right" <?php if($stfdes != 0){ ?> onclick="editcomstaff('<?=$staffid?>')" <?php } else { ?> onclick="alert('Commission not Set');" <?php } ?> /> <img src="<?=base_url()?>assets/images/sal_white.jpg" class = "clickimage" title="Salary" alt="Salary" align = "right" <?if ($staffsalaryid != ""){ ?>onclick="editstafsal(<?=$staffsalaryid?>)"<?php } else { ?> onclick="alert('Employee Salary not Set');" <?php } ?>/> <img src="<?=base_url()?>assets/images/per_white.jpg" class = "clickimage" title="Personal" alt="Personal" align = "right" onclick="editstaff(1,<?=$staffid?>)" /> <br><br><br><br> <fieldset> <legend>Update Staff-Salary</legend> <?php $attributes = array('id' => 'customForm'); echo form_open('hr/editstaffsalary',$attributes); echo form_hidden('staffsalaryid',$staffsalaryid); ?> <ul> <li> <label for="date">Employee Name</label> <input type="text" id="staffname" size="20" value="<?=$stf->name;?>"> <input type="hidden" name="staffid" id="staffid" value="<?=$staffid;?>"> <img id="inliexample1" src="<?=base_url()?>/assets/images/button-search.png" title="Search" class="clickimage" onclick="showstaffdiv()" > <span id="staffnameInfo" class="red_bold">*</span> </li> <?php $stfper=$this->mastermodel->get_data_srow('staffpersonaldetails',$staffid,'id'); $stfemp=$this->mastermodel->get_data_srow('staffemployeedetails',$staffid,'staffid'); $desg = $this->mastermodel->get_data_srow('designation',$stfemp->designationid,'id'); $dept= $this->mastermodel->get_data_srow('department',$stfemp->deptid,'id'); ?> <li id="stfinfodet"> <fieldset><ul><li><label>Employee No</label><label><?=$stfper->employeeid;?></label></li> <li><label>Designation</label><label><?=$desg->designation;?></label></li> <li><label>Department</label><label><?=$dept->departmentname;?></label></li> </ul> </fieldset> </li> <li> <label>Date</label> <input class="one" name="date" id="date" readonly="true" value="<?=$date;?>" type="text" style="background-image: url(../../../../assets/images/datefocus.gif);"> <span id="dateInfo" class="red_bold">*</span> </li> <li> <label>Basic Salary</label> <input type="text" id="basicsalary" name="basicsalary" size="20" value="<?=$basicsalary;?>" > <span id="basicsalaryInfo" class="red_bold">*</span> </li> <li> <table align="left" width="700px"><tr><td> <table class="sort" cellpadding="0" cellspacing="0" align="left" ><caption>Enter Allowance Details</caption> <thead><tr> <th>Allowance Type</th> <th>Amount</th> </tr> <?php $i=1; foreach($allowded as $alde) { if($alde['allowdeductype'] == "1") { $data = array( 'name' => 'newpolicy_'.$i, 'id' => 'newpolicy_'.$i, 'style' => 'width:80%', 'value' => $alde['amount'], ); $allowdeducname=$this->mastermodel->get_data_srow('allowdeduc',$alde['allowdeducid'],'id'); ?> <tr> <td width="200px"><?=$allowdeducname->allowdeducname;?><input type="hidden" value ="<?= $alde['allowdeducid'];?>" name="coverid_<?=$i;?>"> <input type="hidden" value ="<?= $alde['id'];?>" name="hidc_<?=$i;?>"> </td><td width="100px"> <?php echo form_input($data).form_error($data); ?> <span id="newpolicy_<?=$i;?>Info" class="red_bold">*</span></td> </tr> <?php $i++; }} ?> </tbody></table> </td><td width="10px"></td><td> <table class="sort" cellpadding="0" cellspacing="0" align="right" ><caption>Enter Deduction Details</caption> <thead><tr> <th>Deduction Type</th> <th>Amount</th> </tr> <?php $i=1; foreach($allowded as $alde) { if($alde['allowdeductype'] == "0") { $data = array( 'name' => 'newpolicy1_'.$i, 'id' => 'newpolicy1_'.$i, 'style' => 'width:80%', 'value' => $alde['amount'], ); $allowdeducname=$this->mastermodel->get_data_srow('allowdeduc',$alde['allowdeducid'],'id'); ?> <tr> <td width="200px"><?=$allowdeducname->allowdeducname;?><input type="hidden" value ="<?= $alde['allowdeducid'];?>" name="coverid1_<?=$i;?>" </td><td width="100px"> <?php echo form_input($data).form_error($data); ?> <span id="newpolicy1_<?=$i;?>Info" class="red_bold">*</span> <input type="hidden" value ="<?= $alde['id'];?>" name="hidc1_<?=$i;?>"> </td> </tr> <?php $i++; }} ?> </tbody></table></td></tr></table> </li> <li> <label>Premium Target</label> <input type="text" id="premiumtarget" name="premiumtarget" size="20" value="<?=$premiumtarget;?>"> <span id="premiumtargetInfo" class="red_bold">*</span> </li> <li><label for="submit"> </label> <button type="submit" id="submit" onclick="return doallthetwo();">Update</button> </li> </ul> <?php echo form_close();?> </fieldset>