10 replies [Last post]
keyone's picture
Offline
Joined: 10/01/2008
Juice: 95
Was this information Helpful?

Hi, I have ubercart installed with ACL to grant access to nodes based on product purchases. Of course it works great whenever I test it. But staff at clients office all placed test orders, and it only worked for one of them. They did not get access to the node that was tied to the products.

Just looked thru the test orders. All have zero balances. All paid by credit card. I can't see any difference between the one that worked, and the others that did not work. The one that worked was placed last.

Could changing the name of the node cause uber cart not to be able to find it? I did notice that the link in the Features area of the product that says "Node access Grant indefinite access to node 710." is a bad link because the path of the node was changed. The nid did not change, so you can still get to the page via node/710/.

Could this be a workflow-ng problem? I've attached a screenshot. Thanks if you can help!

PreviewAttachmentSize
workflow.jpgworkflow.jpg65.91 KB
Ryan's picture
Offline
Joined: 08/07/2007
Juice: 15438
Re: Node Access based on purchase doesn't always work.

Curious... I've never really had issues with it. Were the ones that failed for logged in users?

keyone's picture
Offline
Joined: 10/01/2008
Juice: 95
Re: Re: Node Access based on purchase doesn't always work.

I dunno. But if I look at the node assigned to the product that the user purchased, and look at node access rights, nobody is assigned to that node...but there should be because somebody purchased that product! That's why I thought it might be a workflow problem.

Ryan's picture
Offline
Joined: 08/07/2007
Juice: 15438
Re: Re: Re: Node Access based on purchase doesn't always work.

Yeah... hmm... you're saying it's even going through the Workflow process to completed but never firing the node access grant?

keyone's picture
Offline
Joined: 10/01/2008
Juice: 95
Re: Re: Re: Re: Node Access based on purchase doesn't always wor

yes, that's what i'm saying. curiously, their is also a file download attached to the products. that does get 'fired' properly, and the users are able to get their files. If I do a test order paying by check, and then the store admin submits the payment, the node access does get properly assigned. But one of the test orders was a credit card order, and that one worked too. Bluh. Going to get my head in this now and try to debug. will post back if i figure it out. ty.

keyone's picture
Offline
Joined: 10/01/2008
Juice: 95
Re: Re: Re: Re: Re: Node Access based on purchase doesn't always

It appears that it does not work for credit card orders, but it does work for check orders (where the store admin goes in after the fact and inputs the payment, marking it complete). What does the 'Process Card' button do on the view order screen?

Ryan's picture
Offline
Joined: 08/07/2007
Juice: 15438
Re: Re: Re: Re: Re: Re: Node Access based on purchase doesn't al

That button takes you to a CC terminal to get payment. Do you have UC set to automatically charge CC's during checkout? If not, you should adjust that in your CC settings. You should see in the order comments whether or not payment was captured, and the order balance should be $0.00.

keyone's picture
Offline
Joined: 10/01/2008
Juice: 95
Re: Re: Re: Re: Re: Re: Re: Node Access based on purchase doesn'

The order balances are zero. And there is a message in the payment screen that says "Credit card payment processed successfully. Approval code: 51526C"

It's definitely a workflow thing. I've been adding new rules and testing. see attached screen cap.

#1) is the rule that was already there, and that one works. I can't recall if I added that, or if that got added when I installed the ubercart node access module. That is when the admin manually adds a payment.

#2) is a rule I added that should grant access when customer checks out and balance is <=0. Does not work.

#4) is a rule I added that should grant access when admin updates order status and balance is <=0. I was hoping admin could at least go in after the fact and trigger the grant. Does not work.

#3) is a rule I added by CLONING the #1 item. Note the yellow highlights...and what module is listed for the rule. I was hoping cloning the working rule would maintain the module, but note how the cloned rule changes the module from uc_node_access to workflow-ng. I did not test that rule, cuz I figured it was the same as #2.

AttachmentSize
screencap.jpg 58.92 KB
keyone's picture
Offline
Joined: 10/01/2008
Juice: 95
Re: Re: Re: Re: Re: Re: Re: Re: Node Access based on purchase do

another clue: it works fine with paypal. why does it work with paypal, pay by check, but not credit card!!!?? will keep digging.

keyone's picture
Offline
Joined: 10/01/2008
Juice: 95
Re: Node Access based on purchase doesn't always work.

Been banging my head about this alot! Another clue...

I notice that paypal, 2checkout modules contain this line of code

uc_cart_complete_sale($order);

where as authorize.net does not.

Part of what uc_cart_complete_sale does is set up a new account for new users. When I place a test order with credit card, it does indeed set up a new user account for me. So, I'm stumped. Wah, someone call the wahmublance!

Ryan's picture
Offline
Joined: 08/07/2007
Juice: 15438
Re: Re: Node Access based on purchase doesn't always work.

Auth.Net doesn't have to do it b/c it goes through the normal checkout process... PayPal and 2CO.com interrupt it as redirected payment methods.