新增资产权证转让管理部分页面增加分页

This commit is contained in:
唐明明
2021-09-22 17:37:58 +08:00
parent b7cacb38c7
commit b06e4f8109
24 changed files with 4646 additions and 1577 deletions

View File

@@ -6,7 +6,7 @@
价格
<image
class="icon"
mode="widthFix" :src="require(marketType == 'low' ? '@/static/icons/market_icon_low.png': '@/static/icons/market_icon_high.png')"
mode="widthFix" :src="require(marketType == 'asc' ? '@/static/icons/market_icon_low.png': '@/static/icons/market_icon_high.png')"
/>
</view>
</view>
@@ -23,27 +23,33 @@
data() {
return {
tabIndex : 0,
marketType : 'low',
marketType : 'asc',
goods : []
};
},
created() {
list().then(res=>{
console.log(res.data)
this.goods = res.data
this.pages = res.page
})
this.getList()
},
methods:{
onTabs(e){
let index = e.target.dataset.index
if(index == 0 && index == this.tabIndex) return
if(index == 1 && index == this.tabIndex) this.marketType = this.marketType == 'low' ? 'high': 'low'
if(index == 1 && index == this.tabIndex) this.marketType = this.marketType == 'asc' ? 'desc': 'asc'
this.tabIndex = index
this.getList()
},
onGoods(e){
this.$Router.push({name: 'goodsDetails', params: {id: e.goods_id}})
},
getList(){
list({
order_by: this.tabIndex == 1 ? this.marketType: ''
}).then(res=>{
this.goods = res.data
this.pages = res.page
})
}
}
}