I'm developing a payment gateway for a Danish provider. There seems to be some interest in the Danish Drupal community for an official gateway (as there is none), so this provider has generously sponsored development of both ECommerce and Übercart modules. But I have some issues with UC:
Firstly, I thought it would just be a matter of implementing a gateway for uc_credit, and let that deal with all the card stuff, and just handle the processing. However looking at the uc_credit code, I see that it stores the card information in the database, and according to PBS (the entity all Danish gateways talk to), that's a big nono.. They're scared enough letting people handle the card data for an instant, if you're actually storing it anywhere, you have to pay big bucks and spend a lot of man hours convincing them that you have a secure setup.
So my only option is to create a fullblown payment gateway from scratch and not get any of the niceness of uc_credit, if I'm gonna make sure that the card data only ever go from $_POST to the gateway HTTPS call?
Secondly, the way uc_payment works, it calls a processing function in the gateway module, and if it returns 'OK', it does an uc_payment_enter to enter the payment on the balance. As far as I can see, the way it deals with the minor difference between an authorization and an captured payment is that it doesn't? I've figured out (with some help) that people handle the capture part by using Workflows, but I don't get how they manage to make their order balance not even out at checkout?
Well, actually, I just thought of a possible way: defining my *_charge function to take $amount as a reference, and then set it to 0 if I'm just authorizing, but that feels rather hacky..
So what am I missing?
Oh, and if someone could give a pointer to where too hook in the capture buttons (form_altering uc_payment_by_order_form?), I'd be very grateful.




Joined: 02/22/2008