• 1) I need to be able to completely replace the Woocommerce add to cart message, rather than append it. If I use the wc_add_to_cart_message filter to remove it, it wipes the whole lot including the Stock Reducer text, so I have to manually remove the text from Woocommerce itself.

    2) I have found it useful to add the expire_soonest variable to both the wc_csr_expire_notice_additional and the wc_csr_expire_notice filters (by adding $item to the end of the filter on line 315 and $this->expire_items() to the filter on line 326). This allows me to notify the user of exactly how long they’ve got before items start being removed, rather than just telling them that there are items expiring sooner. Thought you might want to consider adding this to a future version.

    3) I am using this with the Woocommerce Bookings plugin, but in order for it to work I have to remove the stock management check from the conditionnal on line 471, as it’s not possible to enable stock management for bookable products (as far as I know).

    Just some things to consider. Thanks for this great plugin ??

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author James Golovich

    (@jamesgol)

    Let’s see what we can do.

    1) Try registering a filter with a higher priority (lower number) on the ‘wc_add_to_cart_message’ filter that completely wipes it out.

    Example:

    
        add_filter( 'wc_add_to_cart_message', 'remove_add_to_cart_message', 9, 2 );
        function remove_add_to_cart_message( $message, $product_id = null ) {
            // Maybe add a check in here if you don't want the message removed in all cases
            return '';
        }
    

    2) Seems like a reasonable addition. When I have some time I’ll see about adding it, if you submit a pull request on github it might happen quicker ??

    3) I’ve never seen the Bookings plugin, if you send me a copy when I have a chance I’ll see what it will take to extend support so it works with that plugin (and hopefully others)

    Cheers!

    Thread Starter tomathyg

    (@tomathyg)

    Thanks for responding so quickly.

    1) That worked a treat, and I learnt an important little something in the process!

    2) Yes, I need to get into github – will submit a request. Just to correct myself, I added $item to the end of the wc_csr_expire_notice filter, not wc_csr_expire_notice_additional, so that I can display more info about the item in the notice. In my case, it’s the details (dates and times) that distinguish the items from each other, not the name of the product, which is always the same.

    3) The Woocommerce Bookings plugin is by far the best bookings solution I’ve found and your plugin is exactly what it is missing. If there is limited availability for something that is being booked i.e. a single space, it is important not to let people hang on to that unique item in their cart for too long. However, as it uses ‘bookable’ products, which don’t have ‘stock’ per say, it doesn’t allow for stock management, which CSR checks for (that’s the only problem, as far as I can see). The built-in WC stock management won’t work for the same reason (I think), or is at least very inaccurate and obviously invisible. Will ping you a copy so that you can have a look.

    4, while I’m at it) I might have mentioned this on another thread but the holy grail (for me at least) would be to Ajaxify the whole cart process. WooCommerce Ajax Add To Basket by Oraksoft (will send you that too) does the trick for adding but of course won’t work with CSR. If you can make that happen, you will rightly achieve Woocommerce Hero status for all of eternity, as judged by a panel of me ??

    Tom

    Hi There,

    Is there any update on bookable products?

    As mentioned by Tom, this is what exactly the plugin (woocoommerce booking) is missing.

    The plugin is great and working for product type that has stock management. But bookable product is not working at all.

    Let me know if there is further update on this.

    Looking forward.

    Thanks!

    Plugin Author James Golovich

    (@jamesgol)

    I do not have a copy of the bookings plugin to even look into this. If you send me a copy I can look into it when I have some free time.

    Hi James,

    How can I send you a copy?

    Plugin Author James Golovich

    (@jamesgol)

    My email is [email protected]. I cannot guarantee a time when I will get to this, I am completely swamped right now but as time allows I will work on it.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Minor filter issues / requests, and bookable product issue’ is closed to new replies.