In the uc_cybersource.module, there are several calls to a variable named uc_cybersource_transaction_type. However, the variable name is actually uc_cybersource_hop_transaction_type

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

TR’s picture

Assigned: Unassigned » solotandem
victorforsythe’s picture

Is this true? do we have to change the variable name in the file? Please, are there any comments about this issue?

longwave’s picture

Are you using CyberSource? Are you having any problems with it? This seems like it would only affect things if you are using "Authorize only" mode in CyberSource, as opposed to "Authorize and capture".

terbs’s picture

Yeah I'm using authorize only and it was causing problems so I had to change the name of the variable to fix it. I really think it's just a small error in the code.

streamfan’s picture

Yes, I was having problems! I could not figure out why I could not only authorize charges.

There are some other related changes to be made in _uc_cybersource_post_charge. On line 657
$request['orderPage_transactionType'] = variable_get('uc_cybersource_transaction_type', 'sale')

if one changes it to

$request['orderPage_transactionType'] = variable_get('uc_cybersource_hop_transaction_type', 'sale')

that only uses the default value.

An array called $data gets passed in from function uc_credit_terminal_form_submit($form, &$form_state) in uc_credit_admin. It has an element of txn_type which determines whether its a sale (auth_capture) or just an authorization.

so in pseudo code something like
if ($data['txn_type') = 'auth_capture')
$request['orderPage_transactionType'] = 'sale';
else
$request['orderPage_transactionType'] = 'authorize';

This code is reached after I enter an order on an admin page and then view the order and select process card which goes to the /admin/store/orders/#ordernum/credit screen

This addressed the issue, Is there any work in progress that then allows one to capture the previously authorized charge? It looks like there is code in uc_credit_terminal_form_submit that addresses some of this. Not sure how to access it in Cybersource just yet.

ruichen’s picture

Category: bug » support
Priority: Normal » Critical

I have a hard time to make cybersource-hop.php issue work.

I already have my hop.php generated from my cb acct, and move it to the folder of
/var/www/html/0_supertex_beta/sites/all/modules/ubercart/payment/uc_cybersource/

I don't want to use silent order method

all I want is to have cybersource to handle the credit card.

but I don't know how to configure the settings under payment in my drupal site

do I also need to do a patch?

so confused...

Don't know where to find a complete document on setup/configure this payment with hop
and the ubercart's document's video tutorial with no sound.

Would you help?

ruichen

longwave’s picture

Category: support » bug
Priority: Critical » Normal

This issue is not related to getting CyberSource set up; please search drupal.org and ubercart.org for more info on how to configure CyberSource, if you still have problems then open a new support request with full details of what you've tried, any fields you are unsure how to fill in, or any error messages you receive.

longwave’s picture

Version: 6.x-2.7 » 6.x-2.x-dev
Assigned: solotandem » Unassigned
Status: Active » Needs review
FileSize
2.72 KB

Patch seems fairly straightforward, would be nice to get test results from someone if possible though.

longwave’s picture

Status: Needs review » Fixed

Committed to both branches.

Status: Fixed » Closed (fixed)

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