I get the js error message above on line 61.
Why do you add "uc_paymant.js" in theme_uc_bank_transfer_receive_bank_transfer_form()?

Comments

xibun’s picture

Status: Active » Postponed (maintainer needs more info)

can you please describe the steps necessary to recreate this error? (please also list the SW versions used)

checker’s picture

Sorry for missing information. I get this error on the "admin/store/orders/%/payments". After you click the link "receive bank transfer" on the order view. In theme_uc_bank_transfer_receive_bank_transfer_form() you call uc_paymant.js with drupal_add_js() that causes this error. So I'm asking myself why you need there that script.

xibun’s picture

Status: Postponed (maintainer needs more info) » Active

will have to check (maybe someone else finds the time before me...) - only thing I can say right now is that it works perfectly on our live site (http://www.seizpacks.com)

checker’s picture

Do you override theme_uc_bank_transfer_receive_bank_transfer_form in another module or theme?

xibun’s picture

Just to make sure.. I'm using Drupal 6.19, Ubercart 2.4 and Bank Transfer 1.0beta2.

I've done a quick check to make sure my mind is not playing a trick on me and I cannot reproduce the error here.

As far as I remember I don't override that theme function.

xibun’s picture

and I did another quick test: just removing that line doesn't hurt the functionality in our case - so I guess you are right that it's there for "historic" reason only...

xibun’s picture

Status: Active » Postponed (maintainer needs more info)

I think I found the origin / reason why "uc_paymant.js" is added: there is a similar payment method in the Ubercart payment pack (COD - check).
-> file uc_payment_pack.admin.inc - function theme_uc_payment_pack_receive_check_form()

so I guess we have to file the bug against Ubercart - or do you see a reason why they need it there and we don't need it here ?

(in other words: it seems both payment methods or none of them needs the .js - and therefor I will not remove it as long as Ubercart includes it...)

xibun’s picture

related to this issue is this one: #1416298: Warning upon receiving payment. since Ubercart 7.x-3.0-rc1 uc_payment.js is history. (= removed from both ubercart and uc_bank_transfer)

still, as long is it is not causing any real problems for the Ubercart 6.x-2.x version I will not dig deeper and just leave it as it is.