Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

E-Commerce Modules

Discuss about the various e-commerce modules available:
Ecommerce, SS Shop, SilverCart and SwipeStripe
Alternatively, have a look the shared mailinglist.

Moderators: martimiz, Nicolaas, Sean, frankmullenger, biapar, Willr, Ingo, Jedateach, swaiba, simon_w

Removing Products once "purchased"


3 Posts   919 Views


17 December 2009 at 10:35am Community Member, 61 Posts

I am using the silverstripe ecommerce module as a basis for an orphan sponsorship site, so that each orphan is a "product". This means that once a orphan is sponsored that it needs to be removed from the site.

Is there anyway to set "Allow product to be purchased" to '0' on successful payment??

Any help on this would be appreciated as its for a good cause.



17 December 2009 at 10:37am Community Member, 61 Posts

In addition, I have just checked and have realised that I need to unpublish the "product" rather than update the "can be purchased" box as this leaves the item on the list and just removes the "buy now" image.


29 December 2009 at 2:59am Community Member, 61 Posts

I've just changed my code so that the "product cannot be purchased" will remove the product from the list.

So all I need to do now is update this field on successful purchase (I think at the same time as the products are being added to the orderAttributes table??)

Any help would be appreciated