更换新接口
This commit is contained in:
@@ -59,16 +59,19 @@
|
||||
pageNum: this.pageNum
|
||||
}).then(res => {
|
||||
let tags = res.data.data
|
||||
for (const item of tags) {
|
||||
let tag = item.tags
|
||||
this.tagsArray = tag.split(',')
|
||||
item.tags = this.tagsArray[0]
|
||||
if (tags) {
|
||||
for (const item of tags) {
|
||||
let tag = item.tags
|
||||
this.tagsArray = tag.split(',')
|
||||
item.tags = this.tagsArray[0]
|
||||
}
|
||||
this.$emit("getTimeLength", tags.length);
|
||||
// 用于触底刷新 为数据赋值:通过展开运算符的形式,进行新旧数据的拼接
|
||||
this.productList = [...this.productList, ...res.data.data]
|
||||
//这用于上架时间和点赞量的数据切换
|
||||
// this.productList = res.data.data
|
||||
}
|
||||
this.$emit("getTimeLength", tags.length);
|
||||
// 用于触底刷新 为数据赋值:通过展开运算符的形式,进行新旧数据的拼接
|
||||
this.productList = [...this.productList, ...res.data.data]
|
||||
//这用于上架时间和点赞量的数据切换
|
||||
// this.productList = res.data.data
|
||||
|
||||
}).finally(_ => {
|
||||
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user