...
|
...
|
@@ -5,7 +5,8 @@ |
|
|
*/
|
|
|
|
|
|
var $ = require('yoho-jquery');
|
|
|
var Hbs = require('yoho-handlebars');
|
|
|
var Hbs = require('yoho-handlebars'),
|
|
|
dialog = require('../common/dialog');
|
|
|
|
|
|
var $balanceDetail = $('#balance-detail'),
|
|
|
$orderPrice = $('#order-price');
|
...
|
...
|
@@ -577,9 +578,43 @@ $('#order-submit').click(function() { |
|
|
url: '/cart/ensure/submit',
|
|
|
data: order
|
|
|
}).then(function(data) {
|
|
|
var rdata, subTip;
|
|
|
|
|
|
if (data.code === 200) {
|
|
|
rdata = data.data;
|
|
|
if (rdata && rdata.is_hint === 'Y') {
|
|
|
if(rdata.hintInfo) {
|
|
|
subTip = rdata.hintInfo.productName || '';
|
|
|
|
|
|
if(subTip && subTip.length > 20) {
|
|
|
subTip = subTip.substr(0, 20) + '...';
|
|
|
}
|
|
|
subTip += rdata.hintInfo.suffix + '<br/>' + rdata.hintInfo.lastLine;
|
|
|
}
|
|
|
|
|
|
new dialog.Dialog({
|
|
|
content: subTip,
|
|
|
className: 'ensure-hint-confirm',
|
|
|
btns: [{
|
|
|
btnClass: ['confirm-sure'],
|
|
|
name: '重新选择商品',
|
|
|
cb: function() {
|
|
|
$('#go-cart-btn').trigger('click');
|
|
|
}
|
|
|
}, {
|
|
|
btnClass: ['confirm-cancel'],
|
|
|
name: '继续结算',
|
|
|
cb: function() {
|
|
|
order.continueBuy = true;
|
|
|
$('#order-submit').trigger('click');
|
|
|
}
|
|
|
}]
|
|
|
}).show();
|
|
|
|
|
|
} else {
|
|
|
location.href = data.data.url;
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
});
|
|
|
|
...
|
...
|
|