Page MenuHomePhabricator

Extra decimals on Other amount field gets PTF riled up
Open, Needs TriagePublic

Description

The donor in 775605 pointed out that the form from
https://en.wikipedia.org/wiki/Taj_Mahal?banner=B2021_0721_enIN_dsk_p1_lg_pwk_cnt&force=1&country=IN behaves strangely if you add more than two digits after a decimal point or comma in the Other field. The PTF suggestion amount becomes larger than the donation amount. With more digits the PTF keeps scaling up.

This is not a high priority issue, and Rakhi kindly asked the donor to not 'hack' the Other amount by adding extra decimals, but just as a heads up/fyi Task.

Event Timeline

I believe this is due to the fact that some places '.' or ',' is used for the thousand mark, so after adding 3 chars after the decimal it's converting to thousand? Is that what's going on here @Pcoombe?

I believe this is due to the fact that some places '.' or ',' is used for the thousand mark, so after adding 3 chars after the decimal it's converting to thousand? Is that what's going on here @Pcoombe?

Exactly.

Is is possible to limit it to two digits after the "." or "," so that punctuation is only used for decimals of the currency and not whole amounts? ie. not used to separate thousands? Or are they standard in some places? Can we see if donors insert these commas or periods regularly for denominations into the thousands?

I feel it would be easier to deal with donors asking why the form didn't accept their amount and say that no punctuation is required for whole amounts into the thousands than refund those who accidentally give a way higher amount. That said, volume is not high on these at all!

  • Can get very tricky, so we should approach this with care
  • We could try checking their locale and seeing what decimal separator is expected for the appropriate currency ... could introduce more problems.
Pcoombe renamed this task from India banner: extra decimals on Other amount field gets PTF riled up to Extra decimals on Other amount field gets PTF riled up.Aug 20 2020, 2:59 PM

In today's EN6C banner test, donor #866462 reported (and we are able to reproduce) that adding a trailing '0' to the end of an Other amount multiplies the amount by 1000, i.e. $2.760 becomes $2,760.00

https://en.m.wikipedia.org/wiki/Wikipedia?banner=B2021_112115_en6C_m_p1_lg_amt_7&country=US

As a point of reference, noting that this issue has been present in banners since at least 2017, even prior to implementation of the Pay The Fee feature. Here's an example from December 2017 in which you can produce the issue.

It seems that volume of donors reporting this is not high; and as KRobinson mentioned in today's standup, donors tend to notice pretty quickly!