Page MenuHomePhabricator

Minimum amount changes from CA donation form to Paypal
Closed, ResolvedPublic

Description

A donor reported and we replicated that the minimum CAD amount is different from our form to PayPal's. Can we reconcile this difference so that donors who adjust $1 CAD to $1.27 don't then get another message from Paypal?

Step1.png (930×2 px, 1 MB)

Step2.png (948×2 px, 237 KB)

Event Timeline

@Ejegg Where can I find the current minimum amounts so that I can update the checks on banners and donatewiki? I think they used to be in a file currencyMinimums.js in DonationInterface, but that doesn't seem to exist any more.

Ooh, right, that's now generated with a server-side module so we don't have to update twice every time. Can you try this?

mw.loader.using("ext.donationInterface.currencyRates")
    .then( function () {
        var minimums = mw.config.get('wgDonationInterfaceCurrencyRates');
        // do stuff with minimums['CAD']
    } );

Darn, that's not going to work unless they install the extension with all of the composer dependencies, and I don't think they've done that on donatewiki.

The stuff is all coming from this file, now part of SmashPig:
https://github.com/wikimedia/wikimedia-fundraising-SmashPig/blob/master/PaymentData/ReferenceData/CurrencyRates.php

DStrine moved this task from Triage to Blocked or not fr-tech on the Fundraising-Backlog board.

@Pcoombe OK, this works, if you're willing to wait for the payments-wiki request to come back:

$.getScript("https://payments.wikimedia.org/load.php?modules=ext.donationInterface.currencyRates", function() {
    var minimums = mw.config.get('wgDonationInterfaceCurrencyRates');
    // Do stuff with minimums['CAD']
});

Thanks @Ejegg. I've just copied the updated amounts into donatewiki and banners, since it seems they don't change very often and feels like overkill to add a request every time. I'll watch the file for changes.

One more thing: we have higher minimums for Astropay currencies, and it seems like those have changed too. Where can I find them?

@Pcoombe the AstroPay minimum is $1.50, so you can just multiply the regular ones by 1.5.

Pcoombe claimed this task.

Great, thanks. I've updated the minimum amounts in donatewiki and banners.