[2.5] Round tax/tax refunded amounts on display.

Closes #10162
This commit is contained in:
Mike Jolley 2016-01-25 15:18:49 +00:00
parent b26a13ec47
commit 57c643c93e
1 changed files with 1 additions and 1 deletions

View File

@ -172,7 +172,7 @@ if ( wc_tax_enabled() ) {
<td class="label"><?php echo $tax->label; ?>:</td>
<td class="total"><?php
if ( ( $refunded = $order->get_total_tax_refunded_by_rate_id( $tax->rate_id ) ) > 0 ) {
echo '<del>' . strip_tags( $tax->formatted_amount ) . '</del> <ins>' . wc_price( $tax->amount - $refunded, array( 'currency' => $order->get_order_currency() ) ) . '</ins>';
echo '<del>' . strip_tags( $tax->formatted_amount ) . '</del> <ins>' . wc_price( WC_Tax::round( $tax->amount, wc_get_price_decimals() ) - WC_Tax::round( $refunded, wc_get_price_decimals() ), array( 'currency' => $order->get_order_currency() ) ) . '</ins>';
} else {
echo $tax->formatted_amount;
}