var trNum = document.getElementById('sample_editable_1').getElementsByTagName('tr').length
function $(id){
return document.getElementById(id);
}
function init(){
for(var i=0;i<trNum-1;i++){
$("SrmBidGoods["+i+"].quantity").οnkeyup=function(){
stotal(i);
}
$("SrmBidGoods["+i+"].supplierQuote").οnkeyup=function(){
stotal(i);
}
}
}
function stotal(c){
var supplierTotalQuote = 0;
for(var i=0;i<trNum-1;i++){
x = parseFloat($("SrmBidGoods["+i+"].quantity").value);
y = parseFloat(checkempty($("SrmBidGoods["+i+"].supplierQuote").value))
$("SrmBidGoods["+i+"].goodsTotleQuote").value = parseFloat((x * y).toFixed(3));
supplierTotalQuote = supplierTotalQuote + parseFloat($("SrmBidGoods["+i+"].goodsTotleQuote").value);
}
$("supplierTotalQuote").value = supplierTotalQuote;
}
function $(id){
return document.getElementById(id);
}
function init(){
for(var i=0;i<trNum-1;i++){
$("SrmBidGoods["+i+"].quantity").οnkeyup=function(){
stotal(i);
}
$("SrmBidGoods["+i+"].supplierQuote").οnkeyup=function(){
stotal(i);
}
}
}
function stotal(c){
var supplierTotalQuote = 0;
for(var i=0;i<trNum-1;i++){
x = parseFloat($("SrmBidGoods["+i+"].quantity").value);
y = parseFloat(checkempty($("SrmBidGoods["+i+"].supplierQuote").value))
$("SrmBidGoods["+i+"].goodsTotleQuote").value = parseFloat((x * y).toFixed(3));
supplierTotalQuote = supplierTotalQuote + parseFloat($("SrmBidGoods["+i+"].goodsTotleQuote").value);
}
$("supplierTotalQuote").value = supplierTotalQuote;
}