emppaysliptototal
This commit is contained in:
parent
bd936e04da
commit
189e998344
@ -200,6 +200,7 @@ $('html').bind('keypress', function(e)
|
|||||||
$index = 0;
|
$index = 0;
|
||||||
$i = 0;
|
$i = 0;
|
||||||
$totalempSal = [];
|
$totalempSal = [];
|
||||||
|
//$totalinst =[];
|
||||||
foreach($sample as $i=> $record)
|
foreach($sample as $i=> $record)
|
||||||
{
|
{
|
||||||
//echo 'PAY'.$record->Key;
|
//echo 'PAY'.$record->Key;
|
||||||
@ -257,8 +258,8 @@ $('html').bind('keypress', function(e)
|
|||||||
<?php if(!empty($record->MonthlyIncentives)){echo $record->MonthlyIncentives;}else {echo $record->MasterIncentives;} ?>
|
<?php if(!empty($record->MonthlyIncentives)){echo $record->MonthlyIncentives;}else {echo $record->MasterIncentives;} ?>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- <?php $totalinst [] =$MasterIncentives[$i]; ?>
|
||||||
|
-->
|
||||||
|
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
@ -313,10 +314,13 @@ $('html').bind('keypress', function(e)
|
|||||||
</tbody>
|
</tbody>
|
||||||
<tfoot><tr>
|
<tfoot><tr>
|
||||||
<th colspan="4"></th>
|
<th colspan="4"></th>
|
||||||
<th colspan="4"></th>
|
<th colspan="3"></th>
|
||||||
<th colspan="2"></th>
|
|
||||||
<th>Total</th>
|
<th>Total</th>
|
||||||
<th> <?php echo array_sum($totalempSal);?></th>
|
<th id="inst"><?php echo array_sum($totalinst);?></th>
|
||||||
|
<th id="other"><?php echo array_sum($totalotherDet);?></th>
|
||||||
|
<th id="fest"><?php echo array_sum($totalfestival);?></th>
|
||||||
|
<th id="totalsal"><?php echo array_sum($totalempSal);?></th>
|
||||||
</tr>
|
</tr>
|
||||||
</tfoot>
|
</tfoot>
|
||||||
</table>
|
</table>
|
||||||
@ -520,6 +524,9 @@ function isCheckKeyCode(event){
|
|||||||
|
|
||||||
}
|
}
|
||||||
var totalinst = [];
|
var totalinst = [];
|
||||||
|
var totalotherDet =[];
|
||||||
|
var totalfestival =[];
|
||||||
|
var totalempSal=[];
|
||||||
|
|
||||||
function changeInput(event,k)
|
function changeInput(event,k)
|
||||||
{
|
{
|
||||||
@ -536,8 +543,17 @@ function isCheckKeyCode(event){
|
|||||||
var loanRecd=document.getElementById('loanRecd'+sno).textContent;
|
var loanRecd=document.getElementById('loanRecd'+sno).textContent;
|
||||||
var incentie=parseFloat(document.getElementById('incentie'+sno).textContent);
|
var incentie=parseFloat(document.getElementById('incentie'+sno).textContent);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
totalinst[sno] = incentie;
|
||||||
|
|
||||||
|
|
||||||
var otherDet =parseFloat(document.getElementById('otherDet'+sno).textContent);
|
var otherDet =parseFloat(document.getElementById('otherDet'+sno).textContent);
|
||||||
|
totalotherDet[sno] = otherDet;
|
||||||
|
|
||||||
var Festival =parseFloat(document.getElementById('Festival'+sno).textContent);
|
var Festival =parseFloat(document.getElementById('Festival'+sno).textContent);
|
||||||
|
totalfestival[sno]= Festival ;
|
||||||
var empsal =parseFloat(document.getElementById('empsal'+sno).textContent);
|
var empsal =parseFloat(document.getElementById('empsal'+sno).textContent);
|
||||||
|
|
||||||
var bpay =parseFloat(document.getElementById('bPay'+sno).value);
|
var bpay =parseFloat(document.getElementById('bPay'+sno).value);
|
||||||
@ -693,13 +709,69 @@ function isCheckKeyCode(event){
|
|||||||
|
|
||||||
document.getElementById("empsal"+sno).innerHTML = cals;
|
document.getElementById("empsal"+sno).innerHTML = cals;
|
||||||
|
|
||||||
|
totalempSal[sno]= cals ;
|
||||||
|
|
||||||
|
calculategrandtotal();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
var tempTotal = [];
|
||||||
|
function calculategrandtotal(){
|
||||||
|
|
||||||
|
$.each(totalinst, function( index, value )
|
||||||
|
{
|
||||||
|
//var res2 = value.split('-');
|
||||||
|
tempTotal[index]=parseFloat(value);
|
||||||
|
});
|
||||||
|
|
||||||
|
var sum = 0;
|
||||||
|
|
||||||
|
for (var i = 0; i < tempTotal.length; i++) {
|
||||||
|
sum += tempTotal[i] << 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
$('#inst').text(parseFloat(sum).toFixed(2));
|
||||||
|
|
||||||
|
$.each(totalotherDet, function( index, value )
|
||||||
|
{
|
||||||
|
//var res2 = value.split('-');
|
||||||
|
tempTotal[index]=parseFloat(value);
|
||||||
|
});
|
||||||
|
|
||||||
|
var sum = 0;
|
||||||
|
|
||||||
|
for (var i = 0; i < tempTotal.length; i++) {
|
||||||
|
sum += tempTotal[i] << 0;
|
||||||
|
}
|
||||||
|
$('#other').text(parseFloat(sum).toFixed(2));
|
||||||
|
|
||||||
|
$.each(totalfestival, function( index, value )
|
||||||
|
{
|
||||||
|
//var res2 = value.split('-');
|
||||||
|
tempTotal[index]=parseFloat(value);
|
||||||
|
});
|
||||||
|
|
||||||
|
var sum = 0;
|
||||||
|
|
||||||
|
for (var i = 0; i < tempTotal.length; i++) {
|
||||||
|
sum += tempTotal[i] << 0;
|
||||||
|
}
|
||||||
|
$('#fest').text(parseFloat(sum).toFixed(2));
|
||||||
|
|
||||||
|
$.each(totalempSal, function( index, value )
|
||||||
|
{
|
||||||
|
//var res2 = value.split('-');
|
||||||
|
tempTotal[index]=parseFloat(value);
|
||||||
|
});
|
||||||
|
|
||||||
|
var sum = 0;
|
||||||
|
|
||||||
|
for (var i = 0; i < tempTotal.length; i++) {
|
||||||
|
sum += tempTotal[i] << 0;
|
||||||
|
}
|
||||||
|
$('#totalsal').text(parseFloat(sum).toFixed(2));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user