Commit ae4c07ae by wangzhihui

Merge branch 'SAAS+V4.52.0-0429' of http://192.168.3.233:8090/saas_plus/dj-car-b…

…outique-work-wechat into SAAS+V4.52.0-0429
2 parents cd3ea636 504efe81
Showing 171 changed files with 3094 additions and 332 deletions
...@@ -343,5 +343,10 @@ module.exports = { ...@@ -343,5 +343,10 @@ module.exports = {
// 上传pdf // 上传pdf
uploadPdfAPI(data) { uploadPdfAPI(data) {
return api.post('dj.api.smartcarlife.common.uploadPdf', data, ['file']) return api.post('dj.api.smartcarlife.common.uploadPdf', data, ['file'])
},
// 查询员工是否是导师
getStaffMentorFlag(data) {
return api.post('dj.api.smartcarlife.employee.isMentor', data)
} }
} }
...@@ -224,5 +224,6 @@ App({ ...@@ -224,5 +224,6 @@ App({
count: "", count: "",
versionData: null, versionData: null,
businessSchoolScene: "", businessSchoolScene: "",
ROUTE_QUERY: {},//路由携带的参数
}, },
}); });
...@@ -122,6 +122,7 @@ ...@@ -122,6 +122,7 @@
"pages": [ "pages": [
"pages/carQuotation/signature/signature", "pages/carQuotation/signature/signature",
"pages/carQuotation/index/index", "pages/carQuotation/index/index",
"pages/carQuotation/relevanceOrderSelect/index",
"pages/carQuotation/fullSignture/fullSignture", "pages/carQuotation/fullSignture/fullSignture",
"pages/carQuotation/schemeConfirmation/schemeConfirmation", "pages/carQuotation/schemeConfirmation/schemeConfirmation",
"pages/carQuotation/CarQuotationDetail/CarQuotationDetail", "pages/carQuotation/CarQuotationDetail/CarQuotationDetail",
...@@ -167,7 +168,13 @@ ...@@ -167,7 +168,13 @@
"pages/aiCheck/detail/detail", "pages/aiCheck/detail/detail",
"pages/receptionDetail/receptionDetail", "pages/receptionDetail/receptionDetail",
"pages/aiCheck/defense/defense", "pages/aiCheck/defense/defense",
"pages/extract/extract/extract" "pages/extract/extract/extract",
"pages/extract/confirm/confirm",
"pages/extract/success/success",
"pages/sceneMarket/index/index",
"pages/sceneMarket/clue/clue",
"pages/sceneMarket/clueForm/clueForm",
"pages/sceneMarket/materialPage/materialPage"
] ]
}, },
{ {
...@@ -238,15 +245,11 @@ ...@@ -238,15 +245,11 @@
"preloadRule": { "preloadRule": {
"pages/tabWorkOrder/pages/index/index": { "pages/tabWorkOrder/pages/index/index": {
"network": "all", "network": "all",
"packages": [ "packages": ["tabWorkOrder"]
"tabWorkOrder"
]
}, },
"tabIndex/pages/index/index": { "tabIndex/pages/index/index": {
"network": "all", "network": "all",
"packages": [ "packages": ["tabWorkOrder"]
"tabWorkOrder"
]
} }
}, },
"resolveAlias": { "resolveAlias": {
...@@ -260,4 +263,4 @@ ...@@ -260,4 +263,4 @@
}, },
"lazyCodeLoading": "requiredComponents", "lazyCodeLoading": "requiredComponents",
"resizable": true "resizable": true
}
\ No newline at end of file \ No newline at end of file
}
...@@ -26,6 +26,18 @@ ...@@ -26,6 +26,18 @@
flex-grow: 1; flex-grow: 1;
} }
.meeting-box {
.van-cell {
line-height: auto !important;
border: 2rpx solid #ececec;
border-radius: 16rpx;
margin-top: 16rpx;
padding: 16rpx 24rpx !important;
}
.van-field__control--textarea {
min-height: var(--field-text-area-min-height,144rpx) !important;
}
}
.input-suffix { .input-suffix {
/* height: var(--fontSize88); /* height: var(--fontSize88);
line-height: var(--fontSize88); */ line-height: var(--fontSize88); */
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
show-word-limit show-word-limit
noPadding="{{item.noPadding}}"> noPadding="{{item.noPadding}}">
<!-- slot --> <!-- slot -->
<slot wx:if="{{item.type == 'slot'}}" name="{{item.name}}" /> <slot wx:if="{{item.type == 'slot'}}" name="{{item.slotName || item.name}}" />
<!-- radio --> <!-- radio -->
<view wx:if="{{item.type == 'radio'}}"> <view wx:if="{{item.type == 'radio'}}">
<van-radio-group value="{{formData[item.name]}}" disabled="{{item.disabled||disable}}" class="radio-box" data-attr="{{item.name}}" bindchange="handleRadio"> <van-radio-group value="{{formData[item.name]}}" disabled="{{item.disabled||disable}}" class="radio-box" data-attr="{{item.name}}" bindchange="handleRadio">
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
wx:for-index="kIdx" wx:key="kIdx" name="{{k[item.optionLabel]}}">{{k[item.optionLabel]}}</van-radio> wx:for-index="kIdx" wx:key="kIdx" name="{{k[item.optionLabel]}}">{{k[item.optionLabel]}}</van-radio>
</van-radio-group> </van-radio-group>
</view> </view>
<!-- input / textarea --> <!-- input -->
<view wx:if="{{item.type == 'input'}}" class="input-box" style="{{item.customStyle}}"> <view wx:if="{{item.type == 'input'}}" class="input-box" style="{{item.customStyle}}">
<!-- rows="1" --> <!-- rows="1" -->
<van-field <van-field
...@@ -56,6 +56,12 @@ ...@@ -56,6 +56,12 @@
bindinput="handleInput" /> bindinput="handleInput" />
<text wx:if="{{item.suffix}}" class="input-suffix">{{item.suffix}}</text> <text wx:if="{{item.suffix}}" class="input-suffix">{{item.suffix}}</text>
</view> </view>
<!-- textarea -->
<view wx:if="{{item.type == 'textarea'}}" class="meeting-box">
<view class="meeting-textarea">
<van-field value="{{formData[item.name]}}" hold-keyboard type="textarea" rows="{{item.rows || '4'}}" autosize="{ minHeight: 50 }" show-word-limit placeholder="{{item.placeholder || '请输入'}}" maxlength="{{item.maxlength || 140}}" disabled="{{item.disabled||disable}}" data-attr="{{item.name}}" data-item="{{item}}" bindinput="handleInput" />
</view>
</view>
<!-- picker --> <!-- picker -->
<picker <picker
wx:if="{{item.type == 'select'}}" wx:if="{{item.type == 'select'}}"
......
...@@ -36,7 +36,16 @@ Component({ ...@@ -36,7 +36,16 @@ Component({
isInt: { isInt: {
type: Boolean, type: Boolean,
value: false value: false
} },
color: {
type: String,
value: '#282829'
},
placeholderColor: {
type: String,
value: '#B1B1B3'
},
textStyle: String
}, },
/** /**
...@@ -63,7 +72,12 @@ Component({ ...@@ -63,7 +72,12 @@ Component({
}) })
}, },
setValue(value) { setValue(value) {
let { customMaxLength, maxlength, isLimitNum, isInt } = this.data let {
customMaxLength,
maxlength,
isLimitNum,
isInt
} = this.data
if (this.properties.filterEmoji) { if (this.properties.filterEmoji) {
if (wx.$util.haveEmoji(value)) value = wx.$util.replaceEmoji(value) if (wx.$util.haveEmoji(value)) value = wx.$util.replaceEmoji(value)
} }
...@@ -89,12 +103,16 @@ Component({ ...@@ -89,12 +103,16 @@ Component({
} }
} }
console.log(value) console.log(value)
this.setData({ value }) this.setData({
value
})
return value return value
}, },
textareaInput(e) { textareaInput(e) {
let { value } = e.detail let {
value
} = e.detail
value = this.setValue(value) value = this.setValue(value)
this.triggerEvent('input', { this.triggerEvent('input', {
...@@ -103,7 +121,9 @@ Component({ ...@@ -103,7 +121,9 @@ Component({
}, },
textareaBlur(e) { textareaBlur(e) {
let { value } = e.detail let {
value
} = e.detail
this.setData({ this.setData({
edit: true edit: true
}) })
...@@ -113,4 +133,4 @@ Component({ ...@@ -113,4 +133,4 @@ Component({
}) })
} }
} }
}) })
\ No newline at end of file \ No newline at end of file
<view class='textarea-box {{maxlength>0&&showWordLimit?"showWordLimit":""}}'> <view class='textarea-box {{maxlength>0&&showWordLimit?"showWordLimit":""}}'>
<block wx:if='{{edit}}'> <block wx:if='{{edit}}'>
<text class='textarea' bindtap="openTextarea" <text class='textarea' bindtap="openTextarea"
style="color:{{value?'#282829':'#B1B1B3'}}; {{textStyle}}">{{value||placeholder||'请输入'}}</text> style="color:{{value?color:placeholderColor}}; {{textStyle}}">{{value||placeholder||'请输入'}}</text>
</block> </block>
<block wx:else> <block wx:else>
<textarea class='_textarea_' maxlength="{{customMaxLength?-1:maxlength}}" value='{{value}}' <textarea class='_textarea_' maxlength="{{customMaxLength?-1:maxlength}}" value='{{value}}'
bindinput='textareaInput' focus='{{textareaFocus}}' bindblur='textareaBlur' bindconfirm='textareaBlur'></textarea> bindinput='textareaInput' focus='{{textareaFocus}}' bindblur='textareaBlur' bindconfirm='textareaBlur' style="{{textStyle}}"></textarea>
</block> </block>
<block wx:if='{{maxlength>0&&showWordLimit}}'> <block wx:if='{{maxlength>0&&showWordLimit}}'>
<view class='wordLimit'> <view class='wordLimit'>
......
...@@ -186,7 +186,7 @@ Component({ ...@@ -186,7 +186,7 @@ Component({
pageNum: pageNum, pageNum: pageNum,
pageSize: 10, pageSize: 10,
keyword: searchValue, keyword: searchValue,
sellerMerchantId: userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 ? '' : (userInfo?.merchantId || '') sellerMerchantId: userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6 ? '' : (userInfo?.merchantId || '')
} }
if (nothing) return if (nothing) return
api.searchOrderCustomer(params).then(res => { api.searchOrderCustomer(params).then(res => {
......
...@@ -198,7 +198,7 @@ Component({ ...@@ -198,7 +198,7 @@ Component({
pageNum: pageNum, pageNum: pageNum,
pageSize: 10, pageSize: 10,
keyword: searchValue, keyword: searchValue,
sellerMerchantId: userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 ? '' : (userInfo?.merchantId || '') sellerMerchantId: userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6 ? '' : (userInfo?.merchantId || '')
} }
if (nothing) return if (nothing) return
api.searchOrderCustomer(params).then(res => { api.searchOrderCustomer(params).then(res => {
......
...@@ -35,7 +35,7 @@ Component({ ...@@ -35,7 +35,7 @@ Component({
ready() { ready() {
let userInfo = wx.$util.getUserInfo() let userInfo = wx.$util.getUserInfo()
this.setData({ this.setData({
isForbidden: !(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5), isForbidden: !(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6),
isYqdSuper: app.globalData.isYqdSuper, isYqdSuper: app.globalData.isYqdSuper,
selectedSceneName: constantData?.sceneList?.filter(val => val.sceneType == userInfo?.sceneType)[0]?.sceneName, selectedSceneName: constantData?.sceneList?.filter(val => val.sceneType == userInfo?.sceneType)[0]?.sceneName,
selectedSceneDesc: constantData?.sceneList?.filter(val => val.sceneType == userInfo?.sceneType)[0]?.sceneDesc, selectedSceneDesc: constantData?.sceneList?.filter(val => val.sceneType == userInfo?.sceneType)[0]?.sceneDesc,
......
...@@ -87,6 +87,7 @@ Component({ ...@@ -87,6 +87,7 @@ Component({
3: '区域运营', 3: '区域运营',
4: '驻店负责人', 4: '驻店负责人',
5: '广联销售', 5: '广联销售',
6: '飞行督导'
}, },
loginRole: '', loginRole: '',
userInfo: {}, userInfo: {},
...@@ -95,11 +96,18 @@ Component({ ...@@ -95,11 +96,18 @@ Component({
lifetimes: { lifetimes: {
attached() { attached() {
let userInfo = wx.$util.getUserInfo() let userInfo = wx.$util.getUserInfo(),
{menuList} = this.data
const loginRole = userInfo.subLoginUser?.loginRole const loginRole = userInfo.subLoginUser?.loginRole
if ((userInfo.loginRole == 3 || userInfo.loginRole == 6) && menuList.every((item) => item.menuText != "场景集市")) menuList.push({
menuText: "场景集市",
icon: "sceneMarket",
navigateToUrl: "/packageEquity/pages/sceneMarket/index/index",
})
this.setData({ this.setData({
loginRole, loginRole,
userInfo userInfo,
menuList
}) })
this.getData() this.getData()
} }
...@@ -134,6 +142,12 @@ Component({ ...@@ -134,6 +142,12 @@ Component({
console.log(e) console.log(e)
const thisPage = wx.$router.getPageInstance() const thisPage = wx.$router.getPageInstance()
let { item } = e.currentTarget.dataset let { item } = e.currentTarget.dataset
if(item.navigateToUrl){
wx.navigateTo({
url: item.navigateToUrl
})
return
}
if (item.isTab) return thisPage.changeTabBar && thisPage.changeTabBar({ detail: item?.tabIndex }) if (item.isTab) return thisPage.changeTabBar && thisPage.changeTabBar({ detail: item?.tabIndex })
if (!item.path) wx.$util.showToast('模块暂未开通\r\n敬请期待') if (!item.path) wx.$util.showToast('模块暂未开通\r\n敬请期待')
}, },
......
...@@ -190,8 +190,7 @@ export default { ...@@ -190,8 +190,7 @@ export default {
data,[],"/rop-dj-pairexc/router" data,[],"/rop-dj-pairexc/router"
); );
}, },
/**
/**
* 获取token * 获取token
*/ */
getToken() { getToken() {
...@@ -199,4 +198,68 @@ export default { ...@@ -199,4 +198,68 @@ export default {
"dj.api.smartcarlife.recepiton.customer.oss.getToken", "dj.api.smartcarlife.recepiton.customer.oss.getToken",
); );
}, },
/**
* 获取话术确认状态统计
*/
getExtractCount(data) {
return api.post(
"dj.api.car.boutique.script.extract.check.status.count",
data
);
},
/**
* 多条件获取话术分页列表
*/
extractPage(data) {
return api.post(
"dj.api.car.boutique.script.extract.record.page",
data
);
},
/**
* 话术确认更新
*/
extractUpdate(data) {
return api.post(
"dj.api.car.boutique.script.extract.record.check.update",
data
);
},
/**
* 话术二次确认更新
*/
extractSecondUpdate(data) {
return api.post(
"dj.api.car.boutique.script.extract.record.second.check.update",
data
);
},
/**
* 话术分类查询标签
*/
extractLabel(data) {
return api.post(
"dj.api.car.boutique.script.extract.class.label.list",
data
);
},
/**
* 话术分类查询标签
*/
extractClass(data) {
return api.post(
"dj.api.car.boutique.script.extract.class.list",
data
);
},
/**
* 二次核验权限校验
*/
extractCheck(data) {
return api.post(
"dj.api.car.boutique.script.extract.second.check.permission",
data
);
},
} }
\ No newline at end of file \ No newline at end of file
...@@ -227,5 +227,9 @@ module.exports = { ...@@ -227,5 +227,9 @@ module.exports = {
// 校验订单是否需要上传合同协议 // 校验订单是否需要上传合同协议
checkZyPayFlag(data) { checkZyPayFlag(data) {
return api.post('dj.api.smartcarlife.vehicle.damage.upgrade.quotation.zyPayUrl.check', data) return api.post('dj.api.smartcarlife.vehicle.damage.upgrade.quotation.zyPayUrl.check', data)
} },
// 更新合同协议内容
updateZyInfo(data) {
return api.post('dj.api.smartcarlife.vehicle.damage.upgrade.quotation.zyPayUrl.update', data)
}
} }
...@@ -198,7 +198,7 @@ Page({ ...@@ -198,7 +198,7 @@ Page({
// isStaff && // isStaff &&
// tabIndex == 0 && // tabIndex == 0 &&
// eventRequest.push(this.staffDailyReport(wx.$util.getUserInfo())); // eventRequest.push(this.staffDailyReport(wx.$util.getUserInfo()));
if (tabIndex == 0 && !userInfo?.isSuper && userInfo?.loginRole != 3) if (tabIndex == 0 && !userInfo?.isSuper && userInfo?.loginRole != 3 && userInfo?.loginRole != 6)
eventRequest.push(this.checkAgreeClient(wx.$util.getUserInfo())); eventRequest.push(this.checkAgreeClient(wx.$util.getUserInfo()));
return new Promise((resolve) => { return new Promise((resolve) => {
Promise.all(eventRequest).then(() => { Promise.all(eventRequest).then(() => {
...@@ -224,7 +224,7 @@ Page({ ...@@ -224,7 +224,7 @@ Page({
let { code, data } = res; let { code, data } = res;
if (code == 0) { if (code == 0) {
if (!data) { if (!data) {
if (wx.__HAS_NOTLOGIN_MODAL || userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5) return false; if (wx.__HAS_NOTLOGIN_MODAL || userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) return false;
this.addModalToQueue( this.addModalToQueue(
"交车目标", "交车目标",
"您有未填写的交车目标,请点击前往", "您有未填写的交车目标,请点击前往",
...@@ -269,7 +269,7 @@ Page({ ...@@ -269,7 +269,7 @@ Page({
this.setData({ this.setData({
mode: -1, mode: -1,
}); });
if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5) return false if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) return false
this.addModalToQueue( this.addModalToQueue(
"温馨提示", "温馨提示",
"未配置权益规则,请联系客服处理。", "未配置权益规则,请联系客服处理。",
...@@ -291,7 +291,7 @@ Page({ ...@@ -291,7 +291,7 @@ Page({
this.setData({ this.setData({
userInfo, userInfo,
}); });
if (!userInfo.isSuper && userInfo.loginRole != 3) { if (!userInfo.isSuper && userInfo.loginRole != 3 && userInfo?.loginRole != 6) {
this.get4SStoreList(); this.get4SStoreList();
} else { } else {
this.setData({ showPage: true }) this.setData({ showPage: true })
...@@ -327,11 +327,11 @@ Page({ ...@@ -327,11 +327,11 @@ Page({
get4SStoreList() { get4SStoreList() {
let userInfo = wx.$util.getUserInfo(); let userInfo = wx.$util.getUserInfo();
let params = { let params = {
merchantId: userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 ? "" : userInfo?.merchantId, merchantId: userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6 ? "" : userInfo?.merchantId,
staffUUID: userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 ? "" : userInfo?.uuid, staffUUID: userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6 ? "" : userInfo?.uuid,
scene: 0, scene: 0,
}; };
get4SStoreList(params, userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5).then((result) => { get4SStoreList(params, userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo.loginRole == 6).then((result) => {
let userInfo = wx.$util.getUserInfo(); let userInfo = wx.$util.getUserInfo();
if (!result?.length) { if (!result?.length) {
userInfo.shopMerchantId = null; userInfo.shopMerchantId = null;
...@@ -341,7 +341,7 @@ Page({ ...@@ -341,7 +341,7 @@ Page({
wx.$util.setUserInfo(userInfo); wx.$util.setUserInfo(userInfo);
return wx.$router.reLaunch("pages.accountItems"); return wx.$router.reLaunch("pages.accountItems");
} }
if (result?.length && (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5)) { if (result?.length && (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6)) {
if (result[0]?.merchantName !== '全部' && result[0]?.merchantId) { if (result[0]?.merchantName !== '全部' && result[0]?.merchantId) {
result.unshift({ merchantName: '全部' }) result.unshift({ merchantName: '全部' })
} }
...@@ -415,7 +415,7 @@ Page({ ...@@ -415,7 +415,7 @@ Page({
.then((res) => { .then((res) => {
const { list = [] } = res.data; const { list = [] } = res.data;
if (list.length) { if (list.length) {
if (wx.__HAS_NOTLOGIN_MODAL || userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5) return false; if (wx.__HAS_NOTLOGIN_MODAL || userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) return false;
this.addModalToQueue( this.addModalToQueue(
"对练任务提醒", "对练任务提醒",
"您有未完成的对练任务,点击前往完成", "您有未完成的对练任务,点击前往完成",
...@@ -478,7 +478,7 @@ Page({ ...@@ -478,7 +478,7 @@ Page({
}) })
.then((result) => { .then((result) => {
if (result.data) { if (result.data) {
if (wx.__HAS_NOTLOGIN_MODAL || userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5) return false; if (wx.__HAS_NOTLOGIN_MODAL || userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) return false;
this.addModalToQueue( this.addModalToQueue(
"开单预警", "开单预警",
"您已超过三天未开单", "您已超过三天未开单",
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
<block wx:elif="{{tabIndex == 1}}"> <block wx:elif="{{tabIndex == 1}}">
<view class="navigation-title"> <view class="navigation-title">
<view class="navigation-title-text text-hide"> <view class="navigation-title-text text-hide">
<block wx:if="{{userInfo && (userInfo.isSuper||userInfo.loginRole== 3 || userInfo.loginRole== 5)}}"> <block wx:if="{{userInfo && (userInfo.isSuper||userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6)}}">
数字报价 数字报价
</block> </block>
<block wx:else> <block wx:else>
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
</view> </view>
<custom-tabBar list="{{ tabBarList }}" color="#6C6C70" selectedColor="#347BFF" tabIndex="{{ tabIndex }}" bindchange="changeTabBar" /> <custom-tabBar list="{{ tabBarList }}" color="#6C6C70" selectedColor="#347BFF" tabIndex="{{ tabIndex }}" bindchange="changeTabBar" />
<!-- <store-picker items="{{ storeListRange }}" show="{{ showPicker }}" bindsearch="getStoreList" bindconfirm="changePicker" /> --> <!-- <store-picker items="{{ storeListRange }}" show="{{ showPicker }}" bindsearch="getStoreList" bindconfirm="changePicker" /> -->
<block wx:if="{{userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5}}"> <block wx:if="{{userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6}}">
<side-select-by-page-popup show="{{ shopSideSelectPopup }}" bindconfirm="changePicker" /> <side-select-by-page-popup show="{{ shopSideSelectPopup }}" bindconfirm="changePicker" />
</block> </block>
<block wx:else> <block wx:else>
......
...@@ -4,12 +4,22 @@ Page({ ...@@ -4,12 +4,22 @@ Page({
/** /**
* 页面的初始数据 * 页面的初始数据
*/ */
data: {}, data: {
inputHeight: 0,
searchValue: '',
scrollTop: 0
},
/** /**
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
*/ */
onLoad(options) { onLoad(options) {
wx.$util.getViewInfo('#search-input', res => {
this.setData({
inputHeight: res.height
})
})
if (options.level == 2) this.level = 2
carLifeApi.getCarBrandList().then(res => { carLifeApi.getCarBrandList().then(res => {
// this.setLocalStorage('wx_scrm_car_brand_list', carInfo) // this.setLocalStorage('wx_scrm_car_brand_list', carInfo)
const carInfo = res.data const carInfo = res.data
...@@ -50,7 +60,10 @@ Page({ ...@@ -50,7 +60,10 @@ Page({
}, },
getLetter() { getLetter() {
wx.hideLoading() wx.hideLoading()
let { brandList, letter } = this.data let {
brandList,
letter
} = this.data
let arr = [] let arr = []
if (brandList.length > 0) { if (brandList.length > 0) {
brandList.forEach(e => { brandList.forEach(e => {
...@@ -79,15 +92,27 @@ Page({ ...@@ -79,15 +92,27 @@ Page({
}) })
}, },
start(e) { start(e) {
let { letter } = e.target.dataset let {
letter
} = e.target.dataset
this.setData({ this.setData({
showTip: true, showTip: true,
letter letter
}) })
}, },
move(e) { move(e) {
let { letterHeight, showTip, height, toTop, arr } = this.data let {
let { y, num, isNum } = this letterHeight,
showTip,
height,
toTop,
arr
} = this.data
let {
y,
num,
isNum
} = this
if (showTip) { if (showTip) {
y = e.touches[0].clientY y = e.touches[0].clientY
num = Math.ceil((y - toTop) / letterHeight) num = Math.ceil((y - toTop) / letterHeight)
...@@ -110,17 +135,72 @@ Page({ ...@@ -110,17 +135,72 @@ Page({
}) })
}, },
showCarSeries(e) { showCarSeries(e) {
let { item } = e.currentTarget.dataset, const {
level
} = this
let {
item
} = e.currentTarget.dataset,
brandInfo = { brandInfo = {
vehicleBrandId: item.id, vehicleBrandId: item.id,
vehicleBrandName: item.name vehicleBrandName: item.name
} }
if (item.childs && item.childs.length) if (item.childs && item.childs.length) {
if (level) {
this.setData({
carSeriesList: item.childs
})
return
}
wx.$router.go('carSeries', { wx.$router.go('carSeries', {
brandInfo, brandInfo,
list: item.childs list: item.childs,
}) })
else this.showToast('暂无该品牌车系') } else this.showToast('暂无该品牌车系')
},
cancel() {
this.setData({
carSeriesList: []
})
},
choose(e) {
const {
item
} = e.currentTarget.dataset
wx.$router.back(page => {
page.changeCarBrand && page.changeCarBrand(item)
})
},
scroll(e) {
this.setData({
scrollTop: e.detail.scrollTop
})
},
search(e) {
try {
let {
value
} = e.detail, {
brandList
} = this.data
brandList.map(i => {
i.list.map(k => {
if (k.name.includes(value)) throw k.id
})
})
} catch (id) {
this.setData({
letter: `brand-${id}`,
})
setTimeout(() => {
let {
scrollTop
} = this.data
this.setData({
scrollTopNum: scrollTop - 32
})
}, 200)
}
}, },
/** /**
* 生命周期函数--监听页面初次渲染完成 * 生命周期函数--监听页面初次渲染完成
...@@ -156,4 +236,4 @@ Page({ ...@@ -156,4 +236,4 @@ Page({
* 用户点击右上角分享 * 用户点击右上角分享
*/ */
// onShareAppMessage() {} // onShareAppMessage() {}
}) })
\ No newline at end of file \ No newline at end of file
<!--packageEquity/pages/carEquity/carBrands/carBrands.wxml--> <!--packageEquity/pages/carEquity/carBrands/carBrands.wxml-->
<view class="car-brands-box"> <view class="car-brands-box">
<view class="car-brands"> <view class="car-brands">
<scroll-view style="height:100%;" scroll-y scroll-into-view="{{letter}}"> <search-input bindsearch="search" value="{{searchValue}}" id="search-input" />
<scroll-view style="height:calc(100vh - {{inputHeight}}px);" scroll-y scroll-into-view="{{letter}}" scroll-top="{{scrollTopNum}}" bindscroll="scroll">
<block wx:if="{{flag}}"> <block wx:if="{{flag}}">
<block wx:if="{{brandList.length}}"> <block wx:if="{{brandList.length}}">
<block wx:for="{{brandList}}" wx:key="index"> <block wx:for="{{brandList}}" wx:key="index">
...@@ -9,7 +10,7 @@ ...@@ -9,7 +10,7 @@
<view class="title car-y-center">{{item.letter}}</view> <view class="title car-y-center">{{item.letter}}</view>
<view class="box"> <view class="box">
<block wx:for="{{item.list}}" wx:for-item="i" wx:key="ind" wx:for-index="ind"> <block wx:for="{{item.list}}" wx:for-item="i" wx:key="ind" wx:for-index="ind">
<view class="brands" catchtap="showCarSeries" data-item="{{i}}"> <view class="brands" catchtap="showCarSeries" data-item="{{i}}" id="brand-{{i.id}}">
<view class="list car-y-center"> <view class="list car-y-center">
<image src="{{i.logoUrl}}" class="icon" /> <image src="{{i.logoUrl}}" class="icon" />
{{i.name}} {{i.name}}
...@@ -35,4 +36,16 @@ ...@@ -35,4 +36,16 @@
<!-- 提示 --> <!-- 提示 -->
<view class='tips' hidden='{{!showTip}}'>{{letter}}</view> <view class='tips' hidden='{{!showTip}}'>{{letter}}</view>
</view> </view>
<block wx:if="{{carSeriesList.length}}">
<view class="car-type-box">
<view class="bg" bindtap="cancel" ></view>
<view class="brands-box">
<block wx:for="{{carSeriesList}}" wx:key="index">
<view class="title" bindtap="choose" data-item="{{item}}">{{item.name}}
</view>
</block>
</view>
</view>
</block>
</view> </view>
...@@ -117,4 +117,66 @@ ...@@ -117,4 +117,66 @@
.side-bar{ .side-bar{
font-size: var(--fontSize18); font-size: var(--fontSize18);
} }
}
.car-type-box {
position: fixed;
left: 0;
top: 0;
width: 100vw;
height: 100vh;
font-size: 28rpx;
color: #333;
z-index: 9999;
}
.car-type-box .bg {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.5);
}
.car-type-box .brands-box {
position: absolute;
top: 0;
right: 0;
width: 60.5%;
height: 100%;
overflow-y: scroll;
background: #fff;
-webkit-overflow-scrolling: touch;
animation: move 0.4s;
box-sizing: border-box;
padding-bottom: 40rpx;
}
.car-type-box .title {
width: 100%;
height: 108rpx;
line-height: 108rpx;
box-sizing: border-box;
padding-left: 32rpx;
color: #969799;
background: #F7F8FA;
}
.car-type-box .brands-box .brands-list {
width: 100%;
box-sizing: border-box;
padding-left: 32rpx;
border-bottom: 1rpx solid #e9e9e9;
animation: show-car-type .25s forwards;
}
@keyframes show-car-type{
0%{
min-height: 0;
opacity: 0;
}
100%{
min-height: 100rpx;
opacity: 1;
}
} }
\ No newline at end of file \ No newline at end of file
...@@ -110,7 +110,7 @@ Component({ ...@@ -110,7 +110,7 @@ Component({
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) 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)
......
...@@ -424,7 +424,7 @@ ...@@ -424,7 +424,7 @@
color: #FFFFFF; color: #FFFFFF;
background: #347BFF; background: #347BFF;
border-radius: var(--fontSize32); border-radius: var(--fontSize32);
padding: 0 var(--fontSize32); padding: 0 var(--fontSize24);
margin-right: var(--fontSize16); margin-right: var(--fontSize16);
} }
.order-btn:last-child{ .order-btn:last-child{
......
...@@ -59,7 +59,7 @@ Page({ ...@@ -59,7 +59,7 @@ Page({
}, },
// 合同协议上传确定 // 合同协议上传确定
zyPayConfirm(e) { zyPayConfirm(e) {
wx.showLoading() wx.showLoading({title: '加载中', mask: true})
let { zyPayOrderInfo, zyConfirmFlag } = this.data let { zyPayOrderInfo, zyConfirmFlag } = this.data
if (zyConfirmFlag) return false if (zyConfirmFlag) return false
this.setData({ this.setData({
...@@ -204,6 +204,7 @@ Page({ ...@@ -204,6 +204,7 @@ Page({
* 生命周期函数--监听页面隐藏 * 生命周期函数--监听页面隐藏
*/ */
onHide() { onHide() {
let { timer } = this.data
clearInterval(timer) // 清除定时器 clearInterval(timer) // 清除定时器
}, },
...@@ -211,6 +212,7 @@ Page({ ...@@ -211,6 +212,7 @@ Page({
* 生命周期函数--监听页面卸载 * 生命周期函数--监听页面卸载
*/ */
onUnload() { onUnload() {
let { timer } = this.data
clearInterval(timer) // 清除定时器 clearInterval(timer) // 清除定时器
}, },
......
...@@ -18,7 +18,7 @@ Component({ ...@@ -18,7 +18,7 @@ Component({
userInfo userInfo
} = this.data } = this.data
// 非超管 获取转化人员 销售顾问 // 非超管 获取转化人员 销售顾问
if (!(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5)) { if (!(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6)) {
if (wx.$orderListDateListScreenRefresh) { // 切换门店将数据清空 if (wx.$orderListDateListScreenRefresh) { // 切换门店将数据清空
this.setData({ this.setData({
'form.referrerIds': [], 'form.referrerIds': [],
...@@ -457,8 +457,8 @@ Component({ ...@@ -457,8 +457,8 @@ Component({
}) })
transferIds?.map((val, index) => { transferIds?.map((val, index) => {
val.active = false val.active = false
if (!(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5) && userInfo.uuid == val.uuid) val.active = true if (!(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) && userInfo.uuid == val.uuid) val.active = true
if ((userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5) && index == 0) val.active = true if ((userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) && index == 0) val.active = true
}) })
orderStatus?.map((val, index) => { orderStatus?.map((val, index) => {
val.active = false val.active = false
...@@ -527,7 +527,7 @@ Component({ ...@@ -527,7 +527,7 @@ Component({
} }
}) })
}) })
if ((userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5)) ['selectedYqMerchantList', 'selectedMerchantList'].map(e => { if ((userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6)) ['selectedYqMerchantList', 'selectedMerchantList'].map(e => {
delete obj[e] delete obj[e]
}) })
if (isReset) obj = {} if (isReset) obj = {}
......
...@@ -2,11 +2,11 @@ ...@@ -2,11 +2,11 @@
<scroll-view scroll-y class="confirm-box" style="height:calc(100vh - {{navBarHeight }}px + 1px);margin-top:calc({{navBarHeight }}px - 1px);" hidden="{{!show}}"> <scroll-view scroll-y class="confirm-box" style="height:calc(100vh - {{navBarHeight }}px + 1px);margin-top:calc({{navBarHeight }}px - 1px);" hidden="{{!show}}">
<view class="main" style="padding-bottom:{{btnHeight}}px"> <view class="main" style="padding-bottom:{{btnHeight}}px">
<!-- 非超管转化人员 --> <!-- 非超管转化人员 -->
<view class="box" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5)}}"> <view class="box" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6)}}">
<view class="title"> <view class="title">
<view class="title-left"> <view class="title-left">
转化人员 转化人员
<view class="title-tips" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5)}}">{{userInfo.merchantName}}</view> <view class="title-tips" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6)}}">{{userInfo.merchantName}}</view>
</view> </view>
<view wx:if="{{form.transferIds.length > 12}}" bindtap="showMore" data-type="1" class="collapse-btn {{!employShowMore ? 'rotate-180' : ''}}"> <view wx:if="{{form.transferIds.length > 12}}" bindtap="showMore" data-type="1" class="collapse-btn {{!employShowMore ? 'rotate-180' : ''}}">
<image src="{{IMG_URL}}collapse_icon.png" mode="" /> <image src="{{IMG_URL}}collapse_icon.png" mode="" />
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
</view> </view>
</view> </view>
<!-- 超管转化人员 选择园区店 --> <!-- 超管转化人员 选择园区店 -->
<view class="box" wx:if="{{(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5)}}"> <view class="box" wx:if="{{(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6)}}">
<view class="title"> <view class="title">
<view class="title-left"> <view class="title-left">
转化人员 转化人员
...@@ -42,11 +42,11 @@ ...@@ -42,11 +42,11 @@
</view> </view>
</view> </view>
<!-- 非超管销售顾问 --> <!-- 非超管销售顾问 -->
<view class="box" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5)}}"> <view class="box" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6)}}">
<view class="title"> <view class="title">
<view class="title-left"> <view class="title-left">
销售顾问 销售顾问
<view class="title-tips" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5)}}">{{userInfo.shopMerchantName}}</view> <view class="title-tips" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6)}}">{{userInfo.shopMerchantName}}</view>
</view> </view>
<view wx:if="{{form.referrerIds.length > 12}}" bindtap="showMore" data-type="2" class="collapse-btn {{!salesmanShowMore ? 'rotate-180' : ''}}"> <view wx:if="{{form.referrerIds.length > 12}}" bindtap="showMore" data-type="2" class="collapse-btn {{!salesmanShowMore ? 'rotate-180' : ''}}">
<image src="{{IMG_URL}}collapse_icon.png" mode="" /> <image src="{{IMG_URL}}collapse_icon.png" mode="" />
...@@ -61,11 +61,11 @@ ...@@ -61,11 +61,11 @@
</view> </view>
</view> </view>
<!-- 超管销售顾问 选择4s店 --> <!-- 超管销售顾问 选择4s店 -->
<view class="box" wx:if="{{(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5)}}"> <view class="box" wx:if="{{(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6)}}">
<view class="title"> <view class="title">
<view class="title-left"> <view class="title-left">
销售顾问 销售顾问
<view class="title-tips" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5)}}">{{userInfo.shopMerchantName}}</view> <view class="title-tips" wx:if="{{!(userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6)}}">{{userInfo.shopMerchantName}}</view>
</view> </view>
<view wx:if="{{form.selectedMerchantList.length > 3}}" bindtap="showMore" data-type="2" class="collapse-btn {{!salesmanShowMore ? 'rotate-180' : ''}}"> <view wx:if="{{form.selectedMerchantList.length > 3}}" bindtap="showMore" data-type="2" class="collapse-btn {{!salesmanShowMore ? 'rotate-180' : ''}}">
<image src="{{IMG_URL}}collapse_icon.png" mode="" /> <image src="{{IMG_URL}}collapse_icon.png" mode="" />
......
...@@ -13,6 +13,7 @@ Component({ ...@@ -13,6 +13,7 @@ Component({
type: Boolean, type: Boolean,
observer: function(n) { observer: function(n) {
if (n) { if (n) {
let { showZyTarget, updateZyFlag } = this.data
let sysInfo = wx.getSystemInfoSync() let sysInfo = wx.getSystemInfoSync()
// sysInfo.environment 1 企业微信打开 0微信打开 // sysInfo.environment 1 企业微信打开 0微信打开
// sysInfo.platform === 'windows' || sysInfo.platform === 'mac' || sysInfo.platform === 'linux' 是否pc端打开 // sysInfo.platform === 'windows' || sysInfo.platform === 'mac' || sysInfo.platform === 'linux' 是否pc端打开
...@@ -20,12 +21,23 @@ Component({ ...@@ -20,12 +21,23 @@ Component({
envName: sysInfo.environment ? 1 : 0, envName: sysInfo.environment ? 1 : 0,
envPlat: sysInfo.platform === 'windows' || sysInfo.platform === 'mac' || sysInfo.platform === 'linux' ? 1 : 0 envPlat: sysInfo.platform === 'windows' || sysInfo.platform === 'mac' || sysInfo.platform === 'linux' ? 1 : 0
}) })
// 已上传协议 修改协议
if (updateZyFlag && showZyTarget?.zyPayUrl) {
let fileUrl = wx.$util.deepClone(showZyTarget?.zyPayUrl)
let fileList = fileUrl?.split(',')?.map(v => ({url: v, fileName: v?.split('/').pop()}))
this.setData({
fileType: fileUrl?.includes('.pdf') ? 'pdf' : 'image',
fileList: fileList
})
}
} }
} }
}, },
isListShow: Boolean, // 是否报价单列表 isListShow: Boolean, // 是否报价单列表
onlinePaymentFlag: Boolean, // 是否线上支付 onlinePaymentFlag: Boolean, // 是否线上支付
supplementaryFlag: Boolean // 是否订单补录 supplementaryFlag: Boolean, // 是否订单补录
showZyTarget: Object,
updateZyFlag: Boolean // 是否修改协议
}, },
/** /**
...@@ -107,6 +119,38 @@ Component({ ...@@ -107,6 +119,38 @@ Component({
}) })
}, },
// 预览pdf文件
previewFile(e) {
let { target } = e.currentTarget.dataset
wx.showLoading({
title: '加载中',
mask: true
})
wx.downloadFile({
url: target?.replace(/^http:/, 'https:'), // 将http文件地址转为https (开发环境文件服务器不支持https无法预览)
success: function (res) {
const manage = wx.getFileSystemManager()
let file = target.split('/')
let fileName = file[file.length - 1]
manage.saveFile({
tempFilePath: res.tempFilePath,
filePath: wx.env.USER_DATA_PATH + '/' + fileName,
success: function (res) {
wx.hideLoading()
wx.openDocument({
filePath: wx.env.USER_DATA_PATH + '/' + fileName,
fileType: 'pdf',
showMenu: true,
success: function (res) {
wx.hideLoading()
}
})
}
})
}
})
},
// 图片预览 // 图片预览
previewImage(e) { previewImage(e) {
let { url, index } = e.currentTarget.dataset let { url, index } = e.currentTarget.dataset
...@@ -118,14 +162,14 @@ Component({ ...@@ -118,14 +162,14 @@ Component({
}, },
async uploadPDFs() { async uploadPDFs() {
let { envPlat, envName } = this.data let { envPlat, envName, updateZyFlag } = this.data
if (envPlat == 1 || envName == 1) { // 企微或在pc端打开登录小程序使用跳转h5上传方式 if (envPlat == 1 || envName == 1) { // 企微或在pc端打开登录小程序使用跳转h5上传方式
this.setData({ this.setData({
showChangeFileType: false, showChangeFileType: false,
show: false show: false
}) })
const { zyWebViewUrl } = await wx.$util.getMockData() const { zyWebViewUrl } = await wx.$util.getMockData()
let path = `${zyWebViewUrl}/#/zyUpload` let path = updateZyFlag ? `${zyWebViewUrl}/#/zyUpload?updateZyFlag=true` : `${zyWebViewUrl}/#/zyUpload`
return wx.navigateTo({ return wx.navigateTo({
url: `/pages/webView/webView?url=${encodeURIComponent(path)}`, url: `/pages/webView/webView?url=${encodeURIComponent(path)}`,
events: { events: {
...@@ -153,6 +197,9 @@ Component({ ...@@ -153,6 +197,9 @@ Component({
let tempFile = res.tempFiles[0] let tempFile = res.tempFiles[0]
let fileName = tempFile.name // 获取文件名 let fileName = tempFile.name // 获取文件名
let fileType = fileName.split('.').pop() // 获取文件扩展名 let fileType = fileName.split('.').pop() // 获取文件扩展名
if (tempFile?.size > 1024 * 1024 * 10) {
return wx.$util.showToast('上传文件需≤10M,请压缩后重传或联系总部')
}
// 读取文件 // 读取文件
if (fileType != 'pdf') return wx.$util.showToast('只可上传pdf类型文件') if (fileType != 'pdf') return wx.$util.showToast('只可上传pdf类型文件')
_this.setData({ _this.setData({
...@@ -223,22 +270,42 @@ Component({ ...@@ -223,22 +270,42 @@ Component({
}, },
confirm(e, pageBackNum) { confirm(e, pageBackNum) {
// pageBackNum 从h5返回页面层级数 // pageBackNum 从h5返回页面层级数
let { fileList, isListShow, onlinePaymentFlag, supplementaryFlag } = this.data let _this = this
let thisPage = wx.$router.getPageInstance(pageBackNum || 1) let { fileList, updateZyFlag } = _this.data
if (fileList.length) { if (fileList.length) {
// 报价单列表上传协议或者线上支付方式上传协议或者补录订单上传协议 if (!pageBackNum && updateZyFlag) {
if (isListShow || onlinePaymentFlag || supplementaryFlag) { wx.showModal({
this.triggerEvent('confirm', {zyPayUrl: fileList.map(item => item.url)}) title: '修改确认',
} else { content: '本次操作将永久替换原图或协议(仅限1次修改权限),请确认是否更新?',
thisPage.setData({ confirmText: '确定',
['orderInfo.zyPayUrl']: fileList.map(item => item.url)?.join(','), confirmColor: '#347BFF',
confirmStatus: false success(res) {
if (res.confirm) {
_this.confirmEvent(pageBackNum)
}
}
}) })
thisPage.handleSecondConfirm() } else {
_this.confirmEvent(pageBackNum)
} }
} else { } else {
wx.$util.showToast('请上传合同协议') wx.$util.showToast('请上传合同协议')
} }
},
confirmEvent(pageBackNum) {
let _this = this
let { fileList, isListShow, onlinePaymentFlag, supplementaryFlag } = _this.data
let thisPage = wx.$router.getPageInstance(pageBackNum || 1)
// 报价单列表上传协议或者线上支付方式上传协议或者补录订单上传协议
if (isListShow || onlinePaymentFlag || supplementaryFlag) {
_this.triggerEvent('confirm', {zyPayUrl: fileList.map(item => item.url)})
} else {
thisPage.setData({
['orderInfo.zyPayUrl']: fileList.map(item => item.url)?.join(','),
confirmStatus: false
})
thisPage.handleSecondConfirm()
}
} }
} }
}) })
\ No newline at end of file \ No newline at end of file
...@@ -4,11 +4,13 @@ ...@@ -4,11 +4,13 @@
} }
.tips-text{ .tips-text{
display: flex; display: flex;
align-items: center; align-items: flex-start;
padding: var(--fontSize40) 0 var(--fontSize32) 0; padding: var(--fontSize40) 0 var(--fontSize32) 0;
font-size: var(--fontSize28); font-size: var(--fontSize28);
color: #222222; color: #222222;
image{ image{
flex-shrink: 0;
margin-top: var(--fontSize2);
width: var(--fontSize32); width: var(--fontSize32);
height: var(--fontSize32); height: var(--fontSize32);
margin-right: var(--fontSize12); margin-right: var(--fontSize12);
......
...@@ -2,17 +2,17 @@ ...@@ -2,17 +2,17 @@
<glsx-privacy appletName="生意助手员工版" bind:agreeClick="agreeClick" bind:disagreeClick="disagreeClick"></glsx-privacy> <glsx-privacy appletName="生意助手员工版" bind:agreeClick="agreeClick" bind:disagreeClick="disagreeClick"></glsx-privacy>
<block wx:if="{{!showChangeFileType && !loadingFlag}}"> <block wx:if="{{!showChangeFileType && !loadingFlag}}">
<popup <popup
title="{{'上传合同协议'}}" title="{{updateZyFlag ? '修改合同协议' : '上传合同协议'}}"
show="{{show}}" show="{{show}}"
bindconfirm="confirm" bindconfirm="confirm"
bindcancel="close" bindcancel="close"
cancelText="稍后补录" cancelText="{{updateZyFlag ? '取消' : '稍后补录'}}"
cancelStyle="color: #347BFF;" cancelStyle="color: #347BFF;"
notCloseOnClickOverlay="{{true}}" notCloseOnClickOverlay="{{true}}"
height="auto"> height="auto">
<view class="content"> <view class="content">
<block wx:if="{{!fileList.length}}"> <block wx:if="{{!fileList.length}}">
<view class="tips-text"><image src="{{IMG_URL}}zy_tips_icon.png"></image>事系提成核算,务必提供</view> <view class="tips-text"><image src="{{IMG_URL}}zy_tips_icon.png"></image>上传完毕计入有效成交,订单才可参与提成/清分/积分发放!</view>
<view class="upload_content" bindtap="selectUplaodType"> <view class="upload_content" bindtap="selectUplaodType">
<image src="{{IMG_URL}}zy-upload_icon.png"></image> <image src="{{IMG_URL}}zy-upload_icon.png"></image>
<text class="text">图片或PDF</text> <text class="text">图片或PDF</text>
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
</block> </block>
<block wx:else> <block wx:else>
<view class="file_content" wx:for="{{fileList}}" wx:key="index"> <view class="file_content" wx:for="{{fileList}}" wx:key="index">
<view class="file_box"> <view class="file_box" bindtap="previewFile" data-target="{{item.url}}">
<image class="pdf_icon" src="{{IMG_URL}}zy_upload_pdf.png" mode=""/> <image class="pdf_icon" src="{{IMG_URL}}zy_upload_pdf.png" mode=""/>
<text class="file_name">{{item.fileName}}</text> <text class="file_name">{{item.fileName}}</text>
</view> </view>
......
...@@ -265,7 +265,7 @@ Page({ ...@@ -265,7 +265,7 @@ Page({
// 补录订单上传合同协议点击确定 // 补录订单上传合同协议点击确定
zyPayConfirm(e) { zyPayConfirm(e) {
let { supplementaryOrderId, zyConfirmFlag } = this.data // 补录订单id let { supplementaryOrderId, zyConfirmFlag } = this.data // 补录订单id
wx.showLoading() wx.showLoading({title: '加载中', mask: true})
if (zyConfirmFlag) return false if (zyConfirmFlag) return false
this.setData({ this.setData({
zyConfirmFlag: true zyConfirmFlag: true
......
...@@ -8,7 +8,8 @@ import { ...@@ -8,7 +8,8 @@ import {
cancelOrderById, cancelOrderById,
getQuotationInfoById, getQuotationInfoById,
updateCustomerInfo, updateCustomerInfo,
errorOrderById errorOrderById,
updateZyInfo
} from "../../../api"; } from "../../../api";
import { checkDailyReport } from "~/store/ModalToQueueControl"; import { checkDailyReport } from "~/store/ModalToQueueControl";
import data from "../constant/data"; import data from "../constant/data";
...@@ -214,13 +215,13 @@ Component({ ...@@ -214,13 +215,13 @@ Component({
nothing: false, nothing: false,
currentPage: 1, currentPage: 1,
storeInfo: wx.$util.getUserInfo()?.default4SStoreInfo || {}, storeInfo: wx.$util.getUserInfo()?.default4SStoreInfo || {},
isOrder: !(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5), isOrder: !(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6),
list: [] list: []
}); });
// this.getTotal() // this.getTotal()
if (!noGetList) this.getList(true); if (!noGetList) this.getList(true);
this.getOrderStatistics(); this.getOrderStatistics();
if (!userInfo?.isSuper && userInfo?.loginRole != 3) this.getMerchantCarBrandList(); if (!userInfo?.isSuper && userInfo?.loginRole != 3 && userInfo?.loginRole != 6) this.getMerchantCarBrandList();
}, },
async handleClickOrderBtn(e) { async handleClickOrderBtn(e) {
// 校验是否填写昨日日报 // 校验是否填写昨日日报
...@@ -323,7 +324,7 @@ Component({ ...@@ -323,7 +324,7 @@ Component({
zyPayStatus zyPayStatus
}; };
if (!userInfo.isSuper && userInfo.loginRole != 3) { if (!userInfo.isSuper && userInfo.loginRole != 3 && userInfo?.loginRole != 6) {
// debugger // debugger
params.transferIds = [userInfo.uuid]; params.transferIds = [userInfo.uuid];
} }
...@@ -334,7 +335,10 @@ Component({ ...@@ -334,7 +335,10 @@ Component({
} }
wx.$util.showLoading(); wx.$util.showLoading();
quotationPage({ ...params, ...screenForm }) let eventParams = wx.$util.deepClone({...params, ...screenForm})
// 当合同协议状态为待上传时,传订单状态为待上传7
if (eventParams?.zyPayStatus == '1') eventParams.orderStatus = 7
quotationPage(eventParams)
.then((res) => { .then((res) => {
wx.hideLoading(); wx.hideLoading();
if (res.code == "0") { if (res.code == "0") {
...@@ -479,7 +483,14 @@ Component({ ...@@ -479,7 +483,14 @@ Component({
// 校验是否填写昨日日报 // 校验是否填写昨日日报
let staffCheck = await checkDailyReport(true); let staffCheck = await checkDailyReport(true);
if (staffCheck) return false; if (staffCheck) return false;
return this.setData({ showZyPayPopup: true, showZyTarget: target }) return this.setData({ showZyPayPopup: true, showZyTarget: target, updateZyFlag: false })
}
// 修改合同协议
if (target?.zyPayStatus == '2' && target?.canUpdateZyPayUrl == 1 && type == 'upload') {
// 校验是否填写昨日日报
let staffCheck = await checkDailyReport(true);
if (staffCheck) return false;
return this.setData({ showZyPayPopup: true, showZyTarget: target, updateZyFlag: true })
} }
// wx.$router.go('createOrderCarQuotation', { // wx.$router.go('createOrderCarQuotation', {
// id: target.id // id: target.id
...@@ -586,43 +597,73 @@ Component({ ...@@ -586,43 +597,73 @@ Component({
}, },
// 合同协议上传确定 // 合同协议上传确定
zyPayConfirm(e) { zyPayConfirm(e) {
let { showZyTarget, zyConfirmFlag } = this.data let { showZyTarget, zyConfirmFlag, updateZyFlag } = this.data
wx.showLoading() wx.showLoading({title: '加载中', mask: true})
if (zyConfirmFlag) return false if (zyConfirmFlag) return false
this.setData({ this.setData({
zyConfirmFlag: true zyConfirmFlag: true
}); });
getQuotationInfoById({ if (updateZyFlag) { // 更新合同协议
id: showZyTarget?.id updateZyInfo({ id: showZyTarget?.id, zyPayUrl: e.detail?.zyPayUrl?.join(',') }).then(res => {
}).then(res => { wx.hideLoading()
let { code, message, data } = res let { code, message } = res
if (code == 0) { if (code == 0) {
let orderInfo = this.getInsurance(data)
// 更新客户信息
updateCustomerInfo({ ...orderInfo, zyPayUrl: e.detail?.zyPayUrl?.join(',') }).then(result => {
wx.hideLoading()
this.setData({ this.setData({
showZyPayPopup: false showZyPayPopup: false
}, () => { }, () => {
this.setData({ this.setData({
zyConfirmFlag: false zyConfirmFlag: false,
}); updateZyFlag: false
})
this.search() this.search()
}) })
}) } else {
} else { this.setData({
wx.$util.showToast(message) showZyPayPopup: false
}, () => {
wx.$util.showToast(message)
})
}
}).catch(() => {
wx.hideLoading() wx.hideLoading()
this.setData({ this.setData({
zyConfirmFlag: false,
updateZyFlag: false
})
})
} else {
getQuotationInfoById({
id: showZyTarget?.id
}).then(res => {
let { code, message, data } = res
if (code == 0) {
let orderInfo = this.getInsurance(data)
// 更新客户信息
updateCustomerInfo({ ...orderInfo, zyPayUrl: e.detail?.zyPayUrl?.join(',') }).then(result => {
wx.hideLoading()
this.setData({
showZyPayPopup: false
}, () => {
this.setData({
zyConfirmFlag: false
});
this.search()
})
})
} else {
wx.$util.showToast(message)
wx.hideLoading()
this.setData({
zyConfirmFlag: false
})
}
}).catch(() => {
this.setData({
zyConfirmFlag: false zyConfirmFlag: false
}) })
} wx.hideLoading()
}).catch(() => {
this.setData({
zyConfirmFlag: false
}) })
wx.hideLoading() }
})
}, },
remarkCancel() { remarkCancel() {
this.setData({ this.setData({
...@@ -662,7 +703,7 @@ Component({ ...@@ -662,7 +703,7 @@ Component({
{ screenForm } = this, { screenForm } = this,
obj = {} obj = {}
let searchTemp = wx.$util.deepClone(screenForm || {}); let searchTemp = wx.$util.deepClone(screenForm || {});
if (!userInfo.isSuper && userInfo.loginRole != 3) { if (!userInfo.isSuper && userInfo.loginRole != 3 && userInfo?.loginRole != 6) {
obj.transferIds = [userInfo.uuid]; obj.transferIds = [userInfo.uuid];
} }
if (staffUuid) { if (staffUuid) {
...@@ -674,11 +715,10 @@ Component({ ...@@ -674,11 +715,10 @@ Component({
// ...obj, // ...obj,
// ...searchTemp // ...searchTemp
// }, '2222'); // }, '2222');
orderStatistics({ let eventParams = wx.$util.deepClone({...obj, ...searchTemp, customerName})
...obj, // 当合同协议状态为待上传时,传订单状态为待上传7
...searchTemp, if (eventParams?.zyPayStatus == '1') eventParams.orderStatus = 7
customerName orderStatistics(eventParams)
})
.then((result) => { .then((result) => {
let { data, code } = result; let { data, code } = result;
// debugger // debugger
......
...@@ -163,6 +163,9 @@ ...@@ -163,6 +163,9 @@
</block> </block>
<block wx:else> <block wx:else>
<view wx:if="{{ item.orderStatus != '4' && item.orderStatus!=11&& item.orderStatus!=9 }}" class="btn_class"> <view wx:if="{{ item.orderStatus != '4' && item.orderStatus!=11&& item.orderStatus!=9 }}" class="btn_class">
<block wx:if="{{ item.canUpdateZyPayUrl == 1 && item.zyPayStatus == 2 }}">
<view class="order-btn default-btn padding_20" bindtap="handleClickBtn" data-type="upload" data-target="{{ item }}">修改协议</view>
</block>
<block wx:if="{{ item.orderStatus != '0' }}"> <block wx:if="{{ item.orderStatus != '0' }}">
<view class="order-btn default-btn padding_20" bindtap="jumpReception" data-item="{{ item }}">接待记录</view> <view class="order-btn default-btn padding_20" bindtap="jumpReception" data-item="{{ item }}">接待记录</view>
</block> </block>
...@@ -281,4 +284,4 @@ ...@@ -281,4 +284,4 @@
</view> </view>
</view> </view>
</view> </view>
<zy-pay-popup wx:if="{{showZyPayPopup}}" isListShow="{{true}}" show="{{showZyPayPopup}}" bindconfirm="zyPayConfirm"></zy-pay-popup>
\ No newline at end of file \ No newline at end of file
<zy-pay-popup wx:if="{{showZyPayPopup}}" showZyTarget="{{showZyTarget}}" updateZyFlag="{{updateZyFlag}}" isListShow="{{true}}" show="{{showZyPayPopup}}" bindconfirm="zyPayConfirm"></zy-pay-popup>
\ No newline at end of file \ No newline at end of file
...@@ -516,7 +516,7 @@ ...@@ -516,7 +516,7 @@
.btn_class { .btn_class {
display: flex; display: flex;
gap: var(--fontSize20); gap: var(--fontSize16);
margin-left: auto; margin-left: auto;
} }
...@@ -530,7 +530,7 @@ ...@@ -530,7 +530,7 @@
color: #FFFFFF; color: #FFFFFF;
background: #347BFF; background: #347BFF;
border-radius: var(--fontSize32); border-radius: var(--fontSize32);
padding: var(--fontSize8) var(--fontSize40); padding: var(--fontSize8) var(--fontSize20);
flex-shrink: 0; flex-shrink: 0;
} }
...@@ -542,7 +542,7 @@ ...@@ -542,7 +542,7 @@
} }
.padding_20 { .padding_20 {
padding: 0 var(--fontSize20); padding: 0 var(--fontSize14);
} }
.list .item .order { .list .item .order {
......
{
"component": true,
"usingComponents": {
"order-screen": "../components/OrderScreen/OrderScreen"
}
}
\ No newline at end of file \ No newline at end of file
import aiApi from "../../../aiApi";
Page({
data: {
showPicker: false,
showPopup: false,
defaultIndex:0,
list: [{
label: '标签名',
value: 'sceneLabelName'
}, {
label: '话术来源',
value: 'staffName'
}, {
label: '萃取时间',
value: 'scriptTime'
},
{
label: "提交人",
value: "updatedBy",
type: 'UpdatedBy',
hidden: true
},
{
label: "提交时间",
value: "updatedTime",
type: 'UpdatedTime',
hidden: true
}, {
label: '原文',
value: 'sourceContent'
}, {
label: '润色文本',
value: 'polishContent'
}
],
array: ['美国', '中国', '巴西', '日本'],
navBarHeight: 0,
navStyle: "background-color: transparent;box-shadow:none",
polishedText: '您对这辆车未来的使用规划是怎样的呀?是打算长期频繁使用,长时间陪伴您的出行呢,还是想着开个三四年,体验一番后就考虑更换新车?看样子您是准备多开几年,对吧?',
isExcellent: true,
categories: ['需求探寻', '产品介绍', '价格谈判', '异议处理'],
currentCategory: '需求探寻',
tags: [{
id: 1,
name: '互动深入',
selected: true
},
{
id: 2,
name: '逻辑清晰',
selected: true
},
{
id: 3,
name: '风险灌输有力',
selected: false
},
{
id: 4,
name: '异议处理新颖多样',
selected: false
}
]
},
// 头部返回上一级
back() {
wx.$router.back()
},
onLoad() {
wx.$router.getData(({
item
}) => {
let {
list
} = this.data
if (item.checkStatus == 0) {
list = list.filter(i => !i.hidden)
}
this.extractLabel(list, item)
this.extractClass(item)
})
},
setTags(classCode) {
const {detail} = this.data
aiApi.extractLabel({
classCode
}).then(res => {
const {
labelCode: code
} = res.data[0] || {}
detail.labelCode = code
this.setData({
detail,
tags: res.data
})
})
},
extractLabel(list, item) {
const {classCode} = item
aiApi.extractLabel({
classCode
}).then(res => {
if (item.excellentFlag === null) {
item.excellentFlag = 1
}
if (!item.labelCode) {
const {
labelCode: code
} = res.data[0] || {}
item.labelCode = code
}
this.setData({
detail: item,
list,
tags: res.data
})
})
},
extractClass(detail) {
aiApi.extractClass().then(res => {
const extractClassList = res.data || []
const classArray = extractClassList.map(i => i.className)
const defaultIndex = extractClassList.findIndex(i=>i.classCode == detail.classCode)
this.setData({
extractClassList,
defaultIndex,
classArray
})
})
},
pickerCancel() {
this.setData({
showPicker: false
})
},
pickerConfirm(event) {
const {
index
} = event.detail;
let {
extractClassList,
detail
} = this.data
detail.className = extractClassList[index].className
detail.classCode = extractClassList[index].classCode
this.setData({
showPicker: false,
classIndex: index,
detail
})
this.setTags(detail.classCode)
},
toggleClass() {
this.setData({
showPicker: true
})
},
// 编辑润色文本
handleEdit() {
this.setData({
showPopup: true
})
},
handleCancel() {
this.setData({
showPopup: false
})
},
editConfirm() {
this.handleCancel()
},
navbarReady(e) {
let navBarHeight = e.detail.height
this.setData({
navBarHeight
})
},
onChange(event) {
this.setDetail('excellentFlag', event.detail)
},
setDetail(name, value) {
const {
detail
} = this.data
detail[name] = value
this.setData({
detail
});
},
textareaInput(e) {
this.setDetail('polishContent', e.detail.value)
},
// 标签选择
toggleTag(e) {
const {
code
} = e.currentTarget.dataset
const {
detail
} = this.data
detail.labelCode = code
this.setData({
detail
})
},
// 确认提交
handleConfirm() {
const _this = this;
wx.showModal({
title: '温馨提示',
content: '话术确认完成?',
showCancel: true,
confirmText: '确定',
confirmColor: '#347BFF',
success(res) {
if (res.confirm) {
_this.extractUpdate()
}
}
})
},
extractUpdate() {
const {
detail: {
id,
classCode,
excellentFlag,
labelCode,
polishContent,
type
}
} = this.data
const params = {
id,
classCode,
excellentFlag,
labelCode,
polishContent,
}
let updateApi = 'extractUpdate'
if (type == 2) {
updateApi = 'extractSecondUpdate'
}
aiApi[updateApi](params).then(res => {
if (res.data) {
wx.navigateTo({
url: `/packageEquity/pages/extract/success/success`,
});
}
})
}
})
\ No newline at end of file \ No newline at end of file
{
"usingComponents": {
"van-picker": "@vant/weapp/picker/index",
"van-popup": "@vant/weapp/popup/index",
"van-radio": "@vant/weapp/radio/index",
"van-radio-group": "@vant/weapp/radio-group/index"
},
"navigationStyle": "custom"
}
\ No newline at end of file \ No newline at end of file
/* 基础样式 */
.bg-box {
position: fixed;
inset: 0;
z-index: -1;
width: 750rpx;
height: 640rpx;
background: linear-gradient(to bottom, #DEF6FC 0%, #E3EAFF 27%, #D6E6FF 71%, #F7F8FA 96%);
}
.container {
overflow: auto;
}
.van-radio-group {
display: flex;
gap: 20rpx;
}
.header {
font-size: 36rpx;
font-weight: bold;
padding: 30rpx 0;
text-align: center;
}
/* 信息卡片 */
.info-card {
border-radius: 16rpx;
opacity: 1;
background: #ffffff;
box-shadow: 0 4rpx 20rpx 0 #cdcdd159;
margin: 0 20rpx 20rpx;
padding: 32rpx;
.card-title {
color: #222222;
font-size: 32rpx;
font-weight: 600;
margin-bottom: 20rpx;
position: relative;
&::before {
content: '';
position: absolute;
top: 0;
left: -32rpx;
width: 8rpx;
height: 40rpx;
border-radius: 0 4rpx 4rpx 0;
background: #347bff;
}
}
}
.info-row {
display: flex;
margin-bottom: 15rpx;
font-size: 28rpx;
line-height: 45rpx;
picker {
color: #347BFF; /* 文字颜色 */
}
.picker {
width: 494rpx;
height: 68rpx;
line-height: 64rpx;
padding: 0 16rpx;
border-radius: 8rpx;
opacity: 1;
background: #f7f8fa;
box-sizing: border-box;
display:flex;
justify-content: space-between;
}
.arrow::after {
content: "";
display: inline-block;
width: 6px;
height: 6px;
border-right: 2px solid #181A1F;
border-top: 2px solid #181A1F;
transform: rotate(45deg);
margin-left: 5px;
vertical-align: middle;
}
}
.label {
width: 150rpx;
color: #999ea8;
}
.value {
flex: 1;
color: #292d33;
text {
color:#347BFF;
}
}
/* 内容区块 */
.section {
background: white;
border-radius: 12rpx;
padding: 25rpx;
margin-bottom: 30rpx;
}
.section-title {
font-weight: bold;
display: block;
margin-bottom: 30rpx;
color: #333;
}
.content-box {
background: #f9f9f9;
padding: 20rpx;
border-radius: 8rpx;
line-height: 1.6;
position: relative;
}
.editable {
padding-right: 120rpx;
}
.edit-btn {
position: absolute;
right: 20rpx;
top: 20rpx;
color: #1890ff;
}
/* 评分区域 */
.rating-section,
.category-section {
background: white;
border-radius: 12rpx;
padding: 25rpx;
margin-bottom: 30rpx;
}
.radio-item {
margin-right: 40rpx;
display: inline-block;
}
/* 标签区域 */
.tag-section {
background: white;
border-radius: 12rpx;
padding: 25rpx;
margin-bottom: 30rpx;
}
.tag-container {
display: flex;
flex-wrap: wrap;
gap: 20rpx;
}
.tag {
width: 236rpx;
padding: 16rpx 34rpx;
border-radius: 8rpx;
opacity: 1;
box-sizing: border-box;
border: 2rpx solid #e8ecf0;
background: #f7f8fa;
color: #292d33;
font-size: 28rpx;
line-height: 28rpx;
text-align: center;
}
.tag.selected {
background: #347bff1a;
color: #347bff;
border: 2rpx solid #347bff;
}
/* 确认按钮 */
.confirm-btn {
position:fixed;
bottom: env(safe-area-inset-bottom);
width: calc(100vw - 64rpx);
background: #347BFF;
color: #fff;
margin: 20rpx 32rpx;
border-radius: 12rpx;
height: 80rpx;
line-height: 80rpx;
}
.popup-warp {
position: fixed;
inset:0;
width:100vw;
height:100vh;
background: rgba(40, 40, 41, .5);
.popup-box {
margin: 400rpx auto;
width: 622rpx;
height: 620rpx;
border-radius: 20rpx;
opacity: 1;
border: 2rpx solid #979797;
background: #ffffff;
.popup-title {
text-align: center;
color: #292d33;
font-size: 32rpx;
margin: 50rpx auto;
}
.popup-textarea {
width: 526rpx;
height: 420rpx;
padding: 20rpx;
box-sizing: border-box;
border-radius: 12rpx;
opacity: 1;
border: 2rpx solid #eff0f2;
background: #f4f5f7;
margin: 0 auto;
}
.popup-footer {
margin-top: 40rpx;
height: 100rpx;
width: 100%;
border-radius: 0 0 20rpx 20rpx;
opacity: 1;
border-top: 2rpx solid #f2f2f2;
background: #ffffff;
display:flex;
.btn {
flex: 1;
line-height: 100rpx;
font-size: 30rpx;
text-align:center;
&.btn-left {
color: #292d33;
}
&.btn-right {
color: #347BFF;
}
}
}
}
}
\ No newline at end of file \ No newline at end of file
<navigation-bar class="navigation-header" bindnavbarReady="navbarReady" showBack="{{ true }}" bindback="back"
navStyle="{{navStyle}}">
<view class="navigation-title">
<view class="navigation-title-text text-hide">话术确认</view>
</view>
</navigation-bar>
<view class="bg-box"></view>
<view class="container" style="margin-top: {{navBarHeight}}px; height: calc( 100vh - {{navBarHeight}}px - 86px )">
<!-- 基本信息区域 -->
<view class="info-card">
<view class="card-title">话术信息</view>
<view class="info-row" wx:for="{{list}}" :wx:key="index">
<text class="label">{{item.label}}</text>
<view class="value">{{detail[item.value]}}
<text wx:if="{{item.value == 'polishContent'}}" bindtap="handleEdit">编辑</text>
</view>
</view>
</view>
<view class="info-card">
<view class="card-title">是否优秀话术</view>
<view class="info-row">
<text class="label">是否优秀</text>
<view class="value">
<van-radio-group custom-class="radio-box" value="{{ detail.excellentFlag }}" bind:change="onChange">
<van-radio name="{{1}}">优秀话术</van-radio>
<van-radio name="{{0}}">非优秀话术</van-radio>
</van-radio-group>
</view>
</view>
<block wx:if="{{detail.excellentFlag}}">
<view class="info-row">
<text class="label">分类</text>
<view class="value" bindtap="toggleClass">
<view class="picker">
<view>{{detail.className}}</view>
<view class="arrow"></view>
</view>
</view>
</view>
<view class="info-row">
<text class="label">优秀标签</text>
<view class="value">
<view class="tag-container">
<block wx:for="{{tags}}" wx:key="id">
<view class="tag {{detail.labelCode ==item.labelCode ? 'selected' : ''}}" bindtap="toggleTag" data-code="{{item.labelCode}}">
{{item.labelName}}
</view>
</block>
</view>
</view>
</view>
</block>
</view>
</view>
<!-- 确认按钮 -->
<button class="confirm-btn" bindtap="handleConfirm">确认</button>
<van-popup show="{{ showPicker }}"
position="bottom"
custom-style="height: 40%;"
bind:close="onClose">
<van-picker bind:cancel="pickerCancel" bind:confirm="pickerConfirm" show-toolbar="{{true}}" bindchange="bindPickerChange" default-index="{{ defaultIndex }}" value="{{index}}" columns="{{classArray}}"/>
</van-popup>
<view class="popup-warp" wx:if="{{showPopup}}">
<view class="popup-box">
<view class="popup-title">润色文本</view>
<textarea class="popup-textarea" bindinput="textareaInput" value="{{detail.polishContent}}"></textarea>
<view class="popup-footer">
<view class="btn-left btn" bindtap="handleCancel">取消</view>
<view class="btn-right btn" bindtap="editConfirm">确定</view>
</view>
</view>
</view>
\ No newline at end of file \ No newline at end of file
// packageEquity/pages/extract/extract/extract.js
Page({
/** import aiApi from "../../../aiApi";
* 页面的初始数据 Page({
*/
data: { data: {
navBarHeight: 100,
navStyle: 'background-color: transparent;box-shadow:none',
barList: [
{
label: '全部',
checkStatus: -1
},
{
label: '待确认',
checkStatus: 0,
type: 2,
show: true,
style:
'border:2rpx solod #3582ee80;background-color:#fff5e6;color: #FF9D0A'
},
{
label: '待核验',
checkStatus: 1,
show: true,
style:
'border:2rpx solod #3582ee80;background-color:#fff5e6;color: #FF9D0A'
},
{
label: '已入库',
checkStatus: 2,
show: true,
style:
'border:2rpx solod #3582ee80;background-color:#EAF9F1;color: #35C376'
},
{
label: '已驳回',
checkStatus: 3,
allStatus: [3,4],
status: 4,
show: true,
style:
'border:2rpx solod #3582ee80;background-color:#fdece9;color: #F24724'
}
],
businessTypeList: [
{ label: '延保', type: 0 },
{ label: '精品', type: 1 }
],
activeTab: -1,
businessType: 0,
metaList: [
{
label: "话术来源",
value: "staffName"
},
{
label: '萃取时间',
value: 'scriptTime'
},
{
label: '分类',
value: 'className',
type: 'ClassName'
},
{
label: '优秀标签',
value: 'labelName',
type: 'LabelName'
},
{
label: '提交人',
value: 'updatedBy',
type: 'UpdatedBy'
},
{
label: '提交时间',
value: 'updatedTime',
type: 'UpdatedTime'
}
],
pageNum:1,
pageSize:10,
// 实际开发中这里应该是从接口获取的数据
verificationData: {
status: 'pending' // pending/approved/rejected
// 其他字段...
}
},
matchStatus(checkStatus) {
const barItem = this.data.barList.find(
item => item.checkStatus === checkStatus || item.allStatus?.includes(checkStatus)
)
return barItem || {}
},
back() {
wx.$router.back()
}, },
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) { onLoad(options) {
if(options.type) {
this.showCount(options)
return
}
wx.$router.getData((route)=>{
this.showCount(route)
})
}, },
showCount(route) {
/** const {type} = route.params || route;
* 生命周期函数--监听页面初次渲染完成 const isLink = route.params?false:true
*/ const barList = this.data.barList.filter(i=>i.type != type)
onReady() { barList.forEach(bar=>{
if(bar.status) {
bar.checkStatus = bar.status
}
})
this.setData({barList,type,isLink},()=>{
this.initMethod()
})
}, },
initMethod() {
/** this.getExtractCount();
* 生命周期函数--监听页面显示 this.search();
*/
onShow() {
}, },
search() {
/** this.setData({pageNum:1},()=>{
* 生命周期函数--监听页面隐藏 this.loadData()
*/ })
onHide() {
}, },
loadData() {
/** const {businessType,type,activeTab,pageNum,pageSize,barList} = this.data
* 生命周期函数--监听页面卸载 const checkStatusList = barList.filter(i=>{
*/ return i.checkStatus>=0
onUnload() { }).reduce((prev,cur)=>{
let res = prev.concat(cur.allStatus||cur.checkStatus)
return res
},[])
const params = {
businessType,
type,
pageNum,
pageSize,
checkStatusList:activeTab == -1?checkStatusList:[activeTab]
}
if(activeTab == 3) {
params.checkStatusList = [3,4]
}
aiApi.extractPage(params).then(res=>{
const resList = res.data.list ||[]
this.updateListWithStatus(resList,res.data.total)
})
}, },
onBottomRefresh() {
/** let {
* 页面相关事件处理函数--监听用户下拉动作 total,
*/ pageNum
onPullDownRefresh() { } = this.data
this.setData({ pageNum: ++pageNum })
if (this.data.list.length == total) return
this.loadData()
}, },
mergeStatus(list) {
/** const filterList = list.filter(item => item.checkStatus === 3 || item.checkStatus === 4);
* 页面上拉触底事件的处理函数 const totalCount = filterList.reduce((sum, item) => sum + item.count, 0);
*/ list.forEach(i=>{
onReachBottom() { if(i.checkStatus == 3 || i.checkStatus == 4) {
i.count = totalCount
}
})
return list
}, },
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
}
})
\ No newline at end of file \ No newline at end of file
getExtractCount() {
aiApi.getExtractCount({type:this.data.type}).then(res=>{
let resList = res.data ||[]
const mergeList = this.mergeStatus(resList)
const { barList } = this.data;
const list = barList.map((i) => {
i.count = 0
const v = mergeList.find((k) =>{
return k.checkStatus == i.checkStatus || i.allStatus?.includes(k.checkStatus)
});
return { ...i, ...v };
});
this.setData({ barList: list });
})
},
updateListWithStatus(list,total) {
const updatedList = list.map((item) => {
const barItem = this.matchStatus(item.checkStatus);
return {
triggered:false,
...item,
...barItem
}
})
this.setData({
total,
list: this.data.pageNum == 1?updatedList:[...this.data.list,...updatedList],
});
},
navbarReady(e) {
let navBarHeight = e.detail.height
this.setData({
navBarHeight
})
},
handleSure(e) {
const { item } = e.currentTarget.dataset;
const { type} = this.data
item.type = type
wx.$router.go("/packageEquity/pages/extract/confirm/confirm", {
item,
});
},
showModal(cb) {
wx.showModal({
title: '温馨提示',
content: '话术确认完成?',
showCancel: true,
confirmText: '确定',
confirmColor: '#347BFF',
success(res) {
if (res.confirm) {
cb()
}
}
})
},
handleVerificatio() {
this.showModal(() => {
const {list } = this.data
const ids = list.map(i=>i.id)
aiApi.extractSecondUpdate({ids}).then(res=>{
if(res.data) {
this.initMethod()
}
})
});
},
switchType(e) {
this.setData({
businessType: e.currentTarget.dataset.index,
});
this.search()
},
switchTab(e) {
this.setData({
activeTab: e.currentTarget.dataset.index,
});
this.search();
},
});
{ {
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
"usingComponents": {},
"navigationStyle": "custom"
}
Page {
overflow:hidden;
}
.bg-box {
position: fixed;
inset: 0;
z-index: -1;
width: 750rpx;
height: 400rpx;
background: linear-gradient(0deg, #e8f0fb00 0%, #dde8fb 100%);
}
.container {
padding: 20rpx;
background: #f7f8fa;
}
.stats-bar {
display: flex;
padding: 48rpx 20rpx;
margin-bottom: 20rpx;
border-radius: 24rpx;
opacity: 1;
background: #ffffff;
}
.stat-item {
display: flex;
flex-direction: column;
align-items: center;
flex: 1;
}
.lable {
color: #292d33;
font-size: 26rpx;
margin-bottom: 10rpx;
}
.percent {
color: #2c66f7;
font-size: 48rpx;
font-weight: bold;
font-family: "D DIN PRO";
.unit {
font-weight: 500;
font-size: 24rpx;
}
}
.filter-box {
display: flex;
align-items: center;
justify-content: center;
width: 440rpx;
margin: 0 auto;
padding: 4rpx;
box-sizing:border-box;
height: 64rpx;
line-height: 64rpx;
border-radius: 8rpx;
opacity: 1;
background: #f2f3f5;
.active {
color: #181a1f;
font-weight: 600;
width: 200rpx;
height: 56rpx;
line-height: 56rpx;
box-sizing: border-box;
border-radius: 6rpx;
opacity: 1;
background: #ffffff;
}
.filter-item {
flex: 1;
color: #5a5e66;
text-align: center;
font-size: 28rpx;
}
}
.filter-tabs {
display: flex;
margin-bottom: 20rpx;
}
.filter-tabs text {
flex: 1;
text-align: center;
padding-bottom: 30rpx;
height: 80rpx;
color: #5a5e66;
font-size: 28rpx;
}
.filter-tabs .active {
color: #347BFF;
border-bottom: 4rpx solid #347BFF;
}
.card {
border-radius: 16rpx;
background: #ffffff;
box-shadow: 0 4rpx 16rpx 0 #cdcdd180;
padding: 32rpx;
margin-bottom: 20rpx;
}
.card-header {
display: flex;
align-items: center;
margin-bottom: 20rpx;
.tag-icon {
width: 32rpx;
height: 32rpx;
margin-right: 12rpx;
}
}
.title {
font-size: 32rpx;
font-weight: bold;
}
.status {
margin-left: auto;
font-size: 28rpx;
padding: 6rpx 12rpx;
border-radius: 6rpx;
}
.meta-info {
display: flex;
justify-content: space-between;
flex-wrap: wrap;
color: #999;
font-size: 26rpx;
text {
width: 40%;
margin-bottom: 16rpx;
&:nth-child(2n) {
text-align: right;
width: 60%;
}
}
}
.content-section {
margin: 30rpx 0;
display: flex;
}
.section-title {
width: 128rpx;
margin-bottom: 15rpx;
color: #999ea8;
font-size: 24rpx;
.short-tag {
margin-top:6rpx;
width: 108rpx;
height: 36rpx;
line-height: 36rpx;
text-align:center;
border-radius: 4rpx;
opacity: 1;
border: 2rpx solid #e8ecf0;
background: #f3f4f5;
color: #999ea8;
font-size: 20rpx;
}
.excellent-tag {
margin-top:6rpx;
width: 96rpx;
height: 36rpx;
line-height: 36rpx;
text-align:center;
border-radius: 4rpx;
opacity: 1;
border: 2rpx solid #347bff80;
background: #347bff1a;
color: #347bff;
font-size: 22rpx;
}
}
.original-text{
color: #292d33;
font-size: 28rpx;
flex:1;
text {
color: #347BFF;
}
}
.action-buttons {
display: flex;
margin-top: 40rpx;
}
.btn {
flex: 1;
margin: 0 15rpx;
font-size: 32rpx;
}
.reject {
background-color: #FFF1F0;
color: #FF4D4F;
}
.approve {
background-color: #F6FFED;
color: #52C41A;
}
.btn-warp {
text-align: right;
border-top: 2rpx solid #f2f2f2;
padding-top: 20rpx;
.btn-box {
display: inline-block;
width: 140rpx;
height: 56rpx;
line-height: 56rpx;
border-radius: 32rpx;
opacity: 1;
font-size: 28rpx;
background: #347bff;
color: #fff;
}
}
.btn-verification {
height: 80rpx;
line-height: 80rpx;
color: #fff;
border-radius: 12rpx;
opacity: 1;
background: #347bff;
margin: 30rpx;
}
.nothing {
padding: var(--fontSize100);
text-align: center;
color: #999;
.no-data-img {
width: var(--fontSize160);
height: var(--fontSize160);
}
.list-nothing,
.list-not {
text-align: center;
font-size: var(--fontSize28);
color: #BEC1C7;
}
}
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/extract/extract/extract.wxss */
\ No newline at end of file \ No newline at end of file
<!--packageEquity/pages/extract/extract/extract.wxml-->
<text>packageEquity/pages/extract/extract/extract.wxml</text>
\ No newline at end of file \ No newline at end of file
<wxs src="filter.wxs" module="filter" />
<navigation-bar
class="navigation-header"
bindnavbarReady="navbarReady"
showBack="{{ !isLink }}"
bindback="back"
navStyle="{{ navStyle }}"
>
<view class="navigation-title">
<view class="navigation-title-text text-hide">{{type==1?'话术萃取':'话术核验'}}</view>
</view>
</navigation-bar>
<view class="bg-box"></view>
<view class="container" style="margin-top:{{ navBarHeight }}px; height:calc( 100vh - {{navBarHeight }}px )">
<!-- 顶部状态统计 -->
<view class="stats-bar">
<block wx:for="{{ barList }}">
<view class="stat-item" wx:if="{{ item.show }}">
<text class="label">{{ item.label }}</text>
<text class="percent">{{ item.count||0 }} <text class="unit">条</text></text>
</view>
</block>
</view>
<view class="filter-box">
<view
wx:for="{{ businessTypeList }}"
wx:key="*this"
class="filter-item {{ businessType === item.type ? 'active' : '' }}"
bindtap="switchType"
data-index="{{ item.type }}"
>{{ item.label }}</view>
</view>
<!-- 筛选标签 -->
<view class="filter-tabs">
<text wx:for="{{ barList }}" wx:key="*this" class="{{ activeTab == item.checkStatus ? 'active' : '' }}" bindtap="switchTab" data-index="{{ item.checkStatus }}">
{{ item.label }}
</text>
</view>
<!-- 话术卡片 -->
<scroll-view
style="height: calc(100% - var(--fontSize{{ type == 2 && activeTab == 1 && list.length?600:500 }}));"
scroll-y
enable-back-to-top
refresher-enabled="{{ true }}"
bindrefresherrefresh="search"
bindscrolltolower="onBottomRefresh"
class="list"
refresher-triggered="{{ triggered }}"
>
<block wx:if="{{ list.length }}">
<view class="card" wx:for="{{ list }}">
<view class="card-header">
<gl-image webp class="tag-icon" src="/aiCheck/tag.png"></gl-image>
<text class="title"> {{item.sceneLabelName}}</text>
<text class="status" style="{{ item.style }}">{{ item.label }}</text>
</view>
<view class="meta-info">
<block wx:for="{{ metaList }}" wx:for-item="i" wx:key="i">
<text wx:if="{{ !filter.showFunctions['show' + i.type]||(filter.showFunctions['show' + i.type] && filter.showFunctions['show' + i.type](item)) }}">{{ i.label }}:{{ item[i.value] }}</text>
</block>
</view>
<!-- 原文对照区域 -->
<view class="content-section">
<view class="section-title">
<view>原文</view>
<view class="excellent-tag" wx:if="{{ item.excellentFlag === 1 }}">优秀话术</view>
<view class="short-tag" wx:if="{{ item.excellentFlag === 0 }}">非优秀话术</view>
</view>
<view class="original-text">{{item.sourceContent}}</view>
</view>
<view class="content-section">
<view class="section-title">润色文本</view>
<view class="original-text">{{item.polishContent}}</view>
</view>
<view class="btn-warp" wx:if="{{ item.checkStatus===0 && type != 2 }}">
<button class="btn-box" bindtap="handleSure" data-item="{{ item }}">去确认</button>
</view>
<view class="btn-warp" wx:if="{{ item.checkStatus===1 && type == 2 }}">
<button class="btn-box" bindtap="handleSure" data-item="{{ item }}">去核验</button>
</view>
</view>
</block>
<view wx:else class="nothing">
<image class="no-data-img" src="/packageEquity/images/noData.png" />
<view class="list-not">暂无数据</view>
</view>
</scroll-view>
<button wx:if="{{ type == 2 && activeTab == 1 && list.length }}" class="btn-verification" bindtap="handleVerificatio">批量核验</button>
</view>
\ No newline at end of file \ No newline at end of file
// filter.wxs
var showFunctions = {
showLabelName: function(item) {
return item.checkStatus != 3 && item.checkStatus != 0 && item.checkStatus != 4
},
showUpdatedBy: function(item) {
return item.checkStatus == 2 || item.checkStatus == 3 || item.checkStatus == 4
},
showUpdatedTime: function(item) {
return item.checkStatus == 2 || item.checkStatus == 3 || item.checkStatus == 4
},
showClassName: function(item) {
return item.checkStatus != 3 && item.checkStatus != 0 && item.checkStatus != 4
}
// 其他判断函数...
}
module.exports = {
showFunctions: showFunctions
}
\ No newline at end of file \ No newline at end of file
// packageEquity/pages/extract/success/success.js
let timer = null
Page({
/**
* 页面的初始数据
*/
data: {
navStyle: "background-color: transparent;box-shadow:none",
second: 3,
},
// 头部返回上一级
back() {
wx.$router.back()
},
toList() {
wx.$router.back((page)=>{
page.initMethod()
},2)
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
timer = setInterval(()=>{
let {second} = this.data
console.log(555)
if(second == 0) {
this.toList()
clearInterval(timer)
}
this.setData({
second:--second
})
},1000)
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {
clearInterval(timer)
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
}
})
\ No newline at end of file \ No newline at end of file
{
"usingComponents": {},
"navigationStyle": "custom"
}
\ No newline at end of file \ No newline at end of file
/* integration/pages/point/success/success.wxss */
page {
background: #ffffff;
}
.bg-box {
position: fixed;
inset: 0;
z-index: -1;
width: 750rpx;
height: 300rpx;
background: linear-gradient(0deg, #e8f0fb00 0%, #dde8fb 100%);
}
.container {
display: flex;
flex-direction: column;
align-items: center;
margin-top: 200rpx;
}
.icon {
width: 400rpx;
height: 400rpx;
margin-top: 64rpx;
}
.max_text {
font-weight: 600;
font-size: 40rpx;
color: #292D33;
margin-top: 16rpx;
margin-bottom: 24rpx;
}
.tip_text {
font-weight: 400;
font-size: 28rpx;
color: #7A8299;
}
.btn_group {
margin-top: 128rpx;
.btn_left {
width: 434rpx;
height: 80rpx;
line-height: 80rpx;
border-radius: 12rpx;
opacity: 1;
border: 2rpx solid #dee0e3;
background: #ffffff;
color: #292d33;
font-size: 32rpx;
}
}
.flex_cc {
display: flex;
align-items: center;
justify-content: center;
}
\ No newline at end of file \ No newline at end of file
<navigation-bar class="navigation-header" bindnavbarReady="navbarReady" showBack="{{ true }}" bindback="back" navStyle="{{navStyle}}">
<view class="navigation-title">
<view class="navigation-title-text text-hide">确认完成</view>
</view>
</navigation-bar>
<view class="bg-box"></view>
<view class="container">
<gl-image mode="widthFix" class="icon" src="/bankAccount/success_icon_1.png" />
<view class="max_text">你的话术已确认完成!</view>
<view class="tip_text">{{second}}秒后自动跳回话术萃取列表页</view>
<view class="btn_group flex_cc">
<view class="btn_left flex_cc" bind:tap="toList">我知道了</view>
</view>
</view>
\ No newline at end of file \ No newline at end of file
...@@ -382,7 +382,7 @@ Component({ ...@@ -382,7 +382,7 @@ Component({
['form.staffRangeList']: storeRangeList ['form.staffRangeList']: storeRangeList
}) })
// 超管获取所有质检门店/员工 // 超管获取所有质检门店/员工
if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5) { if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) {
this.getStoreList() this.getStoreList()
} }
}, },
......
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
</view> </view>
</view> </view>
<!-- 超管选择4s店 --> <!-- 超管选择4s店 -->
<view class="box" wx:if="{{userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5}}"> <view class="box" wx:if="{{userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6}}">
<view class="title"> <view class="title">
<view class="title-left"> <view class="title-left">
门店 门店
...@@ -87,7 +87,7 @@ ...@@ -87,7 +87,7 @@
</view> </view>
</view> </view>
<!-- 超管选择员工 --> <!-- 超管选择员工 -->
<view class="box" wx:if="{{userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5}}"> <view class="box" wx:if="{{userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 || userInfo.loginRole == 6}}">
<view class="title"> <view class="title">
<view class="title-left"> <view class="title-left">
员工 员工
......
...@@ -14,7 +14,9 @@ Component({ ...@@ -14,7 +14,9 @@ Component({
}, },
isShowDefeatBtn: { isShowDefeatBtn: {
type: Boolean type: Boolean
} },
hideScore: Boolean,
showReason:Boolean
}, },
/** /**
...@@ -22,7 +24,13 @@ Component({ ...@@ -22,7 +24,13 @@ Component({
*/ */
data: { data: {
contantsData, contantsData,
itemInfo: {} itemInfo: {},
violationStatusText: {
1: '疑似违规',
2: '过度承诺',
0: '未违规'
},
showViolationReason: false
}, },
/** /**
...@@ -66,7 +74,7 @@ Component({ ...@@ -66,7 +74,7 @@ Component({
events?.forEach((event, index) => { events?.forEach((event, index) => {
let regex = new RegExp('环节', 'g') let regex = new RegExp('环节', 'g')
event.stage = event.stage.replace(regex, '') event.stage = event.stage.replace(regex, '')
if(event.stage == '结束') event.stage = '促成交' if (event.stage == '结束') event.stage = '促成交'
event.width = this.getWidth(event, totalMinutes) event.width = this.getWidth(event, totalMinutes)
event.left = event.mergedOffset && Math.min(...event.mergedOffset) / totalMinutes * 90 + 2 event.left = event.mergedOffset && Math.min(...event.mergedOffset) / totalMinutes * 90 + 2
// 相邻质检环节是否存在重叠 // 相邻质检环节是否存在重叠
...@@ -77,7 +85,7 @@ Component({ ...@@ -77,7 +85,7 @@ Component({
} }
event.left = (events[index - 2]?.left + events[index - 2]?.width) > 2 ? (events[index - 2]?.left + events[index - 2]?.width) : 2 // 出现重叠将第二个质检环节向时间轴结束方向偏移 event.left = (events[index - 2]?.left + events[index - 2]?.width) > 2 ? (events[index - 2]?.left + events[index - 2]?.width) : 2 // 出现重叠将第二个质检环节向时间轴结束方向偏移
} }
if (event.left > (90 - event.width)) { // 处理会超出时间轴的质检环节 if (event.left > (90 - event.width)) { // 处理会超出时间轴的质检环节
event.left = (90 - event.width) event.left = (90 - event.width)
} }
...@@ -96,17 +104,15 @@ Component({ ...@@ -96,17 +104,15 @@ Component({
}) })
// 质检环节未知 // 质检环节未知
if (!events?.length) { if (!events?.length) {
events = [ events = [{
{ stage: '未知',
stage: '未知', style: `left: 47%; width: 50%;transform: translateX(-50%);bottom: var(--fontSize34);`,
style: `left: 47%; width: 50%;transform: translateX(-50%);bottom: var(--fontSize34);`, customerClass: 'red-tag',
customerClass: 'red-tag', mergedOffset: [0]
mergedOffset: [0] }]
}
]
} }
this.setData({ this.setData({
['itemInfo.receptionStaticInfoDetailDTOList'] : events, ['itemInfo.receptionStaticInfoDetailDTOList']: events,
['itemInfo.isNoShow']: false ['itemInfo.isNoShow']: false
}) })
}, },
...@@ -126,19 +132,37 @@ Component({ ...@@ -126,19 +132,37 @@ Component({
let diff = item.mergedOffset && Math.max(...item.mergedOffset) - Math.min(...item.mergedOffset) let diff = item.mergedOffset && Math.max(...item.mergedOffset) - Math.min(...item.mergedOffset)
let width = diff / totalMinutes * 90 let width = diff / totalMinutes * 90
let minWidth = item.stage?.length == 3 ? 19 : item.stage?.length == 4 ? 24 : 15 // 根据质检环节最小宽度 let minWidth = item.stage?.length == 3 ? 19 : item.stage?.length == 4 ? 24 : 15 // 根据质检环节最小宽度
let filterWidth = width > minWidth ? width : minWidth // 最小宽度 let filterWidth = width > minWidth ? width : minWidth // 最小宽度
return filterWidth return filterWidth
}, },
// 快速录战败单 // 快速录战败单
createDefeatOrder(e) { createDefeatOrder(e) {
let { item } = e.currentTarget.dataset let {
wx.$router.go('packageEquity.createDeafeatOrder', {customerName: item.customerName, customerPhone: item.phoneNumber}) item
} = e.currentTarget.dataset
wx.$router.go('packageEquity.createDeafeatOrder', {
customerName: item.customerName,
customerPhone: item.phoneNumber
})
}, },
// 点击质检环节 // 点击质检环节
handleTagsTap(e) { handleTagsTap(e) {
let { item } = e.currentTarget.dataset let {
item
} = e.currentTarget.dataset
this.triggerEvent('tagsTap', item) this.triggerEvent('tagsTap', item)
}, },
showViolationReasonFun(){
this.setData({
showViolationReason:true
})
},
closePopup(){
this.setData({
showViolationReason:false
})
}
}, },
attached() { attached() {
let _this = this let _this = this
...@@ -150,6 +174,6 @@ Component({ ...@@ -150,6 +174,6 @@ Component({
if (params.receptionStaticInfoODDetailDTOList) { // 攻防点 if (params.receptionStaticInfoODDetailDTOList) { // 攻防点
_this.getDefensePoints(params.receptionStaticInfoODDetailDTOList, totalMinutes) _this.getDefensePoints(params.receptionStaticInfoODDetailDTOList, totalMinutes)
} }
} }
}) })
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/index/components/record-item/recordItem.wxss */ /* packageEquity/pages/index/components/record-item/recordItem.wxss */
.content{ .content {
box-sizing: border-box; box-sizing: border-box;
width: 100%; width: 100%;
padding-bottom: var(--fontSize8); padding-bottom: var(--fontSize8);
background: #FFFFFF; background: #FFFFFF;
border-radius: var(--fontSize28); border-radius: var(--fontSize28);
&.border-red{ position: relative;
.violation-reason {
position: absolute;
top: var(--fontSize72);
right: var(--fontSize16);
width: var(--fontSize144);
height: var(--fontSize48);
line-height: var(--fontSize48);
border-radius: var(--fontSize8);
background: #f7f8fa;
color: #347bff;
font-size: var(--fontSize24);
font-weight: 600;
text-align: center;
}
&.border-red {
border: var(--fontSize2) solid #F56C50; border: var(--fontSize2) solid #F56C50;
} }
.record-header{
.record-header {
padding: var(--fontSize28) var(--fontSize16) var(--fontSize16) var(--fontSize32); padding: var(--fontSize28) var(--fontSize16) var(--fontSize16) var(--fontSize32);
.base-message{
.base-message {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
margin-bottom: var(--fontSize12); margin-bottom: var(--fontSize12);
view{
view {
display: flex; display: flex;
align-items: center; align-items: center;
} }
.record-name{
.record-name {
flex-shrink: 0; flex-shrink: 0;
margin-right: var(--fontSize12); margin-right: var(--fontSize12);
display: inline-block; display: inline-block;
max-width: var(--fontSize260); max-width: var(--fontSize260);
.value{
.value {
font-weight: 600; font-weight: 600;
font-size: var(--fontSize30); font-size: var(--fontSize30);
color: #292D33; color: #292D33;
} }
.order-name{
.order-name {
font-weight: 400; font-weight: 400;
font-size: var(--fontSize26); font-size: var(--fontSize26);
} }
} }
.record-phone{
.record-phone {
font-size: var(--fontSize26); font-size: var(--fontSize26);
color: #347BFF; color: #347BFF;
} }
.employee-name{
.employee-name {
max-width: var(--fontSize180); max-width: var(--fontSize180);
display: inline-block; display: inline-block;
margin-left: var(--fontSize10); margin-left: var(--fontSize10);
color: #347BFF; color: #347BFF;
font-size: var(--fontSize30); font-size: var(--fontSize30);
} }
.text-hide{
.text-hide {
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
} }
.violation-status {
width: fit-content;
height: var(--fontSize32);
border-radius: var(--fontSize16);
border: var(--fontSize2) solid #38d1c71a;
background: #edfaf9;
padding: 0 var(--fontSize8);
margin-left: var(--fontSize12);
color: #38d1c7;
font-size: var(--fontSize22);
font-weight: 700;
line-height: var(--fontSize32);
}
.violation-1 {
border-color: #7f80fe1a;
background: #f2f2fe;
color: #7f80fe;
}
.violation-2 {
border-color: #ff60531a;
background: #fff4f2;
color: #ff6053;
}
} }
.record-message{
.record-message {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
font-size: var(--fontSize22); font-size: var(--fontSize22);
.record-label{
.record-label {
padding: 0 var(--fontSize8); padding: 0 var(--fontSize8);
height: var(--fontSize32); height: var(--fontSize32);
border-radius: var(--fontSize4); border-radius: var(--fontSize4);
...@@ -64,18 +118,21 @@ ...@@ -64,18 +118,21 @@
margin-right: var(--fontSize12); margin-right: var(--fontSize12);
border: var(--fontSize2) solid #E8ECF0; border: var(--fontSize2) solid #E8ECF0;
} }
.record-label-error{
.record-label-error {
padding: 0 var(--fontSize8); padding: 0 var(--fontSize8);
height: var(--fontSize28); height: var(--fontSize28);
border: var(--fontSize2) solid #F56C50; border: var(--fontSize2) solid #F56C50;
border-radius: var(--fontSize4); border-radius: var(--fontSize4);
color: #F56C50; color: #F56C50;
} }
.record-amount{
.record-amount {
font-size: var(--fontSize32); font-size: var(--fontSize32);
color: #292D33; color: #292D33;
font-family: "numberBold"; font-family: "numberBold";
.line{
.line {
display: inline-block; display: inline-block;
width: var(--fontSize2); width: var(--fontSize2);
height: var(--fontSize14); height: var(--fontSize14);
...@@ -83,24 +140,29 @@ ...@@ -83,24 +140,29 @@
margin: 0 var(--fontSize8); margin: 0 var(--fontSize8);
} }
} }
.record-score{
.record-score {
font-size: var(--fontSize24); font-size: var(--fontSize24);
color: #F56C50; color: #F56C50;
.value{
.value {
font-size: var(--fontSize48); font-size: var(--fontSize48);
font-family: "numberBold"; font-family: "numberBold";
} }
.unit{
.unit {
font-weight: 600; font-weight: 600;
margin-left: var(--fontSize4); margin-left: var(--fontSize4);
} }
&.black{
&.black {
color: #292D33; color: #292D33;
} }
} }
} }
} }
.time-line-box{
.time-line-box {
box-sizing: border-box; box-sizing: border-box;
width: calc(100% - var(--fontSize16)); width: calc(100% - var(--fontSize16));
margin: 0 var(--fontSize8); margin: 0 var(--fontSize8);
...@@ -108,16 +170,19 @@ ...@@ -108,16 +170,19 @@
background: #FAFAFA; background: #FAFAFA;
border-radius: var(--fontSize24); border-radius: var(--fontSize24);
padding: var(--fontSize20); padding: var(--fontSize20);
.time-line{
.time-line {
height: var(--fontSize90); height: var(--fontSize90);
position: relative; position: relative;
.line-status{
.line-status {
width: 100%; width: 100%;
height: var(--fontSize2); height: var(--fontSize2);
background: #D1DBE7; background: #D1DBE7;
position: absolute; position: absolute;
bottom: var(--fontSize32); bottom: var(--fontSize32);
.circular{
.circular {
position: absolute; position: absolute;
top: calc(-1 * var(--fontSize6)); top: calc(-1 * var(--fontSize6));
width: var(--fontSize12); width: var(--fontSize12);
...@@ -125,13 +190,16 @@ ...@@ -125,13 +190,16 @@
border-radius: 50%; border-radius: 50%;
background: #D1DBE7; background: #D1DBE7;
} }
.circular-left{
.circular-left {
left: 0; left: 0;
} }
.circular-right{
.circular-right {
right: var(--fontSize40); right: var(--fontSize40);
} }
.reception-result{
.reception-result {
position: absolute; position: absolute;
right: 0; right: 0;
top: calc(-1 * var(--fontSize14)); top: calc(-1 * var(--fontSize14));
...@@ -141,27 +209,33 @@ ...@@ -141,27 +209,33 @@
text-align: center; text-align: center;
font-size: var(--fontSize20); font-size: var(--fontSize20);
color: #FFFFFF; color: #FFFFFF;
&.success{
&.success {
background: #35C376; background: #35C376;
&:before{
&:before {
content: '√'; content: '√';
} }
} }
&.defeat{
&.defeat {
background: #F24724; background: #F24724;
&:before{
&:before {
content: '×' content: '×'
} }
} }
} }
} }
.creat-order-btn{
.creat-order-btn {
width: var(--fontSize144); width: var(--fontSize144);
position: absolute; position: absolute;
right: 0; right: 0;
top: calc(-1 * var(--fontSize40)); top: calc(-1 * var(--fontSize40));
z-index: 100; z-index: 100;
} }
.bubble { .bubble {
position: relative; position: relative;
background: #00000099; background: #00000099;
...@@ -170,6 +244,7 @@ ...@@ -170,6 +244,7 @@
border-radius: var(--fontSize8); border-radius: var(--fontSize8);
text-align: center; text-align: center;
font-size: var(--fontSize24); font-size: var(--fontSize24);
.bubble-pointer { .bubble-pointer {
width: 0; width: 0;
height: 0; height: 0;
...@@ -181,34 +256,41 @@ ...@@ -181,34 +256,41 @@
bottom: calc(-1 * var(--fontSize16)); bottom: calc(-1 * var(--fontSize16));
transform: translateY(-50%); transform: translateY(-50%);
} }
.bubble-content { .bubble-content {
font-size: var(--fontSize24); font-size: var(--fontSize24);
text-align: center; text-align: center;
white-space: nowrap; white-space: nowrap;
} }
} }
.tags-box{
.tags-item{ .tags-box {
.tags-item {
text-align: center; text-align: center;
position: absolute; position: absolute;
display: flex; display: flex;
bottom: 0; bottom: 0;
.deep-colour-name{
.deep-colour-name {
flex-shrink: 0; flex-shrink: 0;
width: var(--fontSize6); width: var(--fontSize6);
height: var(--fontSize32); height: var(--fontSize32);
background: #F56C50; background: #F56C50;
&.red-tag{
&.red-tag {
background: #F56C50; background: #F56C50;
} }
&.yellow-tag{
&.yellow-tag {
background: #FF9D0A; background: #FF9D0A;
} }
&.green-tag{
&.green-tag {
background: #35C376; background: #35C376;
} }
} }
.name{
.name {
flex-shrink: 0; flex-shrink: 0;
font-size: var(--fontSize24); font-size: var(--fontSize24);
text-align: center; text-align: center;
...@@ -220,19 +302,23 @@ ...@@ -220,19 +302,23 @@
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
&.red-tag{
&.red-tag {
background: #F247241f; background: #F247241f;
color: #F56C50; color: #F56C50;
} }
&.yellow-tag{
&.yellow-tag {
background: #FF9D0A2e; background: #FF9D0A2e;
color: #FF9D0A; color: #FF9D0A;
} }
&.green-tag{
&.green-tag {
background: #35C3762e; background: #35C3762e;
color: #35C376; color: #35C376;
} }
.score{
.score {
font-size: var(--fontSize20); font-size: var(--fontSize20);
font-weight: 400; font-weight: 400;
margin-left: var(--fontSize4); margin-left: var(--fontSize4);
...@@ -240,17 +326,20 @@ ...@@ -240,17 +326,20 @@
} }
} }
} }
.defense{
.defense {
text-align: center; text-align: center;
position: absolute; position: absolute;
bottom: var(--fontSize34); bottom: var(--fontSize34);
.defense-icon{
.defense-icon {
width: var(--fontSize30); width: var(--fontSize30);
height: var(--fontSize60); height: var(--fontSize60);
} }
} }
} }
.total-time{
.total-time {
width: 100%; width: 100%;
display: flex; display: flex;
align-items: center; align-items: center;
...@@ -258,7 +347,8 @@ ...@@ -258,7 +347,8 @@
position: relative; position: relative;
color: #757980; color: #757980;
margin-top: var(--fontSize10); margin-top: var(--fontSize10);
.line{
.line {
width: 100%; width: 100%;
height: var(--fontSize2); height: var(--fontSize2);
background: #D1DBE74D; background: #D1DBE74D;
...@@ -267,18 +357,58 @@ ...@@ -267,18 +357,58 @@
top: 50%; top: 50%;
transform: translateY(-50%); transform: translateY(-50%);
} }
.time-bt{
.time-bt {
background: #FAFAFA; background: #FAFAFA;
border-radius: var(--fontSize28); border-radius: var(--fontSize28);
font-size: var(--fontSize20); font-size: var(--fontSize20);
z-index: 10; z-index: 10;
&.pad-4{
&.pad-4 {
padding: 0 var(--fontSize8); padding: 0 var(--fontSize8);
} }
&.pad-20{
&.pad-20 {
padding: 0 var(--fontSize40); padding: 0 var(--fontSize40);
} }
} }
} }
} }
}
.violation-reason-popup {
width: 622rpx;
height: 754rpx;
border-radius: 20rpx;
display: flex;
flex-direction: column;
.violation-reason-title {
font-size: 32rpx;
font-weight: 500;
line-height: 48rpx;
text-align: center;
padding: 48rpx 0 28rpx;
}
.violation-reason-content {
margin: 0 48rpx;
overflow-y: auto;
height: 472rpx;
word-break: break-all;
font-size: 28rpx;
line-height: 39.2rpx;
color: rgba(41, 45, 51, 1);
}
.violation-reason-btn {
margin-top: auto;
height: 100rpx;
line-height: 100rpx;
text-align: center;
font-size: 32rpx;
font-weight: 500;
color: rgba(52, 123, 255, 1);
border-top: 2rpx solid #ebedf0;
}
} }
\ No newline at end of file \ No newline at end of file
<!--packageEquity/pages/index/components/record-item/recordItem.wxml--> <!--packageEquity/pages/index/components/record-item/recordItem.wxml-->
<wxs src="../../../../index.wxs" module="filter"/> <wxs src="../../../../index.wxs" module="filter" />
<view class="content"> <view class="content">
<block wx:if="{{hideScore && showReason && itemInfo.violationReason}}">
<view class="violation-reason" catchtap="showViolationReasonFun">处理意见</view>
</block>
<view class="record-header"> <view class="record-header">
<view class="base-message"> <view class="base-message">
<view> <view>
...@@ -10,7 +13,14 @@ ...@@ -10,7 +13,14 @@
</view> </view>
<text class="record-phone" data-phone="{{itemInfo.phoneNumber}}">{{filter.desensitizePhoneNumber(itemInfo.phoneNumber)}}</text> <text class="record-phone" data-phone="{{itemInfo.phoneNumber}}">{{filter.desensitizePhoneNumber(itemInfo.phoneNumber)}}</text>
</view> </view>
<view wx:if="{{itemInfo.employeeName && showEmployeeName}}" catchtap="phoneCall" data-phone="{{itemInfo.employeePhone}}" class="employee-name text-hide">{{itemInfo.employeeName}}</view> <view>
<view wx:if="{{itemInfo.employeeName && showEmployeeName }}" catchtap="phoneCall" data-phone="{{itemInfo.employeePhone}}" class="employee-name text-hide">{{itemInfo.employeeName}}</view>
<block wx:if="{{hideScore && itemInfo.violationStatus != null}}">
<view class="violation-status violation-{{itemInfo.violationStatus}}">
{{violationStatusText[itemInfo.violationStatus]}}
</view>
</block>
</view>
</view> </view>
<view class="record-message"> <view class="record-message">
<view> <view>
...@@ -18,7 +28,7 @@ ...@@ -18,7 +28,7 @@
<text class="record-label" wx:if="{{itemInfo.tag}}">{{itemInfo.tag}}</text> <text class="record-label" wx:if="{{itemInfo.tag}}">{{itemInfo.tag}}</text>
<text class="record-label-error" wx:if="{{itemInfo.qualityCheckScore <= 20 && itemInfo.qualityCheckScore !== null && itemInfo.qualityCheckScore !== undefined}}">疑似虚假接待</text> <text class="record-label-error" wx:if="{{itemInfo.qualityCheckScore <= 20 && itemInfo.qualityCheckScore !== null && itemInfo.qualityCheckScore !== undefined}}">疑似虚假接待</text>
</view> </view>
<view> <view wx:if="{{!hideScore}}">
<text class="record-amount" wx:if="{{itemInfo.orderStatus == 1 && itemInfo.orderAmount}}"> <text class="record-amount" wx:if="{{itemInfo.orderStatus == 1 && itemInfo.orderAmount}}">
<text>¥{{filter.convertCentsToYuan(itemInfo.orderAmount)}}</text> <text>¥{{filter.convertCentsToYuan(itemInfo.orderAmount)}}</text>
<text class="line"></text> <text class="line"></text>
...@@ -48,27 +58,25 @@ ...@@ -48,27 +58,25 @@
</view> </view>
</view> </view>
<!-- 质检环节 --> <!-- 质检环节 -->
<view class="tags-box" hidden="{{itemInfo.isNoShow}}"> <block wx:if="{{!hideScore}}">
<block wx:key="index" wx:for="{{itemInfo.receptionStaticInfoDetailDTOList}}" <view class="tags-box" hidden="{{itemInfo.isNoShow}}">
wx:for-item="item"> <block wx:key="index" wx:for="{{itemInfo.receptionStaticInfoDetailDTOList}}" wx:for-item="item">
<view class="tags-item" <view class="tags-item" catchtap="handleTagsTap" data-item="{{item}}" style="{{item.style}}">
catchtap="handleTagsTap" <view class="deep-colour-name {{item.customerClass}}"></view>
data-item="{{item}}" <view data-index="{{index}}" data-item="{{item}}" class="name {{item.customerClass}}">
style="{{item.style}}"> {{item.stage}}<text class="score" wx:if="{{item.totalGetScore}}">{{item.totalGetScore}}</text>
<view class="deep-colour-name {{item.customerClass}}"></view> </view>
<view data-index="{{index}}" data-item="{{item}}" class="name {{item.customerClass}}">
{{item.stage}}<text class="score" wx:if="{{item.totalGetScore}}">{{item.totalGetScore}}</text>
</view> </view>
</view> </block>
</block> </view>
</view> </block>
<!-- 攻防点 --> <!-- 攻防点 -->
<block wx:for="{{itemInfo.receptionStaticInfoODDetailDTOList}}" wx:key="index"> <block wx:for="{{itemInfo.receptionStaticInfoODDetailDTOList}}" wx:key="index">
<view class="defense" style="{{item.style}}"> <view class="defense" style="{{item.style}}">
<gl-image webp class="defense-icon" src="/equity/defense-icon.png" /> <gl-image webp class="defense-icon" src="/equity/defense-icon.png" />
</view> </view>
</block> </block>
</view> </view>
<view class="total-time"> <view class="total-time">
<view class="line"></view> <view class="line"></view>
<view class="time-bt pad-4">{{itemInfo.startTimeStr}}</view> <view class="time-bt pad-4">{{itemInfo.startTimeStr}}</view>
...@@ -76,4 +84,13 @@ ...@@ -76,4 +84,13 @@
<view class="time-bt pad-4">{{itemInfo.endTimeStr}}</view> <view class="time-bt pad-4">{{itemInfo.endTimeStr}}</view>
</view> </view>
</view> </view>
</view>
\ No newline at end of file \ No newline at end of file
</view>
<van-popup model:show="{{showViolationReason}}" round bind:close="closePopup" close-on-click-overlay="{{false}}">
<view class="violation-reason-popup">
<view class="violation-reason-title">处理意见</view>
<view class="violation-reason-content">{{itemInfo.violationReason}}</view>
<view class="violation-reason-btn" bindtap="closePopup">知道了</view>
</view>
</van-popup>
\ No newline at end of file \ No newline at end of file
Component({
/**
* 组件的属性列表
*/
properties: {
tabList: Array,
defaultIndex: {
type: Number,
value: -1,
observer(n) {
this.setData({
tabIndex: n
})
}
}
},
/**
* 组件的初始数据
*/
data: {
tabIndex: 0
},
/**
* 组件的方法列表
*/
methods: {
change(e) {
const {
index,
item
} = e.currentTarget.dataset
this.setData({
tabIndex: index
})
this.triggerEvent('click', item)
}
}
})
\ No newline at end of file \ No newline at end of file
{
"component": true,
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/index/components/recordTab/recordTab.wxss */
.record-tab {
width: 100%;
height: var(--fontSize88);
display: flex;
box-sizing: border-box;
padding: 0 var(--fontSize40);
&-item {
flex: 1;
display: flex;
align-items: center;
justify-content: center;
height: 100%;
flex-shrink: 0;
color: #5a5e66;
font-size: var(--fontSize28);
font-weight: 700;
text-align: center;
position: relative;
transition: all .15s;
}
.active {
color: #347bff;
&::after {
position: absolute;
bottom: 0;
left: 50%;
transform: translateX(-50%);
content: '';
width: var(--fontSize64);
height: var(--fontSize4);
border-radius:var(--fontSize2) var(--fontSize2) 0 0;
background: #347bff;
}
}
}
\ No newline at end of file \ No newline at end of file
<view class="record-tab">
<block wx:for="{{tabList}}" wx:key="index">
<view class="record-tab-item {{tabIndex==index?'active':''}}" bindtap="change" data-index="{{index}}" data-item="{{item}}">
{{ item.text }}
</view>
</block>
</view>
\ No newline at end of file \ No newline at end of file
...@@ -2,6 +2,8 @@ ...@@ -2,6 +2,8 @@
"component": true, "component": true,
"usingComponents": { "usingComponents": {
"task-dialog": "/components/TaskDialog/TaskDialog", "task-dialog": "/components/TaskDialog/TaskDialog",
"record-item": "./components/record-item/recordItem" "record-item": "./components/record-item/recordItem",
"record-tab": "./components/recordTab/recordTab"
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -182,10 +182,11 @@ box-shadow: 0 var(--fontSize24) var(--fontSize24) -var(--fontSize12) #d3d9e680 ...@@ -182,10 +182,11 @@ box-shadow: 0 var(--fontSize24) var(--fontSize24) -var(--fontSize12) #d3d9e680
.menu_box { .menu_box {
display: grid; display: grid;
grid-template-columns: repeat(4, var(--fontSize100)); grid-template-columns: repeat(4, minmax(var(--fontSize100),1fr));
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
padding:var(--fontSize16) var(--fontSize38) 0; padding:var(--fontSize16) 0;
// padding:var(--fontSize16) var(--fontSize38) 0;
background: #FFFFFF; background: #FFFFFF;
border-radius:var(--fontSize16); border-radius:var(--fontSize16);
} }
...@@ -509,6 +510,13 @@ swiper{ ...@@ -509,6 +510,13 @@ swiper{
height: var(--fontSize36); height: var(--fontSize36);
} }
} }
.tab-box{
position: sticky;
top: var(--fontSize80);
left: 0;
z-index: 100;
background: #F7F8FA;
}
.list-box{ .list-box{
padding: 0 var(--fontSize8); padding: 0 var(--fontSize8);
.date-section { .date-section {
...@@ -520,7 +528,7 @@ swiper{ ...@@ -520,7 +528,7 @@ swiper{
align-items: center; align-items: center;
&.sticky-date-section{ &.sticky-date-section{
position: sticky; position: sticky;
top: var(--fontSize80); top: var(--fontSize168);
left: 0; left: 0;
z-index: 1000; z-index: 1000;
} }
...@@ -621,6 +629,7 @@ swiper{ ...@@ -621,6 +629,7 @@ swiper{
background: transparent; background: transparent;
} }
.empty-box{ .empty-box{
padding-top: var(--fontSize14);
display: flex; display: flex;
flex-flow: column; flex-flow: column;
justify-content: center; justify-content: center;
......
...@@ -113,6 +113,9 @@ ...@@ -113,6 +113,9 @@
<gl-image webp src="/equity/screen-icon.png" /> <gl-image webp src="/equity/screen-icon.png" />
</view> </view>
</view> </view>
<view class="tab-box">
<record-tab tabList="{{recordTabList}}" bindclick="recordTabClick"></record-tab>
</view>
<view class="list-box"> <view class="list-box">
<block wx:if="{{filter.isShowEmpty(listData)}}"> <block wx:if="{{filter.isShowEmpty(listData)}}">
<block wx:for="{{listData}}" wx:key="date" wx:if="{{item.receptionStaticInfoDTOList.length}}"> <block wx:for="{{listData}}" wx:key="date" wx:if="{{item.receptionStaticInfoDTOList.length}}">
...@@ -145,7 +148,7 @@ ...@@ -145,7 +148,7 @@
<view class="card-line"></view> <view class="card-line"></view>
</view> </view>
<view class="card-item"> <view class="card-item">
<record-item record="{{record}}" showEmployeeName="{{showEmployeeName}}" isShowDefeatBtn="{{isShowDefeatBtn}}"></record-item> <record-item record="{{record}}" showEmployeeName="{{showEmployeeName}}" isShowDefeatBtn="{{isShowDefeatBtn}}" hideScore></record-item>
</view> </view>
</view> </view>
</block> </block>
......
...@@ -9,7 +9,8 @@ Component({ ...@@ -9,7 +9,8 @@ Component({
*/ */
properties: { properties: {
recordData: Object, recordData: Object,
batchId: Number batchId: Number,
autoPlayConfig: Object
}, },
lifetimes: { lifetimes: {
ready() { ready() {
...@@ -37,7 +38,11 @@ Component({ ...@@ -37,7 +38,11 @@ Component({
*/ */
data: { data: {
progress: 0, progress: 0,
dialogueList: [] dialogueList: [],
violationStatusEnum: {
1: '疑似违规',
2: '过度承诺'
}
}, },
/** /**
...@@ -110,7 +115,7 @@ Component({ ...@@ -110,7 +115,7 @@ Component({
} = e.currentTarget.dataset, { } = e.currentTarget.dataset, {
activeId activeId
} = this.data } = this.data
if(!item) return if (!item) return
thisPage.seek(item.mergedOffset) thisPage.seek(item.mergedOffset)
this.setTopId(item, scroll) this.setTopId(item, scroll)
if (report) this.setTrackData('dialogue_time_point') if (report) this.setTrackData('dialogue_time_point')
...@@ -173,8 +178,11 @@ Component({ ...@@ -173,8 +178,11 @@ Component({
const { const {
data: dialogueList data: dialogueList
} = await api.post("dj.api.smartcarlife.recepiton.findConversationDetailByBatchId", params), { } = await api.post("dj.api.smartcarlife.recepiton.findConversationDetailByBatchId", params), {
autoPlayConfig,
recordData
} = this.data, {
totalDuration totalDuration
} = this.data.recordData, } = recordData,
userInfo = wx.$util.getUserInfo() || {} userInfo = wx.$util.getUserInfo() || {}
let defenceNum = 1, let defenceNum = 1,
defenceDetailList = [] defenceDetailList = []
...@@ -183,7 +191,6 @@ Component({ ...@@ -183,7 +191,6 @@ Component({
e.time = this.formatTime(e.mergedOffset) e.time = this.formatTime(e.mergedOffset)
e.text_id = `text_${e.id}` e.text_id = `text_${e.id}`
e.showCheckDetail = false e.showCheckDetail = false
if (e.defenceDetail) { if (e.defenceDetail) {
e.defenceTitle = `第${numberToChinese(defenceNum)}次攻防` e.defenceTitle = `第${numberToChinese(defenceNum)}次攻防`
defenceNum++ defenceNum++
...@@ -218,11 +225,12 @@ Component({ ...@@ -218,11 +225,12 @@ Component({
if (i.firstClassify == '结束') i.firstClassify = '促成交' if (i.firstClassify == '结束') i.firstClassify = '促成交'
}) })
} else { } else {
if (!userInfo.isSuper && userInfo.loginRole != 3) { if (!userInfo.isSuper && userInfo.loginRole != 3 && userInfo?.loginRole != 6) {
e.appealText = e.conversationDetailAppealId ? '已申诉' : '申诉' e.appealText = e.conversationDetailAppealId ? '已申诉' : '申诉'
e.appealClass = e.conversationDetailAppealId ? 'appeal-disabled' : '' e.appealClass = e.conversationDetailAppealId ? 'appeal-disabled' : ''
} }
} }
if (autoPlayConfig.auto && e.violationFlag == 1 && !this.autoPlayItem) this.autoPlayItem = e
}) })
this.setData({ this.setData({
flag: true, flag: true,
...@@ -261,6 +269,20 @@ Component({ ...@@ -261,6 +269,20 @@ Component({
// // 更新完成后清除加载提示 // // 更新完成后清除加载提示
wx.$util.hideLoading(); wx.$util.hideLoading();
this.relativeToViewport(); this.relativeToViewport();
let item = this.autoPlayItem
if (item) {
this.setTopId(item, true)
setTimeout(() => {
this.seekPlay({
currentTarget: {
dataset: {
item,
scroll: true
}
}
}, false)
}, 500)
}
}, },
highlightKeyword(highlightedText, keywords) { highlightKeyword(highlightedText, keywords) {
keywords.forEach(keyword => { keywords.forEach(keyword => {
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
display: flex; display: flex;
width: 100%; width: 100%;
background: #F0F6FF; background: #F0F6FF;
height: 80rpx; height: var(--fontSize80);
} }
.avatar-box { .avatar-box {
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
.time { .time {
width: var(--fontSize72); width: var(--fontSize72);
height: var(--fontSize28); height: var(--fontSize28);
line-height: 28rpx; line-height: var(--fontSize28);
background: #FFFFFF; background: #FFFFFF;
border: var(--fontSize2) solid #F0F6FF; border: var(--fontSize2) solid #F0F6FF;
border-radius: var(--fontSize28); border-radius: var(--fontSize28);
...@@ -79,6 +79,39 @@ ...@@ -79,6 +79,39 @@
line-height: var(--fontSize40); line-height: var(--fontSize40);
} }
.color-2,
.color-1 {
font-weight: 700 !important;
display: block;
.violation-text {
width: fit-content;
margin-top: var(--fontSize8);
font-size: var(--fontSize22);
height: var(--fontSize32);
line-height: var(--fontSize32);
border-radius: var(--fontSize16);
padding: 0 var(--fontSize8);
border: var(--fontSize2) solid;
}
}
.color-2 {
color: #FF6053;
.violation-text {
border-color: #ff60531a;
background: #fff4f2;
}
}
.color-1 {
color: #7F80FE;
.violation-text {
border-color: #7f80fe1a;
background: #f2f2fe;
}
}
.appeal-btn { .appeal-btn {
display: none; display: none;
margin-left: var(--fontSize46); margin-left: var(--fontSize46);
...@@ -90,7 +123,7 @@ ...@@ -90,7 +123,7 @@
line-height: var(--fontSize44); line-height: var(--fontSize44);
font-size: var(--fontSize24); font-size: var(--fontSize24);
box-sizing: border-box; box-sizing: border-box;
border: 2rpx solid #F56C50; border: var(--fontSize2) solid #F56C50;
} }
.appeal-disabled { .appeal-disabled {
...@@ -212,7 +245,7 @@ ...@@ -212,7 +245,7 @@
} }
.ai-btn { .ai-btn {
width: 536rpx; width: var(--fontSize536);
padding: var(--fontSize20) 0; padding: var(--fontSize20) 0;
display: flex; display: flex;
align-items: center; align-items: center;
...@@ -225,9 +258,9 @@ ...@@ -225,9 +258,9 @@
justify-content: center; justify-content: center;
.icon { .icon {
width: 32rpx; width: var(--fontSize32);
height: 32rpx; height: var(--fontSize32);
margin-right: 8rpx; margin-right: var(--fontSize8);
} }
} }
} }
...@@ -271,7 +304,7 @@ ...@@ -271,7 +304,7 @@
} }
.suggestions-box { .suggestions-box {
margin: 24rpx 0 0; margin: var(--fontSize24) 0 0;
} }
} }
} }
...@@ -339,7 +372,7 @@ ...@@ -339,7 +372,7 @@
height: calc(100% - var(--fontSize140)); height: calc(100% - var(--fontSize140));
transform: translateY(-50%); transform: translateY(-50%);
z-index: 8; z-index: 8;
width: 36rpx; width: var(--fontSize36);
right: -28rpx; right: -28rpx;
.axis-bar { .axis-bar {
...@@ -347,7 +380,7 @@ ...@@ -347,7 +380,7 @@
top: 0; top: 0;
left: 0; left: 0;
// right: -8rpx; // right: -8rpx;
width: 16rpx; width: var(--fontSize16);
height: 100%; height: 100%;
background-color: #E7E7E7; background-color: #E7E7E7;
border-radius: var(--fontSize8); border-radius: var(--fontSize8);
...@@ -368,7 +401,7 @@ ...@@ -368,7 +401,7 @@
left: 50%; left: 50%;
transform: translateX(-50%); transform: translateX(-50%);
z-index: -1; z-index: -1;
width: 8rpx; width: var(--fontSize8);
} }
.yellow-tag { .yellow-tag {
...@@ -408,15 +441,20 @@ ...@@ -408,15 +441,20 @@
left: 50%; left: 50%;
top: 0; top: 0;
transform: translate(-50%, -50%); transform: translate(-50%, -50%);
width: 20rpx; width: var(--fontSize20);
height: 20rpx; height: var(--fontSize20);
background: #FFFFFF; background: #FFFFFF;
border: var(--fontSize4) solid transparent; border: var(--fontSize4) solid transparent;
box-shadow: 0 var(--fontSize4) var(--fontSize16) 0 #7a7a7a33; box-shadow: 0 var(--fontSize4) var(--fontSize16) 0 #7a7a7a33;
border-radius: 100%; border-radius: 100%;
box-sizing: border-box; box-sizing: border-box;
} }
.default-axis-dot{
width: var(--fontSize36);
height: var(--fontSize36);
border: var(--fontSize6) solid #347BFF;
z-index: 9;
}
.axis-text { .axis-text {
position: absolute; position: absolute;
right: var(--fontSize20); right: var(--fontSize20);
...@@ -425,7 +463,7 @@ ...@@ -425,7 +463,7 @@
display: inline-block; display: inline-block;
height: var(--fontSize36); height: var(--fontSize36);
border-radius: var(--fontSize16); border-radius: var(--fontSize16);
padding: 0 22rpx 0 12rpx; padding: 0 var(--fontSize22) 0 var(--fontSize12);
transform: translateY(-50%); transform: translateY(-50%);
white-space: nowrap; white-space: nowrap;
/* 防止文本换行 */ /* 防止文本换行 */
...@@ -477,8 +515,8 @@ ...@@ -477,8 +515,8 @@
left: 50%; left: 50%;
transform: translate(-50%, -50%); transform: translate(-50%, -50%);
background-color: #fff; background-color: #fff;
width: 26rpx; width: var(--fontSize26);
height: 26rpx; height: var(--fontSize26);
} }
} }
...@@ -491,7 +529,7 @@ ...@@ -491,7 +529,7 @@
color: #FFFFFF !important; color: #FFFFFF !important;
background-color: #347BFF !important; background-color: #347BFF !important;
border-radius: var(--fontSize16) 0 0 var(--fontSize16); border-radius: var(--fontSize16) 0 0 var(--fontSize16);
right: 18rpx; right: var(--fontSize18);
z-index: 2; z-index: 2;
} }
...@@ -507,8 +545,8 @@ ...@@ -507,8 +545,8 @@
position: absolute; position: absolute;
top: 50%; top: 50%;
right: 100%; right: 100%;
width: 80rpx; width: var(--fontSize80);
height: 40rpx; height: var(--fontSize40);
transform: translateY(-50%); transform: translateY(-50%);
} }
} }
......
// packageEquity/pages/receptionDetail/components/violationPopup/violationPopup.js
import api from "~/utils/request/request.js";
Component({
/**
* 组件的属性列表
*/
properties: {
batchId:Number,
show: {
type: Boolean,
value: false,
observer(n) {
this.setData({
violationReason: '',
wghsStatus: 2
})
}
}
},
/**
* 组件的初始数据
*/
data: {
radioList: [{
text: '已违规',
value: 2
},
{
text: '未违规',
value: 0
},
],
violationReason: '',
wghsStatus: 2
},
/**
* 组件的方法列表
*/
methods: {
async confirm() {
if (this.submitStatus) return
try {
wx.$util.showLoading('提交中...')
this.submitStatus = true
const {
violationReason,
wghsStatus,
batchId
} = this.data, {
data,
code,
message
} = await api.post('dj.api.smartcarlife.recepiton.violationConfirmation', {
batchId,
wghsStatus,
violationReason
})
if (code == 0) {
if (data) {
this.submitStatus = false
wx.hideLoading()
wx.showToast({
title: '录音已确认完成',
mask: true
})
setTimeout(() => {
this.setData({
show: false
})
wx.$router.back(page => {
page.refreshListData && page.refreshListData()
})
}, 1500)
} else throw message
} else throw message
} catch (error) {
wx.hideLoading()
wx.$util.showToast(error)
this.submitStatus = false
}
},
bindKeyInput(e) {
let {
value
} = e.detail
this.setData({
violationReason: value
})
},
change(e) {
let {
value
} = e.currentTarget.dataset
this.setData({
wghsStatus: value
})
}
}
})
\ No newline at end of file \ No newline at end of file
{
"component": true,
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/receptionDetail/components/violationPopup/violationPopup.wxss */
.content {
.title {
color: #222222;
font-size: 28rpx;
margin: 32rpx 0 12rpx;
}
.radio-box {
height: 80rpx;
border-radius: 8rpx;
background: #f7f8fa;
display: flex;
align-items: center;
padding: 0 12rpx;
gap: 0 60rpx;
.radio {
display: flex;
align-items: center;
color: #292d33;
font-size: 28rpx;
transition: all .15s;
.arc {
width: 32rpx;
height: 32rpx;
border: 2rpx solid #d0d2d6;
box-sizing: border-box;
border-radius: 100%;
margin-right: 20rpx;
transition: all .15s;
}
}
.active {
color: #347bff;
.arc {
border: 11rpx solid #347bff;
}
}
}
.textarea {
height: 572rpx;
box-sizing: border-box;
padding: 24rpx;
border-radius: 12rpx;
background: #f4f5f7;
border: 2rpx solid #eff0f2;
}
}
\ No newline at end of file \ No newline at end of file
<!--tabWorkOrder/pages/mentorshipManage/components/businessSelectPopup/businessSelectPopup.wxml-->
<popup title="疑似违规确认" model:show="{{ show }}" bindconfirm="confirm" height="70vh" bindcancel="hidePopup">
<view class="content">
<view class="title">
请确认此录音是否违规
</view>
<view class="radio-box">
<block wx:for="{{radioList}}" wx:key="index">
<view class="radio {{wghsStatus == item.value ?'active':''}}" bindtap="change" data-value="{{item.value}}">
<view class="arc"></view>
{{item.text}}
</view>
</block>
</view>
<view class="title">请输入您的处理意见</view>
<view class="textarea">
<gl-textarea bindinput="bindKeyInput" maxlength="{{200}}" value="{{violationReason}}" placeholderColor="#3333334d" placeholder="请输入" color="#292d33" textStyle="font-size:28rpx;line-height:32rpx;" />
</view>
</view>
</popup>
\ No newline at end of file \ No newline at end of file
...@@ -157,9 +157,22 @@ Page({ ...@@ -157,9 +157,22 @@ Page({
this.track_businessParam = { this.track_businessParam = {
batchId: options.batchId batchId: options.batchId
} //埋点业务参数 } //埋点业务参数
let {
typeLists
} = this.data,
showViolationBtn = false,
autoPlayConfig = {}
if(options.hideScore && options.violationStatus == 1){
showViolationBtn = true
autoPlayConfig = {
auto:true
}
}
this.setData({ this.setData({
record: options record: options,
typeLists: options.hideScore ? typeLists.splice(0, 1) : typeLists,
showViolationBtn,
autoPlayConfig
}, () => { }, () => {
this.setAudio() this.setAudio()
}) })
...@@ -174,7 +187,7 @@ Page({ ...@@ -174,7 +187,7 @@ Page({
0: 'dialogue', 0: 'dialogue',
1: 'quality_inspection', 1: 'quality_inspection',
2: 'offense_and_defense' 2: 'offense_and_defense'
}[index]) } [index])
this.setData({ this.setData({
activeIndex: index activeIndex: index
}) })
...@@ -192,7 +205,18 @@ Page({ ...@@ -192,7 +205,18 @@ Page({
wx.$util.getViewInfo('.reception-wrap', ({ wx.$util.getViewInfo('.reception-wrap', ({
height height
}) => { }) => {
this.setData({ let {
showViolationBtn
} = this.data
if (showViolationBtn) {
wx.$util.getViewInfo('.violation-btn-box', ({
height: btnHeight
}) => {
this.setData({
receptionWrapHeight: `${(height + btnHeight) * 2}rpx`
})
})
} else this.setData({
receptionWrapHeight: `${height * 2}rpx` receptionWrapHeight: `${height * 2}rpx`
}) })
}) })
...@@ -212,7 +236,7 @@ Page({ ...@@ -212,7 +236,7 @@ Page({
1: '成交', 1: '成交',
2: '战败', 2: '战败',
3: '未知' 3: '未知'
}[record.orderStatus], { } [record.orderStatus], {
endTime, endTime,
totalDuration, totalDuration,
fileUrl, fileUrl,
...@@ -246,6 +270,11 @@ Page({ ...@@ -246,6 +270,11 @@ Page({
keepScreenOn keepScreenOn
}) })
}, },
violationPopupToggle() {
this.setData({
showViolationPopup: true
})
},
/** /**
* 生命周期函数--监听页面初次渲染完成 * 生命周期函数--监听页面初次渲染完成
*/ */
......
...@@ -3,7 +3,8 @@ ...@@ -3,7 +3,8 @@
"quality": "./components/quality/index", "quality": "./components/quality/index",
"attack":"./components/attack/index", "attack":"./components/attack/index",
"record-item": "../index/components/record-item/recordItem", "record-item": "../index/components/record-item/recordItem",
"dialogue":"./components/dialogue/dialogue" "dialogue":"./components/dialogue/dialogue",
"violation-popup":"./components/violationPopup/violationPopup"
}, },
"navigationStyle": "custom" "navigationStyle": "custom"
} }
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/receptionDetail/receptionDetail.wxss */ /* packageEquity/pages/receptionDetail/receptionDetail.wxss */
page { page {
background-color: #FAFAFA !important; background-color: #FAFAFA !important;
overflow:hidden; overflow: hidden;
} }
.navigation-title { .navigation-title {
...@@ -58,9 +58,10 @@ page { ...@@ -58,9 +58,10 @@ page {
color: #5A5E66; color: #5A5E66;
font-weight: 400; font-weight: 400;
text-align: center; text-align: center;
.avg{
font-size: var(--fontSize20); .avg {
font-family: 'numberNor'; font-size: var(--fontSize20);
font-family: 'numberNor';
} }
} }
...@@ -98,11 +99,27 @@ page { ...@@ -98,11 +99,27 @@ page {
font-weight: 400; font-weight: 400;
font-size: var(--fontSize26); font-size: var(--fontSize26);
color: #757980; color: #757980;
margin-left:var(--fontSize4); margin-left: var(--fontSize4);
} }
} }
} }
} }
.type-wrap{
.type-wrap {
padding: 0 var(--fontSize28); padding: 0 var(--fontSize28);
}
.violation-btn-box {
padding: 40rpx 64rpx;
.violation-btn {
color: #ffffff;
font-size: 32rpx;
font-weight: 500;
height: 88rpx;
border-radius: 12rpx;
background: #347bff;
line-height: 88rpx;
text-align: center;
}
} }
\ No newline at end of file \ No newline at end of file
...@@ -6,11 +6,15 @@ ...@@ -6,11 +6,15 @@
<view class="bg"></view> <view class="bg"></view>
<view class="reception-wrap" style="padding-top:{{ navBarHeight }}px;position: relative;"> <view class="reception-wrap" style="padding-top:{{ navBarHeight }}px;position: relative;">
<view class="reception-info" wx:if="{{record}}"> <view class="reception-info" wx:if="{{record}}">
<record-item record="{{record}}"></record-item> <record-item record="{{record}}" hideScore="{{record.hideScore}}" showReason="{{record.violationReason}}"></record-item>
</view> </view>
<view class="reception-nav"> <view class="reception-nav">
<view class="reception-types"> <view class="reception-types">
<view class="type {{activeIndex==index?'active':''}}" wx:for="{{typeLists}}" data-index="{{index}}" bind:tap="changeType">{{item}}<text class="avg" wx:if="{{activeIndex==index&&avgDefence!==''}}" wx:key="index">{{avgDefence}}分</text></view> <block wx:for="{{typeLists}}" wx:key="index">
<view class="type {{activeIndex==index?'active':''}}" data-index="{{index}}" bind:tap="changeType">{{item}}
<text class="avg" wx:if="{{activeIndex==index&&avgDefence!==''}}" >{{avgDefence}}分</text>
</view>
</block>
</view> </view>
<view class="reception-operate"> <view class="reception-operate">
<gl-image class="img share" webp src="/equity/share-icon.png" bind:tap="share" /> <gl-image class="img share" webp src="/equity/share-icon.png" bind:tap="share" />
...@@ -26,9 +30,16 @@ ...@@ -26,9 +30,16 @@
<view class="type-wrap" style="height:calc(100vh - {{receptionWrapHeight}})"> <view class="type-wrap" style="height:calc(100vh - {{receptionWrapHeight}})">
<block wx:if="{{receptionWrapHeight && activeIndex != -1}}"> <block wx:if="{{receptionWrapHeight && activeIndex != -1}}">
<view hidden="{{activeIndex ==1||activeIndex == 2}}" style="height:calc(100vh - {{receptionWrapHeight}})"> <view hidden="{{activeIndex ==1||activeIndex == 2}}" style="height:calc(100vh - {{receptionWrapHeight}})">
<dialogue id="dialogue" bindplay="play" bindpause="onPause" recordData="{{record}}" batchId="{{record.batchId}}"></dialogue> <dialogue id="dialogue" bindplay="play" bindpause="onPause" recordData="{{record}}" batchId="{{record.batchId}}" autoPlayConfig="{{autoPlayConfig}}"></dialogue>
</view> </view>
<quality id="quality" wx:if="{{activeIndex==1}}" batchId="{{record.batchId}}"></quality> <quality id="quality" wx:if="{{activeIndex==1}}" batchId="{{record.batchId}}"></quality>
<attack wx:elif="{{activeIndex==2}}" defenceResultFlag="{{record.defenceResultFlag}}" batchId="{{record.batchId}}"></attack> <attack wx:elif="{{activeIndex==2}}" defenceResultFlag="{{record.defenceResultFlag}}" batchId="{{record.batchId}}"></attack>
</block> </block>
</view>
\ No newline at end of file \ No newline at end of file
</view>
<block wx:if="{{showViolationBtn}}">
<view class="violation-btn-box">
<view class="violation-btn" bindtap="violationPopupToggle">去确认</view>
</view>
</block>
<violation-popup model:show="{{showViolationPopup}}" batchId="{{record.batchId}}"></violation-popup>
\ No newline at end of file \ No newline at end of file
...@@ -11,6 +11,7 @@ Page({ ...@@ -11,6 +11,7 @@ Page({
* 页面的初始数据 * 页面的初始数据
*/ */
data: { data: {
navBarTitle: '加载中...',
navBarHeight: 113.5, navBarHeight: 113.5,
show_reception_confirm: false, show_reception_confirm: false,
showReceptionRendering: false, showReceptionRendering: false,
...@@ -23,22 +24,52 @@ Page({ ...@@ -23,22 +24,52 @@ Page({
isShowDefeatBtn: true, isShowDefeatBtn: true,
loaded: false, loaded: false,
track_event_code: 'staff_reception_list', //埋点动作类型 track_event_code: 'staff_reception_list', //埋点动作类型
violationStatus: 1, //默认疑似违规
tabIndex: 0,
recordTabList: [{
text: '疑似违规',
value: 1
},
{
text: '未违规',
value: 0
},
{
text: '已违规',
value: 2
}
]
}, },
/** /**
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
*/ */
onLoad(options) { onLoad(options) {
if (options.hideScore) {
let {
recordTabList
} = this.data,
tabIndex = recordTabList.findIndex(e => e.value == options.tabValue),
violationStatus = 1
if(options.tabValue != null) violationStatus = options.tabValue
if(tabIndex == -1) tabIndex = 0
this.setData({
hideScore: true,
tabIndex,
violationStatus
})
}
let userInfo = wx.$util.getUserInfo() || {} let userInfo = wx.$util.getUserInfo() || {}
if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5) this.setData({ if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) this.setData({
showEmployeeName: true, showEmployeeName: true,
isShowDefeatBtn: false isShowDefeatBtn: false
}) })
// 超管获取所有质检门店/员工 // 超管获取所有质检门店/员工
this.setData({ this.setData({
nothing: false nothing: false,
navBarTitle: options.hideScore ? '违规录音处理' : (userInfo && (userInfo.isSuper || userInfo.loginRole == 3 || userInfo.loginRole == 5 || userInfo.loginRole == 6)) ? '接待记录' : (userInfo.default4SStoreInfo && userInfo.default4SStoreInfo.merchantName)
}) })
if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5) { if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) {
this.getStoreList() this.getStoreList()
} else { } else {
this.getReceptionList() this.getReceptionList()
...@@ -68,13 +99,15 @@ Page({ ...@@ -68,13 +99,15 @@ Page({
searchForm, searchForm,
isFilterDefeat, isFilterDefeat,
isFilterUpgrade, isFilterUpgrade,
storeRangeList storeRangeList,
violationStatus
} = this.data } = this.data
let userInfo = wx.$util.getUserInfo() || {}; let userInfo = wx.$util.getUserInfo() || {};
const now = new Date(); const now = new Date();
const threeMonthsAgo = new Date(now.getFullYear(), now.getMonth() - 3, now.getDate() + 1) const threeMonthsAgo = new Date(now.getFullYear(), now.getMonth() - 3, now.getDate() + 1)
if (!searchForm.orderResult?.length) searchForm.orderResult = (isFilterDefeat ? [2] : []).concat(isFilterUpgrade ? [1] : []) if (!searchForm.orderResult?.length) searchForm.orderResult = (isFilterDefeat ? [2] : []).concat(isFilterUpgrade ? [1] : [])
let obj = { let obj = {
violationStatus,
startDateTime: searchForm?.startDateTime || new Date(threeMonthsAgo).format('yyyy-MM-dd'), startDateTime: searchForm?.startDateTime || new Date(threeMonthsAgo).format('yyyy-MM-dd'),
endDateTime: searchForm?.endDateTime || now.format('yyyy-MM-dd'), endDateTime: searchForm?.endDateTime || now.format('yyyy-MM-dd'),
customerName: searchForm?.customerName || '', customerName: searchForm?.customerName || '',
...@@ -86,8 +119,8 @@ Page({ ...@@ -86,8 +119,8 @@ Page({
orderResult: searchForm?.orderResult, orderResult: searchForm?.orderResult,
merchantNo: !searchForm?.merchantNo?.length ? (userInfo?.isSuper ? storeRangeList.map(v => { merchantNo: !searchForm?.merchantNo?.length ? (userInfo?.isSuper ? storeRangeList.map(v => {
if (v.merchantNo) return v.merchantNo if (v.merchantNo) return v.merchantNo
}) : userInfo?.loginRole == 3 || userInfo.loginRole == 5 ? '' : [userInfo?.default4SStoreInfo?.merchantId]) : searchForm?.merchantNo, }) : userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6 ? '' : [userInfo?.default4SStoreInfo?.merchantId]) : searchForm?.merchantNo,
staffUuids: userInfo.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 ? searchForm?.staffUuids : [userInfo.uuid] staffUuids: userInfo.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6 ? searchForm?.staffUuids : [userInfo.uuid]
} }
return obj return obj
}, },
...@@ -294,9 +327,14 @@ Page({ ...@@ -294,9 +327,14 @@ Page({
}, },
goto(e) { goto(e) {
let { let {
hideScore
} = this.data, {
record record
} = e.currentTarget.dataset } = e.currentTarget.dataset
wx.$router.go('packageEquity.receptionDetail', record) wx.$router.go('packageEquity.receptionDetail', {
...record,
hideScore
})
wx.$track.setTrackData(0, 'reception_detail', { wx.$track.setTrackData(0, 'reception_detail', {
batchId: record.batchId batchId: record.batchId
}) })
...@@ -304,7 +342,21 @@ Page({ ...@@ -304,7 +342,21 @@ Page({
back() { back() {
wx.$router.back() wx.$router.back()
}, },
recordTabClick(e) {
let {
value
} = e.detail, {
violationStatus
} = this.data
if (value == violationStatus) return
this.setData({
listData: [],
nothing: false,
violationStatus: value
})
this.getReceptionList()
wx.$track.setTrackData(0, 'staff_reception_search', this.getParams())
},
/** /**
* 生命周期函数--监听页面初次渲染完成 * 生命周期函数--监听页面初次渲染完成
*/ */
......
{ {
"usingComponents": { "usingComponents": {
"reception-screen": "../index/components/receptionScreen/receptionScreen", "reception-screen": "../index/components/receptionScreen/receptionScreen",
"record-item": "../index/components/record-item/recordItem" "record-item": "../index/components/record-item/recordItem",
"record-tab": "../index/components/recordTab/recordTab"
}, },
"navigationStyle": "custom" "navigationStyle": "custom"
} }
\ No newline at end of file \ No newline at end of file
...@@ -47,6 +47,9 @@ ...@@ -47,6 +47,9 @@
height: var(--fontSize36); height: var(--fontSize36);
} }
} }
.tab-box{
background: #fff;
}
.list-box{ .list-box{
.box-content{ .box-content{
position: relative; position: relative;
...@@ -58,7 +61,7 @@ ...@@ -58,7 +61,7 @@
height: var(--fontSize72); height: var(--fontSize72);
line-height: var(--fontSize70); line-height: var(--fontSize70);
padding-left: var(--fontSize32); padding-left: var(--fontSize32);
background: #F7F8FA; background: #f7f8fa;
display: flex; display: flex;
align-items: center; align-items: center;
position: sticky; position: sticky;
......
...@@ -6,22 +6,28 @@ ...@@ -6,22 +6,28 @@
<block wx:else> <block wx:else>
<navigation-bar class="navigation-header" bindnavbarReady="navbarReady" showBack navStyle="{{'background-color: #FFFFFF;box-shadow:none;' }}" bindback="back"> <navigation-bar class="navigation-header" bindnavbarReady="navbarReady" showBack navStyle="{{'background-color: #FFFFFF;box-shadow:none;' }}" bindback="back">
<view class="navigation-title"> <view class="navigation-title">
<view class="navigation-title-text text-hide">{{(userInfo && (userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5)) ? '接待记录' : (userInfo.default4SStoreInfo && userInfo.default4SStoreInfo.merchantName)}}</view> <view class="navigation-title-text text-hide">{{navBarTitle}}</view>
</view> </view>
</navigation-bar> </navigation-bar>
</block> </block>
<view class="records-page" style="padding-top:{{ navBarHeight }}px;position: relative;"> <view class="records-page" style="padding-top:{{ navBarHeight }}px;position: relative;">
<view class="screen-box"> <view class="screen-box">
<view> <view>
<!-- <text class="title">接待记录</text> --> <!-- <text class="title">接待记录</text> -->
<text class="name text-hide">{{searchForm.merchantNames.length > 1 ? '部分门店' : searchForm.merchantNames.length ? filter.filterMerchantName(searchForm.merchantNames) : !userInfo.isSuper && userInfo.loginRole != 3 ? userInfo.default4SStoreInfo.merchantName : '全部门店'}}</text> <text class="name text-hide">{{searchForm.merchantNames.length > 1 ? '部分门店' : searchForm.merchantNames.length ? filter.filterMerchantName(searchForm.merchantNames) : !userInfo.isSuper && userInfo.loginRole != 3 && userInfo.loginRole != 6 ? userInfo.default4SStoreInfo.merchantName : '全部门店'}}</text>
</view> </view>
<view bindtap="showScreenPop"> <view bindtap="showScreenPop">
<text class="text">筛选</text> <text class="text">筛选</text>
<gl-image webp src="/equity/screen-icon.png" /> <gl-image webp src="/equity/screen-icon.png" />
</view> </view>
</view> </view>
<scroll-view scroll-y class="list-box" enable-back-to-top refresher-enabled="{{true}}" bindrefresherrefresh="refreshListData" bindscrolltolower="onBottomRefresh" style="height: calc(100% - var(--fontSize80));" scroll-top="{{scrollTop}}" refresher-threshold="104" refresher-triggered="{{triggered}}"> <block wx:if="{{hideScore}}">
<view class="tab-box">
<record-tab tabList="{{recordTabList}}" bindclick="recordTabClick" defaultIndex="{{tabIndex}}"></record-tab>
</view>
</block>
<scroll-view scroll-y class="list-box" enable-back-to-top refresher-enabled="{{true}}" bindrefresherrefresh="refreshListData" bindscrolltolower="onBottomRefresh" style="height: calc(100% - var(--fontSize168));" scroll-top="{{scrollTop}}" refresher-threshold="104" refresher-triggered="{{triggered}}">
<view class="box-content {{!filter.isShowEmpty(listData) ? 'empty-contant' : ''}}"> <view class="box-content {{!filter.isShowEmpty(listData) ? 'empty-contant' : ''}}">
<block wx:if="{{filter.isShowEmpty(listData)}}"> <block wx:if="{{filter.isShowEmpty(listData)}}">
<block wx:for="{{listData}}" wx:key="date" wx:if="{{item.receptionStaticInfoDTOList.length}}"> <block wx:for="{{listData}}" wx:key="date" wx:if="{{item.receptionStaticInfoDTOList.length}}">
...@@ -54,7 +60,7 @@ ...@@ -54,7 +60,7 @@
<view class="card-line"></view> <view class="card-line"></view>
</view> </view>
<view class="card-item" wx:key="subIndex"> <view class="card-item" wx:key="subIndex">
<record-item record="{{record}}" showEmployeeName="{{showEmployeeName}}" isShowDefeatBtn="{{isShowDefeatBtn}}"></record-item> <record-item record="{{record}}" showEmployeeName="{{showEmployeeName}}" isShowDefeatBtn="{{isShowDefeatBtn}}" hideScore="{{hideScore}}"></record-item>
</view> </view>
</view> </view>
</block> </block>
......
// packageEquity/pages/sceneMarket/clue/clue.js
import methods from './methods'
Page({
...methods,
/**
* 页面的初始数据
*/
data: {
tab: [],
tabIndex: -1,
pageSize: 10,
currentPage: 1,
total: 0,
storeName: '',
list: [[]],
flag: false
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
this.getTabHeight()
this.getSceneMarketMaterialMenu()
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
}
})
\ No newline at end of file \ No newline at end of file
{
"usingComponents": {
"material-tab":"../components/materialTab/materialTab"
},
"navigationBarTitleText": "场景线索"
}
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/sceneMarket/clue/clue.wxss */
page {
background: #f7f8fa;
}
.clue-btn {
position: fixed;
bottom: 206rpx;
right: 36rpx;
width: 128rpx;
height: 128rpx;
border-radius: 15.06rpx;
background: #ffffffcc;
box-shadow: 0 3.76rpx 18.82rpx 0 #0000001a;
display: flex;
align-items: center;
justify-content: center;
.clue-icon {
width: 96rpx;
height: 96rpx;
}
}
.search-box {
padding-bottom: 24rpx;
}
.search-input-box {
margin: 16rpx 24rpx 0;
height: 72rpx;
border-radius: 38rpx;
background: #ffffff;
display: flex;
align-items: center;
box-sizing: border-box;
padding: 0 24rpx;
.icon {
width: 32rpx;
height: 32rpx;
margin-right: 12rpx;
flex-shrink: 0;
}
.input {
font-size: 28rpx;
width: calc(100% - 44rpx);
height: 100%;
}
.placeholder {
color: #bec1c7;
}
}
.item {
background: #ffffff;
margin: 0 24rpx 24rpx;
padding: 16rpx 20rpx;
border-radius: 16rpx;
.name {
color: #333333;
font-size: 30rpx;
font-weight: 500;
padding-bottom: 4rpx;
}
.text {
color: #666666;
font-size: 24rpx;
margin-top: 4rpx;
}
}
.clue-list{
.list-nothing{
color: #999ea8;
font-size: 20rpx;
}
}
<view class="search-box">
<material-tab tabList="{{ tab }}" bindclick="tabBarClick" />
<view class="search-input-box">
<image src="/images/search.png" class="icon"></image>
<input type="text" class="input" placeholder="搜索门店名称" placeholder-class="placeholder" maxlength="50"
value="{{storeName}}" confirm-type="search" bindconfirm="inputSearch" />
</view>
</view>
<scroll-view scroll-y style="height:calc(100vh - {{searchBoxHeight}}px)" bindscrolltolower="viewScrollTolower" class="clue-list">
<block wx:if="{{flag}}">
<block wx:if="{{list[0].length}}">
<block wx:for="{{list}}" wx:key="index">
<block wx:for="{{item}}" wx:key="ind" wx:for-item="i" wx:for-index="ind">
<view class="item" bindtap="jumpClue" data-id="{{i.id}}">
<view class="name text-hide">{{i.storeName}}</view>
<view class="text">品牌:{{i.storeBrand}}</view>
<view class="text">业务:{{i.businessCodeName}}</view>
<view class="text">提报日期:{{i.time}}</view>
</view>
</block>
</block>
<block wx:if="{{nothing}}">
<view class="list-nothing">没有更多了~</view>
</block>
</block>
<block wx:else>
<empty-data />
</block>
</block>
</scroll-view>
<view class="clue-btn" bindtap="jumpClue">
<image class="clue-icon" src="https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/equity/material/clue.png" />
</view>
\ No newline at end of file \ No newline at end of file
import {
getSceneClueList,
getSceneMarketMaterialMenu
} from '../request'
import dayjs from 'dayjs'
export default {
inputSearch(e) {
let {
value
} = e.detail
this.setData({
currentPage: 1,
list: [],
flag: false,
nothing: false,
storeName: value
})
this.getSceneClueList()
},
search() {
this.setData({
currentPage: 1,
list: [],
flag: false,
nothing: false,
storeName: ''
})
this.getSceneClueList()
},
tabBarClick(e) {
if (this.data.tabIndex == e.detail) return
const tabIndex = e.detail
this.setData({
tabIndex
})
this.search()
},
jumpClue(e) {
let {
id
} = e.currentTarget.dataset,
url = '/packageEquity/pages/sceneMarket/clueForm/clueForm'
if (id) url += `?id=${id}`
wx.navigateTo({
url,
})
},
/**获取tab高度 */
getTabHeight() {
wx.$util.getViewInfo('.search-box', res => {
if (res?.height) this.setData({
searchBoxHeight: res.height
})
})
},
async getSceneMarketMaterialMenu() {
try {
const {
code,
message,
data
} = await getSceneMarketMaterialMenu()
if (code == 0) {
this.setData({
tab: data
})
this.tabBarClick({
detail: 0
})
} else throw message
} catch (error) {
wx.$util.showToast(error)
}
},
async getSceneClueList() {
try {
wx.$util.showLoading()
const {
tab,
storeName,
tabIndex,
pageSize,
currentPage
} = this.data, {
code,
message,
data
} = await getSceneClueList({
pageSize,
currentPage,
businessCode: tab[tabIndex].code,
storeName
})
wx.hideLoading()
if (code == 0) {
let {
list,
total
} = data
list?.map(e => {
e.time = dayjs(e.createdDate).format('YYYY-MM-DD')
})
this.setData({
[`list[${currentPage - 1}]`]: list || [],
total,
flag: true
}, () => {
setTimeout(() => {
wx.hideLoading()
}, 200)
})
} else throw message
} catch (error) {
wx.hideLoading()
this.setData({
flag: true
})
wx.$util.showToast(error)
}
},
viewScrollTolower() {
let {
currentPage,
total,
pageSize
} = this.data
if (!pageSize) pageSize = 10
if (Math.ceil(total / pageSize) > currentPage) {
this.setData({
currentPage: currentPage + 1
})
this.getSceneClueList()
} else {
this.setData({
nothing: true
})
}
}
}
\ No newline at end of file \ No newline at end of file
// packageEquity/pages/sceneMarket/clueForm/clueForm.js
import methods from './methods'
Page({
...methods,
/**
* 页面的初始数据
*/
data: {
formData: {},
dynamicFormData: {},
nextBtn: true,
dynamicForm: []
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
this.getSceneMarketConfig(() => {
if (options.id) {
this.findSceneMarketLeadsById(options.id)
} else this.getSceneMarketMaterialMenu()
wx.setNavigationBarTitle({
title: options.id ? '线索详情' : '线索登记',
})
})
},
})
\ No newline at end of file \ No newline at end of file
{
"usingComponents": {
"van-popup": "@vant/weapp/popup/index",
"van-picker": "@vant/weapp/picker/index",
"form-item":"../components/formItem/formItem"
},
"navigationBarTitleText": "加载中..."
}
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/sceneMarket/clueForm/clueForm.wxss */
page {
background: #f7f8fa;
}
.layout {
padding: 24rpx 24rpx 232rpx;
.box {
padding: 0 20rpx;
border-radius: 16rpx;
background: #fff;
margin-bottom: 24rpx;
.form-item {
border-bottom: 2rpx solid #eff0f2;
&:last-of-type {
border-bottom: none;
}
}
}
.title {
color: #333333;
font-size: 28rpx;
font-weight: 500;
padding: 24rpx 0;
line-height: 32rpx;
border-bottom: 2rpx solid #eff0f2;
}
}
.btn-box {
position: fixed;
left: 0;
width: 100%;
bottom: 0;
padding: 64rpx 0;
background: #f7f8fa;
z-index: 2;
.btn {
width: 622rpx;
height: 88rpx;
margin: 0 auto;
border-radius: 12rpx;
background: #347bff;
display: flex;
align-items: center;
justify-content: center;
color: #ffffff;
font-size: 32rpx;
}
.disabled-btn {
background: rgba(52, 123, 255, .5);
}
}
\ No newline at end of file \ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!