OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2016 The Chromium Authors. All rights reserved. | 2 * Copyright 2016 The Chromium Authors. All rights reserved. |
3 * Use of this source code is governed by a BSD-style license that can be | 3 * Use of this source code is governed by a BSD-style license that can be |
4 * found in the LICENSE file. | 4 * found in the LICENSE file. |
5 */ | 5 */ |
6 | 6 |
7 /* global PaymentRequest:false */ | 7 /* global PaymentRequest:false */ |
8 | 8 |
9 /** | 9 /** |
10 * Launches the PaymentRequest UI that offers free shipping in California and | 10 * Launches the PaymentRequest UI that offers free shipping in California and |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
76 } else { | 76 } else { |
77 shippingOption.id = 'usShippingOption'; | 77 shippingOption.id = 'usShippingOption'; |
78 shippingOption.label = 'Standard shipping in US'; | 78 shippingOption.label = 'Standard shipping in US'; |
79 shippingOption.amount.value = '5.00'; | 79 shippingOption.amount.value = '5.00'; |
80 details.total.amount.value = '10.00'; | 80 details.total.amount.value = '10.00'; |
81 } | 81 } |
82 details.displayItems.splice(0, 1, shippingOption); | 82 details.displayItems.splice(0, 1, shippingOption); |
83 details.shippingOptions = [shippingOption]; | 83 details.shippingOptions = [shippingOption]; |
84 } else { | 84 } else { |
85 delete details.shippingOptions; | 85 delete details.shippingOptions; |
| 86 details.error = 'We do not ship to this address'; |
86 } | 87 } |
87 return details; | 88 return details; |
88 } | 89 } |
OLD | NEW |