...
|
...
|
@@ -44,7 +44,7 @@ |
|
|
props: ['productUrl'],
|
|
|
data() {
|
|
|
return {
|
|
|
nullbox : 'hide',
|
|
|
nullbox: 'hide',
|
|
|
busy: false,
|
|
|
editmodel: false,
|
|
|
page: 0,
|
...
|
...
|
@@ -54,12 +54,12 @@ |
|
|
methods: {
|
|
|
loadMore: function() {
|
|
|
let _this = this;
|
|
|
this.busy = true;
|
|
|
|
|
|
this.busy = true;
|
|
|
$.ajax({
|
|
|
url: '/home/favorite/favpaging',
|
|
|
data: {
|
|
|
page : ++_this.page
|
|
|
page: ++_this.page
|
|
|
}
|
|
|
}).then(result => {
|
|
|
if (result.isend) {
|
...
|
...
|
@@ -69,12 +69,12 @@ |
|
|
}
|
|
|
|
|
|
if (result.list.length) {
|
|
|
result.list.forEach(function(o){
|
|
|
result.list.forEach(function(o) {
|
|
|
_this.productData.push(o);
|
|
|
});
|
|
|
}
|
|
|
|
|
|
_this.nullbox = _this.productData.length ? "hide" : "";
|
|
|
_this.nullbox = _this.productData.length ? 'hide' : '';
|
|
|
}).fail(() => {
|
|
|
tip('网络错误');
|
|
|
});
|
...
|
...
|
@@ -87,17 +87,19 @@ |
|
|
},
|
|
|
showDelBtn(index) {
|
|
|
this.hideDelBth();
|
|
|
var delBtn = $("#del-" + index);
|
|
|
var width = delBtn.width();
|
|
|
$("#li-" + index).css("transform","translateX(-" + width + "px)");
|
|
|
let delBtn = $('#del-' + index);
|
|
|
let width = delBtn.width();
|
|
|
|
|
|
$('#li-' + index).css('transform', 'translateX(-' + width + 'px)');
|
|
|
},
|
|
|
hideDelBth() {
|
|
|
this.productData.forEach(function(d, index){
|
|
|
$("#li-" + index).css("transform","translateX(0px)");
|
|
|
})
|
|
|
this.productData.forEach(function(d, index) {
|
|
|
$('#li-' + index).css('transform', 'translateX(0px)');
|
|
|
});
|
|
|
},
|
|
|
delItem(index, id) {
|
|
|
let _this = this;
|
|
|
|
|
|
$.ajax({
|
|
|
method: 'POST',
|
|
|
url: '/home/del-favdel',
|
...
|
...
|
|