Description: Staff role created a Donation Campaign.

1) As a donor, went to donation campaign and entered $1, then clicked on Donate Now.
2) Was taken to Paypal sandbox, entered info for cc payment. Donation total entered: 1.00 (One Dollar)
3) Went back to check on the donation on the Donations Received tab of the Donation Campaign, and find my donation, but the site lists it as a donation of $100.00 (One Hundred Dollars)!
4) Checked the Paypal sandbox confirmation page, which says donation of One Dollar.

Somehow it multiplied my one dollar donation by 100 in the site's Donations Received.

Comments

skjalf’s picture

Title: Donation amount shows up wrong on Donations Received » Donation amount multiplied by 100 on Donations Received tab

edit title for more clarity

seanberto’s picture

Issue is that Views does not convert back from cents to dollars....

seanberto’s picture

Status: Active » Fixed

Fixed with:
sean@sean-larkins-macbook:~/git/watershednow/drupal/sites/all/modules/contrib-patch$git commit -am "Fixing issue in http://drupal.org/node/960616#comment-3662200"
[master fca2028] Fixing issue in http://drupal.org/node/960616#comment-3662200
5 files changed, 99 insertions(+), 6 deletions(-)
create mode 100644 drupal/sites/all/modules/contrib-patch/simple_payments-int_to_decimal-960616.patch

seanberto’s picture

Title: Donation amount multiplied by 100 on Donations Received tab » Retest PayPal donations
Assigned: Unassigned » skjalf
Priority: Major » Critical
Status: Fixed » Active

Changing title to queue up for retesting.

seanberto’s picture

Component: Code » QA
seanberto’s picture

Assigned: skjalf » seanberto
seanberto’s picture

Assigned: seanberto » skjalf
seanberto’s picture

I'd still like to get another set of eyes on this, testing 1.5, 10.5, 100 donations. I've checked and it seems to work. but pretty critical, so worth getting another set of eyes on this.

seanberto’s picture

Priority: Critical » Major
skjalf’s picture

Assigned: skjalf » seanberto
Status: Active » Needs review

The major multiplication bug seems to be fixed. The amounts display correctly within the site but are not $DD.CC format (WSN displays least amount of decimals possible), however the math is right and the amounts match up.

Here's how it shows up-- value entered into WSN original donation page, value displayed on PayPal, and value displayed back on WSN. Passing it back to @seanberto for review and closing if this is acceptable.

Entered into WSN Amount displayed PP Amount displayed WSN
1.5 1.50 1.5
10.50 10.50 10.5
100 100.00 100
1 1.00 1
1.00 1.00 1
seanberto’s picture

Assigned: seanberto » skjalf

Not great, but okay for now. Really, we need more patches to Simple Payments.

Passing back to you to test the values presented in the Excel export.

skjalf’s picture

Assigned: skjalf » seanberto
Status: Needs review » Reviewed & tested by the community

Excel files download accurately with the values stored by Watershed Now (decimals rounded... i.e., $10.5, $100, etc) as shown above.

I think we can close? It looks like it is working as we expect. (Also, if that RTBC tag was the wrong one to assign.. sorry)

seanberto’s picture

Status: Reviewed & tested by the community » Closed (fixed)

Cool. Closing. Wheew, I'm glad my patch to simple payments worked....