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

Coupons are being floored (2.75 becomes 2.00) #515

Open
vcardillo opened this issue Feb 24, 2016 · 1 comment
Open

Coupons are being floored (2.75 becomes 2.00) #515

vcardillo opened this issue Feb 24, 2016 · 1 comment

Comments

@vcardillo
Copy link
Member

I've checked, and there appears to be a bug in both Android ​_and_​ iOS where coupons with cents (e.g. $2.75) are being floored (e.g. to $2.00). (edited)

[10:11]
The backend is returning the float as a string, but it seems like you guys are casting it to an int

https://bentonow.slack.com/archives/engineering/p1456294206000002

@josephlausf
Copy link
Contributor

fixed

simulator screen shot feb 24 2016 11 22 50 am

{"data":"{\"Stripe\":{\"stripeToken\":\"NULL\"},\"OrderDetails\":{\"tax_percentage\":\"8.75\",\"delivery_price\":\"1.99\",\"tax_cents\":\"98\",\"total_cents\":\"1447\",\"coords\":{\"lat\":\"37.787360\",\"long\":\"-122.408219\"},\"items_total\":\"15.00\",\"address\":{\"number\":\"246-298\",\"state\":\"CA\",\"street\":\"Powell Street\",\"city\":\"San Francisco\",\"zip\":\"94102\"},\"subtotal\":\"12.22\",\"tip_cents\":\"225\",\"total_cents_without_coupon\":\"2073\",\"tip_percentage\":\"15\",\"coupon_discount_cents\":\"575\"},\"order_type\":\"2\",\"OrderItems\":[{\"items\":[{\"id\":\"58\",\"type\":\"main\",\"name\":\"Hawaiian Shrimp Poke\"},{\"id\":\"62\",\"type\":\"side1\",\"name\":\"Cucumber Salad\"},{\"id\":\"60\",\"type\":\"side2\",\"name\":\"Dungeness Crab Roll\"},{\"id\":\"1\",\"type\":\"side3\",\"name\":\"Eggplant\"},{\"id\":\"48\",\"type\":\"side4\",\"name\":\"Enoki Mushrooms\"}],\"unit_price\":\"15.00\",\"item_type\":\"CustomerBentoBox\"}],\"AppVersion\":\"2.68\",\"kitchen\":\"1\",\"CouponCode\":\"ridev\",\"for_date\":\"2016-02-25\",\"Platform\":\"iOS\",\"scheduled_window_start\":\"11:00\",\"scheduled_window_end\":\"12:00\",\"OrderAheadZone\":\"1\",\"Eta\":{\"min\":\"15\",\"max\":\"25\"},\"MenuId\":\"321\",\"IdempotentToken\":\"CB6B7791-B0F7-427B-9D6E-959450996C69\"}"}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants