我想在购物车中隐藏优惠券字段。为此,我将其包装在引导折叠元素中,并将display:none添加到现有的优惠券字段。编辑:在来自@gael(WooCommerce: Coupon doens't work in cart if I wrap it in collapse element)的评论之后,我发现,如果我<em
以下工作代码是购物车的折扣,至少有3个项目,不包括‘销售’产品,现在我需要忽略此折扣中的categoty‘礼物’(如果它在购物车中): //10% discount at minimum 3 itemsin cart not for sale items
add_action('woocommerce_cart_calculate_fees' , 'custom_cart_discount', 20