[PlayBilling] Total optional on only app-store billing requested
Context: Total is a field in the "new PaymentRequest()" API. It specifies the amount and currency of the payment request. However, when the merchant requests for the app-store billing (e.g., Google Play Store billing - by specifying "https://play.google.com/billing" as the method), the total field becomes unnecessary. This is because app-stores takes the total from elsewhere. Before: The total field is mandatory for PaymentRequest. After: The total field is optional if only app-store methods are requested. When total field is optional and left out, Chrome would add a total of amount 0, currency "ZZZ" and label "AppStoreBillingTotalPlaceHolder". Change: * Added a RuntimeEnabledFeature: PaymentRequestTotalOptional * Added an about flag: payment-request-optional-total * change the optionality of the total field and details field of PaymentRequest API. Related Doc: * Chrome Status: https://www.chromestatus.com/feature/5226111782879232 * Intent to Prototype: https://groups.google.com/a/chromium.org/forum/#!msg/blink-dev/TJVn0Ps9ugA/3unr2Vo8AgAJ * W3C explainer: https://github.com/w3c/payment-request/issues/912 Bug: 1066531 Change-Id: Id5ad87b9fc452fd41a1ebef066d981737545a235 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2150974Reviewed-by:Rouslan Solomakhin <rouslan@chromium.org> Reviewed-by:
Yaron Friedman <yfriedman@chromium.org> Reviewed-by:
David Bokan <bokan@chromium.org> Commit-Queue: Liquan (Max) Gu <maxlg@chromium.org> Cr-Commit-Position: refs/heads/master@{#769914}
Showing
Please register or sign in to comment