Hello,

First all, id like to say you guys did an awesome job with this new ecommerce script.

I created a custom payment method, although when creating it I would've enjoy having an extra argument somewhere in the hook_submit_form.

That argument would tell us if the form is being callback from the administration or is it being called by a front end user. Adding the argument in the form: commerce_payment_order_transaction_add_form where the commerce_payment_method_callback is being called.

If there is one already please let me know.

Thanks.

CommentFileSizeAuthor
#2 doc.patch615 byteswebadpro

Comments

damien tournoud’s picture

Thanks for reporting this. Actually, the $checkout_pane argument of CALLBACK_commerce_payment_method_submit_form() will be NULL for admin-submitted payments. You can rely on this.

Could you please roll a patch for the documentation block of CALLBACK_commerce_payment_method_submit_form() to make this clear?

webadpro’s picture

StatusFileSize
new615 bytes

I think this should work.

damien tournoud’s picture

Status: Active » Fixed

Thanks for the patch! I reformatted it to fit in the 80 column limit, and merged it into 7.x-1.x.

webadpro’s picture

Great and thanks for the tip of 80 column limit. I wasn't aware of that.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

Minor Error