Add mobile commerce in payment tool string (#101)
This commit is contained in:
parent
dc2c6720f1
commit
d337be8f03
@ -181,6 +181,10 @@ public class PaymentToolUtils {
|
|||||||
} else if (paymentTool.isSetCryptoCurrency()) {
|
} else if (paymentTool.isSetCryptoCurrency()) {
|
||||||
rootNode.put("type", "crypto_currency");
|
rootNode.put("type", "crypto_currency");
|
||||||
rootNode.put("crypto_currency", paymentTool.getCryptoCurrency().name());
|
rootNode.put("crypto_currency", paymentTool.getCryptoCurrency().name());
|
||||||
|
} else if (paymentTool.isSetMobileCommerce()) {
|
||||||
|
rootNode.put("type", "mobile_commerce");
|
||||||
|
MobilePhone mobilePhone = paymentTool.getMobileCommerce().getPhone();
|
||||||
|
rootNode.put("mobile_commerce", mobilePhone.getCc() + mobilePhone.getCtn());
|
||||||
} else {
|
} else {
|
||||||
throw new UnsupportedOperationException("Unknown payment tool type. Must be bank card, terminal or digital wallet");
|
throw new UnsupportedOperationException("Unknown payment tool type. Must be bank card, terminal or digital wallet");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user