Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Send WorldPay emails to contact_email for AD renewals #278

Merged
merged 4 commits into from
Oct 8, 2018

Commits on Oct 5, 2018

  1. Send WorldPay emails to contact_email for AD renewals

    https://eaflood.atlassian.net/browse/WC-489
    
    Users sometimes go through the assisted digital route to renew because they cannot access their account. When a user goes through WorldPay for payment, we send the account email through to WorldPay, which it then uses to send confirmation of the payment. If the user is AD because they can't access the account, this makes the confirmation meaningless.
    
    So if a renewal is done via assisted digital, we should be passing the contact email to WorldPay, and not the account email.
    irisfaraway committed Oct 5, 2018
    Configuration menu
    Copy the full SHA
    a7bfff8 View commit details
    Browse the repository at this point in the history

Commits on Oct 8, 2018

  1. Add spec for AD renewals in WorldpayXmlService

    The XML should use a different email address when the renewal is AD, so we need a new fixture and a new spec.
    irisfaraway committed Oct 8, 2018
    Configuration menu
    Copy the full SHA
    58bf92b View commit details
    Browse the repository at this point in the history
  2. WorldpayXmlService now takes a current_user when initialising

    Improve the specs to handle this.
    irisfaraway committed Oct 8, 2018
    Configuration menu
    Copy the full SHA
    b91d40a View commit details
    Browse the repository at this point in the history
  3. Get different contact emails for digital and AD

    We do this by checking if the current user's email matches the renewal account email. If they do, then the user who owns the registration is doing the renewal and it must be digital. If they don't, then another user is doing the renewal on their behalf and it must be assisted digital.
    irisfaraway committed Oct 8, 2018
    Configuration menu
    Copy the full SHA
    3c51f38 View commit details
    Browse the repository at this point in the history