From 6cf5971d61c85c3a426ab461c725143608a2201b Mon Sep 17 00:00:00 2001 From: Ade Bateman Date: Fri, 16 Sep 2016 18:25:01 -0700 Subject: [PATCH] Add support for currency system. Fixes #185. --- index.html | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/index.html b/index.html index 692e2732..54fee5d8 100644 --- a/index.html +++ b/index.html @@ -634,10 +634,11 @@

PaymentMethodData dictionary

PaymentCurrencyAmount

-dictionary PaymentCurrencyAmount {
-  required DOMString currency;
-  required DOMString value;
-};
+        dictionary PaymentCurrencyAmount {
+          required DOMString currency;
+          required DOMString value;
+          DOMString currencySystem = "urn:iso:std:iso:4217";
+        };
       

A PaymentCurrencyAmount dictionary is used to supply monetary amounts. @@ -646,13 +647,20 @@

PaymentCurrencyAmount

The following fields are required:

-
currency
+
currencySystem
+
+ currencySystem is a URL that indicates the currency system that the + currency identifier belongs to. By default, the value is + urn:iso:std:iso:4217 indicating that currency + is defined by [[ISO4217]] (for example, USD for US Dollars). +
+
currency
- currency is a string containing a currency identifier. The most common - identifiers are three-letter alphabetic codes as defined by [[ISO4217]] (for example, - "USD" for US Dollars) however any string is considered valid. + currency is a string containing a currency identifier. The + value of currency can be any string that is valid within + the currency system indicated by currencySystem.
-
value
+
value
A valid decimal monetary value containing a monetary amount. A string is a valid decimal monetary value if it consists of the following components in the given order: