If you're here searching for "ZZZ_ORDERID", then you'll need to add the ZZZ_ORDERID reference to your cashnet configuration.
The following two variables are posted:
'ref1type1' => 'ZZZ_ORDERID'
'ref1val1' => $order->order_id

Now that that is out of the way, this should probably be configurable. The user should also be able to add more variables to the form post without hacking the module. Each variable would then get its own set of ref#type1 and ref#var1 variables in the post.

Comments

millenniumtree’s picture

Status: Active » Needs work
StatusFileSize
new2.72 KB

...and of course, I wrote a patch

In the CASHNet configuration (admin/store/settings/payment/edit/methods), I've added a field for the Order ID code and defaulted it to 'ZZZ_ORDERID'. This variable is always posted as ref1type1/ref1var1, just as before, but now you can change ZZZ_ORDERID to anything you like.

I also added a couple of additional optional fields - email and name - our implementation required these two. Again, you can specify any variable you like for them - We used EMAIL_G and NAME_G
I hope the code doesn't freak anyone out - I sometimes over-engineer things. To add even more variables would be quite simple, just by adding a couple of lines in the module.

If you can make use of this, please let me know.

chrisfromredfin’s picture

Hey there - I apparently never turned on notifications for this issue queue and am just seeing these issues now! Going to take a look at this stuff tomorrow... initially the patch seems OK although I may try and make the custom variables even more flexible/configurable still.

chrisfromredfin’s picture

Status: Needs work » Fixed

started with this patch and merely added some help text to the "additional variables" section so people would know how it applied to the generated code. thanks for giving back, millenniumtree!

Status: Fixed » Closed (fixed)

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