attendance
This commit is contained in:
parent
d523e9b287
commit
5f3a4f6b50
40
application/views/attendance.php
Executable file → Normal file
40
application/views/attendance.php
Executable file → Normal file
@ -1,4 +1,4 @@
|
||||
<script src="<?php echo base_url()?>assets/lightswitch/lightswitch/lib/jquery.tabletojson.js"></script>
|
||||
<script src="<?php echo base_url()?>assets/lightswitch/lightswitch/lib/jquery.tabletojson.js"></script>
|
||||
<script src="<?php echo base_url()?>assets/lightswitch/lightswitch/lib/jquery.tabletojson.min.js"></script>
|
||||
<script src="<?php echo base_url()?>assets/js/jquery.CongelarFilaColumna.js"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-datepicker/1.5.0/js/bootstrap-datepicker.js"></script>
|
||||
@ -687,7 +687,7 @@ function myFunction(p,i,v)
|
||||
{
|
||||
var current = value.textContent == '' ? 0:parseFloat(value.textContent);
|
||||
totalworkingHrs += current;
|
||||
if(current == 0){paidleave--;}
|
||||
if(current == 0){absent++;}
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -705,18 +705,24 @@ function myFunction(p,i,v)
|
||||
|
||||
|
||||
|
||||
if(paidleave == 1 )
|
||||
{
|
||||
absent = 0;
|
||||
}else if(paidleave == 0)
|
||||
{
|
||||
absent = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
absent = paidleave-0;
|
||||
paidleave = 0;
|
||||
}
|
||||
// if(paidleave == 1 )
|
||||
// {
|
||||
// absent = 0;
|
||||
// alert('if');
|
||||
// }
|
||||
// if(paidleave == 0)
|
||||
// {
|
||||
// absent = 0;
|
||||
// alert('else if');
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// // absent = paidleave-0;
|
||||
// // paidleave = 0;
|
||||
// absent = paidleave;
|
||||
// paidleave = 0;
|
||||
// alert('else');
|
||||
// }
|
||||
document.getElementById(totalhrsid).textContent = parseFloat(totalworkingHrs).toFixed(2);// == ''?0:parseFloat(totalworkingHrs));
|
||||
document.getElementById(totalothrsid).textContent = parseFloat(totalOTHrs).toFixed(2);// == ''?0:parseFloat(totalOTHrs));
|
||||
document.getElementById(paidleaveid).textContent = parseFloat(paidleave).toFixed(2);
|
||||
@ -804,12 +810,12 @@ function resetFinalValues()
|
||||
{
|
||||
|
||||
//alert('inside for');
|
||||
var a = parseFloat(document.getElementById(i+'PL').textContent);
|
||||
// var a = parseFloat(document.getElementById(i+'PL').textContent);
|
||||
var b = parseFloat(document.getElementById(i+'AB').textContent);
|
||||
//alert(a+'-'+b+'-'+totaldays);
|
||||
if(totaldays == (a+b))
|
||||
if(totaldays == (b))
|
||||
{
|
||||
document.getElementById(i+'PL').textContent = '0.00';
|
||||
//document.getElementById(i+'PL').textContent = '0.00';
|
||||
document.getElementById(i+'AB').textContent = '0.00';
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user