...
|
...
|
@@ -35,8 +35,8 @@ let goodObj = { |
|
|
$('.good-item').on('click', '.name,.color-size-row,.img', function(e) {
|
|
|
self.goodClick(e);
|
|
|
});
|
|
|
$('.check-all').on('click', function() {
|
|
|
self.checkedAllClick();
|
|
|
$('.check-all').on('click', function(e) {
|
|
|
self.checkedAllClick(e);
|
|
|
});
|
|
|
$('.btn-del').on('click', function() {
|
|
|
self.delClick();
|
...
|
...
|
@@ -50,6 +50,8 @@ let goodObj = { |
|
|
$(e.currentTarget).toggleClass('checked');
|
|
|
},
|
|
|
removeInvalidClick() {
|
|
|
let self = this;
|
|
|
|
|
|
dialog.showDialog({
|
|
|
dialogText: '您确定要清空失效商品吗?',
|
|
|
hasFooter: {
|
...
|
...
|
@@ -143,17 +145,19 @@ let goodObj = { |
|
|
dialog.hideDialog();
|
|
|
});
|
|
|
},
|
|
|
checkedAllClick() {
|
|
|
checkedAllClick(e) {
|
|
|
let self = this;
|
|
|
|
|
|
if (self.handle.editMode) {
|
|
|
$(this).find('.chk.edit').toggleClass('checked');
|
|
|
if ($(this).find('.chk.edit').hasClass('checked')) {
|
|
|
$(e.currentTarget).find('.chk.edit').toggleClass('checked');
|
|
|
if ($(e.currentTarget).find('.chk.edit').hasClass('checked')) {
|
|
|
$('.good-item .chk.edit').addClass('checked');
|
|
|
} else {
|
|
|
$('.good-item .chk.edit').removeClass('checked');
|
|
|
}
|
|
|
} else {
|
|
|
$(this).find('.chk.select').toggleClass('checked');
|
|
|
let checked = $(this).find('.chk.select').hasClass('checked');
|
|
|
$(e.currentTarget).find('.chk.select').toggleClass('checked');
|
|
|
let checked = $(e.currentTarget).find('.chk.select').hasClass('checked');
|
|
|
|
|
|
if (checked) {
|
|
|
let promise = self.clearLowStock();
|
...
|
...
|
@@ -406,16 +410,12 @@ let goodObj = { |
|
|
},
|
|
|
openChosepanel(e, isGift) {
|
|
|
let self = this;
|
|
|
|
|
|
let skn = $(e.delegateTarget).data('skn');
|
|
|
|
|
|
let id,
|
|
|
count,
|
|
|
canEditNum,
|
|
|
minNum,
|
|
|
promotionId;
|
|
|
|
|
|
|
|
|
let isSelected = $(e.delegateTarget).find('.chk.select').hasClass('checked');
|
|
|
|
|
|
id = $(e.delegateTarget).data('id');
|
...
|
...
|
|