the following is from a kind review by rszrama:

Instead of using a custom table to track incoming bank transfers, you could create on submit a "pending" payment transaction for the order with the message being something along the lines of "Awaiting bank transfer from customer." This will then show up on the order's Payment tab. Then you can define a local action for the transaction that lets the administrator mark when a payment has been received. This would work similar to the local action menu items in my commerce_authnet module for capturing / voiding / crediting against an existing transaction. If you do this, you can get rid of your custom table altogether, making your .install just a removal of variables.

Additionally, if you aren't using a callback, it doesn't have to be present. So, if you do what I recommend above, you'll keep the submit_form_submit callback but can remove the submit_form_validate callback.

I don't have time to work on this in the near future.. hope someone can step up with a patch for this!

Comments

yannisc’s picture

I think it would be best to have the bank details shown on checkout completion page, set the order in pending state and send bank details to the email as well.

I'm trying to do the above, but I'm stuck as I don't know which hook to use to alter to show the bank details at the checkout completion page.

I tried the hook_commerce_checkout_page_info_alter hook, but it seems that this function doesn't have access to the bank details array.

stroobl’s picture

Status: Active » Needs work
StatusFileSize
new1.88 KB

This patch creates the transaction in commerce_payment_transaction in a pending state and removes submit_form_validate. I guess you can also remove the table commerce_payment_bank_transfer from the module .install file if you use this.
I still have to find out how to define the action that allows to set the payment status from pending to success.

stroobl’s picture

Status: Needs work » Needs review
StatusFileSize
new7.3 KB

This should be the complete patch. You can now confirm a payment with the "Confirm payment" link in an order's payment tab.

xibun’s picture

thanks stroobl! I will try to review this weekend.

xibun’s picture

Status: Needs review » Fixed

works perfectly on my localhost. patch committed. thanks again.

@yannisc: please open (a) new issue(s) for the tasks you mentioned. the original intent of this issue was addressed by stroobl's patch.

-otto-’s picture

Hi,

the 'confirm payment' link also shows up for other payment methods which do not need this link.
I've tried to find a fix for this, but so far, no luck. There should be a check somewhere in the code to only show this link for bank transfer payment method.

Any suggestions?

xibun’s picture

Status: Fixed » Needs work

let me revert the state of the issue so we don't loose it out of sight.

svendecabooter’s picture

subscribe

thimothoeye’s picture

Status: Needs work » Needs review
StatusFileSize
new2.27 KB

This removes the link for transactions that aren't bank transfers and haven't been completed. I changed the access callback function to outrule other transactions.

pardalman’s picture

subs

derjochenmeyer’s picture

Status: Needs review » Reviewed & tested by the community

looks good to me

svendecabooter’s picture

Status: Reviewed & tested by the community » Needs review
StatusFileSize
new1.89 KB

Here is an updated patch, because the patch above doesn't work with the latest code of Drupal Commerce.
Specifically the access callback function parameters changed in #1252226: commerce_payment_transaction entity specifies invalid access callback.

Anonymous’s picture

Title: introduce Commerce's method of handling payments » Prevent payment confirmation link appearing on other payment types
Version: 7.x-1.0-alpha1 » 7.x-1.0-alpha2
Category: task » bug
Priority: Normal » Major
Status: Needs review » Reviewed & tested by the community

I manually applied the patch from #12 and it worked for me!

xibun’s picture

Priority: Major » Normal
Status: Reviewed & tested by the community » Fixed

thanks thimothoeye and svendecabooter! patch committed.

Status: Fixed » Closed (fixed)

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