Authored by Aiden Xu

分期订单

... ... @@ -59,8 +59,8 @@ $('.status').each(function() {
$(CHECKBOX_SELECTOR + ':checkbox').click(function() {
// var selection = repayment.getSelection();
// var isSkipped = false;
// var curSel = $(this).data('sortId');
// var isChecked = $(this).is(':checked');
//
//
//
// if (isChecked && selection[0] !== curSel ||
... ... @@ -77,7 +77,9 @@ $(CHECKBOX_SELECTOR + ':checkbox').click(function() {
var selection = repayment.getSelection();
var isSkipped = false;
var isChecked = $(this).is(':checked');
var lastIndex = $('input:first').data('sortId');
var curSel = $(this).data('sortId');
var self = this;
selection.forEach(function(sel) {
... ... @@ -88,6 +90,11 @@ $(CHECKBOX_SELECTOR + ':checkbox').click(function() {
}
});
// 取消选择时候判断下标,只能先取消大的
if (selection && selection.length > 0 && !isChecked && curSel < selection[0].index) {
isSkipped = true;
}
if (isSkipped) {
setTimeout(function() {
tip.show($(self).is(':checked') ? '请按时间顺序取消选择,不可以跨期' : '请按时间顺序添加还款,不可以跨期');
... ...