我们正在使用 Woocommerce Payments,在我们的订单确认电子邮件中,付款方式显示为 Woocommerce Payments,而不是 Visa、Mastercard 等付款来源。
我已经找到了如何完全删除付款方式(见下文),但我将如何删除它并重新添加到付款来源?
<tfoot>
<?php
if ( $totals = $order->get_order_item_totals() ) {
$i = 0;
foreach ( $totals as $key => $total ) {
$i++;
if ( $key !== 'payment_method' ){
?><tr>
<th scope="row" colspan="2" style="text-align:left; border: 1px solid #eee; <?php if ( $i == 1 ) echo 'border-top-width: 4px;'; ?>"><?php echo $total['label']; ?></th>
<td style="text-align:left; border: 1px solid #eee; <?php if ( $i == 1 ) echo 'border-top-width: 4px;'; ?>"><?php echo $total['value']; ?></td>
</tr><?php
}
}
}
?>