Commit fec45f90 by 前端

Merge branch 'SAAS+V5.6.1' into 'develop'

上线合并

See merge request !486
2 parents 3ac5dcf5 aa7351a1
Showing 129 changed files with 3019 additions and 892 deletions
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
"editor.defaultFormatter": "esbenp.prettier-vscode" "editor.defaultFormatter": "esbenp.prettier-vscode"
}, },
"[wxml]": { "[wxml]": {
"editor.defaultFormatter": "esbenp.prettier-vscode" "editor.defaultFormatter": "1251208555.wxml-pretty"
}, },
"[wxss]": { "[wxss]": {
"editor.defaultFormatter": "esbenp.prettier-vscode" "editor.defaultFormatter": "esbenp.prettier-vscode"
...@@ -109,5 +109,7 @@ ...@@ -109,5 +109,7 @@
"gitlens.codeLens.recentChange.enabled": true, "gitlens.codeLens.recentChange.enabled": true,
"gitlens.currentLineBlame": true, "gitlens.currentLineBlame": true,
"gitlens.currentLineBlame.format": "${author}, ${date} - ${message}", "gitlens.currentLineBlame.format": "${author}, ${date} - ${message}",
"gitlens.blame.visibility": "on" "gitlens.blame.visibility": "on",
} // 待团队讨论后再开启
"prettier.enable": false
}
\ No newline at end of file \ No newline at end of file
...@@ -433,34 +433,98 @@ module.exports = { ...@@ -433,34 +433,98 @@ module.exports = {
}, },
// 获取北森token // 获取北森token
findBeiSenSSOToken(data) { findBeiSenSSOToken(data) {
return api.post('dj.pad.api.beisen.findBeiSenSSOToken', data, [], '/rop-dj-pad/router') return api.post(
'dj.pad.api.beisen.findBeiSenSSOToken',
data,
[],
'/rop-dj-pad/router'
)
}, },
// 获取学习中心权限 // 获取学习中心权限
getStudyCenterPermission(data) { getStudyCenterPermission(data) {
return api.post('dj.pad.api.staff.study.center.access.auth.verify', data, [], '/rop-dj-pad/router') return api.post(
'dj.pad.api.staff.study.center.access.auth.verify',
data,
[],
'/rop-dj-pad/router'
)
}, },
// 学习中心开单限制 // 学习中心开单限制
checkStudyTaskAPI(data) { checkStudyTaskAPI(data) {
return api.post('dj.api.pad.learning.center.study.permission', data, [], '/rop-dj-pad/router') return api.post(
'dj.api.pad.learning.center.study.permission',
data,
[],
'/rop-dj-pad/router'
)
}, },
// 学习中心开始测评弹窗 // 学习中心开始测评弹窗
learninglevelExam(data) { learninglevelExam(data) {
return api.post('dj.api.pad.learning.center.level.exam', data, [], '/rop-dj-pad/router') return api.post(
'dj.api.pad.learning.center.level.exam',
data,
[],
'/rop-dj-pad/router'
)
}, },
// 查询北森考试结果 // 查询北森考试结果
getBeisenExamResult(data) { getBeisenExamResult(data) {
return api.post('dj.api.pad.learning.center.beisen.exam.result', data, [], '/rop-dj-pad/router') return api.post(
'dj.api.pad.learning.center.beisen.exam.result',
data,
[],
'/rop-dj-pad/router'
)
}, },
// 学习中心-短课程详情 // 学习中心-短课程详情
getShortCourseDetail(data) { getShortCourseDetail(data) {
return api.post('dj.pad.api.staff.study.short.course.detail', data, [], '/rop-dj-pad/router') return api.post(
'dj.pad.api.staff.study.short.course.detail',
data,
[],
'/rop-dj-pad/router'
)
}, },
// 上传视频文件返回封面 // 上传视频文件返回封面
uploadFileWithCover(data) { uploadFileWithCover(data) {
return api.post('dj.api.smartcarlife.common.uploadVideo.returnWithCover', data, ['file']) return api.post(
'dj.api.smartcarlife.common.uploadVideo.returnWithCover',
data,
['file']
)
}, },
// 获取员工日报/周报/月报模版 // 获取员工日报/周报/月报模版
getStaffTemplate(data) { getStaffTemplate(data) {
return api.post('dj.api.carboutique.find.staff.good.news.template', data) return api.post('dj.api.carboutique.find.staff.good.news.template', data)
},
// 工资申述入口判断
hasPerformanceConfig(data) {
return api.post(
'dj.staff.api.has.performance.config.formerchant',
data,
[],
'/rop-dj-staff-miniprogram/router'
)
},
// 接口名称:异常订单锁单信息查询
// 接口地址:dj.api.smartcarlife.goodsOrder.abnormalOrder.lock.select
abnormalOrderLock() {
return api.post(
'dj.api.smartcarlife.goodsOrder.abnormalOrder.lock.select',
{}
)
},
// http://localhost:8081/rop-dj-riskmanage/router//dj.api.staff.miniprogram.salaryapply.daily.report.fill.check/1.0.0
// 检查今天是否在T1-T5之间
salaryapplyFillCheck(data) {
return api.post(
'dj.api.staff.miniprogram.salaryapply.daily.report.fill.check',
data,
[],
'/rop-dj-staff-miniprogram/router'
)
// return api.post(
// 'dj.api.staff.miniprogram.salaryapply.daily.report.fill.check'
// )
} }
} }
...@@ -231,7 +231,8 @@ Component({ ...@@ -231,7 +231,8 @@ Component({
if (s.goods.goodsId == e.goods.goodsId) { if (s.goods.goodsId == e.goods.goodsId) {
e.active = true e.active = true
e.count = s.count e.count = s.count
e.goods.sellPrice = s.goods.sellPrice // e.goods.sellPrice = s.goods.sellPrice
Object.assign(e.goods, s.goods)
} }
} }
//初始化进来不显示标识 //初始化进来不显示标识
...@@ -246,6 +247,15 @@ Component({ ...@@ -246,6 +247,15 @@ Component({
e.multipleSpecificationsGoods.id e.multipleSpecificationsGoods.id
) { ) {
e.count = s.count e.count = s.count
if (
s.multipleSpecificationsGoods.goods &&
e.multipleSpecificationsGoods.goods
) {
Object.assign(
e.multipleSpecificationsGoods.goods,
s.multipleSpecificationsGoods.goods
)
}
// e.active=s.acitve // e.active=s.acitve
} }
} }
...@@ -283,17 +293,27 @@ Component({ ...@@ -283,17 +293,27 @@ Component({
console.log(arr, 'removeDuplicates') console.log(arr, 'removeDuplicates')
var uniqueArray = [] var uniqueArray = []
for (var i = 0; i < arr.length; i++) { for (var i = 0; i < arr.length; i++) {
let goodsType = let goodsType = ''
arr[i].goodsFlag == 1 ? 'goods' : 'multipleSpecificationsGoods.goods' if (arr[i].goodsFlag == 1) {
goodsType = 'goods'
} else if (arr[i].goodsFlag == 2) {
goodsType = 'multipleSpecificationsGoods.goods'
} else if (arr[i].goodsFlag == 3) {
goodsType = 'packageGoods'
}
let value = this.circulation(arr[i], goodsType)[property] let value = this.circulation(arr[i], goodsType)[property]
// 兼容套餐 // 兼容套餐
let result = uniqueArray.some(item => { let result = uniqueArray.some(item => {
let key = let key = ''
item.goodsFlag == 1 if (item.goodsFlag == 1) {
? 'goods' key = 'goods'
: item.goodsFlag == 2 } else if (item.goodsFlag == 2) {
? 'multipleSpecificationsGoods.goods' key = 'multipleSpecificationsGoods.goods'
: '' } else if (item.goodsFlag == 3) {
key = 'packageGoods'
}
let deepValue = this.circulation(item, key) let deepValue = this.circulation(item, key)
return deepValue ? deepValue[property] === value : false return deepValue ? deepValue[property] === value : false
}) })
...@@ -354,7 +374,7 @@ Component({ ...@@ -354,7 +374,7 @@ Component({
if (chooseGoodsList.length > 0) { if (chooseGoodsList.length > 0) {
chooseGoodsList.map(x => { chooseGoodsList.map(x => {
if (x.goods && x.goods.goodsId == c.goods.goodsId) { if (x.goods && x.goods.goodsId == c.goods.goodsId) {
c.goods.price = x.goods.price || 0 Object.assign(c.goods, x.goods)
} }
}) })
} }
...@@ -373,14 +393,27 @@ Component({ ...@@ -373,14 +393,27 @@ Component({
x.multipleSpecificationsGoods.goods.goodsId == x.multipleSpecificationsGoods.goods.goodsId ==
c.multipleSpecificationsGoods.goods.goodsId c.multipleSpecificationsGoods.goods.goodsId
) { ) {
c.multipleSpecificationsGoods.goods.price = Object.assign(
x.multipleSpecificationsGoods.goods.price || 0 c.multipleSpecificationsGoods.goods,
x.multipleSpecificationsGoods.goods
)
} }
} }
}) })
} }
} }
} }
if (c.packageGoods) {
if (chooseGoodsList.length > 0) {
chooseGoodsList.map(x => {
if (x.goodsFlag == 3 && x.packageGoods) {
if (x.packageGoods.goodsId == c.packageGoods.goodsId) {
Object.assign(c.packageGoods, x.packageGoods)
}
}
})
}
}
} }
}) })
return arr return arr
......
...@@ -278,7 +278,6 @@ Component({ ...@@ -278,7 +278,6 @@ Component({
if (data) { if (data) {
wx.$util.setUserInfo({ ...wx.$util.getUserInfo(), subLoginUser: data.subLoginUser }) wx.$util.setUserInfo({ ...wx.$util.getUserInfo(), subLoginUser: data.subLoginUser })
wx.$util.hideLoading() wx.$util.hideLoading()
// wx.$storage.rm('dateStaffPop')
this.eventCallback(item, userInfo?.sceneType, false, data) this.eventCallback(item, userInfo?.sceneType, false, data)
} else { } else {
wx.$util.showToast(message) wx.$util.showToast(message)
......
...@@ -6,42 +6,39 @@ Component({ ...@@ -6,42 +6,39 @@ Component({
properties: { properties: {
//1:精品升级 0 会员权益 //1:精品升级 0 会员权益
sceneType: { sceneType: {
type: String, type: String
}, },
show: { show: {
type: Boolean, type: Boolean,
observer: function (n) { } observer: function (n) {}
}, },
goodsData: { goodsData: {
type: Object, type: Object,
observer: function (n) { observer: function (n) {
console.log(n, '999', this.data.chooseGoodsList) console.log(n, '999', this.data.chooseGoodsList)
this.setGoodsActive(); this.setGoodsActive()
} }
}, },
chooseGoodsList: { chooseGoodsList: {
type: Array, type: Array,
observer: function (n) { observer: function (n) {
// this.setGoodsActive(); // this.setGoodsActive();
}, }
}, }
}, },
observers: { observers: {
'show': function (value, old) { show: function (value, old) {
console.log(value, old, 'show'); console.log(value, old, 'show')
let thisPage = wx.$router.getPageInstance() let thisPage = wx.$router.getPageInstance()
thisPage.setData({ thisPage.setData({
scrollDisabled: value scrollDisabled: value
}) })
} }
}, },
/** /**
* 组件的初始数据 * 组件的初始数据
*/ */
data: { data: {},
},
/** /**
* 组件的方法列表 * 组件的方法列表
...@@ -49,25 +46,30 @@ Component({ ...@@ -49,25 +46,30 @@ Component({
methods: { methods: {
setGoodsActive() { setGoodsActive() {
//同步数量 //同步数量
let { let { chooseGoodsList, goodsData } = this.data
chooseGoodsList, if (
goodsData goodsData &&
} = this.data; goodsData.multipleSpecificationsGoods &&
goodsData.multipleSpecificationsGoods.skuGoodsList.forEach(c => { goodsData.multipleSpecificationsGoods.skuGoodsList
if (chooseGoodsList.length > 0) { ) {
chooseGoodsList.map(x => { goodsData.multipleSpecificationsGoods.skuGoodsList.forEach(c => {
if (x.goodsFlag == 2) { if (chooseGoodsList && chooseGoodsList.length > 0) {
if (x.multipleSpecificationsGoods.goods && x.multipleSpecificationsGoods.goods.goodsId == c.goodsId) { chooseGoodsList.map(x => {
c.count = x.count || 0 if (x.goodsFlag == 2) {
if (
x.multipleSpecificationsGoods.goods &&
x.multipleSpecificationsGoods.goods.goodsId == c.goodsId
) {
c.count = x.count || 0
}
} }
} })
}) }
} })
this.setData({
}) goodsData
this.setData({ })
goodsData }
})
}, },
hidePopup() { hidePopup() {
this.setData({ this.setData({
...@@ -76,34 +78,23 @@ Component({ ...@@ -76,34 +78,23 @@ Component({
this.triggerEvent('cancel') this.triggerEvent('cancel')
}, },
choose(e) { choose(e) {
let { let { item, index } = e.currentTarget.dataset
item, let { goodsData } = this.data
index let { active } = item
} = e.currentTarget.dataset
let {
goodsData
} = this.data
let {
active
} = item
//全部取消选择 //全部取消选择
goodsData.multipleSpecificationsGoods.skuGoodsList.forEach(item => item.active = false) goodsData.multipleSpecificationsGoods.skuGoodsList.forEach(
item => (item.active = false)
)
goodsData.multipleSpecificationsGoods.skuGoodsList[index].active = !active goodsData.multipleSpecificationsGoods.skuGoodsList[index].active = !active
this.setData({ this.setData({
goodsData goodsData
}) })
}, },
input(e) { input(e) {
let { let { index } = e.currentTarget.dataset
index let { goodsData } = this.data
} = e.currentTarget.dataset
let {
goodsData
} = this.data
console.log(e) console.log(e)
let { let { value } = e.detail
value
} = e.detail
if (value < 1) value = 1 if (value < 1) value = 1
if (value > 999) value = 999 if (value > 999) value = 999
goodsData.multipleSpecificationsGoods.skuGoodsList[index].count = value goodsData.multipleSpecificationsGoods.skuGoodsList[index].count = value
...@@ -117,10 +108,7 @@ Component({ ...@@ -117,10 +108,7 @@ Component({
}) })
}, },
getChooseList() { getChooseList() {
let { let { chooseGoodsList, goodsData } = this.data
chooseGoodsList,
goodsData
} = this.data;
console.log(chooseGoodsList, goodsData) console.log(chooseGoodsList, goodsData)
let chooseList = [], let chooseList = [],
selectList = [] selectList = []
...@@ -134,10 +122,13 @@ Component({ ...@@ -134,10 +122,13 @@ Component({
goodsFlag: 2, goodsFlag: 2,
isFlag: true, isFlag: true,
multipleSpecificationsGoods: { multipleSpecificationsGoods: {
baseGoodsName: goodsData.multipleSpecificationsGoods.baseGoodsName, baseGoodsName:
goodsData.multipleSpecificationsGoods.baseGoodsName,
id: goodsData.multipleSpecificationsGoods.id, id: goodsData.multipleSpecificationsGoods.id,
specificationGoodsMap: goodsData.multipleSpecificationsGoods.specificationGoodsMap, specificationGoodsMap:
specificationList: goodsData.multipleSpecificationsGoods.specificationList, goodsData.multipleSpecificationsGoods.specificationGoodsMap,
specificationList:
goodsData.multipleSpecificationsGoods.specificationList,
goods: c goods: c
} }
}) })
...@@ -148,43 +139,61 @@ Component({ ...@@ -148,43 +139,61 @@ Component({
if (selectList.length) { if (selectList.length) {
selectList.forEach(c => { selectList.forEach(c => {
if (!c.count) c.count = 1 if (!c.count) c.count = 1
c.multipleSpecificationsGoods.goods.price = c.multipleSpecificationsGoods.goods.sellPrice || 0 let price = c.multipleSpecificationsGoods.goods.sellPrice || 0
// 会员权益
if (this.data.sceneType == '0') {
price = Math.round(price * 100)
}
c.multipleSpecificationsGoods.goods.price = price
if (chooseGoodsList.length > 0) { if (chooseGoodsList.length > 0) {
chooseGoodsList.map(x => { chooseGoodsList.map(x => {
if (x.goodsFlag == 2 && x.multipleSpecificationsGoods) { if (x.goodsFlag == 2 && x.multipleSpecificationsGoods) {
console.log(x.multipleSpecificationsGoods.goods && x.multipleSpecificationsGoods.goods.goodsId == c.multipleSpecificationsGoods.goods.goodsId, 'x.multipleSpecificationsGoods.goods && x.multipleSpecificationsGoods.goods.goodsId == c.multipleSpecificationsGoods.goods.goodsId') console.log(
if (x.multipleSpecificationsGoods.goods && x.multipleSpecificationsGoods.goods.goodsId == c.multipleSpecificationsGoods.goods.goodsId) { x.multipleSpecificationsGoods.goods &&
x.multipleSpecificationsGoods.goods.goodsId ==
c.multipleSpecificationsGoods.goods.goodsId,
'x.multipleSpecificationsGoods.goods && x.multipleSpecificationsGoods.goods.goodsId == c.multipleSpecificationsGoods.goods.goodsId'
)
if (
x.multipleSpecificationsGoods.goods &&
x.multipleSpecificationsGoods.goods.goodsId ==
c.multipleSpecificationsGoods.goods.goodsId
) {
console.log(c) console.log(c)
//精品升级需要处理数量,会员权益不需要 //精品升级需要处理数量,会员权益不需要
x.count = c.multipleSpecificationsGoods.goods.count || 0 x.count = c.multipleSpecificationsGoods.goods.count || 0
} }
} }
}) })
let arr = chooseGoodsList.filter(item => item.multipleSpecificationsGoods && item.multipleSpecificationsGoods.goods) let arr = chooseGoodsList.filter(
item =>
item.multipleSpecificationsGoods &&
item.multipleSpecificationsGoods.goods
)
console.log(arr) console.log(arr)
selectList.forEach(oldval => { selectList.forEach(oldval => {
if (oldval.multipleSpecificationsGoods) { if (oldval.multipleSpecificationsGoods) {
if (!arr.some(newVal => newVal.multipleSpecificationsGoods.goods.goodsId == oldval.multipleSpecificationsGoods.goods.goodsId)) { if (
!arr.some(
newVal =>
newVal.multipleSpecificationsGoods.goods.goodsId ==
oldval.multipleSpecificationsGoods.goods.goodsId
)
) {
chooseList.push(oldval) chooseList.push(oldval)
} }
} }
}) })
} else { } else {
chooseList = selectList chooseList = selectList
} }
}) })
} }
console.log(chooseList, 'chooseList') console.log(chooseList, 'chooseList')
chooseList = chooseList.concat(chooseGoodsList) chooseList = chooseList.concat(chooseGoodsList)
console.log(chooseList, 'chooseList') console.log(chooseList, 'chooseList')
return [selectList, chooseList] return [selectList, chooseList]
}, },
confirm() { confirm() {
let [selectList, chooseList] = this.getChooseList() let [selectList, chooseList] = this.getChooseList()
...@@ -194,22 +203,25 @@ Component({ ...@@ -194,22 +203,25 @@ Component({
let thisPage = wx.$router.getPageInstance() let thisPage = wx.$router.getPageInstance()
if (this.data.sceneType == 1) { if (this.data.sceneType == 1) {
thisPage.setData({ thisPage.setData({
goodsList: chooseList, goodsList: chooseList
});
thisPage?.setGoodsTotal && thisPage.setGoodsTotal(chooseList);
} else {
thisPage.setData({
['orderInfo.vdQuotationGoodsList']: chooseList
}, () => {
//会员权益
thisPage.totalFee()
}) })
thisPage?.setGoodsTotal && thisPage.setGoodsTotal(chooseList)
} else {
thisPage.setData(
{
['orderInfo.vdQuotationGoodsList']: chooseList
},
() => {
//会员权益
thisPage.totalFee()
}
)
} }
this.setData({ this.setData({
show: false show: false
}) })
}, }
}, },
lifetimes: { lifetimes: {
attached() { attached() {
...@@ -219,5 +231,4 @@ Component({ ...@@ -219,5 +231,4 @@ Component({
}) })
} }
} }
})
\ No newline at end of file \ No newline at end of file
})
// components/orderPromptPop/orderPromptPop.js // components/orderPromptPop/orderPromptPop.js
Component({ Component({
/** /**
* 组件的属性列表 * 组件的属性列表
*/ */
...@@ -18,7 +17,7 @@ Component({ ...@@ -18,7 +17,7 @@ Component({
}, },
includesChildHeight: { includesChildHeight: {
type: String, type: String,
value: 'var(--fontSize980)' value: 'var(--fontSize1020)'
}, },
sceneObj: { sceneObj: {
observer: function (v) { observer: function (v) {
...@@ -46,21 +45,26 @@ Component({ ...@@ -46,21 +45,26 @@ Component({
*/ */
data: { data: {
infoData: {}, infoData: {},
payTypeList: [{ payTypeList: [
label: '收款方为门店收款', {
value: '3' label: '收款方为门店收款',
}, { value: '3'
label: '收款方为嘀加且属于对公转账收款', },
value: '4' {
}, { label: '收款方为嘀加且属于对公转账收款',
label: '收款方为嘀加二维码收款', value: '4'
value: '5', },
tips: '适用于已有交易收款流水需补录订单时' {
}, { label: '收款方为嘀加二维码收款',
label: '特殊收款', value: '5',
value: '6', tips: '适用于已有交易收款流水需补录订单时'
tips: '仅用于无法关联流水或混合支付场景,请谨慎选择。' },
}] {
label: '特殊收款',
value: '6',
tips: '仅用于无法关联流水或混合支付场景,请谨慎选择。'
}
]
}, },
/** /**
...@@ -91,4 +95,4 @@ Component({ ...@@ -91,4 +95,4 @@ Component({
this.triggerEvent('confirm', infoData) this.triggerEvent('confirm', infoData)
} }
} }
})
\ No newline at end of file \ No newline at end of file
})
...@@ -18,12 +18,12 @@ export const appId = "wx570d9331f9ace0bd"; ...@@ -18,12 +18,12 @@ export const appId = "wx570d9331f9ace0bd";
* 4预发布 * 4预发布
* 5cdptest * 5cdptest
*/ */
let index = 4; let index = 2;
const accountInfo = wx.getAccountInfoSync(); const accountInfo = wx.getAccountInfoSync();
const systemInfo = wx.getSystemInfoSync(); const systemInfo = wx.getSystemInfoSync();
const envName = accountInfo.miniProgram.envVersion; const envName = accountInfo.miniProgram.envVersion;
//手动控制体验版环境的请求 true就依据下面index false就默认2 //手动控制体验版环境的请求 true就依据下面index false就默认2
const manual = true; const manual = false;
const release = false; const release = false;
// 判断小程序环境 // 判断小程序环境
...@@ -88,10 +88,12 @@ export const ALIYUN = ALIYUN_LIST[1]; ...@@ -88,10 +88,12 @@ export const ALIYUN = ALIYUN_LIST[1];
export const quotedImgUrl = createQuotedUrl[target[envIndex]]; export const quotedImgUrl = createQuotedUrl[target[envIndex]];
export const scoket_url = scoketURL[target[envIndex]]; export const scoket_url = scoketURL[target[envIndex]];
// sentry Dsn 地址 // sentry Dsn 地址
export const dsnUrl = "https://ddaadc52bf8d4ecc92eca632683d456a@sentry.glsx.com.cn/23"; export const dsnUrl =
"https://ddaadc52bf8d4ecc92eca632683d456a@sentry.glsx.com.cn/23";
// 图片基地址 // 图片基地址
export const ImgUrl = "https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat"; export const ImgUrl =
"https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat";
export const ossConfig = { export const ossConfig = {
// 请求域名 格式:https://xxx.xxx.com // 请求域名 格式:https://xxx.xxx.com
......
<!--packageCrowdFunding/pages/paymentSuccess/paymentSuccess.wxml--> <!--packageCrowdFunding/pages/paymentSuccess/paymentSuccess.wxml-->
<view class="successPay"> <view class="successPay">
<view class="tips">支付成功</view> <view class="tips">支付成功</view>
<view class="sum">订单支付成功,实付{{orderDetail.totalPrice}}元</view> <view class="sum">订单支付成功,实付{{orderDetail.finalPrice}}元</view>
</view> </view>
<view class="orderInfo"> <view class="orderInfo">
<activity-info OderType="pay" orderInfo="{{orderDetail}}" /> <activity-info OderType="pay" orderInfo="{{orderDetail}}" />
......
...@@ -241,5 +241,9 @@ module.exports = { ...@@ -241,5 +241,9 @@ module.exports = {
// 查询订单可展示按钮类型 // 查询订单可展示按钮类型
getMoreBtnAPI(data) { getMoreBtnAPI(data) {
return api.post('dj.api.smartcarlife.refundApplyRecord.button.select', data) return api.post('dj.api.smartcarlife.refundApplyRecord.button.select', data)
} },
// 工资申述入口判断
hasPerformanceConfig(data) {
return api.post('dj.staff.api.has.performance.config.formerchant', data, [], '/rop-dj-staff-miniprogram/router')
}
} }
...@@ -44,7 +44,7 @@ Component({ ...@@ -44,7 +44,7 @@ Component({
{ {
labelName: '实际支付', labelName: '实际支付',
orderType: 'success', orderType: 'success',
key: 'totalPrice' key: 'finalPrice'
}, },
{ {
labelName: '订单状态', labelName: '订单状态',
......
...@@ -15,5 +15,5 @@ ...@@ -15,5 +15,5 @@
</view> </view>
<record-list model:showPopup="{{showPopup}}" deviceOrientation="{{deviceOrientation}}" mode="{{mode}}"></record-list> <record-list model:showPopup="{{showPopup}}" deviceOrientation="{{deviceOrientation}}" mode="{{mode}}"></record-list>
<order-prompt-popup wx:if="{{ showPromptDialog }}" show="{{ showPromptDialog }}" bindconfirm="promptHandleConfirm" bindcancel="promptCancel" popupSlotStyle="height: calc(100% - var(--fontSize160));" height="var(--fontSize540);" includesChildHeight="var(--fontSize1020);"></order-prompt-popup> <order-prompt-popup wx:if="{{ showPromptDialog }}" show="{{ showPromptDialog }}" bindconfirm="promptHandleConfirm" bindcancel="promptCancel" popupSlotStyle="height: calc(100% - var(--fontSize160));" height="var(--fontSize540);" includesChildHeight="var(--fontSize1060);"></order-prompt-popup>
<order-no-popup wx:if="{{ tipsProps }}" show="{{ tipsProps }}" title="请选择交易参考号" bind:success="navigator" orderNoList="{{ orderNoList }}" /> <order-no-popup wx:if="{{ tipsProps }}" show="{{ tipsProps }}" title="请选择交易参考号" bind:success="navigator" orderNoList="{{ orderNoList }}" />
\ No newline at end of file \ No newline at end of file
// packageEquity/pages/carEquity/components/EquityList/EquityList.js // packageEquity/pages/carEquity/components/EquityList/EquityList.js
import { checkDailyReport, checkStudyTask } from "~/store/ModalToQueueControl"; import {
checkDailyReport,
checkStudyTask,
checkAbnormalOrder
} from '~/store/ModalToQueueControl'
import carLifeApi from '../../../../carEquityApi' import carLifeApi from '../../../../carEquityApi'
import constantData from '../constant/data' import constantData from '../constant/data'
const TABLIST = ['全部', '待补单', '提单失败', '已完成'] const TABLIST = ['全部', '待补单', '提单失败', '已完成']
...@@ -17,9 +21,7 @@ Component({ ...@@ -17,9 +21,7 @@ Component({
observer(val) { observer(val) {
console.log(val) console.log(val)
if (val == 1) { if (val == 1) {
let { let { list } = this.data
list
} = this.data
setTimeout(() => { setTimeout(() => {
// 解决商品内容提早请求,导致不计算问题 // 解决商品内容提早请求,导致不计算问题
this.setData({ this.setData({
...@@ -38,27 +40,28 @@ Component({ ...@@ -38,27 +40,28 @@ Component({
*/ */
data: { data: {
storeInfo: {}, storeInfo: {},
orderObj: [{ orderObj: [
label: '车架号', {
key: 'vin' label: '车架号',
}, key: 'vin'
{ },
label: '业务来源', {
key: 'ywly' label: '业务来源',
}, key: 'ywly'
{ },
label: '商品名称', {
key: 'goodName' label: '商品名称',
}, key: 'goodName'
{ },
label: '服务期限', {
key: 'serviceExpire', label: '服务期限',
suffix: '年' key: 'serviceExpire',
}, suffix: '年'
{ },
label: '商品内容', {
key: 'goodServiceName' label: '商品内容',
} key: 'goodServiceName'
}
], ],
statisticsObj: {}, statisticsObj: {},
btnTxt: { btnTxt: {
...@@ -105,12 +108,17 @@ Component({ ...@@ -105,12 +108,17 @@ Component({
*/ */
methods: { methods: {
onLoad(noGetList) { onLoad(noGetList) {
let userInfo = wx.$util.getUserInfo() || {}; let userInfo = wx.$util.getUserInfo() || {}
this.setData({ this.setData({
nothing: false, nothing: false,
pageNum: 1, pageNum: 1,
storeInfo: wx.$util.getUserInfo()?.default4SStoreInfo || {}, storeInfo: wx.$util.getUserInfo()?.default4SStoreInfo || {},
isOrder: !(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) isOrder: !(
userInfo?.isSuper ||
userInfo?.loginRole == 3 ||
userInfo.loginRole == 5 ||
userInfo?.loginRole == 6
)
}) })
this.getTotal() this.getTotal()
if (!noGetList) this.getList(true) if (!noGetList) this.getList(true)
...@@ -124,9 +132,7 @@ Component({ ...@@ -124,9 +132,7 @@ Component({
}) })
}, },
getTotal() { getTotal() {
let { let { storeInfo } = this.data
storeInfo
} = this.data
carLifeApi carLifeApi
.equityStatistics({ .equityStatistics({
merchantId: storeInfo?.merchantId merchantId: storeInfo?.merchantId
...@@ -134,9 +140,7 @@ Component({ ...@@ -134,9 +140,7 @@ Component({
.then(res => { .then(res => {
// console.log(res, '统计---') // console.log(res, '统计---')
if (res.code == '0') { if (res.code == '0') {
let { let { data } = res
data
} = res
this.setData({ this.setData({
statisticsObj: data || {} statisticsObj: data || {}
}) })
...@@ -152,14 +156,8 @@ Component({ ...@@ -152,14 +156,8 @@ Component({
}) })
}, },
getList(isReset = false) { getList(isReset = false) {
let { let { pageSize, pageNum, tabList, tabIndex, customerName, storeInfo } =
pageSize, this.data
pageNum,
tabList,
tabIndex,
customerName,
storeInfo
} = this.data
if (this.data.nothing) { if (this.data.nothing) {
return return
} }
...@@ -168,16 +166,18 @@ Component({ ...@@ -168,16 +166,18 @@ Component({
pageNum, pageNum,
customerName, customerName,
// item.confName == // item.confName ==
orderStatus: constantData.equityStatusList.find(item => tabList[tabIndex].text == item.confName)?.confId || '', orderStatus:
constantData.equityStatusList.find(
item => tabList[tabIndex].text == item.confName
)?.confId || '',
merchantId: storeInfo?.merchantId merchantId: storeInfo?.merchantId
} }
carLifeApi.equityPage(params).then(res => { carLifeApi.equityPage(params).then(res => {
if (res.code == '0') { if (res.code == '0') {
let { let { data, count } = res.data
data, let tempList = isReset
count ? data || []
} = res.data : this.data.list.concat(data || [])
let tempList = isReset ? data || [] : this.data.list.concat(data || [])
this.setData({ this.setData({
list: tempList, list: tempList,
pageNum: pageNum + 1, pageNum: pageNum + 1,
...@@ -216,18 +216,14 @@ Component({ ...@@ -216,18 +216,14 @@ Component({
this.search() this.search()
}, },
input(e) { input(e) {
let { let { value } = e.detail
value
} = e.detail
this.setData({ this.setData({
customerName: value customerName: value
}) })
}, },
// 首次进入会触发该方法,因此不需要在attached调getList // 首次进入会触发该方法,因此不需要在attached调getList
tabClick(e) { tabClick(e) {
let { let { searchObj } = this.data
searchObj
} = this.data
delete searchObj.statusList delete searchObj.statusList
this.setData({ this.setData({
tabIndex: e.detail, tabIndex: e.detail,
...@@ -238,14 +234,15 @@ Component({ ...@@ -238,14 +234,15 @@ Component({
// 录单/重新录单 // 录单/重新录单
async handleRecordOrder(e) { async handleRecordOrder(e) {
// 校验是否填写昨日日报 // 校验是否填写昨日日报
let staffCheck = await checkDailyReport(true); let staffCheck = await checkDailyReport(true)
if (staffCheck) return false; if (staffCheck) return false
// 校验学习中心开单限制 // 校验学习中心开单限制
let staffStudyTask = await checkStudyTask() let staffStudyTask = await checkStudyTask()
if (staffStudyTask) return false if (staffStudyTask) return false
let { // 校验异常订单
target let abnormalOrderCheck = await checkAbnormalOrder()
} = e.currentTarget.dataset if (abnormalOrderCheck) return false
let { target } = e.currentTarget.dataset
console.log(target) console.log(target)
wx.$router.go('serviceInfo', { wx.$router.go('serviceInfo', {
contractNo: target.contractNo, contractNo: target.contractNo,
...@@ -254,10 +251,7 @@ Component({ ...@@ -254,10 +251,7 @@ Component({
}, },
// 查看/下载合同 // 查看/下载合同
async handlePreviewContract(e) { async handlePreviewContract(e) {
let { let { target, type } = e.currentTarget.dataset
target,
type
} = e.currentTarget.dataset
wx.$util.showLoading('加载中...') wx.$util.showLoading('加载中...')
let params = { let params = {
contractNo: target.contractNo contractNo: target.contractNo
...@@ -266,10 +260,7 @@ Component({ ...@@ -266,10 +260,7 @@ Component({
let result = await carLifeApi.equityOrderList({ let result = await carLifeApi.equityOrderList({
orderId: target.orderId orderId: target.orderId
}) })
let { let { code, data } = result
code,
data
} = result
if (code == 0) { if (code == 0) {
if (data.length == 1) { if (data.length == 1) {
carLifeApi.printContract(params).then(res => { carLifeApi.printContract(params).then(res => {
...@@ -301,16 +292,19 @@ Component({ ...@@ -301,16 +292,19 @@ Component({
// 签名 // 签名
async handleSignature(e) { async handleSignature(e) {
// 校验是否填写昨日日报 // 校验是否填写昨日日报
let staffCheck = await checkDailyReport(true); let staffCheck = await checkDailyReport(true)
if (staffCheck) return false; if (staffCheck) return false
// 校验学习中心开单限制 // 校验学习中心开单限制
let staffStudyTask = await checkStudyTask() let staffStudyTask = await checkStudyTask()
if (staffStudyTask) return false if (staffStudyTask) return false
// 校验异常订单
let abnormalOrderCheck = await checkAbnormalOrder()
if (abnormalOrderCheck) return false
let { target } = e.currentTarget.dataset let { target } = e.currentTarget.dataset
wx.$router.go("signature", { wx.$router.go('signature', {
orderId: target.orderId, orderId: target.orderId,
tabIndex: 2 tabIndex: 2
}); })
}, },
// 复制链接 // 复制链接
...@@ -321,7 +315,8 @@ Component({ ...@@ -321,7 +315,8 @@ Component({
} }
wx.showModal({ wx.showModal({
title: '温馨提示', title: '温馨提示',
content: '如需下载PDF报告单,请复制下载地址后到手机浏览器中打开。下载地址5分钟内有效', content:
'如需下载PDF报告单,请复制下载地址后到手机浏览器中打开。下载地址5分钟内有效',
confirmText: '复制地址', confirmText: '复制地址',
confirmColor: '#347BFF', confirmColor: '#347BFF',
success(res) { success(res) {
...@@ -335,9 +330,7 @@ Component({ ...@@ -335,9 +330,7 @@ Component({
}, },
handleDownload() { handleDownload() {
let { let { url } = this.data
url
} = this.data
let _this = this let _this = this
if (!url) { if (!url) {
wx.$util.showToast('没有合同') wx.$util.showToast('没有合同')
...@@ -371,4 +364,4 @@ Component({ ...@@ -371,4 +364,4 @@ Component({
}) })
} }
} }
})
\ No newline at end of file \ No newline at end of file
})
...@@ -24,10 +24,12 @@ Page({ ...@@ -24,10 +24,12 @@ Page({
timer = setInterval(() => { timer = setInterval(() => {
let objNameStr = 'textNameObj.confirmName' let objNameStr = 'textNameObj.confirmName'
// const str = '前往提单(10s)' // const str = '前往提单(10s)'
that.setData({ if (zyFlag) {
[objNameStr]: `${zyFlag ? '下一步·上传协议(4/4)' : '下一步·去签名(4/4)'}(${sec}s)`, that.setData({
showBtnFlag: true [objNameStr]: `下一步·上传协议(4/4)(${sec}s)`,
}) showBtnFlag: true
})
}
sec-- sec--
if (sec == -1) { if (sec == -1) {
clearInterval(timer) // 清除定时器 clearInterval(timer) // 清除定时器
...@@ -36,8 +38,8 @@ Page({ ...@@ -36,8 +38,8 @@ Page({
if (zyFlag) { // 需要上传合同协议 if (zyFlag) { // 需要上传合同协议
return this.setData({ showZyPopup: true }) // 上传合同协议弹窗 return this.setData({ showZyPopup: true }) // 上传合同协议弹窗
} }
// 跳转签名页面 // 跳转列表页面
wx.$router.redirectTo('signature', { id, orderId }) wx.$router.reLaunch("packageEquity.equityPage?tabIndex=1");
} }
}, 1000) }, 1000)
this.setData({timer}) this.setData({timer})
...@@ -74,9 +76,7 @@ Page({ ...@@ -74,9 +76,7 @@ Page({
}) })
if (code == 0) { if (code == 0) {
// 返回到报价单列表 // 返回到报价单列表
wx.$router.reLaunch("packageEquity.equityPage", { wx.$router.reLaunch("packageEquity.equityPage?tabIndex=1");
tabIndex: 1,
})
} else { } else {
wx.$util.showToast(message) wx.$util.showToast(message)
} }
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<view class="payInfo"> <view class="payInfo">
<view class="payCom"> <view class="payCom">
<view class="title">支付成功</view> <view class="title">支付成功</view>
<view class="payPrice">订单支付成功,实付 {{orderDetail.totalPrice}} 元</view> <view class="payPrice">订单支付成功,实付 {{orderDetail.finalPrice}} 元</view>
</view> </view>
<view class="tips"> <view class="tips">
<view class="title">温馨提示</view> <view class="title">温馨提示</view>
...@@ -20,11 +20,10 @@ ...@@ -20,11 +20,10 @@
</view> </view>
</view> </view>
<view class="order-info"> <view class="order-info">
<order-info OderType="detail" orderInfo="{{orderDetail}}" /> <order-info OderType="detail" orderInfo="{{orderDetail}}" />
</view> </view>
<view class="btn_box"> <view class="btn_box">
<Gl-Button-Group bindbtnTap="btnTap" wx:if="{{showBtnFlag}}" textNameObj="{{textNameObj}}" /> <Gl-Button-Group bindbtnTap="btnTap" wx:if="{{showBtnFlag}}" textNameObj="{{textNameObj}}" />
</view> </view>
<!-- 上传合同协议 --> <!-- 上传合同协议 -->
<zy-pay-popup show="{{showZyPopup}}" wx:if="{{showZyPopup}}" onlinePaymentFlag="{{true}}" bindconfirm="zyPayConfirm"></zy-pay-popup> <zy-pay-popup show="{{showZyPopup}}" wx:if="{{showZyPopup}}" onlinePaymentFlag="{{true}}" bindconfirm="zyPayConfirm"></zy-pay-popup>
\ No newline at end of file \ No newline at end of file
<!-- packageEquity/pages/carQuotation/CarQuotationPay/CarQuotationPay.wxml --> <!-- packageEquity/pages/carQuotation/CarQuotationPay/CarQuotationPay.wxml -->
<navigation-bar showBack navStyle="{{navStyle}}" bindback="back">订单支付</navigation-bar> <navigation-bar showBack navStyle="{{ navStyle }}" bindback="back">订单支付</navigation-bar>
<view class="big-img page-box isFullSucreen"> <view class="big-img page-box isFullSucreen">
<!-- <view class="titleBox"> <!-- <view class="titleBox">
<view class="imgBox" bind:tap="back"> <view class="imgBox" bind:tap="back">
...@@ -7,39 +7,35 @@ ...@@ -7,39 +7,35 @@
</view> </view>
<view class="navigation-title-text">订单支付</view> <view class="navigation-title-text">订单支付</view>
</view> --> </view> -->
<view class="money">总保费{{orderDetail.totalPrice}}元/年</view> <view class="money">总保费{{orderDetail.finalPrice}}元/年</view>
</view> </view>
<view class="OrderInfoPay"> <view class="OrderInfoPay">
<view class=" box"> <view class="box">
<view class="tab-head"> <view class="tab-head">
<view <view
class="tab-item {{selectPayType === item.id?'active':'' }}" class="tab-item {{ selectPayType === item.id?'active':'' }}"
wx:for="{{payItems}}" wx:for="{{ payItems }}"
wx:key="index" wx:key="index"
data-item="{{item}}" data-item="{{ item }}"
data-value="{{item.id}}" data-value="{{ item.id }}"
catchtap="changePayType"> catchtap="changePayType"
<gl-image >
class="btn_icon" <gl-image class="btn_icon" data-item="{{ item }}" webp src="/miniProgram/{{ item.icon }}.png"></gl-image>
data-item="{{item}}" {{item.name}}
webp </view>
src="/miniProgram/{{item.icon}}.png"></gl-image>
{{item.name}}
</view> </view>
<!-- 微信/pos机支付 -->
<block wx:if="{{ selectPayType == 1 || selectPayType == 3 }}">
<view class="pay-box">
<view class="tab-title">{{orderDetail.merchantName}}</view>
<view class="tab-qrcode">
<image src="{{ selectPayType==1?wxqrcode:posqrcode }}" mode="widthFix" />
</view>
<view class="tab-desc" hidden="{{ selectPayType==3 }}">请让客户打开微信扫描上方付款码进行支付</view>
<view class="tab-desc" hidden="{{ selectPayType==1 }}">请使用POS机扫描此码,再向客户收款</view>
</view>
</block>
</view> </view>
<!-- 微信/pos机支付 -->
<block wx:if="{{selectPayType == 1 || selectPayType == 3}}">
<view class="pay-box">
<view class="tab-title">{{orderDetail.merchantName}}</view>
<view class="tab-qrcode">
<image src="{{selectPayType==1?wxqrcode:posqrcode}}" mode="widthFix" />
</view>
<view class="tab-desc" hidden="{{selectPayType==3}}">请让客户打开微信扫描上方付款码进行支付</view>
<view class="tab-desc" hidden="{{selectPayType==1}}">请使用POS机扫描此码,再向客户收款</view>
</view>
</block>
</view>
<!-- <view class="qrCodeCom"> <!-- <view class="qrCodeCom">
<view class="title"> <view class="title">
<image <image
...@@ -76,7 +72,7 @@ ...@@ -76,7 +72,7 @@
<view class="bg" /> <view class="bg" />
</view> --> </view> -->
<view class="orderInfo"> <view class="orderInfo">
<order-detail OderType="pay" orderInfo="{{orderDetail}}" /> <order-detail OderType="pay" orderInfo="{{ orderDetail }}" />
</view> </view>
<view class="tips"> <view class="tips">
<view class="title">费用说明</view> <view class="title">费用说明</view>
...@@ -86,11 +82,7 @@ ...@@ -86,11 +82,7 @@
<view class="title">适用门店</view> <view class="title">适用门店</view>
<view class="storeComBox"> <view class="storeComBox">
<!-- mode="widthFix" --> <!-- mode="widthFix" -->
<image <image class="storeIcon" src="../../../images/storeIcon.png" binderror="" bindload="" />
class="storeIcon"
src="../../../images/storeIcon.png"
binderror=""
bindload="" />
<view class="store"> <view class="store">
<view class="name">{{merchantName4s}}</view> <view class="name">{{merchantName4s}}</view>
<!-- <view class="address">深圳市宝安区西乡大道与金湾大道交汇处(大铲湾世界名车博览中心内)</view> --> <!-- <view class="address">深圳市宝安区西乡大道与金湾大道交汇处(大铲湾世界名车博览中心内)</view> -->
...@@ -99,5 +91,4 @@ ...@@ -99,5 +91,4 @@
</view> </view>
</view> </view>
</view> </view>
<!-- <popup-select-pay show="{{popPayShow}}" bindconfirm="changePayType" /> --> <!-- <popup-select-pay show="{{popPayShow}}" bindconfirm="changePayType" /> -->
\ No newline at end of file \ No newline at end of file
...@@ -256,6 +256,19 @@ ...@@ -256,6 +256,19 @@
</view> </view>
</view> </view>
<view class="box"> <view class="box">
<view class="title">异常标记</view>
<view class="list-box">
<block wx:for="{{ form.abnormalFlag }}" wx:key="index">
<view
class="item text-center {{ item.active?'active':''}} {{item.disabled ?'disabled':'' }}"
bindtap="choose"
data-list-name="abnormalFlag"
data-index="{{ index }}"
>{{item.name}}</view>
</block>
</view>
</view>
<view class="box">
<view class="title">支付方式</view> <view class="title">支付方式</view>
<view class="list-box"> <view class="list-box">
<block wx:for="{{ form.payType }}" wx:key="index"> <block wx:for="{{ form.payType }}" wx:key="index">
......
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
"popup-input": "../PopupInput/PopupInput", "popup-input": "../PopupInput/PopupInput",
"goods": "../GoodsPackage/Goods", "goods": "../GoodsPackage/Goods",
"sku-goods": "/components/SkuGoods/Goods", "sku-goods": "/components/SkuGoods/Goods",
"date-select":"/components/DateSelect/dateSelect" "date-select":"/components/DateSelect/dateSelect",
"van-picker": "@vant/weapp/picker/index"
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -7,9 +7,28 @@ var replaceItemText = function (name, item) { ...@@ -7,9 +7,28 @@ var replaceItemText = function (name, item) {
return name ? name + item : '' return name ? name + item : ''
} }
var divideByHundred = function (str) {
var floatVal = parseFloat(str)
if (isNaN(floatVal)) {
return 0
}
floatVal = Math.round(str) / 100
var strVal = floatVal.toString()
var searchVal = strVal.indexOf('.')
if (searchVal < 0) {
searchVal = strVal.length
strVal += '.'
}
while (strVal.length <= searchVal + 2) {
strVal += '0'
}
return parseFloat(strVal)
}
/* /*
* 导出 * 导出
*/ */
module.exports = { module.exports = {
replaceItemText: replaceItemText replaceItemText: replaceItemText,
divideByHundred: divideByHundred
} }
// 0待报价、1待确认、2待支付、3已支付、4已支付 5(已完成)、-1战败 // 0待报价、1待确认、2待支付、3已支付、4已支付 5(已完成)、-1战败
const orderStatusObj = { const orderStatusObj = {
'0': '待报价', 0: '待报价',
'1': '待确认', 1: '待确认',
'2': '待支付', 2: '待支付',
'3': '已支付', 3: '已支付',
'4': '已支付', 4: '已支付',
'5': '已完成', 5: '已完成',
'-1': '战败', '-1': '战败',
'9': '已撤销', 9: '已撤销',
'11': '已失效', 11: '已失效',
'6': '已退款' 6: '已退款',
14: '审批中'
} }
const orderStatusList = [{ const orderStatusList = [
{
confName: '待报价', confName: '待报价',
confId: '0' confId: '0'
}, { },
{
confName: '待确认', confName: '待确认',
confId: '1' confId: '1'
}, { },
{
confName: '待支付', confName: '待支付',
confId: '2' confId: '2'
}, { },
{
confName: '已支付', confName: '已支付',
confId: '3' confId: '3'
}, { },
{
confName: '已完成', confName: '已完成',
confId: '5' confId: '5'
}, { },
{
confName: '已退款', confName: '已退款',
confId: '6' confId: '6'
}, },
...@@ -37,7 +44,8 @@ const orderStatusList = [{ ...@@ -37,7 +44,8 @@ const orderStatusList = [{
{ {
confName: '错误订单', confName: '错误订单',
confId: '11' confId: '11'
}, { },
{
confName: '战败', confName: '战败',
confId: '-1' confId: '-1'
} }
...@@ -46,4 +54,4 @@ const orderStatusList = [{ ...@@ -46,4 +54,4 @@ const orderStatusList = [{
export default { export default {
orderStatusObj, orderStatusObj,
orderStatusList orderStatusList
}
\ No newline at end of file \ No newline at end of file
}
...@@ -2,44 +2,86 @@ ...@@ -2,44 +2,86 @@
<glsx-privacy appletName="生意助手员工版" bind:agreeClick="agreeClick" bind:disagreeClick="disagreeClick"></glsx-privacy> <glsx-privacy appletName="生意助手员工版" bind:agreeClick="agreeClick" bind:disagreeClick="disagreeClick"></glsx-privacy>
<!-- <scroll-view class="container" scroll-y style="height:{{windowHeight}}px"> --> <!-- <scroll-view class="container" scroll-y style="height:{{windowHeight}}px"> -->
<navigation-bar class="navigation-header" bindnavbarReady="navbarReady" showBack="{{ true }}" bindback="back"> <navigation-bar class="navigation-header" bindnavbarReady="navbarReady" showBack="{{ true }}" bindback="back">
<view class="navigation-title"> <view class="navigation-title">
<view class="navigation-title-text text-hide"> <view class="navigation-title-text text-hide">车险信息</view>
车险信息 </view>
</view>
</view>
</navigation-bar> </navigation-bar>
<!-- {{scrollDisabled? "": height:{{windowHeight}}px}} --> <!-- {{scrollDisabled? "": height:{{windowHeight}}px}} -->
<view class="layout {{(showTips||waitInputCount)?'fullSucreen-tips':'' }} {{scrollDisabled?'scroll-disabled':''}}" style="padding-top:{{ navBarHeight }}px; "> <view
<first-step id="FirstStep" serviceInfo="{{ owner }}" dataAttrName="{{ dataAttrName }}" orderInfo="{{ orderInfo }}" subBtnShow="{{ false }}" mode="{{mode}}" /> class="layout {{ (showTips||waitInputCount)?'fullSucreen-tips':'' }} {{scrollDisabled?'scroll-disabled':'' }}"
<second-step id="SecondStep" orderInfo="{{ orderInfo }}" quotationGoodsList="{{ quotationGoodsList }}" bindconfirm="handleSecondConfirm" bindeditSave="handleEditSave" paymentMethod="{{paymentMethod}}" /> style="padding-top:{{ navBarHeight }}px;"
>
<first-step
id="FirstStep"
serviceInfo="{{ owner }}"
dataAttrName="{{ dataAttrName }}"
orderInfo="{{ orderInfo }}"
subBtnShow="{{ false }}"
mode="{{ mode }}"
/>
<second-step
id="SecondStep"
orderInfo="{{ orderInfo }}"
quotationGoodsList="{{ quotationGoodsList }}"
bindconfirm="handleSecondConfirm"
bindeditSave="handleEditSave"
paymentMethod="{{ paymentMethod }}"
totalFee="{{ totalFee }}"
bind:showTips="tipsEvent"
/>
</view> </view>
<view wx:if="{{showTips}}" class="btns {{isFullSucreen?'isFullSucreen-btn':''}}"> <view wx:if="{{ showTips && !orderInfo.resetOrder }}" class="btns {{ isFullSucreen?'isFullSucreen-btn':'' }}">
<view class="tips"> <view class="tips">
<image class=" tipsIcon" src="../../../images/tips.png" /> <image class="tipsIcon" src="../../../images/tips.png" />
<view class="contentText"> <view class="contentText">
<view class="tradeNoCon"> <view class="tradeNoCon">
<view>交易参考号:</view> <view>交易参考号:</view>
<view class="tradeNo text-hide">{{tradeNo}}</view> <view class="tradeNo text-hide">{{tradeNo}}</view>
<view>(共{{selectOutTradeNoArr.length}}条)</view> <view>(共{{selectOutTradeNoArr.length}}条)</view>
</view> </view>
<!-- <view>支付时间:{{accountDate}}</view> --> <!-- <view>支付时间:{{accountDate}}</view> -->
<view class="tipsbox"> <view class="tipsbox">
<view>支付金额:¥{{totalFee/100}}</view> <view>支付金额:¥{{totalFee/100}}</view>
<view class="tipsbtn" bindtap="tipsEvent">补录订单</view> <view class="tipsbtn" bindtap="tipsEvent">补录订单</view>
</view> </view>
</view> </view>
<!-- <image class="closeIcon" bindtap="closeTips" src="../../../images/closeIcon.png" /> --> <!-- <image class="closeIcon" bindtap="closeTips" src="../../../images/closeIcon.png" /> -->
</view> </view>
</view> </view>
<!-- </scroll-view> --> <!-- </scroll-view> -->
<!-- 2025-8月版本 隐藏补录订单入口 --> <!-- 2025-8月版本 隐藏补录订单入口 -->
<!-- <view class="waitOrderCon {{ showTips? 'showTips':'' }}" wx:if="{{ waitInputCount && !orderInfo.resetOrder && !isErrorOrder&&!outTradeNo }}"> <!-- <view class="waitOrderCon {{ showTips? 'showTips':'' }}" wx:if="{{ waitInputCount && !orderInfo.resetOrder && !isErrorOrder&&!outTradeNo }}">
<tips-bottom style="width: 100%;box-sizing: border-box;" tipsProps="{{ tipsProps }}" /> <tips-bottom style="width: 100%;box-sizing: border-box;" tipsProps="{{ tipsProps }}" />
</view> --> </view> -->
<order-no-popup wx:if="{{ showOrderpop && !(isErrorOrder) }}" outTradeNo="{{ selectOutTradeNoArr }}" switchValuerec="{{switchValue}}" show="{{ showOrderpop }}" bind:success="navigator" title="请选择交易参考号" /> <order-no-popup
<order-popup orderType="{{orderInfo.payType }}" resetTransNo="{{orderInfo.transactionNo || orderInfo.outTradeNo}}" resetOrder="{{orderInfo.resetOrder}}" orderInfo="{{orderInfo}}" wx:if="{{showPopup}}" show="{{showPopup}}" /> wx:if="{{ showOrderpop }}"
outTradeNo="{{ selectOutTradeNoArr }}"
switchValuerec="{{ switchValue }}"
show="{{ showOrderpop }}"
bind:success="navigator"
title="请选择交易参考号"
/>
<order-popup
orderType="{{ orderInfo.payType }}"
resetTransNo="{{ orderInfo.transactionNo || orderInfo.outTradeNo }}"
resetOrder="{{ orderInfo.resetOrder }}"
orderInfo="{{ orderInfo }}"
wx:if="{{ showPopup }}"
show="{{ showPopup }}"
/>
<!-- vin二次复核 --> <!-- vin二次复核 -->
<vin-sec-dialog wx:if="{{showVinDialog}}" showVinDialog="{{showVinDialog}}" secFormData="{{secFormData}}" bindonClose="handleSecClose" bindonConfirm="handleSecConfirm"></vin-sec-dialog> <vin-sec-dialog
wx:if="{{ showVinDialog }}"
showVinDialog="{{ showVinDialog }}"
secFormData="{{ secFormData }}"
bindonClose="handleSecClose"
bindonConfirm="handleSecConfirm"
></vin-sec-dialog>
<!-- 上传合同协议 --> <!-- 上传合同协议 -->
<zy-pay-popup show="{{showZyPopup}}" wx:if="{{showZyPopup}}" supplementaryFlag="{{supplementaryFlag}}" bindconfirm="zyPayConfirm"></zy-pay-popup> <zy-pay-popup
show="{{ showZyPopup }}"
wx:if="{{ showZyPopup }}"
supplementaryFlag="{{ supplementaryFlag }}"
bindconfirm="zyPayConfirm"
></zy-pay-popup>
<study-permission-modal id="customModal" /> <study-permission-modal id="customModal" />
\ No newline at end of file \ No newline at end of file
...@@ -324,6 +324,14 @@ ...@@ -324,6 +324,14 @@
background: #FFF5E6; background: #FFF5E6;
padding: var(--fontSize4) var(--fontSize8); padding: var(--fontSize4) var(--fontSize8);
border-radius: var(--fontSize4); border-radius: var(--fontSize4);
font-size: var(--fontSize24);
}
.approving-txt {
color: #FF9D0A;
background: #ff9d0a1a;
padding: var(--fontSize4) var(--fontSize8);
border-radius: var(--fontSize4);
} }
.list .content { .list .content {
...@@ -503,7 +511,7 @@ ...@@ -503,7 +511,7 @@
color: #347BFF; color: #347BFF;
} }
.refund-box{ .refund-box {
margin-left: var(--fontSize16); margin-left: var(--fontSize16);
background: #FFF2E0; background: #FFF2E0;
padding: var(--fontSize4) var(--fontSize8); padding: var(--fontSize4) var(--fontSize8);
...@@ -835,6 +843,7 @@ ...@@ -835,6 +843,7 @@
padding-left: var(--fontSize24); padding-left: var(--fontSize24);
margin: 0 auto; margin: 0 auto;
} }
.modalbox:last-child { .modalbox:last-child {
margin-top: var(--fontSize16); margin-top: var(--fontSize16);
} }
...@@ -865,65 +874,112 @@ ...@@ -865,65 +874,112 @@
width: calc(100% - 36rpx); width: calc(100% - 36rpx);
} }
.repeal-modal{ .repeal-modal {
background: rgba(0, 0, 0, 0.6); background: rgba(0, 0, 0, 0.6);
position: fixed; position: fixed;
top: 0; top: 0;
right: 0; right: 0;
left: 0; left: 0;
bottom: 0; bottom: 0;
z-index: 999; z-index: 999;
}
.repeal-wrap{
width: 622rpx;
height: 496rpx;
background: #FFFFFF;
border-radius: 20rpx;
transform: translate(-50%, -50%);
position: absolute;
top: 50%;
left: 50%;
padding: 40rpx 0 0;
box-sizing: border-box;
}
.repeal-wrap .title{
font-weight: 600;
font-size: 32rpx;
color: #222222;
text-align: center;
line-height: 48rpx;
}
.repeal-wrap .textarea-wrap{
margin: 40rpx 0;
padding: 0 40rpx ;
width: 100%;
box-sizing: border-box;
}
.repeal-wrap .textarea{
background: #F4F5F7;
width: 100%;
height: 224rpx;
padding: 24rpx;
box-sizing: border-box;
border-radius: 12rpx;
}
.repeal-wrap .footer{
position: absolute;
bottom: 0;
border-top: 2rpx solid #EBEDF0;
display: flex;
width: 100%;
}
.repeal-wrap .footer .btn{
height: 96rpx;
line-height: 96rpx;
flex: 1;
font-weight: 400;
font-size: 32rpx;
color: #333333;
text-align: center;
}
.repeal-wrap .footer .btn:last-child{
color: #3582EE;
border-left: 2rpx solid #EBEDF0;
} }
.repeal-wrap {
width: 622rpx;
height: 496rpx;
background: #FFFFFF;
border-radius: 20rpx;
transform: translate(-50%, -50%);
position: absolute;
top: 50%;
left: 50%;
padding: 40rpx 0 0;
box-sizing: border-box;
}
.repeal-wrap .title {
font-weight: 600;
font-size: 32rpx;
color: #222222;
text-align: center;
line-height: 48rpx;
}
.repeal-wrap .textarea-wrap {
margin: 40rpx 0;
padding: 0 40rpx;
width: 100%;
box-sizing: border-box;
}
.repeal-wrap .textarea {
background: #F4F5F7;
width: 100%;
height: 224rpx;
padding: 24rpx;
box-sizing: border-box;
border-radius: 12rpx;
}
.repeal-wrap .footer {
position: absolute;
bottom: 0;
border-top: 2rpx solid #EBEDF0;
display: flex;
width: 100%;
}
.repeal-wrap .footer .btn {
height: 96rpx;
line-height: 96rpx;
flex: 1;
font-weight: 400;
font-size: 32rpx;
color: #333333;
text-align: center;
}
.repeal-wrap .footer .btn:last-child {
color: #3582EE;
border-left: 2rpx solid #EBEDF0;
}
.error-order-box {
box-sizing: border-box;
padding: 16rpx;
border-radius: 8rpx;
// opacity: 1;
// border: 2rpx solid #181a1f1a;
background: #f7f8fa;
margin-bottom: 16rpx;
.label {
color: #999EA8;
margin-right: 30rpx;
}
.value {
color: #5A5E66;
}
.row+.row {
margin-top: 6rpx;
}
}
.abnormal-tag {
display: flex;
.text {
margin-left: 15rpx;
}
}
.error-icon {
display: inline-block;
width: 28rpx;
height: 24rpx;
margin-left: 9rpx;
// margin-right: 6rpx;
margin-top: 3rpx;
}
\ No newline at end of file \ No newline at end of file
// packageEquity/pages/clueList/components/EquityItem/EquityItem.js // packageEquity/pages/clueList/components/EquityItem/EquityItem.js
import itemMixin from "../itemMixins"; import itemMixin from '../itemMixins'
import { checkDailyReport, checkStudyTask } from "~/store/ModalToQueueControl"; import {
checkDailyReport,
checkStudyTask,
checkAbnormalOrder
} from '~/store/ModalToQueueControl'
Component({ Component({
behaviors: [itemMixin], behaviors: [itemMixin],
...@@ -8,7 +12,7 @@ Component({ ...@@ -8,7 +12,7 @@ Component({
* 组件的属性列表 * 组件的属性列表
*/ */
properties: { properties: {
data: Object, data: Object
}, },
/** /**
...@@ -17,37 +21,37 @@ Component({ ...@@ -17,37 +21,37 @@ Component({
data: { data: {
sceneTypeStatusMap: [ sceneTypeStatusMap: [
{ {
label: "精品加装", label: '精品加装',
key: "1", key: '1'
}, },
{ {
label: "权益服务", label: '权益服务',
key: "0", key: '0'
}, }
], ],
orderObj: [ orderObj: [
{ {
label: "升级价格", label: '升级价格',
key: "quotedPriceUpdate", key: 'quotedPriceUpdate',
unit: "¥", unit: '¥'
}, },
{ {
label: "支付时间", label: '支付时间',
key: "payTime", key: 'payTime'
}, }
], ],
orderStatusEnum: { orderStatusEnum: {
0: "待报价", 0: '待报价',
1: "待确认", 1: '待确认',
2: "待支付", 2: '待支付',
3: "已支付", 3: '已支付',
4: "权益提单已完成", 4: '权益提单已完成',
5: "完成", 5: '完成',
"-1": "战败", '-1': '战败',
9: "已撤销", 9: '已撤销',
11: "错误订单", 11: '错误订单'
}, },
selectType: 1, selectType: 1
}, },
/** /**
...@@ -56,15 +60,15 @@ Component({ ...@@ -56,15 +60,15 @@ Component({
methods: { methods: {
showAllFun() { showAllFun() {
this.setData({ this.setData({
showAll: !this.data.showAll, showAll: !this.data.showAll
}); })
}, },
selectType(e) { selectType(e) {
let { type } = e.currentTarget.dataset; let { type } = e.currentTarget.dataset
console.log(e, e.currentTarget.dataset, type); console.log(e, e.currentTarget.dataset, type)
this.setData({ this.setData({
selectType: type, selectType: type
}); })
}, },
// 确定是否要显示 // 确定是否要显示
showSelectType({ item = {} }) { showSelectType({ item = {} }) {
...@@ -72,40 +76,43 @@ Component({ ...@@ -72,40 +76,43 @@ Component({
this, this,
{ {
show: true, show: true,
title: "请选择录单入口", title: '请选择录单入口',
tabTitleShow: false, tabTitleShow: false,
success: (res) => { success: res => {
// 跳转新增订单页面 并带特定参数 // 跳转新增订单页面 并带特定参数
let { orderInfo, selectType } = this.data; let { orderInfo, selectType } = this.data
console.log(item, "showSelectType"); console.log(item, 'showSelectType')
if (selectType == 1) { if (selectType == 1) {
wx.$router.go("tabWorkOrder.createOrder", { wx.$router.go('tabWorkOrder.createOrder', {
...item, ...item
}); })
} else { } else {
wx.$router.go("tabWorkOrder.defeatOrder", { wx.$router.go('tabWorkOrder.defeatOrder', {
...item, ...item
}); })
} }
}, },
error: () => { }, error: () => {}
}, },
"#modal2" '#modal2'
); )
}, },
async jump() { async jump() {
// 校验是否填写昨日日报 // 校验是否填写昨日日报
let staffCheck = await checkDailyReport(); let staffCheck = await checkDailyReport()
if (staffCheck) return false;; if (staffCheck) return false
// 校验学习中心开单限制 // 校验学习中心开单限制
let staffStudyTask = await checkStudyTask() let staffStudyTask = await checkStudyTask()
if (staffStudyTask) return false if (staffStudyTask) return false
const { data } = this.data; // 校验异常订单
let params = {}; let abnormalOrderCheck = await checkAbnormalOrder()
if (abnormalOrderCheck) return false
const { data } = this.data
let params = {}
if (data.boutiqueOrders && data.boutiqueOrders.length) if (data.boutiqueOrders && data.boutiqueOrders.length)
params = data.boutiqueOrders[0]; params = data.boutiqueOrders[0]
// wx.$router.go('tabWorkOrder.createOrder', params) // wx.$router.go('tabWorkOrder.createOrder', params)
this.showSelectType({ item: params }); this.showSelectType({ item: params })
}, }
}, }
}); })
// packageEquity/pages/clueList/components/UpgradeItem/UpgradeItem.js // packageEquity/pages/clueList/components/UpgradeItem/UpgradeItem.js
import itemMixin from '../itemMixins' import itemMixin from '../itemMixins'
import { checkDailyReport, checkStudyTask } from "~/store/ModalToQueueControl"; import {
checkDailyReport,
checkStudyTask,
checkAbnormalOrder
} from '~/store/ModalToQueueControl'
Component({ Component({
behaviors: [itemMixin], behaviors: [itemMixin],
/** /**
...@@ -14,24 +18,26 @@ Component({ ...@@ -14,24 +18,26 @@ Component({
* 组件的初始数据 * 组件的初始数据
*/ */
data: { data: {
sceneTypeStatusMap: [{ sceneTypeStatusMap: [
label: '权益服务', {
key: '0' label: '权益服务',
}, key: '0'
{ },
label: '精品加装', {
key: '1' label: '精品加装',
}, key: '1'
}
], ],
orderObj: [{ orderObj: [
label: '升级价格', {
key: 'totalPrice', label: '升级价格',
unit: '¥' key: 'totalPrice',
}, unit: '¥'
{ },
label: '支付时间', {
key: 'successDate' label: '支付时间',
} key: 'successDate'
}
], ],
status: { status: {
1: '待跟进', 1: '待跟进',
...@@ -42,7 +48,7 @@ Component({ ...@@ -42,7 +48,7 @@ Component({
9: '已撤销', 9: '已撤销',
10: '已关闭', 10: '已关闭',
11: '已失效', 11: '已失效',
12: '已退款', 12: '已退款'
} }
}, },
...@@ -52,14 +58,15 @@ Component({ ...@@ -52,14 +58,15 @@ Component({
methods: { methods: {
async jump() { async jump() {
// 校验是否填写昨日日报 // 校验是否填写昨日日报
let staffCheck = await checkDailyReport(true); let staffCheck = await checkDailyReport(true)
if (staffCheck) return false;; if (staffCheck) return false
// 校验学习中心开单限制 // 校验学习中心开单限制
let staffStudyTask = await checkStudyTask() let staffStudyTask = await checkStudyTask()
if (staffStudyTask) return false if (staffStudyTask) return false
const { // 校验异常订单
data let abnormalOrderCheck = await checkAbnormalOrder()
} = this.data if (abnormalOrderCheck) return false
const { data } = this.data
let params = { let params = {
isClue: true isClue: true
} }
...@@ -67,4 +74,4 @@ Component({ ...@@ -67,4 +74,4 @@ Component({
wx.$router.go('createOrderCarQuotationSimple', params) wx.$router.go('createOrderCarQuotationSimple', params)
} }
} }
})
\ No newline at end of file \ No newline at end of file
})
// packageCrowdFunding/pages/homePage/index/index.js // packageCrowdFunding/pages/homePage/index/index.js
import { setConfigInfo } from "~/store/index"; import { setConfigInfo } from "~/store/index";
import { checkDailyReport, checkStudyTask } from "~/store/ModalToQueueControl"; import { checkDailyReport, checkStudyTask,checkAbnormalOrder } from "~/store/ModalToQueueControl";
import { getReceptionRecordList, getRecordDetailList, checkMissingReception, checkMerchantDirect } from "../../receptionRecordsApi"; import { getReceptionRecordList, getRecordDetailList, checkMissingReception, checkMerchantDirect } from "../../receptionRecordsApi";
import aiApi from "../../aiApi"; import aiApi from "../../aiApi";
import { getWaitAuditCountAPI, waitstaffstateAPI, getStaffTemplate } from "~/api/api"; import { getWaitAuditCountAPI, waitstaffstateAPI, getStaffTemplate } from "~/api/api";
...@@ -972,68 +972,6 @@ Component({ ...@@ -972,68 +972,6 @@ Component({
} }
}); });
}, },
checkStaffOrderStatus() {
let userInfo = wx.$util.getUserInfo();
let dateStaffPop = wx.$storage.get("dateStaffPop");
let nowDate = new Date().format("yyyy-MM-dd");
let {
sceneType,
default4SStoreInfo: { merchantId },
} = userInfo;
let dayBoolean = dateStaffPop?.date && nowDate == dateStaffPop?.date;
let flag = dateStaffPop?.[sceneType]?.[merchantId];
console.log(flag, "flag", dateStaffPop?.[sceneType], dateStaffPop?.[sceneType]?.[merchantId]);
// let num = 0
// 当天已查询过
if (dayBoolean && flag) {
// num = dateStaffPop?.num || 0
// num = num + 1
// num = 1
return;
}
orderStaffValid({
sceneType: userInfo.sceneType,
})
.then((result) => {
console.log(result, "orderStaffValid");
if (result.data) {
if (wx.__HAS_NOREPORT_MODAL || wx.__HAS_NOTLOGIN_MODAL) return false;
wx.__HAS_NOREPORT_MODAL = true;
wx.showModal({
title: "开单预警",
content: "您已超过三天未开单",
showCancel: false,
// cancelText: '取消', // '取消
cancelColor: "#292D33",
confirmText: "确定",
confirmColor: "#347BFF",
success(res) {
// if (res.confirm) {
// wx.$router.go('tabWorkOrder.staffDaily', {
// reportDate: hasNeedReport.date
// })
// }
},
complete: () => {
// 这个延迟的目的是为了避免短时间内重复弹出
// 你要是没有这个需要也可以去掉,直接把标志位改成 false 就行
setTimeout(() => {
wx.__HAS_NOREPORT_MODAL = false;
}, 2000);
},
});
wx.$storage.set("dateStaffPop", {
date: new Date().format("yyyy-MM-dd"),
0: {
[userInfo.default4SStoreInfo.merchantId]: true,
...dateStaffPop[0],
},
});
}
})
.catch((err) => {});
},
getStaffTargetTask() { getStaffTargetTask() {
return new Promise((resolve) => { return new Promise((resolve) => {
let userInfo = wx.$util.getUserInfo(); let userInfo = wx.$util.getUserInfo();
...@@ -1238,110 +1176,131 @@ Component({ ...@@ -1238,110 +1176,131 @@ Component({
navGo: throttle(async function (e) { navGo: throttle(async function (e) {
// debugger // debugger
// wx.$util.showLoading('跳转中...') // wx.$util.showLoading('跳转中...')
let { mode, taskId, merchantBrand, mentorFlag } = this.data; let { mode, taskId, merchantBrand, mentorFlag } = this.data
let { item } = e.currentTarget.dataset; let { item } = e.currentTarget.dataset
let userInfo = wx.$util.getUserInfo(); let userInfo = wx.$util.getUserInfo()
// 如果 item.path 相同,则不执行后续跳转 // 如果 item.path 相同,则不执行后续跳转
if (item.path === lastPath) { if (item.path === lastPath) {
console.log("路径一样"); console.log('路径一样')
return; // 直接返回,不执行后续逻辑 return // 直接返回,不执行后续逻辑
} }
// 解决路径不清空问题 // 解决路径不清空问题
setTimeout(() => { setTimeout(() => {
lastPath = null; lastPath = null
}, 2000); }, 2000)
lastPath = item.path; // 更新上一次的路径 lastPath = item.path // 更新上一次的路径
if (item.path == "tabWorkOrder.supervisorDaily") { if (item.path == 'tabWorkOrder.supervisorDaily') {
this.openWorkReportTemp(item); this.openWorkReportTemp(item)
return; return
} }
if (item.path) { if (item.path) {
if (item.menuText == "驻店目标") { if (item.menuText == '驻店目标') {
return wx.$router.go(item.path, { return wx.$router.go(item.path, {
id: taskId, id: taskId
}); })
} else { } else {
if (item.menuText === "培训资料") { if (item.menuText === '培训资料') {
let params = { let params = {
merchantId: userInfo?.default4SStoreInfo?.merchantId, merchantId: userInfo?.default4SStoreInfo?.merchantId,
staffUuid: userInfo?.uuid, staffUuid: userInfo?.uuid,
scene: 0, scene: 0,
taskId: 5, taskId: 5
}; }
commonApi.shutDownTaskApi(params); commonApi.shutDownTaskApi(params)
} }
// console.log(merchantBrand.findIndex((i) => ["鸿蒙智行"].includes(i.name)) == -1); // console.log(merchantBrand.findIndex((i) => ["鸿蒙智行"].includes(i.name)) == -1);
// debugger // debugger
if (item.menuText == "战败下单" && merchantBrand.findIndex((i) => ["鸿蒙智行"].includes(i.name)) == -1) { if (
item.path = "packageEquity.createDeafeatOrder"; item.menuText == '战败下单' &&
merchantBrand.findIndex(i => ['鸿蒙智行'].includes(i.name)) == -1
) {
item.path = 'packageEquity.createDeafeatOrder'
} }
if (item.menuText == "战败下单") { if (item.menuText == '战败下单') {
// 校验是否填写昨日日报 // 校验是否填写昨日日报
let staffCheck = await checkDailyReport(true); let staffCheck = await checkDailyReport(true)
if (staffCheck) return false; if (staffCheck) return false
// 校验学习中心开单限制 // 校验学习中心开单限制
let staffStudyTask = await checkStudyTask(); let staffStudyTask = await checkStudyTask()
if (staffStudyTask) return false; if (staffStudyTask) return false
// 校验异常订单
let abnormalOrderCheck = await checkAbnormalOrder()
if (abnormalOrderCheck) return false
} }
if (item.path == "packageEquity.start") { if (item.path == 'packageEquity.start') {
wx.$track.setTrackData(0, "aiCheck_page", {}, "", 0); wx.$track.setTrackData(0, 'aiCheck_page', {}, '', 0)
} }
if (item.path == "packageEquity.clueList") { if (item.path == 'packageEquity.clueList') {
wx.$track.setTrackData(0, "leads_page", {}, "", 0); wx.$track.setTrackData(0, 'leads_page', {}, '', 0)
} }
// 飞行督导点击带教管理入口埋点 // 飞行督导点击带教管理入口埋点
if (item.path == "tabWorkOrder.mentorshipManage" && userInfo?.loginRole == 6) { if (
wx.$track.setTrackData(0, "mentorship_page", {}, "", 0); item.path == 'tabWorkOrder.mentorshipManage' &&
userInfo?.loginRole == 6
) {
wx.$track.setTrackData(0, 'mentorship_page', {}, '', 0)
} }
// 飞行督导/导师点击延保区域日报入口埋点 // 飞行督导/导师点击延保区域日报入口埋点
if (item.path == "tabWorkOrder.supervisorDaily" && (userInfo?.loginRole == 6 || mentorFlag)) { if (
wx.$track.setTrackData(0, "supervisor_daily_page", {}, "", 0); item.path == 'tabWorkOrder.supervisorDaily' &&
(userInfo?.loginRole == 6 || mentorFlag)
) {
wx.$track.setTrackData(0, 'supervisor_daily_page', {}, '', 0)
} }
// 接待记录埋点 // 接待记录埋点
if (item.path == "packageEquity.receptionRecords") { if (item.path == 'packageEquity.receptionRecords') {
wx.$track.setTrackData(0, "reception_records", {}, "", 0); wx.$track.setTrackData(0, 'reception_records', {}, '', 0)
} }
return wx.$router.go(item.path, { return wx.$router.go(item.path, {
scene: 0, scene: 0,
params: item.params || {}, params: item.params || {}
}); })
} }
} else { } else {
// 场景集市添加埋点 // 场景集市添加埋点
if (item.menuText == "场景集市") { if (item.menuText == '场景集市') {
wx.$track.setTrackData(0, "scenario_marketplace", {}, "", 0); wx.$track.setTrackData(0, 'scenario_marketplace', {}, '', 0)
} }
if (item.navigateToUrl) { if (item.navigateToUrl) {
wx.navigateTo({ wx.navigateTo({
url: item.navigateToUrl, url: item.navigateToUrl
}); })
return; return
} }
// 工资绩效特殊处理 // 工资绩效特殊处理
if (item.menuText == "工资绩效") { if (item.menuText == '工资绩效') {
return wx.$router.go("packageEquity.collegeScene", { return wx.$router.go('packageEquity.collegeScene', {
reLaunchPath: "packageEquity.equityPage", reLaunchPath: 'packageEquity.equityPage',
tabIndex: 0, tabIndex: 0
}); })
} }
// 校验是否填写昨日日报 // 校验是否填写昨日日报
let staffCheck = await checkDailyReport(true); let staffCheck = await checkDailyReport(true)
console.log(staffCheck, "staffCheck"); console.log(staffCheck, 'staffCheck')
if (staffCheck) return false; if (staffCheck) return false
// 校验学习中心开单限制 // 校验学习中心开单限制
let staffStudyTask = await checkStudyTask(); let staffStudyTask = await checkStudyTask()
if (staffStudyTask) return false; if (staffStudyTask) return false
// 校验异常订单
let abnormalOrderCheck = await checkAbnormalOrder()
if (abnormalOrderCheck) return false
/**禁止提单 */ /**禁止提单 */
if (item.beforeClick && (await wx.$globalDataFunction[item.beforeClick]())) return; if (
if (merchantBrand?.findIndex((i) => ["鸿蒙智行"].includes(i.name)) != -1) { item.beforeClick &&
wx.$router.go("beforeCreate", { (await wx.$globalDataFunction[item.beforeClick]())
mode, )
}); return
if (
merchantBrand?.findIndex(i => ['鸿蒙智行'].includes(i.name)) != -1
) {
wx.$router.go('beforeCreate', {
mode
})
} else { } else {
this.setData({ this.setData({
showPromptDialog: true, showPromptDialog: true
}); })
} }
} }
}, 2000), }, 2000),
......
...@@ -314,7 +314,7 @@ Page({ ...@@ -314,7 +314,7 @@ Page({
}) })
getRecruitDetailAPI({ getRecruitDetailAPI({
id: id id
}) })
.then(res => { .then(res => {
let { let {
......
// const api = wx.$request
import api from '~/utils/request/request.js'
// const api = wx.$request
module.exports = {
/** 工资申诉概览信息查询:
* appealMonth-申诉月份(YYYY-MM)
*/
getSummaryInfo(data) {
return api.post(
'dj.api.staff.miniprogram.salaryapply.summary',
data,
[],
'/rop-dj-staff-miniprogram/router'
)
},
/** 工资申诉订单统计查询
* appealMonth-申诉月份(YYYY-MM)
* sceneType-(0-会员权益/升级;1-精品升级;2-次新车转化;3-售后众筹;4-积分商城)
* merchantId- 4S店ID
*/
getStatistics(data) {
return api.post(
'dj.api.staff.miniprogram.salaryapply.order.statistics',
data,
[],
'/rop-dj-staff-miniprogram/router'
)
},
/** 工资申诉复议记录查询
* appealMonth-申诉月份(YYYY-MM)
*/
getReplyList(data) {
return api.post(
'dj.api.staff.miniprogram.salaryapply.reply.list',
data,
[],
'/rop-dj-staff-miniprogram/router'
)
},
/** 新增平板录音申诉
* appealType-申诉类型(1:考勤,2:平板录音)
* appealMonth-sceneType-merchantId-padRecordNum
*/
createSalaryapply(data) {
return api.post(
'dj.api.staff.miniprogram.salaryapply.pad.create',
data,
[],
'/rop-dj-staff-miniprogram/router'
)
},
/** 工资申诉最新记录查询
* appealMonth-申诉月份(YYYY-MM)
* appealType-申诉类型(1:考勤,2:平板录音)
*/
getApplyLatest(data) {
return api.post(
'dj.api.staff.miniprogram.salaryapply.latest',
data,
[],
'/rop-dj-staff-miniprogram/router'
)
},
/** 4s店查询对应的园区店 */
querySceneRefByShop(data) {
return api.post('dj.api.scenemerchantref.querySceneRefByShop', data)
},
/** 获取所有销售列表 */
getEmployeeAllList(data) {
return api.post('dj.api.smartcarlife.employee.getAll', data)
},
}
{
"component": true,
"usingComponents": {
"van-popup": "@vant/weapp/popup/index",
"van-uploader": "@vant/weapp/uploader/index"
}
}
.popup-content {
height: 100%;
display: flex;
flex-direction: column;
background: #fff;
}
.van-popup--bottom {
border-radius: var(--fontSize20) var(--fontSize20) 0 0 !important;
}
.popup-fixed-top {
flex: 0 0 auto;
}
.popup-fixed-bottom {
flex: 0 0 auto;
padding: var(--fontSize20) var(--fontSize40);
border-top: var(--fontSize2) solid #E8E8EA;
}
.popup-scroll-area {
flex: 1;
overflow-y: auto;
box-sizing:border-box;
padding: var(--fontSize30) var(--fontSize32);
}
::-webkit-scrollbar {
display: none;
width: 0;
height: 0;
color: transparent;
background: transparent;
}
.popup-title {
height: var(--fontSize110);
line-height: var(--fontSize110);
font-size: var(--fontSize32);
font-weight: 500;
text-align: center;
border-bottom: var(--fontSize2) solid #E8E8EA;
color: #292d33;
}
.notice-text {
font-size: var(--fontSize24);
color: #292d33;
line-height: 1.67;
padding:var(--fontSize24) 0;
.notice-date {
font-weight: 600;
color: #292D33;
}
}
.form-item {
padding: var(--fontSize28) 0;
&:last-child {
margin-bottom: 0;
}
&.form-item-row {
display: flex;
align-items: center;
justify-content: space-between;
.form-label {
margin-bottom: 0;
flex-shrink: 0;
margin-right: var(--fontSize20);
}
}
}
.form-label {
font-size: var(--fontSize28);
color: #292D33;
margin-bottom: var(--fontSize20);
}
.form-value {
font-size: var(--fontSize28);
color: #292D33;
font-weight: 500;
flex-shrink: 0;
text {
color: #2A82E4;
}
}
.form-input-wrapper {
display: flex;
align-items: center;
height: var(--fontSize80);
flex: 1;
max-width: var(--fontSize280);
}
.form-input {
flex: 1;
font-size: var(--fontSize28);
color: #333;
height: 100%;
border-radius: var(--fontSize12);
border: var(--fontSize2) solid #eff0f2;
padding: 0 var(--fontSize20);
box-sizing: border-box;
text-align: right;
}
.form-unit {
font-size: var(--fontSize28);
color: #666;
margin-left: var(--fontSize12);
}
.upload-wrapper {
margin-top: var(--fontSize10);
position: relative;
}
.upload-count-badge {
position: absolute;
bottom: var(--fontSize20);
left: 50%;
transform: translateX(-50%);
font-size: var(--fontSize24);
color: #999;
z-index: 2;
}
.plus {
::v-deep .van-uploader__wrapper {
display: flex;
flex-wrap: wrap;
gap: var(--fontSize20);
}
::v-deep .van-uploader__upload {
width: var(--fontSize160);
height: var(--fontSize160);
background: #f5f5f5;
border: var(--fontSize2) dashed #eff0f2;
border-radius: var(--fontSize8);
}
::v-deep .van-uploader__preview {
width: var(--fontSize160);
height: var(--fontSize160);
border-radius: var(--fontSize8);
overflow: hidden;
}
::v-deep .van-uploader__upload-text {
font-size: var(--fontSize24);
color: #999999;
}
::v-deep .van-icon-photograph:before {
content: '' !important;
width: var(--fontSize32) !important;
height: var(--fontSize32) !important;
background-image: url('https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/miniProgram/icon-plus.png') !important;
background-size: 100% 100% !important;
}
}
.upload-wrapper .plus .van-icon-photograph:before {
content: '' !important;
width: var(--fontSize32) !important;
height: var(--fontSize32) !important;
background-image: url('https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/miniProgram/icon-plus.png') !important;
background-size: 100% 100% !important;
}
.form-textarea {
width: 100%;
box-sizing: border-box;
height: var(--fontSize192);
padding: var(--fontSize24);
font-size: var(--fontSize28);
color: #333;
background: #f5f5f5;
border-radius: var(--fontSize16);
line-height: 1.6;
}
.char-count {
text-align: right;
font-size: var(--fontSize24);
color: #999;
margin-top: var(--fontSize10);
}
.popup-buttons {
display: flex;
gap: var(--fontSize24);
}
.cancel-btn, .confirm-btn {
flex: 1;
height: var(--fontSize80);
border-radius: var(--fontSize12);
font-size: var(--fontSize32);
line-height: var(--fontSize80);
text-align: center;
}
.cancel-btn {
background: #F4F5F7;
color: #323233;
border: var(--fontSize2) solid #E8E8EA;
}
.confirm-btn {
background: #347BFF;
color: #fff;
&.disabled {
background:rgba(52, 123, 255, 0.37);
color: #F4F5F7;
cursor: not-allowed;
}
}
<wxs module="utils">
// 计算upload-text(适配数组结构)
var getUploadText = function(imageList, maxCount, defaultText) {
var currentCount = 0;
if (imageList && imageList.length != null) {
// 获取已完成文件的数量(status === 'done' 或没有 status 字段,说明是编辑回显的数据)
for (var i = 0; i < imageList.length; i++) {
var file = imageList[i];
if (file) {
// 如果 status 是 'done' 或者没有 status 字段(编辑回显的数据),都计算在内
if (!file.status || file.status === 'done') {
currentCount = currentCount + 1;
}
}
}
}
var max = maxCount ? (maxCount - 0) : 1;
if (max > 1) {
return '('+currentCount+'/'+max+')';
}
return defaultText || '(' + max + ')';
};
module.exports = {
getUploadText: getUploadText
};
</wxs>
<van-popup show="{{ show }}" position="bottom"custom-style="height: 90%; border-radius: 12px 12px 0 0;" bind:close="onClose">
<view class="popup-content">
<view class="popup-fixed-top">
<view class="popup-title">{{ title }}</view>
</view>
<scroll-view class="popup-scroll-area" scroll-y="{{ true }}" scroll-top="{{ scrollTop }}" scroll-with-animation="{{ false }}" show-scrollbar="{{ false }}">
<view class="notice-text">
规定申诉时间为 <text class="notice-date">{{ dateRange }}</text>,支持提交修订异议处理,总部流转审批,请在规定时间内完成,逾期不再受理。
</view>
<view class="form-item form-item-row">
<view class="form-label">{{ currentLabel }}</view>
<view class="form-value"> <text>{{ form.actualAttendanceDays || form.padRecordNum }}</text> {{ unit }}</view>
</view>
<view class="form-item form-item-row">
<view class="form-label">{{ appealLabel }}</view>
<view class="form-input-wrapper">
<input class="form-input" placeholder="{{ appealType === 'recording' ? '输入正确条数' : '输入正确数字' }}" value="{{ appealType === 'recording' ? form.applyPadRecordNum : form.applyActualAttendanceDays }}" bindinput="onAppealNumInput" />
<text class="form-unit">{{ unit }}</text>
</view>
</view>
<view class="form-item">
<view class="form-label">上传截图说明</view>
<view class="upload-wrapper">
<van-uploader class="plus" file-list="{{ form.attachmentList }}" upload-text="{{ utils.getUploadText(form.attachmentList, 9, '上传照片') }}" max-count="9" multiple="{{ true }}" deletable preview-size="var(--fontSize160)" bind:after-read="onImageAfterRead" bind:delete="onImageDelete"></van-uploader>
</view>
</view>
<view class="form-item">
<view class="form-label">备注说明</view>
<textarea class="form-textarea" placeholder="请输入(500字以内)" value="{{ form.remark }}" bindinput="onRemarkInput" maxlength="500"></textarea>
<view class="char-count">{{ form.remark.length }}/500</view>
</view>
<view class="form-item">
<view class="form-label">其他异常问题留言</view>
<textarea class="form-textarea" placeholder="请输入(500字以内)" value="{{ form.otherAbnormalMessage }}" bindinput="onOtherIssuesInput" maxlength="500"></textarea>
<view class="char-count">{{ form.otherAbnormalMessage.length }}/500</view>
</view>
</scroll-view>
<view class="popup-fixed-bottom">
<view class="popup-buttons">
<view class="cancel-btn" bindtap="onClose">取消</view>
<view class="confirm-btn {{ isFormValid ? '' : 'disabled' }}" bindtap="onConfirm">确认</view>
</view>
</view>
</view>
</van-popup>
// compoents/monthCalendar/monthCalendar.js
Component({
options: {
multipleSlots: true // 在组件定义时的选项中启用多slot支持
},
/** * 组件的属性列表 * 用于组件自定义设置 */
properties: {
index: {
type: Number
}
},
/**
* 组件的初始数据
*/
data: {
selectMonth: -1, // 默认显示上个月,0代表本月,-1代表上个月,1代表下个月
timeBean: {}
},
/**
* 组件生命周期函数--在组件实例刚刚被创建时执行
*/
lifetimes: {
attached: function() {
// 初始化时间数据,默认显示上个月
const timeBean = this.getMonthData(-1)
this.setData({
timeBean
})
// 通知父组件初始月份
this.triggerEvent('monthChange', {
timeBean: timeBean,
selectMonth: -1
})
}
},
/**
* 组件的方法列表
*/
methods: {
/**
* 获取月份数据
* selectMonth: 0代表本月,-1代表上个月,1代表下个月
*/
getMonthData: function(selectMonth) {
const now = new Date()
const currentYear = now.getFullYear()
const currentMonth = now.getMonth() + 1 // 当前月份(1-12)
// 计算目标月份
let targetYear = currentYear
let targetMonth = currentMonth + selectMonth
// 处理跨年
while (targetMonth < 1) {
targetMonth += 12
targetYear -= 1
}
while (targetMonth > 12) {
targetMonth -= 12
targetYear += 1
}
// 检查是否在一年范围内(从当前月份往前推12个月,即从去年当前月到今年当前月)
// 例如:当前是2024年3月,可查看范围是2023年3月到2024年3月
const minYear = currentYear - 1
const minMonth = currentMonth
const maxYear = currentYear
const maxMonth = currentMonth
// 判断是否在范围内:不能超过当前月,不能早于一年前
const isAfterCurrentMonth = (targetYear > maxYear) || (targetYear === maxYear && targetMonth > maxMonth)
const isBeforeOneYear = (targetYear < minYear) || (targetYear === minYear && targetMonth < minMonth)
const isWithinRange = !isAfterCurrentMonth && !isBeforeOneYear
// 格式化月份显示
const yearMonth = targetYear + '-' + (targetMonth < 10 ? '0' + targetMonth : targetMonth)
const yearMonthLabel = targetYear + '-' + targetMonth + ''
// 判断是否应该显示"下个月"按钮
const shouldShowNextMonth = selectMonth < -1 // 只有selectMonth < -1时才显示下个月按钮
// 判断是否应该显示"上个月"按钮:如果往前一个月还在范围内,则显示
const nextSelectMonth = selectMonth - 1
let nextTargetYear = currentYear
let nextTargetMonth = currentMonth + nextSelectMonth
// 处理跨年
while (nextTargetMonth < 1) {
nextTargetMonth += 12
nextTargetYear -= 1
}
while (nextTargetMonth > 12) {
nextTargetMonth -= 12
nextTargetYear += 1
}
const nextIsAfterCurrentMonth = (nextTargetYear > maxYear) || (nextTargetYear === maxYear && nextTargetMonth > maxMonth)
const nextIsBeforeOneYear = (nextTargetYear < minYear) || (nextTargetYear === minYear && nextTargetMonth < minMonth)
const nextIsWithinRange = !nextIsAfterCurrentMonth && !nextIsBeforeOneYear
const shouldShowLastMonth = nextIsWithinRange
return {
yearMonth: yearMonthLabel,
formatYearMonth: yearMonth,
selectMonth: selectMonth,
isCurrentMonth: selectMonth === 0,
isWithinRange: isWithinRange,
targetYear: targetYear,
targetMonth: targetMonth,
shouldShowNextMonth: shouldShowNextMonth,
shouldShowLastMonth: shouldShowLastMonth
}
},
/**
* 点击了上一月,选择月份数字减一
*/
lastMonth: function (e) {
// 触发短震动反馈
wx.vibrateShort()
var selectMonth = this.data.selectMonth - 1
var timeBean = this.getMonthData(selectMonth)
// 检查是否超出一年范围
if (!timeBean.isWithinRange) {
// wx.showToast({
// title: '仅支持查看一年内的月份',
// icon: 'none'
// })
return
}
this.setData({
timeBean,
selectMonth
})
// 触发月份切换事件,通知父组件
this.triggerEvent('monthChange', {
timeBean: timeBean,
selectMonth: selectMonth
})
},
/**
* 点击了下一月,选择月份数字加一
*/
nextMonth: function (e) {
// 触发短震动反馈
wx.vibrateShort()
var selectMonth = this.data.selectMonth + 1
// 检查是否超出范围:只能选择当前月的上一月或更早的月份(selectMonth <= -1)
// 如果selectMonth >= 0,说明下个月是当前月或未来月份,不应该可选
if (selectMonth >= 0) {
// wx.showToast({
// title: '只能选择当前月的上一月',
// icon: 'none'
// })
return
}
var timeBean = this.getMonthData(selectMonth)
// 检查是否超出一年范围
if (!timeBean.isWithinRange) {
// wx.showToast({
// title: '仅支持查看一年内的月份',
// icon: 'none'
// })
return
}
this.setData({
timeBean,
selectMonth
})
// 触发月份切换事件,通知父组件
this.triggerEvent('monthChange', {
timeBean: timeBean,
selectMonth: selectMonth
})
}
}
})
{
"component": true,
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
/* tabWorkOrder/pages/staffDaily/weekCalendar/weekCalendar.wxss */
/* compoents/weekCalendar/weekCalendar.wxss */
.row {
display: flex;
flex-direction: column;
justify-content: space-around;
align-items: center;
background: #fff;
.week_box {
height: var(--fontSize60);
width: 100%;
display: flex;
justify-content: space-around;
align-items: center;
box-shadow: 0 var(--fontSize4) var(--fontSize8) 0 #cdcdd159;
}
.date_box {
height: var(--fontSize128);
width: 100%;
display: flex;
justify-content: space-around;
align-items: center;
}
.left {
margin-left: 10rpx;
}
.right {
margin-right: 20rpx;
}
}
.weekselect {
height: var(--fontSize80);
flex-direction: row;
justify-content: space-between;
}
.column {
display: flex;
flex-flow: column;
align-items: center;
justify-content: center;
flex: 1;
}
.nextWeek {
font-family: PingFangSC-Regular;
font-weight: 400;
flex-direction: row;
color: #181A1F;
width: var(--fontSize200);
font-size: 28rpx;
}
.dateType {
position: relative;
display: flex;
align-items: center;
justify-content: center;
font-size: var(--fontSize32);
color: #292D33;
border-radius: 50%;
width: var(--fontSize64);
height: var(--fontSize64);
.empty {
box-sizing: border-box;
position: absolute;
width: var(--fontSize38);
text-align: center;
height: var(--fontSize32);
background: #F24724;
border-radius: var(--fontSize16);
bottom: var(--fontSize40);
left: var(--fontSize40);
font-size: var(--fontSize22);
z-index: 2;
padding: 0 var(--fontSize4);
color: #fff;
}
}
.dateType.dateType_disabled {
color: #BEC1C7;
}
.weekType {
font-size: var(--fontSize28);
color: #292D33;
}
.select-column {
.dateType {
background: #347BFF;
color: #fff;
}
}
.disabled {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding-bottom: var(--fontSize5);
padding-top: var(--fontSize5);
margin-left: var(--fontSize5);
margin-right: var(--fontSize5);
margin-top: var(--fontSize10);
flex: 1;
border-top-left-radius: var(--fontSize20);
border-top-right-radius: var(--fontSize20);
background: #F6FCFE;
color: #292D33;
}
.timeType {
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: var(--fontSize28);
color: #181A1F;
width: 280rpx;
height: 64rpx;
text-align: center;
line-height: 64rpx;
border-radius: 20px;
background: #f2f3f5;
}
.line {
height: var(--fontSize1);
width: 100%;
background-color: gainsboro;
}
.lastweek {
width: var(--fontSize200);
font-family: PingFangSC-Regular;
font-weight: 400;
font-size: var(--fontSize28);
flex-direction: row;
color: #181A1F;
}
.line-shadow {
height: var(--fontSize3);
width: 100%;
background-color: gainsboro;
box-shadow: 5px 0px 5px 0px gainsboro;
}
@font-face {
font-family: "iconfont";
src: url('iconfont.eot?t=1533031583450');
/* IE9*/
src: url('iconfont.eot?t=1533031583450#iefix') format('embedded-opentype'),
/* IE6-IE8 */
url('data:application/x-font-woff;charset=utf-8;base64,d09GRgABAAAAAAZsAAsAAAAACRQAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABHU1VCAAABCAAAADMAAABCsP6z7U9TLzIAAAE8AAAARAAAAFZW70iqY21hcAAAAYAAAAB4AAABwJvIBhZnbHlmAAAB+AAAAkwAAAKQdkD3EWhlYWQAAAREAAAAMQAAADYSKu8/aGhlYQAABHgAAAAgAAAAJAfdA4hobXR4AAAEmAAAABgAAAAYF+r//2xvY2EAAASwAAAADgAAAA4CUAFWbWF4cAAABMAAAAAfAAAAIAEVAF1uYW1lAAAE4AAAAUUAAAJtPlT+fXBvc3QAAAYoAAAAQgAAAFjpq2VXeJxjYGRgYOBikGPQYWB0cfMJYeBgYGGAAJAMY05meiJQDMoDyrGAaQ4gZoOIAgCKIwNPAHicY2Bk/sM4gYGVgYOpk+kMAwNDP4RmfM1gxMjBwMDEwMrMgBUEpLmmMDgwVDzbztzwv4EhhrmVoREozAiSAwAyfQ0teJzFkcENhDAMBMcEIoQo5T60cG9q4cWDyqAjt8GtYz5XAWtNZK8cOXKAASjiI3qwHSO0ybXmF6bm93xVT4x0isOrL37dt7zMz5anTH0ZkQ+628UUq7wme2/0v+Z2rk8V+z8e9ESvSfi+JPEvfibaI34llB8XahpqeJxlUTtoFGEQ/uf/s8/s43b39pm7vdtdb1cTvXCbuz0f5ILGQo+gEYOoVQQbidEqpFE8CAE1IQg2KbQRwdIuAUmTWNtaCBZBC1GwujK355/a4ZsPZoaBb75BDELDQ7JHHGSgk6iBLqN5hICdgFDBZQiSZh1PgBkwpl1USBIlAReFdTINdsgWrTRrxjbLsSoo4MNUkGZJHSfQanbwBUitMoA75t3UayWdvALRSfz1vIvfgVmJSmrnTH719EwxrRr8qqTrrq5v8izD8BiPqAos25bACCKbv2dUz9yrnMIVkNzEm7sjV8f0e8+bj8o1WwDo9cAYqyofZjRPo3jiWYbucgWZdzw5OlGE1Z+jjiGV4x+IBhwT7uO/CCMkgAYS/IJe/hp/+3+G+7kDPVgexAiR4XD4bASRdSQgGwUIufRam9FqMVvjNAVUqHWgrdWB0FRBa3cAQhc+5jfckBxsg2+vwKwX0uZ38K2dHcsn84NKqSFuk/vbvKNdGvilc4X5FaFRwocl9+g35YL64ujNS/X8sawR+qMB2SAsStA0mkVdKrcZJ1ErTurAUSjAsccUKWBSZWbRovZn09CBWmanWTvO2pll+0CF2ZYdZBC1aEGXk0ABsiGLqtbyUq3w4Nbc7cLFcd1hbVHGa8u63Fe0h2uDpeAsL2OYWegusEQVSaMcyoO3Imx9nXrcXNr6LOFP8gH8ESXA3UDloXEdc9cSPG5M2iCJT/cnFxXDUBYn978EROC4u6NwJRZHCUDBTINcmKUWVsnu5uYu+gfDb3VreJxjYGRgYADi/KUVefH8Nl8ZuFkYQOB6W+h8GP3///96FgbmViCXg4EJJAoATnwMXwAAAHicY2BkYGBu+N/AEMPC+P8/AwMLAwNQBAWwAQB19gRuBAAAAAPpAAAEAAAABAAAAAQB//8EAAAAAAAAAAB2AIQAkgDSAUgAAHicY2BkYGBgYwhkYGUAASYg5gJCBob/YD4DABFIAXMAeJxlj01OwzAQhV/6B6QSqqhgh+QFYgEo/RGrblhUavdddN+mTpsqiSPHrdQDcB6OwAk4AtyAO/BIJ5s2lsffvHljTwDc4Acejt8t95E9XDI7cg0XuBeuU38QbpBfhJto41W4Rf1N2MczpsJtdGF5g9e4YvaEd2EPHXwI13CNT+E69S/hBvlbuIk7/Aq30PHqwj7mXle4jUcv9sdWL5xeqeVBxaHJIpM5v4KZXu+Sha3S6pxrW8QmU4OgX0lTnWlb3VPs10PnIhVZk6oJqzpJjMqt2erQBRvn8lGvF4kehCblWGP+tsYCjnEFhSUOjDFCGGSIyujoO1Vm9K+xQ8Jee1Y9zed0WxTU/3OFAQL0z1xTurLSeTpPgT1fG1J1dCtuy56UNJFezUkSskJe1rZUQuoBNmVXjhF6XNGJPyhnSP8ACVpuyAAAAHicY2BigAAuBuyAjZGJkZmRhZGVkY2RnYGxgrs4MS8rMzE/JzWthAfKLspMzyhhTcrPzzZkzc1MS8xjYAAAPg4OSAAA') format('woff'),
url('iconfont.ttf?t=1533031583450') format('truetype'),
/* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
url('iconfont.svg?t=1533031583450#iconfont') format('svg');
/* iOS 4.1- */
}
.icon {
width: 36rpx;
height: 36rpx;
}
.iconfont {
font-family: "iconfont" !important;
font-size: 16px;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
/**
*字体图标,左右箭头,书,米饭,可以修改界面对图标进行修改替换
*/
.icon-sanjiaoleft:before {
content: "\e6b6";
}
.icon-sanjiaoright:before {
content: "\e6b7";
}
.icon-book1:before {
content: "\e631";
}
.icon-mifan:before {
content: "\e606";
}
\ No newline at end of file \ No newline at end of file
<!--tabWorkOrder/pages/staffDaily/weekCalendar/weekCalendar.wxml-->
<!--compoents/weekCalendar/weekCalendar.wxml-->
<view class="line"></view>
<view class="row weekselect">
<view class="row lastweek" bindtap="lastMonth">
<block wx:if="{{ timeBean.shouldShowLastMonth }}">
<!-- <text class="iconfont icon-sanjiaoleft" style="padding:var(--fontSize15);color: #bec1c7;"></text> -->
<gl-image class="icon left" src="{{ '/miniProgram/arrow-left.png' }}" webp></gl-image>
<view style="">上个月</view>
</block>
</view>
<view class="timeType">{{timeBean.yearMonth}}</view>
<view class="row nextWeek" bindtap="nextMonth">
<block wx:if="{{ timeBean.shouldShowNextMonth }}">
<view style=" ">下个月</view>
<gl-image class="icon right" src="{{ '/miniProgram/arrow-right.png' }}" webp></gl-image>
<!-- <text class="iconfont icon-sanjiaoright" style="padding:var(--fontSize15);color: #bec1c7;"></text> -->
</block>
</view>
</view>
<!-- <view class="line-shadow"></view> -->
<view class="suspension" bindtap="addMenuClick">
<text class="iconfont icon-tianjia" style="font-size:var(--fontSize60); color:#fff;"></text>
</view>
\ No newline at end of file \ No newline at end of file
// components/staffSelector/staffSelector.js
Component({
/**
* 组件的属性列表
*/
properties: {
// 控制弹框显示/隐藏
show: {
type: Boolean,
value: false
},
// 员工选项列表,格式:[{text: '姓名', value: 'id'}, ...]
options: {
type: Array,
value: []
},
// 当前选中的值(整个对象)
selectedValue: {
type: Object,
value: {
staffPhone: "13132112120",
text: "晨星1号",
value: "173690cbda6d4e8bbccdb3ab485858f8"
}
}
},
/**
* 组件的初始数据
*/
data: {
keyWord: '',
filteredOptions: [],
selectedOptions: [],
searchTimer: null
},
/**
* 组件生命周期函数
*/
lifetimes: {
attached: function() {
// 组件初始化时,如果弹框已显示且有数据,进行初始化
const { show, options, selectedValue } = this.properties
if (show && options && options.length > 0) {
this.initPopup()
}
}
},
/**
* 组件的方法列表
*/
methods: {
/**
* 关闭弹框
*/
onClose: function() {
this.setData({
show: false,
keyWord: ''
})
// 清除防抖定时器
if (this.data.searchTimer) {
clearTimeout(this.data.searchTimer)
this.setData({ searchTimer: null })
}
// 触发关闭事件
this.triggerEvent('close')
},
/**
* 初始化弹框数据
*/
initPopup: function() {
const { options, selectedValue } = this.properties
// 兼容处理:支持多种数据格式
let selectedValueObj = null
let selectedValueId = null
if (selectedValue) {
if (typeof selectedValue === 'string') {
// 字符串格式:直接是 value
selectedValueId = selectedValue
const foundOption = options.find(opt => opt.value === selectedValue)
if (foundOption) {
selectedValueObj = foundOption
}
} else if (typeof selectedValue === 'object') {
// 对象格式
if (selectedValue.value) {
// 格式1:{ staffPhone, text, value }
selectedValueId = selectedValue.value
selectedValueObj = selectedValue
} else if (selectedValue.staffId) {
// 格式2:{ staffName, staffId, staffPhone }
selectedValueId = selectedValue.staffId
// 从 options 中查找对应的对象
const foundOption = options.find(opt => opt.value === selectedValue.staffId)
if (foundOption) {
selectedValueObj = {
staffPhone: selectedValue.staffPhone || foundOption.staffPhone,
text: selectedValue.staffName || foundOption.text,
value: selectedValue.staffId || foundOption.value
}
}
}
}
}
// 处理选项列表,标记选中状态
let processedOptions = options.map(option => ({
...option,
checked: selectedValueId && option.value === selectedValueId
}))
// 设置选中的选项ID数组(用于单选模式)
let selectedOptions = []
if (selectedValueId) {
const selectedOption = processedOptions.find(opt => opt.value === selectedValueId)
if (selectedOption) {
selectedOptions = [selectedValueId]
}
}
this.setData({
filteredOptions: processedOptions,
selectedOptions: selectedOptions,
keyWord: ''
})
},
/**
* 搜索输入
*/
onSearchInput: function(e) {
const value = e.detail.value || ''
this.setData({
keyWord: value
})
// 清除之前的定时器
if (this.data.searchTimer) {
clearTimeout(this.data.searchTimer)
}
// 设置防抖:500ms 后执行搜索
const timer = setTimeout(() => {
this.performSearch(value)
}, 500)
this.setData({
searchTimer: timer
})
},
/**
* 搜索确认
*/
onSearch: function(e) {
const keyword = e.detail.value || ''
this.setData({
keyWord: keyword
})
this.performSearch(keyword)
},
/**
* 执行搜索
*/
performSearch: function(keyword) {
const { options } = this.properties
const { selectedOptions } = this.data
let filteredOptions = options
if (keyword) {
filteredOptions = options.filter(option =>
option.text && option.text.includes(keyword)
)
}
// 保持选中状态
if (selectedOptions.length > 0) {
const selectedValue = selectedOptions[0]
filteredOptions = filteredOptions.map(option => ({
...option,
checked: option.value === selectedValue
}))
} else {
filteredOptions = filteredOptions.map(option => ({
...option,
checked: false
}))
}
this.setData({
filteredOptions: filteredOptions
})
},
/**
* 重置搜索
*/
handleSearchReset: function() {
this.setData({
keyWord: ''
})
this.performSearch('')
},
/**
* 切换选项选中状态(单选模式)
*/
toggleOption: function(e) {
const value = e.currentTarget.dataset.value
const { options } = this.properties
const { filteredOptions } = this.data
// 先取消所有选中状态
filteredOptions.forEach(option => {
option.checked = false
})
// 找到点击的选项并设置选中状态
const filteredIndex = filteredOptions.findIndex(option => option.value === value)
if (filteredIndex >= 0) {
filteredOptions[filteredIndex].checked = true
}
this.setData({
filteredOptions,
selectedOptions: [value]
})
},
/**
* 确认选择
*/
onConfirm: function() {
const { selectedOptions } = this.data
if (selectedOptions.length > 0) {
const selectedValue = selectedOptions[0]
const { options } = this.properties
const selectedOption = options.find(option => option.value === selectedValue)
if (selectedOption) {
// 触发确认事件,传递选中的整个对象
this.triggerEvent('confirm', {
value: selectedValue,
option: selectedOption
})
}
}
// 关闭弹框
this.onClose()
}
},
/**
* 属性观察器
*/
observers: {
// 监听弹框显示、选项列表和选中值的变化
'show, options, selectedValue': function(show, options, selectedValue) {
// 当弹框显示且有选项数据时,初始化数据(包括选中回显)
if (show && options && options.length > 0) {
this.initPopup()
}
}
}
})
{
"component": true,
"usingComponents": {
"van-popup": "@vant/weapp/popup/index"
}
}
/* components/staffSelector/staffSelector.sass */
/* 员工选择弹出层样式 */
.popup-content {
height: 100%;
display: flex;
flex-direction: column;
position: relative;
overflow: hidden;
}
/* 设置popup顶部圆角 */
.van-popup--bottom {
border-radius: var(--fontSize20) var(--fontSize20) 0 0 !important;
overflow: hidden;
}
.popup-fixed-top {
flex: 0 0 auto;
}
.popup-fixed-bottom {
flex: 0 0 auto;
padding: 0 var(--fontSize40);
background: #fff;
}
.popup-scroll-area {
flex: 1;
overflow-y: auto;
padding: 0 var(--fontSize40);
}
.popup-title {
height: var(--fontSize110);
line-height: var(--fontSize110);
font-size: var(--fontSize32);
font-weight: 500;
text-align: center;
border-bottom: var(--fontSize2) solid #E8E8EA;
}
.search-box {
width: var(--fontSize686);
padding: var(--fontSize16) 0;
margin: 0 var(--fontSize40);
.search-input {
width: 100%;
display: flex;
align-items: center;
height: var(--fontSize72);
background-color: #f5f5f5;
border-radius: var(--fontSize36);
padding: 0 var(--fontSize30);
font-size: var(--fontSize28);
box-sizing: border-box;
position: relative;
.search-icon {
width: var(--fontSize28);
height: var(--fontSize28);
position: absolute;
left: 45%;
top: 50%;
transform: translate(-100%, -50%);
z-index: 1;
margin-left: calc(var(--fontSize-14) - var(--fontSize28));
}
.input {
flex: 1;
height: 100%;
text-align: center;
background-color: transparent;
color: #292d33;
font-size: var(--fontSize28);
}
.input-placeholder {
color: #BEC1C7;
text-align: center;
}
.search-clear {
width: var(--fontSize36);
height: var(--fontSize36);
position: absolute;
right: var(--fontSize30);
top: 50%;
z-index: 999;
transform: translateY(-50%);
}
}
}
.popup-options {
padding: var(--fontSize10) 0;
}
.option-item {
display: flex;
justify-content: space-between;
align-items: center;
padding: var(--fontSize24) 0;
border-bottom: var(--fontSize2) solid #eee;
font-size: var(--fontSize28);
}
.option-item:active {
background-color: #f2f3f5;
}
.option-name {
flex: 1;
}
.option-item.checked .option-name {
color: #347BFF;
}
.option-check {
width: var(--fontSize40);
height: var(--fontSize40);
display: flex;
align-items: center;
justify-content: center;
}
.option-check.checked {
color: #347BFF;
}
.check-icon {
width:var(--fontSize32);
height:var(--fontSize32);
}
.empty-tip {
padding: var(--fontSize60) 0;
text-align: center;
color: #999;
font-size: var(--fontSize28);
}
.popup-buttons {
display: flex;
justify-content: space-between;
padding: var(--fontSize20) 0;
}
.cancel-btn, .confirm-btn {
width: var(--fontSize331);
height: var(--fontSize80);
border-radius: var(--fontSize12);
font-size: var(--fontSize32);
line-height: var(--fontSize80);
display: flex;
align-items: center;
justify-content: center;
}
.cancel-btn {
background-color: #F4F5F7;
color: #323233;
margin-right: var(--fontSize24);
}
.confirm-btn {
background-color: #347BFF;
color: #fff;
}
<!-- 员工选择弹出层 -->
<van-popup show="{{ show }}" position="bottom" custom-style="height: 70%; border-radius: 12px 12px 0 0;" bind:close="onClose">
<view class="popup-content">
<!-- 固定顶部区域 -->
<view class="popup-fixed-top">
<view class="popup-title">选择员工</view>
<!-- 搜索框 -->
<view class="search-box">
<view class="search-input">
<block wx:if="{{ !keyWord }}">
<image src="/images/search.png" class="search-icon" />
</block>
<input
type="text"
placeholder="搜索"
class="input"
confirm-type="search"
value="{{ keyWord }}"
placeholder-class="input-placeholder"
bindinput="onSearchInput"
bindconfirm="onSearch"
/>
<block wx:if="{{ keyWord }}">
<image src="/images/clear.png" class="search-clear" bindtap="handleSearchReset" />
</block>
</view>
</view>
</view>
<!-- 可滚动的中间区域 -->
<view class="popup-scroll-area">
<!-- 选项列表 -->
<view class="popup-options" wx:if="{{ options.length > 0 }}">
<view
class="option-item {{ item.checked ? 'checked' : '' }}"
wx:for="{{ filteredOptions }}"
wx:key="value"
bindtap="toggleOption"
data-value="{{ item.value }}"
>
<view class="option-name">{{item.text}}</view>
<view class="option-check {{ item.checked ? 'checked' : '' }}">
<!-- <text class="check-icon" wx:if="{{ item.checked }}">✓</text> -->
<image src="/images/icon-strategy-checked.png" class="check-icon" wx:if="{{ item.checked }}" />
</view>
</view>
<view class="empty-tip" wx:if="{{ filteredOptions.length === 0 }}">
<text>无匹配结果</text>
</view>
</view>
</view>
<!-- 固定底部区域 -->
<view class="popup-fixed-bottom">
<view class="popup-buttons">
<view class="cancel-btn" bindtap="onClose">取消</view>
<view class="confirm-btn" bindtap="onConfirm">确定</view>
</view>
</view>
</view>
</van-popup>
/**
* 工资申诉常量数据映射
* 将API返回的数据映射到 salaryItems 数据结构
*/
// 工资项基础配置
const SALARY_ITEM_CONFIG = [
{
id: 'attendance',
title: '实际出勤天数',
centerLeft: '根据打卡数据产生',
btnText: '申诉考勤',
unit: '天',
defaultValue: 0
},
{
id: 'daily',
title: '日报完成天数',
centerLeft: '填写驻店日报天数',
btnText: '去补日报',
unit: '天',
defaultValue: 0,
hasMissingDates: true
},
{
id: 'recording',
title: '平板录音总数',
centerLeft: '触客总数为',
btnText: '申诉平板',
unit: '条',
defaultValue: 0
}
]
// API字段映射配置
const API_FIELD_MAP = {
attendance: {
value: 'actualAttendanceDays',
deduction: 'attendanceDeductionAmount',
appealable: 'attendanceAppealable'
},
daily: {
value: 'dailyReportDays',
deduction: 'dailyReportDeductionAmount',
appealable: 'dailyReportable',
missingDates: 'missingDailyReportDates'
},
recording: {
value: 'padRecordNum',
deduction: 'padDeductionAmount',
appealable: 'padAppealable'
}
}
/**
* 格式化扣款金额显示
*/
const formatDeductionAmount = (amount) => {
if (!amount || amount === 0) return ''
return amount > 0 ? `-${amount}元` : `${amount}元`
}
/**
* 格式化缺失日期显示
*/
const formatMissingDates = (dates) => {
if (!dates || !Array.isArray(dates) || dates.length === 0) return ''
return dates.map(date => {
if (date.includes('-')) {
const day = date.split('-')[2]
return day.replace(/^0+/, '')
}
return date
}).join('、') + '号'
}
/**
* 格式化数值显示
*/
const formatValue = (value, unit, defaultValue = 0) => {
const num = value !== undefined && value !== null ? value : defaultValue
return `${num}${unit}`
}
/**
* 创建单个工资项数据
*/
const createSalaryItem = (config, apiData) => {
const fieldMap = API_FIELD_MAP[config.id]
const value = apiData[fieldMap.value]
const deductionAmount = apiData[fieldMap.deduction]
const appealable = apiData[fieldMap.appealable] || false
const missingDates = config.hasMissingDates ? apiData[fieldMap.missingDates] : null
return {
id: config.id,
title: config.title,
value: formatValue(value, config.unit, config.defaultValue),
centerLeft: config.centerLeft,
centerLeftNum: '',
centerRight: deductionAmount ? '扣款' : '',
centerRightPrice: formatDeductionAmount(deductionAmount),
bottomText: missingDates && missingDates.length > 0 ? '缺失天数为' : '',
bottomDays: config.hasMissingDates ? formatMissingDates(missingDates) : '',
btnText: appealable ? config.btnText : '',
btnType: config.id,
appealable
}
}
/**
* 将API数据映射到工资项数据结构
* @param {Object} apiData - API返回的数据对象
* @returns {Array} salaryItems 数组
*/
export function mapApiDataToSalaryItems(apiData = {}) {
return SALARY_ITEM_CONFIG.map(config => createSalaryItem(config, apiData))
}
/**
* 默认的工资项数据结构(用于初始化或兜底)
*/
export const defaultSalaryItems = mapApiDataToSalaryItems({})
{
"navigationStyle": "custom",
"enablePullDownRefresh": false,
"usingComponents": {
"monthCalendar": "/packageEquity/pages/salaryAppeal/components/monthCalendar/monthCalendar",
"staffSelector": "/packageEquity/pages/salaryAppeal/components/staffSelector/staffSelector",
"appealSelector": "/packageEquity/pages/salaryAppeal/components/appealSelector/appealSelector"
}
}
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/salaryAppeal/salaryAppeal.wxss */
page {
background: #F7F8FA;
height: 100%;
}
.container_page {
height: 100%;
overflow-y: auto;
-webkit-overflow-scrolling: touch;
padding-bottom: var(--fontSize214);
}
.content {
padding:0 var(--fontSize20);
}
.header {
display: flex;
justify-content: space-between;
height:var(--fontSize88);
line-height:var(--fontSize88);
padding:0 var(--fontSize32);
.header-title {
color: #292d33;
font-size: var(--fontSize28);
font-weight: 500;
.sub-title{
color: #999ea8;
font-size: var(--fontSize24);
font-weight: 400;
margin-left: var(--fontSize8);
}
}
.header-right {
display: flex;
align-items: center;
color: #347bff;
font-size: var(--fontSize28);
.icon-select {
width: var(--fontSize40);
height: var(--fontSize40);
margin-left: var(--fontSize16);
}
}
}
.header-56 {
height: var(--fontSize112);
line-height: var(--fontSize112);
}
// 当月基本工资统计
.salary-list {
.salary-item {
width: var(--fontSize710);
min-height: var(--fontSize140);
border-radius: var(--fontSize16);
box-sizing: border-box;
background: #ffffff;
margin-bottom: var(--fontSize24);
padding: var(--fontSize24) var(--fontSize32);
.top {
display: flex;
justify-content: space-between;
color: #292d33;
font-size: var(--fontSize28);
font-weight: 500;
}
.center {
display: flex;
justify-content: space-between;
color: #757980;
font-size: var(--fontSize24);
font-weight: 400;
margin: var(--fontSize14) 0 var(--fontSize16) 0;
.price {
color: #ea6612;
font-size: var(--fontSize28);
font-weight: 400;
}
.num {
color: #2A82E4;
margin-left: var(--fontSize8);
}
}
.bottom {
color: #757980;
font-size: var(--fontSize24);
font-weight: 400;
.days {
color: #2A82E4;
margin-left: var(--fontSize8);
}
}
.btn {
width: 84px;
height: 28px;
border-radius: 16px;
opacity: 1;
border: 1px solid #347bff;
background: #ffffff;
color: #347bff;
font-size: 14px;
font-weight: 400;
display: flex;
align-items: center;
justify-content: center;
margin-top: var(--fontSize16);
margin-left: auto;
}
}
}
.order-card {
box-sizing: border-box;
width: var(--fontSize710);
border-radius: var(--fontSize16);
background: #ffffff;
padding: var(--fontSize24) var(--fontSize32);
display: flex;
flex-wrap: wrap;
justify-content: space-between;
margin: 0 auto;
&-item {
width: calc(50% - var(--fontSize8));
margin-bottom: var(--fontSize24);
display: flex;
flex-direction: column;
&:nth-last-child(1),
&:nth-last-child(2) {
margin-bottom: 0;
}
&-label {
color: #999ea8;
font-size: var(--fontSize24);
margin-bottom: var(--fontSize8);
}
&-value {
color: #292D33;
font-size: var(--fontSize28);
font-weight:500;
line-height: 1.2;
}
}
}
.reply-record {
box-sizing: border-box;
width: var(--fontSize710);
background: #ffffff;
padding: var(--fontSize24) var(--fontSize32);
.record-card {
border-radius: var(--fontSize16);
padding: var(--fontSize24) var(--fontSize32);
background: #f2f2f2;
margin-bottom: var(--fontSize24);
&:last-child {
margin-bottom: 0;
}
.text {
color: #292d33;
font-size: var(--fontSize28);
font-weight: 400;
}
.type-date {
color: #757b85;
font-size: var(--fontSize24);
font-weight: 400;
margin-top: var(--fontSize44);
text-align:right;
.date {
margin-left:4px;
}
}
}
.empty-data {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding: var(--fontSize80) 0;
.empty-icon {
width: var(--fontSize200);
height: auto;
}
.empty-text {
color: #999ea8;
font-size: var(--fontSize28);
font-weight: 400;
margin-top: var(--fontSize24);
}
}
}
\ No newline at end of file \ No newline at end of file
<glsx-privacy appletName="工作申诉" bind:agreeClick="agreeClick" bind:disagreeClick="disagreeClick"></glsx-privacy>
<view class="container_page">
<navigation-bar bindback="jump" bindnavbarReady="navbarReady" showBack="{{ true }}">
<view class="navigation-title">
<!-- <view class="navigation-title-text text-hide">{{orderObj.merchantName || '全部'}}</view> -->
<view class="navigation-title-text text-hide">工资申诉</view>
</view>
</navigation-bar>
<view style="margin-top:{{ navBarHeight }}px">
<monthCalendar bind:monthChange="onMonthChange"></monthCalendar>
</view>
<view class="content">
<view class="header">
<view class="header-title">
<text>当月基本工资统计</text>
</view>
<view class="header-right" bindtap="showStaffPopup">
<p>{{filters.staffName}}</p>
<image wx:if="{{staffAbled}}" class="icon-select" src="/packageEquity/pages/image/icon-salary-arrow-d.png" mode="widthFix"></image>
</view>
</view>
<view class="salary-list">
<view
class="salary-item"
wx:for="{{salaryItems}}"
wx:key="id"
data-type="{{item.btnType}}"
data-index="{{index}}"
>
<view class="top">
<p>{{item.title}}</p>
<p>{{item.value}}</p>
</view>
<view class="center">
<p>
<text wx:if="{{item.id === 'recording' ? item.centerLeftNum : true}}">{{item.centerLeft}}</text>
<text class="num" wx:if="{{item.centerLeftNum}}">{{item.centerLeftNum}}</text>
</p>
<p>
<text wx:if="{{item.centerRightPrice}}">{{item.centerRight}} </text>
<text class="price" wx:if="{{item.centerRightPrice}}">{{item.centerRightPrice}}</text>
<text class="price" style="color: #757980;" wx:if="{{!item.centerRightPrice && item.btnType != 'attendance'}}">扣款 -</text>
</p>
</view>
<view class="bottom" wx:if="{{item.bottomText || item.bottomDays}}">
<text wx:if="{{item.bottomText && item.bottomDays}}">{{item.bottomText}} </text>
<text class="days" wx:if="{{item.bottomDays}}">{{item.bottomDays}}</text>
</view>
<view class="btn" wx:if="{{item.btnAble}}" bindtap="onSalaryItemClick" data-type="{{item.btnType}}" data-index="{{index}}">
{{item.btnText}}
</view>
</view>
</view>
<!-- 订单数统计卡片 -->
<view class="header header-56">
<view class="header-title">
<text>订单数统计</text> <text class="sub-title">订单数若有异常请跟总部联系</text>
</view>
</view>
<view class="order-card">
<view
class="order-card-item"
wx:for="{{orderList}}"
wx:key="index"
wx:if="{{item.value != '0' && item.value != 0}}"
data-index="{{index}}"
>
<view class="order-card-item-label">{{item.label}}</view>
<view class="order-card-item-value">{{item.value}}</view>
</view>
</view>
<!-- 申诉答复记录 -->
<view class="header header-56">
<view class="header-title">
<text>申诉答复记录</text>
</view>
</view>
<view class="reply-record">
<block wx:if="{{appealRecords && appealRecords.length > 0}}">
<view
class="record-card"
wx:for="{{appealRecords}}"
wx:key="index"
>
<view class="text">
{{item.text}}
</view>
<view class="type-date">
申诉类型:<text class="type">{{item.type}}</text> <text class="date">{{item.date}}</text>
</view>
</view>
</block>
<view class="empty-data" wx:else>
<image class="empty-icon" src="/packageEquity/pages/image/icon-emepty.png" mode="widthFix"></image>
<view class="empty-text">暂无数据</view>
</view>
</view>
</view>
</view>
<!-- 员工选择弹出层 -->
<staffSelector
show="{{ showStaffPopup }}"
options="{{ staffOptions }}"
selected-value="{{ filters }}"
bind:close="onCloseStaffPopup"
bind:confirm="onStaffSelectConfirm"
></staffSelector>
<!-- 申诉弹出层 -->
<appealSelector
show="{{ showAppealPopup }}"
actual-days="{{ actualDays }}"
appeal-type="{{ appealType }}"
title="{{ appealTitle }}"
current-label="{{ appealCurrentLabel }}"
appeal-label="{{ appealLabel }}"
unit="{{ appealUnit }}"
max-value="{{ appealMaxValue }}"
default-form="{{ appealDefaultForm }}"
date-range="{{ dateRange }}"
bind:close="onCloseAppealPopup"
bind:confirm="onAppealConfirm"
></appealSelector>
...@@ -484,6 +484,12 @@ Page({ ...@@ -484,6 +484,12 @@ Page({
// 转换每个图片/视频 // 转换每个图片/视频
images.forEach((image) => { images.forEach((image) => {
// 跳过没有 URL 或状态不是 done 的文件
if (!image.url || (image.status && image.status !== "done")) {
console.warn("跳过无效或未完成的文件:", image);
return;
}
const fileItem = { const fileItem = {
fileType, fileType,
fileSubtype, fileSubtype,
...@@ -494,6 +500,10 @@ Page({ ...@@ -494,6 +500,10 @@ Page({
if (fileType === 3) { if (fileType === 3) {
fileItem.fileFormat = "mp4"; fileItem.fileFormat = "mp4";
fileItem.fileName = image.name || this.getImageNameByKey(keyNum); fileItem.fileName = image.name || this.getImageNameByKey(keyNum);
// 如果有封面图,也添加到提交数据中
if (image.coverUrl) {
fileItem.coverUrl = image.coverUrl;
}
} }
// 如果是检测报告,添加额外字段 // 如果是检测报告,添加额外字段
...@@ -869,7 +879,11 @@ Page({ ...@@ -869,7 +879,11 @@ Page({
// 处理详情数据 // 处理详情数据
handleDetailData(data, evalOrderNo) { handleDetailData(data, evalOrderNo) {
const { basic = {}, carInfo = {}, carLicense = {}, images = [] } = data; const { basic = {}, carInfo = {}, carLicense = {}, images } = data;
// 确保 images 是数组,如果为 null 或 undefined,设置为空数组
const imageList = Array.isArray(images) ? images : [];
console.log("handleDetailData - 原始 images:", images, "处理后:", imageList);
// 处理地区显示格式:确保是 "省份 城市" 格式 // 处理地区显示格式:确保是 "省份 城市" 格式
// 车辆所在地 // 车辆所在地
...@@ -1072,10 +1086,16 @@ Page({ ...@@ -1072,10 +1086,16 @@ Page({
}; };
// 处理图片数据 // 处理图片数据
const imageList = {}; const processedImageList = {};
images.forEach((image) => { imageList.forEach((image) => {
const { fileType, fileSubtype, fileUrl } = image; const { fileType, fileSubtype, fileUrl, coverUrl } = image;
// 检查 fileUrl 是否为空
if (!fileUrl) {
console.warn("图片数据中 fileUrl 为空,跳过:", image);
return;
}
// 根据 fileType 和 fileSubtype 映射到对应的 key // 根据 fileType 和 fileSubtype 映射到对应的 key
// fileType: 1-车辆图片, 2-证件资料, 3-车辆视频, 4-其他图片, 5-车辆检测报告 // fileType: 1-车辆图片, 2-证件资料, 3-车辆视频, 4-其他图片, 5-车辆检测报告
...@@ -1103,18 +1123,36 @@ Page({ ...@@ -1103,18 +1123,36 @@ Page({
} }
if (key) { if (key) {
if (!imageList[key]) { if (!processedImageList[key]) {
imageList[key] = []; processedImageList[key] = [];
}
// 根据 fileType 构造不同的数据结构
if (fileType === 3) {
// 视频文件:需要 videoUrl、coverUrl 和 isVideo 标识
processedImageList[key].push({
url: fileUrl, // 视频 URL
thumb: coverUrl || "", // 封面图(van-uploader 使用 thumb 作为预览图)
coverUrl: coverUrl || "", // 保存封面图 URL,用于预览
isVideo: true,
name: this.getImageNameByKey(key),
key: key,
status: "done",
});
} else {
// 普通图片
processedImageList[key].push({
url: fileUrl,
isVideo: false,
name: this.getImageNameByKey(key),
key: key,
status: "done",
});
} }
imageList[key].push({
url: fileUrl,
name: this.getImageNameByKey(key),
key: key,
});
} }
}); });
updateData["formData.imageList"] = imageList; updateData["formData.imageList"] = processedImageList;
// 一次性更新所有数据 // 一次性更新所有数据
console.log( console.log(
......
...@@ -29,19 +29,37 @@ Component({ ...@@ -29,19 +29,37 @@ Component({
imageData: function (newImageData) { imageData: function (newImageData) {
// 监听 imageData 变化,重新初始化图片列表 // 监听 imageData 变化,重新初始化图片列表
console.log("imageData 变化:", newImageData); console.log("imageData 变化:", newImageData);
if (newImageData && Object.keys(newImageData).length > 0) {
// 处理回显数据:确保所有文件都有 status 字段和 isVideo 字段 // 如果 newImageData 为 null 或 undefined,设置为空对象
const processedImageList = {}; if (!newImageData) {
const { uploadVideoFields } = this.data; this.setData({
// 获取所有视频字段的 key 集合 imageList: {},
const videoKeys = new Set( });
uploadVideoFields.map((field) => String(field.key)) return;
); }
for (const key in newImageData) { // 处理回显数据:确保所有文件都有 status 字段和 isVideo 字段
const fileList = newImageData[key]; const processedImageList = {};
if (Array.isArray(fileList)) { const { uploadVideoFields } = this.data;
processedImageList[key] = fileList.map((file) => { // 获取所有视频字段的 key 集合
const videoKeys = new Set(
uploadVideoFields.map((field) => String(field.key))
);
for (const key in newImageData) {
const fileList = newImageData[key];
if (Array.isArray(fileList) && fileList.length > 0) {
// 过滤掉 url 为空的文件,并处理每个文件
processedImageList[key] = fileList
.filter((file) => {
// 过滤掉没有 url 的文件
if (!file || !file.url) {
console.warn("过滤掉无效文件(url 为空):", file);
return false;
}
return true;
})
.map((file) => {
const processedFile = { ...file }; const processedFile = { ...file };
// 如果文件没有 status 字段,说明是编辑回显的数据,设置为 'done' // 如果文件没有 status 字段,说明是编辑回显的数据,设置为 'done'
if (!processedFile.status) { if (!processedFile.status) {
...@@ -71,15 +89,18 @@ Component({ ...@@ -71,15 +89,18 @@ Component({
} }
return processedFile; return processedFile;
}); });
} else {
processedImageList[key] = fileList; // 如果过滤后数组为空,不添加到 processedImageList
if (processedImageList[key].length === 0) {
delete processedImageList[key];
} }
} }
this.setData({
imageList: processedImageList,
});
console.log("已更新 imageList:", this.data.imageList);
} }
this.setData({
imageList: processedImageList,
});
console.log("已更新 imageList:", this.data.imageList);
}, },
}, },
...@@ -170,18 +191,36 @@ Component({ ...@@ -170,18 +191,36 @@ Component({
// 初始化图片列表 // 初始化图片列表
initImageList() { initImageList() {
const { imageData, uploadVideoFields } = this.data; const { imageData, uploadVideoFields } = this.data;
if (imageData && Object.keys(imageData).length > 0) {
// 处理回显数据:确保所有文件都有 status 字段和 isVideo 字段 // 如果 imageData 为空,设置为空对象
const processedImageList = {}; if (!imageData || Object.keys(imageData).length === 0) {
// 获取所有视频字段的 key 集合 this.setData({
const videoKeys = new Set( imageList: {},
uploadVideoFields.map((field) => String(field.key)) });
); return;
}
for (const key in imageData) {
const fileList = imageData[key]; // 处理回显数据:确保所有文件都有 status 字段和 isVideo 字段
if (Array.isArray(fileList)) { const processedImageList = {};
processedImageList[key] = fileList.map((file) => { // 获取所有视频字段的 key 集合
const videoKeys = new Set(
uploadVideoFields.map((field) => String(field.key))
);
for (const key in imageData) {
const fileList = imageData[key];
if (Array.isArray(fileList) && fileList.length > 0) {
// 过滤掉 url 为空的文件,并处理每个文件
processedImageList[key] = fileList
.filter((file) => {
// 过滤掉没有 url 的文件
if (!file || !file.url) {
console.warn("initImageList - 过滤掉无效文件(url 为空):", file);
return false;
}
return true;
})
.map((file) => {
const processedFile = { ...file }; const processedFile = { ...file };
// 如果文件没有 status 字段,说明是编辑回显的数据,设置为 'done' // 如果文件没有 status 字段,说明是编辑回显的数据,设置为 'done'
if (!processedFile.status) { if (!processedFile.status) {
...@@ -211,14 +250,17 @@ Component({ ...@@ -211,14 +250,17 @@ Component({
} }
return processedFile; return processedFile;
}); });
} else {
processedImageList[key] = fileList; // 如果过滤后数组为空,不添加到 processedImageList
if (processedImageList[key].length === 0) {
delete processedImageList[key];
} }
} }
this.setData({
imageList: processedImageList,
});
} }
this.setData({
imageList: processedImageList,
});
}, },
// 处理上传 // 处理上传
...@@ -836,13 +878,36 @@ Component({ ...@@ -836,13 +878,36 @@ Component({
// 校验必填项 // 校验必填项
validate() { validate() {
const { imageList, uploadFields } = this.data; const { imageList, uploadFields, uploadCertificateFields, uploadVideoFields, uploadReportFields, uploadOtherFields } = this.data;
// 合并所有字段
const allFields = [
...uploadFields,
...uploadCertificateFields,
...uploadVideoFields,
...uploadReportFields,
...uploadOtherFields,
];
// 1. 检查是否有正在上传的文件
for (let field of allFields) {
const list = imageList[field.key] || [];
const uploadingFiles = list.filter(file => file.status === 'uploading');
if (uploadingFiles.length > 0) {
return {
message: `${field.label}正在上传中,请稍候...`,
};
}
}
// 检查必填的车辆图片 // 2. 检查必填的车辆图片(只检查状态为 done 的文件)
for (let field of uploadFields) { for (let field of uploadFields) {
if (field.required) { if (field.required) {
console.log(imageList[field.key], 'imageList[field.key]');
const list = imageList[field.key] || []; const list = imageList[field.key] || [];
if (list.length === 0) { // 只统计上传完成的文件
const doneFiles = list.filter(file => !file.status || file.status === 'done');
if (doneFiles.length === 0) {
return { return {
message: `请上传${field.label}`, message: `请上传${field.label}`,
}; };
......
...@@ -121,6 +121,7 @@ Page({ ...@@ -121,6 +121,7 @@ Page({
} }
}) })
wx.$storage.rm('dateStaffPop') wx.$storage.rm('dateStaffPop')
wx.$storage.rm('abnormalOrderPop')
if (selectIndex == 0) { // 搜门店 if (selectIndex == 0) { // 搜门店
wx.$router.go('pages.sceneIndex') wx.$router.go('pages.sceneIndex')
this.setData({ jumpPageFlag: false }) this.setData({ jumpPageFlag: false })
......
...@@ -106,6 +106,14 @@ Component({ ...@@ -106,6 +106,14 @@ Component({
{ {
name: '已退款', name: '已退款',
value: [5, 12] value: [5, 12]
},
{
name: '错误订单',
value: [11]
},
{
name: '审批中',
value: [14]
} }
], ],
constructionStatusList: [ constructionStatusList: [
...@@ -127,6 +135,21 @@ Component({ ...@@ -127,6 +135,21 @@ Component({
value: 'Z' value: 'Z'
} }
], ],
abnormalList: [
{
name: '全部',
active: true,
value: ''
},
{
name: '无异常',
value: 'N'
},
{
name: '异常',
value: 'Y'
}
],
maxDate: new Date().format('yyyy-MM-dd'), maxDate: new Date().format('yyyy-MM-dd'),
orderTimeList: [ orderTimeList: [
{ {
...@@ -247,8 +270,13 @@ Component({ ...@@ -247,8 +270,13 @@ Component({
this.getsellerUserIdList(userInfo?.shopMerchantId, 1) this.getsellerUserIdList(userInfo?.shopMerchantId, 1)
}, },
init() { init() {
let { orderTimeList, payTimeList, userInfo, constructionStatusList } = let {
this.data orderTimeList,
payTimeList,
userInfo,
constructionStatusList,
abnormalList
} = this.data
// 非超管 // 非超管
if ( if (
!( !(
...@@ -318,7 +346,8 @@ Component({ ...@@ -318,7 +346,8 @@ Component({
this.setData({ this.setData({
['form.orderTimeList']: wx.$util.deepClone(orderTimeList), ['form.orderTimeList']: wx.$util.deepClone(orderTimeList),
['form.payTimeList']: wx.$util.deepClone(payTimeList), ['form.payTimeList']: wx.$util.deepClone(payTimeList),
['form.constructionFlag']: wx.$util.deepClone(constructionStatusList) ['form.constructionFlag']: wx.$util.deepClone(constructionStatusList),
['form.abnormalFlag']: wx.$util.deepClone(abnormalList)
}) })
}, },
showMore(e) { showMore(e) {
......
...@@ -256,6 +256,19 @@ ...@@ -256,6 +256,19 @@
</view> </view>
</view> </view>
<view class="box"> <view class="box">
<view class="title">异常标记</view>
<view class="list-box">
<block wx:for="{{ form.abnormalFlag }}" wx:key="index">
<view
class="item text-center {{ item.active?'active':''}} {{item.disabled ?'disabled':'' }}"
bindtap="choose"
data-list-name="abnormalFlag"
data-index="{{ index }}"
>{{item.name}}</view>
</block>
</view>
</view>
<view class="box">
<view class="title">施工状态</view> <view class="title">施工状态</view>
<view class="list-box"> <view class="list-box">
<block wx:for="{{ form.constructionFlag }}" wx:key="index"> <block wx:for="{{ form.constructionFlag }}" wx:key="index">
......
module.exports = { module.exports = {
data: { data: {
orderObj: [ orderObj: [
{ {
label: '工单编号:', label: '工单编号:',
key: 'orderCode', key: 'orderCode',
copy: true copy: true
}, },
{ {
label: '工单时间:', label: '工单时间:',
key: 'time', key: 'time',
dateChange: true dateChange: true
}, },
{ {
label: '工单状态:', label: '工单状态:',
key: 'status', key: 'status',
color: '#14CC68', color: '#14CC68',
status: true status: true
}, },
{ {
label: '支付方式:', label: '支付方式:',
key: 'payType', key: 'payType',
payType: true payType: true
} }
], ],
customerObj: [ customerObj: [
{ {
label: '客户姓名:', label: '客户姓名:',
key: 'customerName' key: 'customerName'
}, },
{ {
label: '性别:', label: '性别:',
key: 'customerSex', key: 'customerSex',
enum: { enum: {
1: '男', 1: '男',
2: '女' 2: '女'
} }
}, },
{ {
label: '手机号:', label: '手机号:',
key: 'customerPhone', key: 'customerPhone',
color: '#347BFF', color: '#347BFF',
callBack: 'makePhoneCall', callBack: 'makePhoneCall',
copy: true copy: true
}, },
{ {
label: '车型:', label: '车型:',
key: 'carType' key: 'carType'
}, },
{ {
label: '车架号:', label: '车架号:',
key: 'standNo' key: 'standNo'
}, },
{ {
label: '车牌号:', label: '车牌号:',
key: 'plateNumber' key: 'plateNumber'
}, },
{ {
label: '是否体验:', label: '是否体验:',
key: 'experienceFlag', key: 'experienceFlag',
enum: { enum: {
Y: '是', Y: '是',
N: '否' N: '否'
} }
}, },
{ {
label: '销售顾问:', label: '销售顾问:',
arr: ['merchantName', 'employeeName'] arr: ['merchantName', 'employeeName']
}, },
{ {
label: '转化专员:', label: '转化专员:',
arr: ['sellerMerchantName', 'sellerName'] arr: ['sellerMerchantName', 'sellerName']
}, },
{ {
label: '备注:', label: '备注:',
key: 'remark' key: 'remark'
} }
], ],
payType: { payType: {
0: '战败', 0: '战败',
1: '微信支付', 1: '微信支付',
2: '门店收款', 2: '门店收款',
3: 'pos机支付', 3: 'pos机支付',
4: '支付宝支付', 4: '支付宝支付',
5: '嘀加收款', 5: '嘀加收款',
6: '对公转账', 6: '对公转账',
7: '其它收款' 7: '其它收款'
}, },
orderType: [ orderType: [
{ {
name: '全部', name: '全部',
active: true, active: true,
value: [] value: []
}, },
{ {
name: '升级下单', name: '升级下单',
value: [1, 2, 3, 4, 6] value: [1, 2, 3, 4, 6]
}, },
{ {
name: '核销抵扣', name: '核销抵扣',
value: [5] value: [5]
} }
], ],
status: { status: {
12: { 12: {
text: '已退款', text: '已退款',
color: '#8F959E' color: '#8F959E'
}, },
11: { 11: {
text: '已失效', text: '错误订单',
color: '#8F959E', color: '#EB4E4E',
background: ' #F3F4F5' background: '#fdeded'
}, },
10: { 14: {
text: '已关闭', text: '审批中',
color: '#8F959E' color: '#FF9D0A',
}, background: '#fff5e6'
9: { },
text: '已撤销', 10: {
color: '#8F959E' text: '已关闭',
}, color: '#8F959E'
1: { },
text: '待跟进', 9: {
color: '#FF9D0A', text: '已撤销',
background: '#FFF5E6' color: '#8F959E'
}, },
2: { 1: {
text: '战败', text: '待跟进',
color: '#F24724', color: '#FF9D0A',
background: '#FDECE9' background: '#FFF5E6'
}, },
3: { 2: {
text: '待支付', text: '战败',
color: '#FF9D0A', color: '#F24724',
background: '#FFF5E6' background: '#FDECE9'
}, },
4: { 3: {
text: '已支付', text: '待支付',
color: '#35C376', color: '#FF9D0A',
background: '#EAF9F1' background: '#FFF5E6'
}, },
6: { 4: {
text: '已评价', text: '已支付',
color: '#347BFF', color: '#35C376',
background: '#EAF1FF' background: '#EAF9F1'
} },
}, 6: {
// 订单状态 1 待跟进, 2 不升级, 3 待支付,4 已支付,6 已评价 , 9 已撤销 text: '已评价',
statusList: [ color: '#347BFF',
{ background: '#EAF1FF'
name: '待跟进', }
value: [1] },
}, // 订单状态 1 待跟进, 2 不升级, 3 待支付,4 已支付,6 已评价 , 9 已撤销
{ statusList: [
name: '已支付', {
value: [4] name: '待跟进',
}, value: [1]
{ },
name: '待支付', {
value: [3] name: '已支付',
}, value: [4]
{ },
name: '已撤销', {
value: [9] name: '待支付',
}, value: [3]
{ },
name: '战败', {
value: [2] name: '已撤销',
}, value: [9]
{ },
name: '已评价', {
value: [6] name: '战败',
}, value: [2]
{ },
name: '已关闭', {
value: [10] name: '已评价',
}, value: [6]
{ },
name: '已失效', {
value: [11] name: '已关闭',
} value: [10]
], },
grassInfo: {}, {
orderCode: '', name: '审批中',
userInfo: {} value: [14]
} },
{
name: '错误订单',
value: [11]
}
],
grassInfo: {},
orderCode: '',
userInfo: {}
}
} }
...@@ -41,14 +41,15 @@ Page({ ...@@ -41,14 +41,15 @@ Page({
wx.hideLoading() wx.hideLoading()
// 跳转到智能体后添加返回拦截 // 跳转到智能体后添加返回拦截
if (param.needIntercept) { if (param.needIntercept) {
wx.enableAlertBeforeUnload && wx.enableAlertBeforeUnload({ wx.enableAlertBeforeUnload &&
message: '您还没有完成本次短课程学习,是否确定退出?', wx.enableAlertBeforeUnload({
success: (modalRes) => { message: '您还没有完成本次短课程学习,是否确定退出?',
if (modalRes.confirm) { success: modalRes => {
wx.navigateBack() if (modalRes.confirm) {
wx.navigateBack()
}
} }
} })
})
// 没有返回触发事件, 使用定时器轮询学习状态,是否卸载返回拦截弹窗 // 没有返回触发事件, 使用定时器轮询学习状态,是否卸载返回拦截弹窗
this.setTime(param) this.setTime(param)
} }
...@@ -56,7 +57,8 @@ Page({ ...@@ -56,7 +57,8 @@ Page({
setTime(param) { setTime(param) {
time = setTimeout(() => { time = setTimeout(() => {
commonApi.getShortCourseDetail({ commonApi
.getShortCourseDetail({
id: param?.studyId id: param?.studyId
}) })
.then(res => { .then(res => {
...@@ -105,11 +107,11 @@ Page({ ...@@ -105,11 +107,11 @@ Page({
}, },
handleMessage(e) { handleMessage(e) {
const { data } = e.detail; const { data } = e.detail
// 将数据返回给跳转来源 // 将数据返回给跳转来源
if (data) { if (data) {
const eventChannel = this.getOpenerEventChannel(); const eventChannel = this.getOpenerEventChannel()
eventChannel.emit('webViewMessage', data[0]); // 发送数据 eventChannel.emit('webViewMessage', data[0]) // 发送数据
this.setData({ this.setData({
isH5Bind: true isH5Bind: true
}) })
...@@ -128,9 +130,9 @@ Page({ ...@@ -128,9 +130,9 @@ Page({
} }
// 中邮上传合同协议页面 // 中邮上传合同协议页面
if (url.includes('zyUpload')) { if (url.includes('zyUpload')) {
const eventChannel = this.getOpenerEventChannel(); const eventChannel = this.getOpenerEventChannel()
if (!this.data.isH5Bind) { if (!this.data.isH5Bind) {
eventChannel.emit('webViewMessage', 'cancel'); // 发送数据 eventChannel.emit('webViewMessage', 'cancel') // 发送数据
} }
} }
// 北森考试页面返回 // 北森考试页面返回
......
{ {
"projectname": "%E7%B2%BE%E5%93%81%E5%8D%87%E7%BA%A7", "projectname": "%E7%B2%BE%E5%93%81%E5%8D%87%E7%BA%A7",
"compileType": "miniprogram", "compileType": "miniprogram",
"libVersion": "3.13.1", "libVersion": "3.13.1",
"packOptions": { "packOptions": {
"ignore": [ "ignore": [
{ {
"value": ".vscode", "value": ".vscode",
"type": "folder" "type": "folder"
} }
], ],
"include": [] "include": []
}, },
"setting": { "setting": {
"urlCheck": false, "urlCheck": false,
"coverView": true, "coverView": true,
"es6": true, "es6": true,
"postcss": true, "postcss": true,
"minified": true, "minified": true,
"enhance": true, "enhance": true,
"showShadowRootInWxmlPanel": true, "showShadowRootInWxmlPanel": true,
"packNpmRelationList": [], "packNpmRelationList": [],
"ignoreUploadUnusedFiles": true, "ignoreUploadUnusedFiles": true,
"babelSetting": { "babelSetting": {
"ignore": [], "ignore": [],
"disablePlugins": [], "disablePlugins": [],
"outputPath": "" "outputPath": ""
}, },
"useCompilerPlugins": [ "useCompilerPlugins": [
"sass" "sass"
], ],
"ignoreDevUnusedFiles": false, "ignoreDevUnusedFiles": false,
"minifyWXML": true, "minifyWXML": true,
"compileWorklet": false, "compileWorklet": false,
"uglifyFileName": false, "uglifyFileName": false,
"uploadWithSourceMap": true, "uploadWithSourceMap": true,
"packNpmManually": false, "packNpmManually": false,
"minifyWXSS": true, "minifyWXSS": true,
"localPlugins": false, "localPlugins": false,
"disableUseStrict": false, "disableUseStrict": false,
"condition": false, "condition": false,
"swc": false, "swc": false,
"disableSWC": true "disableSWC": true
}, },
"editorSetting": { "editorSetting": {
"tabIndent": "insertSpaces", "tabIndent": "insertSpaces",
"tabSize": 2 "tabSize": 2
}, },
"appid": "wx4e697bcf4954ceef", "appid": "wx570d9331f9ace0bd",
"simulatorPluginLibVersion": {} "simulatorPluginLibVersion": {}
} }
\ No newline at end of file \ No newline at end of file
...@@ -123,7 +123,7 @@ export const getYQorderInfo = () => { ...@@ -123,7 +123,7 @@ export const getYQorderInfo = () => {
api api
.getMerchantRecordingSettings({ .getMerchantRecordingSettings({
scene: 1, scene: 1,
merchantId: userInfo.shopMerchantId, merchantId: userInfo.shopMerchantId
// merchantName: userInfo.shopMerchantName // merchantName: userInfo.shopMerchantName
}) })
.then(res => { .then(res => {
...@@ -131,7 +131,7 @@ export const getYQorderInfo = () => { ...@@ -131,7 +131,7 @@ export const getYQorderInfo = () => {
let { code, data } = res let { code, data } = res
if (code == 0) { if (code == 0) {
let YQorderSetting = {} let YQorderSetting = {}
console.log(data, 'data'); console.log(data, 'data')
const keyMap = { const keyMap = {
carBrand: 'carTypeRequiredFlag', carBrand: 'carTypeRequiredFlag',
carNo: 'standNoRequiredFlag', carNo: 'standNoRequiredFlag',
...@@ -139,10 +139,10 @@ export const getYQorderInfo = () => { ...@@ -139,10 +139,10 @@ export const getYQorderInfo = () => {
notUpgradeExperience: 'foEfRequiredFlag', notUpgradeExperience: 'foEfRequiredFlag',
notUpgradeRejectionReason: 'foRrRequiredFlag' notUpgradeRejectionReason: 'foRrRequiredFlag'
} }
; (data.orderFieldSettingList || []).forEach(e => { ;(data.orderFieldSettingList || []).forEach(e => {
const key = keyMap[e.fieldKey] || e.fieldKey const key = keyMap[e.fieldKey] || e.fieldKey
YQorderSetting[key] = e.isRequired ? 'Y' : 'N' YQorderSetting[key] = e.isRequired ? 'Y' : 'N'
}) })
YQorderSetting.shopMerchantId = userInfo.shopMerchantId YQorderSetting.shopMerchantId = userInfo.shopMerchantId
// 过滤园区店是否需要屏蔽手机号选项 // 过滤园区店是否需要屏蔽手机号选项
...@@ -261,6 +261,10 @@ export const checkScene = options => { ...@@ -261,6 +261,10 @@ export const checkScene = options => {
removeSystemStorage() removeSystemStorage()
// wx.$relogin = relogin // wx.$relogin = relogin
} }
// 跳到会员权益报价单列表页 登录场景不是会员权益的 踢出登录
if (query && query.page == 'equityPage' && userInfo.sceneType != 0) {
return '当前登录场景不一致,请重新登录。'
}
// 判断对象是否满足任意一个key // 判断对象是否满足任意一个key
// console.log(query, ' query') // console.log(query, ' query')
if (query && (query.scene || query.merchantId || query.type || query.page)) { if (query && (query.scene || query.merchantId || query.type || query.page)) {
...@@ -283,7 +287,11 @@ export const checkScene = options => { ...@@ -283,7 +287,11 @@ export const checkScene = options => {
h5AuthPhone: 'pages/h5AuthPhone/h5AuthPhone', h5AuthPhone: 'pages/h5AuthPhone/h5AuthPhone',
mentorShipManage: mentorShipManage:
'tabWorkOrder/pages/mentorshipManage/mentorshipManage', 'tabWorkOrder/pages/mentorshipManage/mentorshipManage',
refundApply: 'tabWorkOrder/pages/refundApply/refundApply' refundApply: 'tabWorkOrder/pages/refundApply/refundApply',
orderDetail: 'tabWorkOrder/pages/orderDetail/orderDetail',
recruitDetail:
'packageEquity/pages/recruitManage/recruitDetail/recruitDetail',
equityPage: 'packageEquity/pages/TabBar/equityPage'
} }
options.path = pagePath[query.page] options.path = pagePath[query.page]
} }
...@@ -528,8 +536,8 @@ export const loginLogAdd = options => { ...@@ -528,8 +536,8 @@ export const loginLogAdd = options => {
// "登录方式(1账号密码登录,2.手机号授权,3验证码)" // "登录方式(1账号密码登录,2.手机号授权,3验证码)"
api api
.loginLogAdd(options) .loginLogAdd(options)
.then(result => { }) .then(result => {})
.catch(err => { }) .catch(err => {})
} }
}) })
} }
<!--subvehicleConversion/pages/paySuccess/paySuccess.wxml--> <!--subvehicleConversion/pages/paySuccess/paySuccess.wxml-->
<wxs src="./index.wxs" module="filter" /> <wxs src="./index.wxs" module="filter" />
<view class="successPay"> <view class="successPay">
<view class="tips">支付成功</view> <view class="tips">支付成功</view>
<view class="sum">订单支付成功,实付{{orderDetail.totalPrice}}元</view> <view class="sum">订单支付成功,实付{{orderDetail.finalPrice}}元</view>
</view> </view>
<view class="orderInfo"> <view class="orderInfo">
<view class="orderInfoCom"> <view class="orderInfoCom">
<view class="title">订单信息</view> <view class="title">订单信息</view>
<view class="info"> <view class="info">
<block wx:for="{{orderForm}}" wx:key="index"> <block wx:for="{{orderForm}}" wx:key="index">
<view class="item"> <view class="item">
<view class="label">{{item.labelName}}</view> <view class="label">{{item.labelName}}</view>
<view class="text"> <view class="text">
{{ item.key==goodsName?filter.replaceItemText(orderDetail[item.key]):orderDetail[item.key] ||''}} {{ item.key==goodsName?filter.replaceItemText(orderDetail[item.key]):orderDetail[item.key] ||''}}
</view> </view>
</view> </view>
</block> </block>
</view> </view>
</view> </view>
</view> </view>
\ No newline at end of file \ No newline at end of file
This diff could not be displayed because it is too large.
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!