Forum Academy Marketplace Showcase Pricing Features

How to make a button unclickable when an alert text box appear

hi I’m working in a marketplace template customisation.

I’ve got a question on the checkout step: when buyer A’s cart item was just bought by buyer B before buyer A checkout, then buyer A will see an alert when he is checking out:

Then before buyer A adjust/remove the cart item, he should not be able to click the “Checkout” button.

So how to make the “Checkout” button unclickable when the text alert show? Because the text altert is in repeating group, I can not find it in the checkout button conditions:

Or how to develop a custom workflow?

Can someone help? Thanks


If the product is bought by Buyer B then this product is no longer available in the Buyer B cart.
It contains of Buyer A. So your condition will get fail.

So try to manage some field in product table called sold-out with boolean to ensure it will be not available for Buyer A and disable the checkout button.

Hope this help you.

hi mani, thanks for the reply. I’ve add a new “Sold-out” field in item, with default setting as “no”.

Could you advise how to change the item status to “yes” after one buyer place the order and deplete certain item’s stock? I have Item Stock field in data.

Was trying to set state in the check-out page after one buyer placed order, but couldn’t link the sold-out boolean with the workflow…

While someone placing the order, after deducting the quantity from stock, check if the stock is 0. If it’s 0, Sold-out = yes

Try to add “do workflow action” to the Checkout Page with if any of the cart item is sold-out (yes means no productis availableto place this order, no then allow the order to take place) then just disable the button.

It can work with cart items :filtered with sold-out =yes >0

This topic was automatically closed after 70 days. New replies are no longer allowed.