...
|
...
|
@@ -3,7 +3,7 @@ |
|
|
<cheader :title="sortName" class="list-header">
|
|
|
<i class="icon icon-filter" slot="right" @click="openFilter"></i>
|
|
|
</cheader>
|
|
|
<order :config="orderConfig" :val="order" V-if="!empty"></order>
|
|
|
<order :config="orderConfig" :val="order" v-if="enableOrder"></order>
|
|
|
<List :data="productList" :empty="empty"></List>
|
|
|
<Filter :config="filterConfig" v-ref:filter></Filter>
|
|
|
</div>
|
...
|
...
|
@@ -46,7 +46,8 @@ |
|
|
productList: [],
|
|
|
|
|
|
// state
|
|
|
inSearching: false // 请求中
|
|
|
inSearching: false, // 请求中
|
|
|
enableOrder: false
|
|
|
};
|
|
|
},
|
|
|
computed: {
|
...
|
...
|
@@ -75,7 +76,7 @@ |
|
|
}
|
|
|
|
|
|
this.inSearching = true;
|
|
|
$.get(this.url, Object.assign({
|
|
|
return $.get(this.url, Object.assign({
|
|
|
order: this.order,
|
|
|
page: nextPage
|
|
|
}, this.filter, locationQuery))
|
...
|
...
|
@@ -152,7 +153,12 @@ |
|
|
self.$refs.filter.isVisible = false;
|
|
|
});
|
|
|
|
|
|
this.search();
|
|
|
this.search()
|
|
|
.then(()=>{
|
|
|
if (self.productList.length) {
|
|
|
self.enableOrder = true;
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
};
|
|
|
|
...
|
...
|
|