Tim,
   I'm not sure, but that sounds similar to what some of the salesforce
integration does.  Essentially when the user adds an item to the cart that
we want transfered to salesforce we annotate the cart with the information
we'll need later.  We then subscribe to one of the finance workflow events
that signals a successful charge, and in that method pull the data out of
the annotation and save it to salesforce.

So for you I'd assume you could follow a similar pattern.  I'd checkout
getpaid.SalesforcePloneFormGenAdapter or getpaid.SalesforceOrderRecorder and
see if the pattern works for your case.

-Rob

On Mon, Mar 1, 2010 at 2:17 AM, Tim Knapp <[email protected]> wrote:

> Hi,
>
> I've finally started to opensource my subscribemember tool[1] package
> now and though the code has been in production use now for 8+ months and
> works fine I'm trying to genericise the code now to work with any of the
> getpaid payment processors.
>
> The codebase as it stands is hardcoded to work with getpaid.paypal and
> it does this by overriding the whole checkout process[2], injecting the
> Products.remember-based object into the cart (it already has the
> required getpaid fields on it) and then sending the user off to paypal
> whereupon finishing payment the remember-based user is given the correct
> roles[3] to access the site. What I was thinking otoh to set this up in
> a more generic fashion was to have a subscriber for say the
> IPrincipalCreated and whatever would be a good interface from getpaid
> (checkout one?) and then do the injection of the remember object into
> the cart and carry on the checkout process. This may very well not be
> possible (as I think I've investigated something along these lines in
> the past) so I was wondering if anyone had any suggestions on how I
> could achieve this?
>
> Thanks,
> Tim
>
> [1]
> http://dev.plone.org/collective/browser/collective.subscribemember/trunk
> [2]
>
> http://dev.plone.org/collective/browser/collective.subscribemember/trunk/collective/subscribemember/browser/checkout.py
> [3]
>
> http://dev.plone.org/collective/browser/collective.subscribemember/trunk/collective/subscribemember/subscribers.py#L50
>
> --
> GetPaid for Plone: http://www.plonegetpaid.com (overview info) |
> http://code.google.com/p/getpaid (code and issue tracker)
> You received this message because you are subscribed to the Google Groups
> "getpaid-dev" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]<getpaid-dev%[email protected]>
>
> For more options, visit this group at
> http://groups.google.com/group/getpaid-dev?hl=en?hl=en
>

-- 
GetPaid for Plone: http://www.plonegetpaid.com (overview info) | 
http://code.google.com/p/getpaid (code and issue tracker)
You received this message because you are subscribed to the Google Groups 
"getpaid-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]

For more options, visit this group at
http://groups.google.com/group/getpaid-dev?hl=en?hl=en

Reply via email to