Skip to content

Instantly share code, notes, and snippets.

@goofmint

goofmint/index.js

Created Nov 14, 2017
Embed
What would you like to do?
// 支払い方法の設定
var supportedInstruments = [{
supportedMethods: ['basic-card']
data: {
supportedNetworks: [
'visa', 'mastercard', 'amex', 'discover',
'diners', 'jcb', 'unionpay'
]
}
}];
// 支払い情報について
var details = {
displayItems: [{
label: '元値',
amount: { currency: 'JPY', value: '6500' }
}, {
label: '割引',
amount: { currency: 'JPY', value: '-1000' }
}],
total: {
label: '合計',
amount: { currency: 'JPY', value : '5500' }
}
};
var request = new PaymentRequest(supportedInstruments, details);
request.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment