Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support rzepsen

    (@rzepsen)

    Hello @petergus

    You would probably like the plugin to generate the same quantity coupons, exactly as described in the order. The solution to this problem would be to add the theme you are using to the functions.php file this filter

    /**
     * @snippet       Display Separate Cart Items for Product Quantity > 1 | WooCommerce
     * @how-to        Get CustomizeWoo.com FREE
     * @sourcecode    https://businessbloomer.com/?p=72541
     * @author        Rodolfo Melogli
     * @testedwith    WooCommerce 3.5.1
     * @donate $9     https://businessbloomer.com/bloomer-armada/
     */
     
    // -------------------
    // 1. Split product quantities into multiple cart items
    // Note: this is not retroactive - empty cart before testing
     
    function bbloomer_split_product_individual_cart_items( $cart_item_data, $product_id ){
      $unique_cart_item_key = uniqid();
      $cart_item_data['unique_key'] = $unique_cart_item_key;
      return $cart_item_data;
    }
     
    add_filter( 'woocommerce_add_cart_item_data', 'bbloomer_split_product_individual_cart_items', 10, 2 );
     
    // -------------------
    // 2. Force add to cart quantity to 1 and disable +- quantity input
    // Note: product can still be added multiple times to cart
     
    add_filter( 'woocommerce_is_sold_individually', '__return_true' );

    Best regards

    Thread Starter petergus

    (@petergus)

    Thank you! I dont know if this works though, I am using Cartflows, so maybe it is bypassing the functions. (in a test it did not work)

    Plugin Support rzepsen

    (@rzepsen)

    Hello @petergus

    In that case, can you disable Cartflow for a test to see if my proposed solution works in a configuration without Cartflow? Then we would be sure that it does not work with the plugin you are using.

    Best regards

    Plugin Support rzepsen

    (@rzepsen)

    Hello @petergus

    As we haven’t got any replies, I’m marking this topic as resolved for now.

    Best regards

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Multiple PDF coupons not sent in EMail’ is closed to new replies.