Commit 4b95ed26 by 张立顺

fix 驻店日报超管和督导校验逻辑

1 parent 949ffc8b
...@@ -399,23 +399,23 @@ Page({ ...@@ -399,23 +399,23 @@ Page({
}, },
showStorePicker() { showStorePicker() {
let { userInfo } = this.data let { userInfo } = this.data
; (userInfo?.isSuper || ;(userInfo?.isSuper ||
userInfo?.loginRole == 3 || userInfo?.loginRole == 3 ||
userInfo?.loginRole == 5) && userInfo?.loginRole == 5) &&
this.setData({ this.setData({
showPicker: true, showPicker: true,
pickerType: 'merchant' pickerType: 'merchant'
}) })
}, },
showStaffPicker() { showStaffPicker() {
let { userInfo } = this.data let { userInfo } = this.data
; (userInfo?.isSuper || ;(userInfo?.isSuper ||
userInfo?.loginRole == 3 || userInfo?.loginRole == 3 ||
userInfo?.loginRole == 5) && userInfo?.loginRole == 5) &&
this.setData({ this.setData({
showPicker: true, showPicker: true,
pickerType: 'staff' pickerType: 'staff'
}) })
}, },
navbarReady(e) { navbarReady(e) {
let navBarHeight = e.detail.height let navBarHeight = e.detail.height
...@@ -540,7 +540,7 @@ Page({ ...@@ -540,7 +540,7 @@ Page({
showCancel: false, showCancel: false,
confirmText: '确定', confirmText: '确定',
confirmColor: '#347BFF', confirmColor: '#347BFF',
success(res) { } success(res) {}
}) })
} else { } else {
wx.$util.showToast(message) wx.$util.showToast(message)
...@@ -560,7 +560,8 @@ Page({ ...@@ -560,7 +560,8 @@ Page({
carBandList, carBandList,
hwObjArray, hwObjArray,
hwOhterObjArray, hwOhterObjArray,
otherObjArray otherObjArray,
userInfo
} = this.data } = this.data
// 是督导和老板,提交评论 // 是督导和老板,提交评论
// console.log(approvedSource != '', approvedSource, 'approvedSource') // console.log(approvedSource != '', approvedSource, 'approvedSource')
...@@ -649,7 +650,7 @@ Page({ ...@@ -649,7 +650,7 @@ Page({
// 非调休 日报填报前参数校验 // 非调休 日报填报前参数校验
let check = await this.dailyReportCheck(orderObj) let check = await this.dailyReportCheck(orderObj)
console.log(check, 'check') console.log(check, 'check')
if (check && (!(userInfo?.isSuper || userInfo?.loginRole == 3))) return false if (check && !(userInfo?.isSuper || userInfo?.loginRole == 3)) return false
// orderObj.reportType = reportType // orderObj.reportType = reportType
// console.log(orderObj, 'orderObj') // console.log(orderObj, 'orderObj')
wx.$util.showLoading() wx.$util.showLoading()
...@@ -671,7 +672,7 @@ Page({ ...@@ -671,7 +672,7 @@ Page({
showCancel: false, showCancel: false,
confirmText: '确定', confirmText: '确定',
confirmColor: '#347BFF', confirmColor: '#347BFF',
success(res) { } success(res) {}
}) })
} else { } else {
wx.$util.showToast(message) wx.$util.showToast(message)
...@@ -780,9 +781,11 @@ Page({ ...@@ -780,9 +781,11 @@ Page({
0: '问界', 0: '问界',
1: '鸿蒙' 1: '鸿蒙'
} }
context += `【${bandType[el.brandType] || item.firstBrandName context += `【${
}】 店端总未触客数+门店售前触客数与当月实际交车数不符,差异值${item.differenceValue bandType[el.brandType] || item.firstBrandName
},请相关驻店销售对齐核销再次提交\t\n` }】 店端总未触客数+门店售前触客数与当月实际交车数不符,差异值${
item.differenceValue
},请相关驻店销售对齐核销再次提交\t\n`
el.deliveryCountinputError = true el.deliveryCountinputError = true
el.equityToShopCountinputError = true el.equityToShopCountinputError = true
el.notDeliveryCountinputError = true el.notDeliveryCountinputError = true
...@@ -1314,7 +1317,11 @@ Page({ ...@@ -1314,7 +1317,11 @@ Page({
let { orderObj, staffCurrent } = this.data let { orderObj, staffCurrent } = this.data
// 先查4s店对应的园区店,再用园区店查员工 // 先查4s店对应的园区店,再用园区店查员工
api api
.querySceneRefByShop({ scene: 0, merchantId: orderObj.merchantId, pageSize: 200 }) .querySceneRefByShop({
scene: 0,
merchantId: orderObj.merchantId,
pageSize: 200
})
.then(result => { .then(result => {
// console.log(result, 'result') // console.log(result, 'result')
let { code, data, message } = result let { code, data, message } = result
...@@ -1387,7 +1394,7 @@ Page({ ...@@ -1387,7 +1394,7 @@ Page({
wx.$util.message(message) wx.$util.message(message)
} }
}) })
.catch(err => { }) .catch(err => {})
}, },
inputSearch(e) { inputSearch(e) {
let { pickerType } = this.data let { pickerType } = this.data
...@@ -1596,7 +1603,7 @@ Page({ ...@@ -1596,7 +1603,7 @@ Page({
} }
// } // }
}) })
.catch(err => { }) .catch(err => {})
}, },
/** /**
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
...@@ -1718,5 +1725,5 @@ Page({ ...@@ -1718,5 +1725,5 @@ Page({
/** /**
* 生命周期函数--监听页面初次渲染完成 * 生命周期函数--监听页面初次渲染完成
*/ */
onReady: function () { } onReady: function () {}
}) })
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!