woocommerce-local-pickup-time icon indicating copy to clipboard operation
woocommerce-local-pickup-time copied to clipboard

Override pickup delay option on products

Open keytronic opened this issue 6 years ago • 8 comments

it would be great to be able to override default pickup delay for some products. I'm dealing with several type of products : 80% need 1 day to be packed but some others are already done (or can be done in few minutes) and could be pickup after 2 hours. And at the opposite some others need more then 2/3 days.

keytronic avatar Jun 14 '19 21:06 keytronic

@JordanGout are you thinking that products would have their own pickup time requirements which dictate the entire order's pickup time or an order would have multiple pickup times by product?

timnolte avatar Jun 17 '19 03:06 timnolte

@timnolte I think order's pickup time should be the maximum time of order's products. If one product can be ready in few hours but another in 2 days order can be pickup in 2 days

keytronic avatar Jun 17 '19 06:06 keytronic

@timnolte I'm thinking about something else it is possible to be able to set delay on product's variations? 🤔 A bakery exemple : cake for 4 people / 6 people can be available in 2 hours but cake for 8 or 10 people in 1day

keytronic avatar Jun 17 '19 18:06 keytronic

I'll have to see where I can take this. Currently the pickup date is only an order meta field, not tied to a product in any way.

timnolte avatar Jun 25 '19 01:06 timnolte

I vote for this one.

jottesjs avatar Mar 28 '20 08:03 jottesjs

Related to this: Some products are only available at specific days. E.g. a bakery, producing special bred xy only on Fridays, so you only can pick up on Fridays and Saturdays, but you have to place your order on Thursday or earlier, to make sure your product ordered for Saturday will be taken from the production of Friday (and not be eventually sold out before the order is processed).

jottesjs avatar Mar 28 '20 10:03 jottesjs

@timnolte I'm trying to implement this feature. As I need to make options on product variations I use woocommerce_product_after_variable_attributes hook.

~~The only problem is related to plugin init. Product variations use AJAX but plugin do not load admin if call is from AJAX.~~

~~if ( is_admin() && ( ! defined( 'DOING_AJAX' ) || ! DOING_AJAX ) ) { ... }~~

~~Can I safely remove this condition ? or maybe there is a way I didn't know.~~ Last part not relevant anymore in 2024 :)

keytronic avatar Jul 19 '20 09:07 keytronic

@timnolte Would you accept PR on this topic? I made the change add pickup time on single product and variations

keytronic avatar Sep 11 '24 17:09 keytronic