admin管理员组

文章数量:1346036

The Block Checkout shows the quantity purchased in a circle over the image top. Customers keep asking about how many are in their order because they expect it as a line item, not an image. The overlaid image doesn't even state what that number is.

I understand the Block Checkout doesn't have a template for that because it's Javascript/React. I was able to add a custom field with this code in the header.

 if (WC_Blocks_Utils::has_block_in_page(wc_get_page_id('checkout'), 'woocommerce/checkout')) {
   add_action('woocommerce_init', function() {
     woocommerce_register_additional_checkout_field (
 ...

I can hide the circle-quantity with css.

QUESTION: How can I add a row to the item with "Quantity: 2" (or how many the customer ordered).

本文标签: Change Woocommerce Block Checkout Item Quantity DisplayStack Overflow