Fixed cost for up to 5 sample products - using buybutton.js and JS Buy SK

HolstDigital
Visitor
2 0 0

Currently, I add a 'buy sample' button beneath the 'buy button' once it's rendered.

A click event on this button currently adds a single sample to the buybutton.js cart - this is working fine (sample is setup as a variant).

However, my client wants to set up a rule where customers can buy up to a maximum of 5 samples (these are posted in a box that can only fit up to 5 samples).

This order of samples will always cost £5, even if they decide to buy less than 5 samples due to the size of the box the sample come in and the associated postage fees.

Any help on this would be tremendously appreciated - open to using storefront API buybutton buy js etc...

 

 

Replies 2 (2)

AlexHodzitsky
Shopify Partner
72 19 27

Hi HolstDigital! Hope you are doing well!

Should the user, for example, be able to add 7 samples to the cart to place it as one order, but at the same time these products will be divided into two boxes by 5 and 2 samples and the price for it will be £10?

I didn't choose the Shopify, the Shopify chose me.
Linkedin: alex-hodzitsky
HolstDigital
Visitor
2 0 0

Hey Alex!

Thanks for the reply.

My client's happy with only giving customers the option to buy up to 5 samples. They don't really want users to order more than that.

Obviously, If a customer does want more, they can always do this through a separate checkout process. 

Hope that helps?