change order #2471

This commit is contained in:
Mike Jolley 2013-02-19 18:11:18 +00:00
parent 820371a502
commit 012a62cf3a
2 changed files with 13 additions and 13 deletions

View File

@ -398,14 +398,14 @@ jQuery( function($){
var order_shipping_tax = $('#_order_shipping_tax').val(); var order_shipping_tax = $('#_order_shipping_tax').val();
var order_discount = $('#_order_discount').val(); var order_discount = $('#_order_discount').val();
if ( ! order_shipping ) order_shipping = 0;
if ( ! order_shipping_tax ) order_shipping_tax = 0;
if ( ! order_discount ) order_discount = 0;
order_shipping = accounting.unformat( order_shipping.replace(',', '.') ); order_shipping = accounting.unformat( order_shipping.replace(',', '.') );
order_shipping_tax = accounting.unformat( order_shipping_tax.replace(',', '.') ); order_shipping_tax = accounting.unformat( order_shipping_tax.replace(',', '.') );
order_discount = accounting.unformat( order_discount.replace(',', '.') ); order_discount = accounting.unformat( order_discount.replace(',', '.') );
if ( ! order_shipping ) order_shipping = 0;
if ( ! order_shipping_tax ) order_shipping_tax = 0;
if ( ! order_discount ) order_discount = 0;
$('#order_items_list tr.item').each(function(){ $('#order_items_list tr.item').each(function(){
var line_subtotal = $(this).find('input.line_subtotal').val(); var line_subtotal = $(this).find('input.line_subtotal').val();
@ -413,16 +413,16 @@ jQuery( function($){
var line_total = $(this).find('input.line_total').val(); var line_total = $(this).find('input.line_total').val();
var line_tax = $(this).find('input.line_tax').val(); var line_tax = $(this).find('input.line_tax').val();
if ( ! line_subtotal ) line_subtotal = 0;
if ( ! line_subtotal_tax ) line_subtotal_tax = 0;
if ( ! line_total ) line_total = 0;
if ( ! line_tax ) line_tax = 0;
line_subtotal = accounting.unformat( line_subtotal.replace(',', '.') ); line_subtotal = accounting.unformat( line_subtotal.replace(',', '.') );
line_subtotal_tax = accounting.unformat( line_subtotal_tax.replace(',', '.') ); line_subtotal_tax = accounting.unformat( line_subtotal_tax.replace(',', '.') );
line_total = accounting.unformat( line_total.replace(',', '.') ); line_total = accounting.unformat( line_total.replace(',', '.') );
line_tax = accounting.unformat( line_tax.replace(',', '.') ); line_tax = accounting.unformat( line_tax.replace(',', '.') );
if ( ! line_subtotal ) line_subtotal = 0;
if ( ! line_subtotal_tax ) line_subtotal_tax = 0;
if ( ! line_total ) line_total = 0;
if ( ! line_tax ) line_tax = 0;
line_subtotals = line_subtotals + line_subtotal; line_subtotals = line_subtotals + line_subtotal;
line_subtotal_taxes = line_subtotal_taxes + line_subtotal_tax; line_subtotal_taxes = line_subtotal_taxes + line_subtotal_tax;
line_totals = line_totals + line_total; line_totals = line_totals + line_total;
@ -448,12 +448,12 @@ jQuery( function($){
var line_total = $(this).find('input.line_total').val(); var line_total = $(this).find('input.line_total').val();
var line_tax = $(this).find('input.line_tax').val(); var line_tax = $(this).find('input.line_tax').val();
if ( ! line_total ) line_total = 0;
if ( ! line_tax ) line_tax = 0;
line_total = accounting.unformat( line_total.replace(',', '.') ); line_total = accounting.unformat( line_total.replace(',', '.') );
line_tax = accounting.unformat( line_tax.replace(',', '.') ); line_tax = accounting.unformat( line_tax.replace(',', '.') );
if ( ! line_total ) line_total = 0;
if ( ! line_tax ) line_tax = 0;
line_totals = line_totals + line_total; line_totals = line_totals + line_total;
if ( woocommerce_writepanel_params.round_at_subtotal=='no' ) { if ( woocommerce_writepanel_params.round_at_subtotal=='no' ) {

File diff suppressed because one or more lines are too long