?
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/add_multiple_employee_salary_payment.php |
<script type="text/javascript"> function select_all() { if($("#check_salary_payment_all").attr("checked")==true) { $(".check_salary").attr("checked", true); } else { $(".check_salary").attr("checked", false); } } function checksalempdetfunc() { var date=document.getElementById('date').value; var length=document.getElementById('empcount').value; if($('#checksalempdet').is(':checked')) { var checkval=true; $('#button1').removeAttr('disabled'); } else { var checkval=false; $('#button1').attr('disabled', 'disabled'); } for(var i=1; i <length; i++) { var empid= $("input#salempdet_"+i).val(); $.ajax({ type: "POST", url: "<?= site_url('hr/checksalarymonth') ?>", data: "id="+empid+"&date="+date, beforeSend: function(){ showPreloader('checkloading')}, complete: function(){ hidePreloader('checkloading') }, success: function(msg) { if(msg=='salary_not_set' || msg=='salary_exists') { $("input#salempdet_"+i).attr('checked', false); } else { $("input#salempdet_"+i).attr('checked', checkval); } }, async: false }); } } jQuery(document).ready(function() { checksalempdetfunc(); }); </script> <?php $attributes=array('id'=>'validateform','class'=>'customForm'); echo form_open('hr/addinhr/insert_multiple_salary_payment/view_salary_payment',$attributes); ?> <input type="hidden" name="salary_date" value="<?=$date;?>"/> <div id="checkloading"></div> <li> <table class="sort" cellpadding="0" cellspacing="0"> <caption>Staff</caption> <thead><tr> <th><input type="checkbox" style="width:20px;" name="checksalempdet" checked id="checksalempdet" onclick="checksalempdetfunc()" value="1"/></th> <th>Sl No.</th> <th>Employee no</th> <th>Name</th> <th>Designation</th> <th>Department</th> <th width="15%" class="last">Action</th> </tr> </thead> <?php $z=1; $no=1; foreach ($viewinfo as $row) { if($z%2==0) $alt="alt"; else $alt="alt1"; echo '<tr class="'.$alt.'"> <td><input type="checkbox" class="check_salary" style="width:20px;" name="salempdet[]" id="salempdet_'.$no.'" onchange="checksalarymonthind('.$no.')" value="'.$row['employee_id'].'"/></td> <td>'.$no.'</td> <td>'.$row['employee_no'].'</td><td>';?> <?php echo $row['employee_name']?> <?php echo '</td> <td>'; echo $row['designation_name']; echo '</td><td>'; echo $row['department_name']; echo '</td><td >'; $value='1~'.$row['employee_id'].'~'.$row['employee_id']; ?> <div id="console_fronticons" style="float:left"> <div class="fronticons" style="float:left"> <img class="inliexample1" src="<?=base_url()?>/assets/images/saldet.png" title="Salary Details" width="20" height="20" alt="Salary Details" align = "center" class="clickimage slslip" onclick="viewsalaryslip('<?=$row['employee_id'];?>','<?=$date;?>')" /> </div> </div> <?php echo '</td></tr>' ; $no++; $z++; } echo '<input type="hidden" name="empcount" id="empcount" value="'.$no.'"/>'; ?> </table> </li> <div style="display:none"> <div id="empdiv"> </div> </div> <li id="processbutton"><label for="submit"> </label> <button type="submit" class="clickimage" id="button1" onclick="addformdata('validateform')">Process</button> </li>