CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviContribute (Moderator: Donald Lobo) »
  • CiviCRM / PayJunction Need for Consistency in Transaction Results
Pages: [1]

Author Topic: CiviCRM / PayJunction Need for Consistency in Transaction Results  (Read 962 times)

mdlueck

  • Ask me questions
  • ****
  • Posts: 382
  • Karma: 4
  • CiviCRM version: 4.7.24
  • CMS version: Drupal 6.x
  • MySQL version: 5.5.54
  • PHP version: 5.3.10
CiviCRM / PayJunction Need for Consistency in Transaction Results
April 26, 2011, 01:41:07 pm
We are making progress on getting the issues worked out in our CiviContribute forms. Today PayJunction sent us an Rx of how to do yearly site memberships correctly. http://forum.civicrm.org/index.php/topic,19673.msg81879.html Now those charges go through to PayJunction correctly. Woo hoo!!!!

We see a noticeable difference between simple Donation transactions and Site Membership transactions:
1) The simple Donation transactions CONSISTENTLY get to "Completed" state in CiviCRM
2) Site membership transactions get stuck in "Pending" state in CiviCRM

Alex from PayJunction sends the following message:

Quote
Hi Michael,

I do see the yearly membership, it was charged today for $135, and it was setup in Recurring. It is scheduled to process again on 4/26/2012.

As you mentioned in the Forum, PayJunction does not return an IPN, and we do not eventually respond with an IPN. We will need to see if Donald Lobo can possibly help with letting us know which files (or code/modules) needs to be updated in order to set the state to "Completed" rather than setting it to "Pending" once a transaction has taken place.

It sounds like, if the module is able to automatically update the transaction all the way through to "completed" state, then it may be possible that everything else will work correctly. Otherwise, Susan will need to continue to update the status to Completed manually.

However, we would like to know if Lobo can  provide some insight on which file(s)/code will need to be updated in order to make sure that everything works correctly if we were to do this. Or, we would like to know if it is simply not possible to "automatically" update the status of a transaction to "Completed" once a transaction has taken place, and if instead, it does require that an individual manually update the status to "Completed".

Please advise.

With Kindest Regards,
Alex Estrada

Senior Tech Support Rep
PayJunction, Inc.

That was such a positive response from them, I thought to pass the query along in its entirety, and even set the message icon to a Smiley  :)

It seems we are SO CLOSE... just a bit out of place somewhere and this web site will be finally working properly... I hope!
« Last Edit: April 26, 2011, 01:43:51 pm by mdlueck »
--
Michael Lueck
Lueck Data Systems
http://www.lueckdatasystems.com/

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: CiviCRM / PayJunction Need for Consistency in Transaction Results
April 26, 2011, 02:49:10 pm

i would check the file

CRM/Core/Payment/PayJunction.php

a bit more carefully and fix that code (see the function checkResult)

seems like it always returns that the payment succeeded irrespective of the status.

Also for direct payment processors (like payjunction), i dont think we set pending status (i might be wrong here)

I think you might need to trace thru the code and see what payjunction returns and what w do and where/when/how the pending status is set
 
lobo

A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

mdlueck

  • Ask me questions
  • ****
  • Posts: 382
  • Karma: 4
  • CiviCRM version: 4.7.24
  • CMS version: Drupal 6.x
  • MySQL version: 5.5.54
  • PHP version: 5.3.10
Re: CiviCRM / PayJunction Need for Consistency in Transaction Results
May 12, 2011, 12:58:10 pm
Another reply from Alex at PayJunction as follows:

Quote
Hi Michael,

I've looked at the file (CRM/Core/Payment/PayJunction.php) and its difficult for me to determine what to actually change in order to make this work.

I'm not a CiviCRM developer, so I dont know a lot of the backend API/Vars/etc.

I looked at other modules and found that some of them use the following variable:

$statusName = 'Completed';

I'm assuming that this is a variable/setting that we need to also add/update within the PayJunction module. However, I'm not sure where to implement this within the existing Module. My guess is that it would be somewhere within the following:

// Success
      $params['trxn_result_code'] = $pjpgResponse['dc_response_code'];
      $params['trxn_id']          = $pjpgResponse['dc_transaction_id'];
      $params['gross_amount'  ]   = $params['amount'];
     

Maybe, add something like the following? :  $params['statusName' ]   = 'Completed';

The other option that I'm thinking may be where we need to update this is somewhere within the following If clause:

// create recurring object
      if ($params['is_recur'] == true && $params['installments'] > 1) {     
   
However, I'm not sure how we would actually set the stage to Completed.
Can we do this? :  $params['statusName' ]   = 'Completed';

We would need an actual CiviCRM developer to take a look at this in order to indicate if my assumptions are correct. And if so, how to actually implement the call to set the transaction to "Completed" for a membership type

With Kindest Regards,
Alex Estrada

Senior Tech Support Rep
PayJunction, Inc.

I saw that Michael Morris and Gene Chi of Phase2 Technology, LLC contributed this code. I had a brief email dialog with Michael Morris concerning the add-on module for recurring payments. He said that particular module was last used by a client running Drupal 5 / Civi 1.9. I never heard back from him as to what timer mode his module was assisting with, however I am guessing that his module was assisting with CiviCRM running the recurring timer, and we are running with PayJunction controlling the recurring timer.

Anyway, perhaps few/no one is actually using PayJunction as a CC gateway with current builds of Civi? (shrug)

As usual, I will forward replies back to Alex / Pay Junction. Thank you in advance.
--
Michael Lueck
Lueck Data Systems
http://www.lueckdatasystems.com/

mdlueck

  • Ask me questions
  • ****
  • Posts: 382
  • Karma: 4
  • CiviCRM version: 4.7.24
  • CMS version: Drupal 6.x
  • MySQL version: 5.5.54
  • PHP version: 5.3.10
Re: CiviCRM / PayJunction Need for Consistency in Transaction Results
May 23, 2011, 09:51:05 am
Could we please get an update on this so we can send a reply back to Pay Junction?

thanks!
--
Michael Lueck
Lueck Data Systems
http://www.lueckdatasystems.com/

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: CiviCRM / PayJunction Need for Consistency in Transaction Results
May 23, 2011, 11:24:46 am

Since payjunction is community supported and not too many folks seems to be using it, your best bet might be to see how something similar is handled with paypal pro and then ensure PJ does the same thing

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

mdlueck

  • Ask me questions
  • ****
  • Posts: 382
  • Karma: 4
  • CiviCRM version: 4.7.24
  • CMS version: Drupal 6.x
  • MySQL version: 5.5.54
  • PHP version: 5.3.10
Re: CiviCRM / PayJunction Need for Consistency in Transaction Results
May 23, 2011, 03:01:06 pm
(sigh) ack your reply, passed it along to PJ...
--
Michael Lueck
Lueck Data Systems
http://www.lueckdatasystems.com/

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviContribute (Moderator: Donald Lobo) »
  • CiviCRM / PayJunction Need for Consistency in Transaction Results

This forum was archived on 2017-11-26.