Support from Acquia helps fund testing for Drupal Acquia logo

Comments

s_leu created an issue. See original summary.

s_leu’s picture

Adding what i had so far.

Berdir’s picture

Status: Active » Needs work
  1. +++ b/src/Plugin/Payment/Method/DatatransXMLDeriver.php
    @@ -0,0 +1,83 @@
    +              'hmac_key_2' => $configuration_plugin->getHmacKeyTwo(),
    +              'use_hmac_2' => $configuration_plugin->getUseHmacTwo(),
    

    copied from the other one, but I'm pretty sure we will not need them. this was needed on the return page, to sign their response. That's not necessary, there is only one API call and their response to it.

  2. +++ b/src/Plugin/Payment/Method/DatatransXMLMethod.php
    @@ -0,0 +1,85 @@
    +    $request->addHeader('If-Modified-Since', gmdate(DATE_RFC1123, $last_fetched));
    

    I don't think we need this, just $client->post() is probably enough?

Arla’s picture

FileSize
9.59 KB

Removed hmac2 parameters. Also made other changes while testing. Still not fully functional.

Arla’s picture

Uh, both patches are bad. Remaking, with interdiff.

Arla’s picture

FileSize
1.5 KB
25.97 KB

Tested a bit, had to change the request XML.

Berdir’s picture

Status: Needs work » Needs review
FileSize
44.64 KB
10.88 KB

This is the working patch, fixed some bugs, renamed and removed some configuration variables.

Yes, the broken aliases are indeed a test account problem, works with a different test account that I have.

Berdir’s picture

That patch was wrong, another try.

  • Berdir committed 4527d41 on 8.x-1.x
    Issue #2688495 by Arla, Berdir, s_leu: Add XML payment method
    
Berdir’s picture

Status: Needs review » Fixed

Committed.

Status: Fixed » Closed (fixed)

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