Commit 1c1cdc9c by 前端

Merge branch 'AI_V1.0.0' of http://192.168.3.233:8090/saas_plus/dj-car-boutique-…

…work-wechat into AI_V1.0.0
2 parents b04df3c9 1c8f0d7d
...@@ -62,15 +62,14 @@ Page({ ...@@ -62,15 +62,14 @@ Page({
let tempList = isReset ? data?.list : this.data.inspectList.concat(data?.list) let tempList = isReset ? data?.list : this.data.inspectList.concat(data?.list)
tempList.map(e => { tempList.map(e => {
if (e.seconds) e._seconds = this.formatTime(e.seconds) if (e.seconds) e._seconds = this.formatTime(e.seconds)
e.tempServer= e.serviceList.slice(0,5) e.tempServer = e.serviceList.slice(0, 5)
}) })
this.setData({ this.setData({
inspectList: tempList, inspectList: tempList,
pageNum: pageNum + 1,
total: data?.total, total: data?.total,
nothing: data?.total == (tempList.length - 1), nothing: data?.total == (tempList.length - 1),
}) })
console.log(this.data.pageNum)
} else { } else {
wx.$util.showToast(message) wx.$util.showToast(message)
} }
...@@ -166,6 +165,12 @@ Page({ ...@@ -166,6 +165,12 @@ Page({
}) })
}, },
scrollonReachBottom() { scrollonReachBottom() {
let {
pageNum
} = this.data
this.setData({
pageNum: pageNum + 1,
})
this.getList() this.getList()
}, },
storeConfirm(e) { storeConfirm(e) {
...@@ -214,22 +219,24 @@ Page({ ...@@ -214,22 +219,24 @@ Page({
tempList tempList
} = this.data, } = this.data,
list = arr ? arr : selectedYqMerchantList; list = arr ? arr : selectedYqMerchantList;
let res= list.find(item=>!item.merchantNo)
if(!res){
tempList[0].active=false
}
tempList.forEach(val => { tempList.forEach(val => {
list.forEach(v => { list.forEach(v => {
// if (list.length == 1 && list[0].merchantName == '全部') {
// val.active = false
// }
if (v.merchantNo == val.merchantNo) { if (v.merchantNo == val.merchantNo) {
val.active = v.active val.active = v.active
} }
}) })
}) })
let res = false;
tempList.forEach(item => {
if (item.merchantName !== '全部' && item.active) {
res = true
}
})
if (!res) {
tempList[0].active = true
} else {
tempList[0].active = false
}
if (arr) { if (arr) {
this.setData({ this.setData({
tempList tempList
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!