Commit e1564135 by 李伟康

feat(packageEquity): 新增接待缺失报备功能并优化待办事项展示

新增“接待缺失报备”页面及接口支持,包括:
- 接口:checkMerchantDirect、checkMissingReception、getMissingOptions、addMissingReception、getMissingCustomerList
- 页面:missingReception 页面路由注册与跳转逻辑
- 功能:区域运营角色增加招聘管理菜单及统计数支持
- 展示:首页待办事项合并显示常规任务与缺失接待报备,并提供快捷跳转
- 样式:hot_icon 样式调整以适配 UI 规范
- 网络请求增强:增加网络类型判断,提升用户体验

此外,修复部分代码格式问题,统一变量解构风格,提高代码可读性。
1 parent 6305c59c
...@@ -192,7 +192,8 @@ ...@@ -192,7 +192,8 @@
"pages/sceneMarket/clue/clue", "pages/sceneMarket/clue/clue",
"pages/sceneMarket/clueForm/clueForm", "pages/sceneMarket/clueForm/clueForm",
"pages/sceneMarket/materialPage/materialPage", "pages/sceneMarket/materialPage/materialPage",
"pages/newReceptionRecords/newReceptionRecords" "pages/newReceptionRecords/newReceptionRecords",
"pages/missingReception/missingReception"
] ]
}, },
{ {
......
...@@ -7,10 +7,17 @@ import { ...@@ -7,10 +7,17 @@ import {
} from "~/store/ModalToQueueControl"; } from "~/store/ModalToQueueControl";
import { import {
getReceptionRecordList, getReceptionRecordList,
getRecordDetailList getRecordDetailList,
checkMissingReception,
checkMerchantDirect
} from "../../receptionRecordsApi" } from "../../receptionRecordsApi"
import aiApi from '../../aiApi' import aiApi from '../../aiApi'
import { getWaitAuditCountAPI } from '~/api/api' import {
getWaitAuditCountAPI,
waitstaffstateAPI
} from '~/api/api'
import dayjs from 'dayjs'
let lastPath = null; // 用于存储上一次的路径 let lastPath = null; // 用于存储上一次的路径
function throttle(func, delay) { function throttle(func, delay) {
let timeoutId; let timeoutId;
...@@ -187,6 +194,7 @@ Component({ ...@@ -187,6 +194,7 @@ Component({
taskInfo: {}, taskInfo: {},
current: 0, current: 0,
todoList: [], todoList: [],
missingRecordTodoList: [],
stodoList: [], stodoList: [],
todos: { todos: {
1: "日报填写提醒", 1: "日报填写提醒",
...@@ -375,6 +383,7 @@ Component({ ...@@ -375,6 +383,7 @@ Component({
this.getData(name); this.getData(name);
}, },
checkIsPadOrNot() { checkIsPadOrNot() {
let _this = this
wx.getRendererUserAgent({ wx.getRendererUserAgent({
success(res) { success(res) {
let isPad = /iPad|Android.*Tablet|Kindle|Silk/i.test(res.userAgent); let isPad = /iPad|Android.*Tablet|Kindle|Silk/i.test(res.userAgent);
...@@ -470,9 +479,16 @@ Component({ ...@@ -470,9 +479,16 @@ Component({
batchId: item.batchId batchId: item.batchId
}, '', 0) }, '', 0)
}, },
onLoad() { async onLoad() {
const isStaff = app.globalData.isStaff; const isStaff = app.globalData.isStaff;
let userInfo = wx.$util.getUserInfo() || {}; let userInfo = wx.$util.getUserInfo() || {};
/**门店是否直营 */
const merchantDirectSales = await checkMerchantDirect({
merchantId: userInfo.shopMerchantId,
scene: 0
})
this.merchantDirectSales = merchantDirectSales.data
// 飞行督导不展示接待记录暂时取消埋点 // 飞行督导不展示接待记录暂时取消埋点
if (userInfo.loginRole != 6) this.onPageShow() if (userInfo.loginRole != 6) this.onPageShow()
if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) this.setData({ if (userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5 || userInfo?.loginRole == 6) this.setData({
...@@ -576,6 +592,15 @@ Component({ ...@@ -576,6 +592,15 @@ Component({
let index = menuList?.findIndex((val) => val.menuText == "交车目标"); let index = menuList?.findIndex((val) => val.menuText == "交车目标");
index > -1 && menuList.splice(index, 1); index > -1 && menuList.splice(index, 1);
} }
// 区域运营 - feature:招聘管理
if (userInfo?.loginRole == 3 && menuList.every((item) => item.name != '招聘管理')) {
menuList.push({
menuText: "招聘管理",
path: "packageEquity.recruitManage",
icon: "recruit-manage",
tipsNum: 0
})
}
// 区域运营/飞行督导 // 区域运营/飞行督导
if ((userInfo?.loginRole == 3 || userInfo?.loginRole == 6) && menuList.every((item) => item.menuText != '工作日报')) { if ((userInfo?.loginRole == 3 || userInfo?.loginRole == 6) && menuList.every((item) => item.menuText != '工作日报')) {
menuList.push({ menuList.push({
...@@ -606,6 +631,43 @@ Component({ ...@@ -606,6 +631,43 @@ Component({
icon: "mentorship-manage" icon: "mentorship-manage"
}); });
} }
if ((isStaff || userInfo.isSuper || userInfo?.loginRole == 3 || userInfo.loginRole == 5)) {
if (this.merchantDirectSales) {
let {
uuid,
merchantId,
shopMerchantId
} = userInfo
const missingresponse = await checkMissingReception({
merchantId: shopMerchantId,
yqMerchantId: merchantId,
staffUuid: uuid,
sceneType: 0,
reportStartDate: dayjs().subtract(6, 'day').format('YYYY-MM-DD'),
reportEndDate: dayjs().format('YYYY-MM-DD'),
})
let missingRecordTodoList = []
if (missingresponse.code == 0) {
missingresponse.data.reverse().map(e => {
if (e.missingReceptionRecord && !e.hasReceptionReport && !missingRecordTodoList.length) missingRecordTodoList.push(e)
})
}
this.setData({
missingRecordTodoList,
})
if (menuList.every((item) => item.menuText != "接待缺失报备")) menuList.push({
menuText: "接待缺失报备",
path: "packageEquity.missingReception",
icon: "missing-reception",
});
} else {
let delIndex = menuList.findIndex(item => item.menuText == "接待缺失报备")
if (delIndex != -1) menuList = menuList.splice(delIndex, 1)
this.setData({
missingRecordTodoList: [],
})
}
}
this.checkIsPadOrNot(); this.checkIsPadOrNot();
this.getData(); this.getData();
// 隐藏待办事项模块 // 隐藏待办事项模块
...@@ -614,6 +676,7 @@ Component({ ...@@ -614,6 +676,7 @@ Component({
let eventArr = [this.getYqStoreConfig(), this.getInspectionBadgeCode(), this.getBusiness(), this.getStoreList(), this.extractCheck()] let eventArr = [this.getYqStoreConfig(), this.getInspectionBadgeCode(), this.getBusiness(), this.getStoreList(), this.extractCheck()]
if (isStaff) eventArr.push(this.getStaffTargetTask(), this.getIsMentor()) if (isStaff) eventArr.push(this.getStaffTargetTask(), this.getIsMentor())
if (userInfo.loginRole == 3) eventArr.push(this.getAwaitAuditCount(userInfo)) if (userInfo.loginRole == 3) eventArr.push(this.getAwaitAuditCount(userInfo))
if (userInfo.loginRole == 3) eventArr.push(this.getWaitStaff(userInfo))
Promise.all(eventArr).then(() => { Promise.all(eventArr).then(() => {
this.menuListRest(); // 解决融合和非融合互相切换导致战败按钮问题 this.menuListRest(); // 解决融合和非融合互相切换导致战败按钮问题
}) })
...@@ -624,7 +687,9 @@ Component({ ...@@ -624,7 +687,9 @@ Component({
}, },
getAwaitAuditCount(userInfo) { getAwaitAuditCount(userInfo) {
return new Promise(resolve => { return new Promise(resolve => {
let { menuList } = this.data let {
menuList
} = this.data
// 区域运营角色退款审批入口 // 区域运营角色退款审批入口
if (userInfo?.loginRole == 3 && menuList.every(item => item.menuText != '待审批')) { if (userInfo?.loginRole == 3 && menuList.every(item => item.menuText != '待审批')) {
menuList.push({ menuList.push({
...@@ -635,11 +700,47 @@ Component({ ...@@ -635,11 +700,47 @@ Component({
}) })
} }
let index = menuList.findIndex(e => e.menuText == '待审批') let index = menuList.findIndex(e => e.menuText == '待审批')
getWaitAuditCountAPI({sceneType: userInfo?.sceneType}).then(res => { getWaitAuditCountAPI({
let { code, data } = res sceneType: userInfo?.sceneType
}).then(res => {
let {
code,
data
} = res
if (code == 0) { if (code == 0) {
this.setData({ this.setData({
[`menuList[${index}].tipsNum`]: data.waiteForAuditNum [`menuList[${index}].tipsNum`]: data.totalCount
})
}
resolve()
})
})
},
// 获取招聘管理统计数量
getWaitStaff(userInfo) {
return new Promise(resolve => {
let {
menuList
} = this.data
// 区域运营角色退款审批入口
if (userInfo?.loginRole == 3 && menuList.every(item => item.menuText != '招聘管理')) {
menuList.push({
menuText: '招聘管理',
path: 'packageEquity.recruitManage',
icon: 'recruit-manage',
tipsNum: 0
})
}
let index = menuList.findIndex(e => e.menuText == '招聘管理')
waitstaffstateAPI({}).then(res => {
console.log("招聘管理", res);
let {
code,
data
} = res
if (code == 0) {
this.setData({
[`menuList[${index}].tipsNum`]: data.waitProcessCount
}) })
} }
resolve() resolve()
...@@ -1220,7 +1321,7 @@ Component({ ...@@ -1220,7 +1321,7 @@ Component({
console.log(staffCheck, 'staffCheck'); console.log(staffCheck, 'staffCheck');
if (staffCheck) return false; if (staffCheck) return false;
/**禁止提单 */ /**禁止提单 */
if(item.beforeClick && await wx.$globalDataFunction[item.beforeClick]()) return if (item.beforeClick && await wx.$globalDataFunction[item.beforeClick]()) return
if ( if (
merchantBrand?.findIndex((i) => ["鸿蒙智行"].includes(i.name)) != -1 merchantBrand?.findIndex((i) => ["鸿蒙智行"].includes(i.name)) != -1
) { ) {
...@@ -1236,14 +1337,20 @@ Component({ ...@@ -1236,14 +1337,20 @@ Component({
}, 2000), }, 2000),
promptHandleConfirm(e) { promptHandleConfirm(e) {
let { payFlag, payType } = e.detail let {
let { mode } = this.data payFlag,
payType
} = e.detail
let {
mode
} = this.data
let thisPage = wx.$router.getPageInstance(); let thisPage = wx.$router.getPageInstance();
let paymentMethod = payFlag != 2 ? 1 : payType let paymentMethod = payFlag != 2 ? 1 : payType
if (payFlag == 1 || payType == 3 || payType == 4 || payType == 6) { if (payFlag == 1 || payType == 3 || payType == 4 || payType == 6) {
wx.$router.go( wx.$router.go(
mode ? "createOrderCarQuotationSimple" : "createOrderCarQuotation", mode ? "createOrderCarQuotationSimple" : "createOrderCarQuotation", {
{paymentMethod} paymentMethod
}
); );
} else { } else {
thisPage.tipsEvent && thisPage.tipsEvent &&
...@@ -1597,5 +1704,11 @@ Component({ ...@@ -1597,5 +1704,11 @@ Component({
this.getReceptionList() this.getReceptionList()
wx.$track.setTrackData(0, 'staff_reception_search', this.getParams()) wx.$track.setTrackData(0, 'staff_reception_search', this.getParams())
}, },
gotoMissingReception() {
const [item] = this.data.missingRecordTodoList
wx.$router._to('/packageEquity/pages/missingReception/missingReception', {
reportDate: item.reportDate
}, 'navigateTo')
}
}, },
}); });
\ No newline at end of file \ No newline at end of file
...@@ -212,17 +212,19 @@ box-shadow: 0 var(--fontSize24) var(--fontSize24) -var(--fontSize12) #d3d9e680 ...@@ -212,17 +212,19 @@ box-shadow: 0 var(--fontSize24) var(--fontSize24) -var(--fontSize12) #d3d9e680
} }
.hot_icon{ .hot_icon{
position: absolute; position: absolute;
right: 0; right: var(--fontSize46);
top: 0; top: 0;
width: var(--fontSize38); min-width: var(--fontSize24);
height: var(--fontSize32); height: var(--fontSize24);
background: #F24724; background: #F24724;
border-radius: var(--fontSize16); border-radius: var(--fontSize16);
color: #FFFFFF; color: #FFFFFF;
font-size: var(--fontSize22); font-size: var(--fontSize20);
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items:center; align-items:center;
padding:var(--fontSize2);
border:var(--fontSize2) solid #ffffff;
} }
.bubble_icon{ .bubble_icon{
position: absolute; position: absolute;
......
...@@ -57,10 +57,11 @@ ...@@ -57,10 +57,11 @@
<view wx:for="{{3}}" wx:key="index" wx:for-index="idx" class="dot {{current==idx?'active':''}}"></view> <view wx:for="{{3}}" wx:key="index" wx:for-index="idx" class="dot {{current==idx?'active':''}}"></view>
</view> </view>
</view> </view>
<block wx:if="{{isWait&&todoList.length>0}}"> <block wx:if="{{isWait&&(todoList.length || missingRecordTodoList.length)}}">
<view class="todo-list"> <view class="todo-list">
<view class="title">今日待办·{{todoList.length}}</view> <view class="title">今日待办·{{todoList.length + missingRecordTodoList.length}}</view>
<view class="todo-items"> <view class="todo-items">
<block wx:if="{{todoList.length}}">
<view class="todo-item" wx:key="idx" wx:for="{{ispopUp?todoList:stodoList}}" wx:for-index="idx"> <view class="todo-item" wx:key="idx" wx:for="{{ispopUp?todoList:stodoList}}" wx:for-index="idx">
<view class="todo-item-title"> <view class="todo-item-title">
<image src="{{IMG_URL}}{{item.taskType=='1'?'warn':'task'}}.png" /><text>{{todos[item.taskId]}}</text> <image src="{{IMG_URL}}{{item.taskType=='1'?'warn':'task'}}.png" /><text>{{todos[item.taskId]}}</text>
...@@ -71,12 +72,24 @@ ...@@ -71,12 +72,24 @@
<view class="todo-item-btn" wx:elif="{{item.taskId==1}}" data-id="{{item.taskId}}" bindtap="goto">去填写</view> <view class="todo-item-btn" wx:elif="{{item.taskId==1}}" data-id="{{item.taskId}}" bindtap="goto">去填写</view>
<view class="todo-item-btn" wx:else bindtap="closeRemind" data-id="{{item.taskId}}">关闭提醒</view> <view class="todo-item-btn" wx:else bindtap="closeRemind" data-id="{{item.taskId}}">关闭提醒</view>
</view> </view>
</block>
<block wx:if="{{missingRecordTodoList.length}}" wx:key="idx" wx:for-index="idx">
<view class="todo-item">
<view class="todo-item-title">
<image src="{{IMG_URL}}warn.png" />
<text>接待缺失报备</text>
</view>
<view class="todo-item-info">请报备缺失接待客户的原因</view>
<view class="todo-item-btn" bindtap="gotoMissingReception">去报备</view>
</view>
</block>
</view> </view>
<view class="pack-up {{!ispopUp?'pack-up-active':''}}" wx:if="{{todoList.length>2}}" bindtap="packupList"> <view class="pack-up {{!ispopUp?'pack-up-active':''}}" wx:if="{{(missingRecordTodoList.length + todoList.length)>2}}" bindtap="packupList">
<image src="{{IMG_URL}}pack-up.png" /> <image src="{{IMG_URL}}pack-up.png" />
</view> </view>
</view> </view>
</block> </block>
<view class="menu_box"> <view class="menu_box">
<block wx:for="{{ menuList }}" wx:key="index"> <block wx:for="{{ menuList }}" wx:key="index">
<view class="menu_item" bindtap="navGo" data-item="{{ item }}"> <view class="menu_item" bindtap="navGo" data-item="{{ item }}">
......
// compoents/weekCalendar/weekCalendar.js
Component({
options: {
multipleSlots: true // 在组件定义时的选项中启用多slot支持
},
/** * 组件的属性列表 * 用于组件自定义设置 */
properties: {
timeBean: {
// 属性名 在wxml调用组件时利用该属性传递组件显示的数据
type: Object, // 类型(必填),目前接受的类型包括:String, Number, Boolean, Object, Array, null(表示任意类型)
value: '' // 属性初始值(可选),如果未指定则会根据类型选择一个
},
index: {
type: Number
}
// weeklyList: {
// type: Array,
// value: []
// }
},
/**
* 组件的方法列表
*/
methods: {
lastWeek: function (e) {
//点击了上一周
this.triggerEvent('lastWeek')
},
nextWeek: function (e) {
//点击了下一周
this.triggerEvent('nextWeek')
},
itemClick: function (e) {
//点击了某一日,传递该日的下标
// 超过当前时间不可点击
if (e.currentTarget.dataset.disabled) {
return
}
var index = e.currentTarget.dataset.index
this.triggerEvent('dayClick', index)
}
}
})
{
"component": true,
"usingComponents": {}
}
\ No newline at end of file \ No newline at end of file
/* tabWorkOrder/pages/staffDaily/weekCalendar/weekCalendar.wxss */
/* compoents/weekCalendar/weekCalendar.wxss */
.row {
display: flex;
flex-direction: column;
justify-content: space-around;
align-items: center;
background: #fff;
.week_box{
height: var(--fontSize60);
width: 100%;
display: flex;
justify-content: space-around;
align-items: center;
box-shadow: 0 var(--fontSize4) var(--fontSize8) 0 #cdcdd159;
}
.date_box{
height: var(--fontSize128);
width: 100%;
display: flex;
justify-content: space-around;
align-items: center;
}
}
.weekselect {
height: var(--fontSize80);
flex-direction: row;
justify-content: space-between;
}
.column {
display: flex;
flex-flow: column;
align-items: center;
justify-content: center;
flex: 1;
}
.nextWeek {
font-family: PingFangSC-Regular;
font-weight: 400;
flex-direction: row;
color: #181A1F;
width: var(--fontSize180);
}
.dateType {
position: relative;
display: flex;
align-items: center;
justify-content: center;
font-size: var(--fontSize32);
color: #292D33;
border-radius: 50%;
width: var(--fontSize64);
height: var(--fontSize64);
.empty {
box-sizing: border-box;
position: absolute;
width: var(--fontSize38);
text-align: center;
height: var(--fontSize32);
background: #F24724;
border-radius: var(--fontSize16);
bottom: var(--fontSize40);
left: var(--fontSize40);
font-size: var(--fontSize22);
z-index: 2;
padding: 0 var(--fontSize4);
color: #fff;
}
}
.dateType.dateType_disabled{
color: #BEC1C7;
}
.weekType {
font-size: var(--fontSize28);
color: #292D33;
}
.select-column {
.dateType{
background: #347BFF;
color: #fff;
}
}
.disabled {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding-bottom: var(--fontSize5);
padding-top: var(--fontSize5);
margin-left: var(--fontSize5);
margin-right: var(--fontSize5);
margin-top: var(--fontSize10);
flex: 1;
border-top-left-radius: var(--fontSize20);
border-top-right-radius: var(--fontSize20);
background: #F6FCFE;
color: #292D33;
}
.timeType {
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: var(--fontSize28);
color: #181A1F;
// font-size: var(--fontSize35);
// font-weight: bold;
// margin-right: auto;
}
.line {
height: var(--fontSize1);
width: 100%;
background-color: gainsboro;
}
.lastweek {
width: var(--fontSize180);
font-family: PingFangSC-Regular;
font-weight: 400;
font-size: var(--fontSize28);
flex-direction: row;
color: #181A1F;
}
.line-shadow {
height: var(--fontSize3);
width: 100%;
background-color: gainsboro;
box-shadow: 5px 0px 5px 0px gainsboro;
}
@font-face {
font-family: "iconfont";
src: url('iconfont.eot?t=1533031583450');
/* IE9*/
src: url('iconfont.eot?t=1533031583450#iefix') format('embedded-opentype'),
/* IE6-IE8 */
url('data:application/x-font-woff;charset=utf-8;base64,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') format('woff'),
url('iconfont.ttf?t=1533031583450') format('truetype'),
/* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
url('iconfont.svg?t=1533031583450#iconfont') format('svg');
/* iOS 4.1- */
}
.iconfont {
font-family: "iconfont" !important;
font-size: 16px;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
/**
*字体图标,左右箭头,书,米饭,可以修改界面对图标进行修改替换
*/
.icon-sanjiaoleft:before {
content: "\e6b6";
}
.icon-sanjiaoright:before {
content: "\e6b7";
}
.icon-book1:before {
content: "\e631";
}
.icon-mifan:before {
content: "\e606";
}
\ No newline at end of file \ No newline at end of file
<!--tabWorkOrder/pages/staffDaily/weekCalendar/weekCalendar.wxml-->
<!--compoents/weekCalendar/weekCalendar.wxml-->
<view class="line"></view>
<view class="row weekselect">
<view class="row lastweek" bindtap="lastWeek">
<text class="iconfont icon-sanjiaoleft" style="padding:var(--fontSize15);color: #bec1c7;"></text>
<view style="">上一周</view>
</view>
<view class="timeType">{{timeBean.yearMonth}}</view>
<view class="row nextWeek" bindtap="nextWeek">
<block wx:if="{{ !timeBean.isInCurrentWeek }}">
<view style=" ">下一周</view>
<text class="iconfont icon-sanjiaoright" style="padding:var(--fontSize15);color: #bec1c7;"></text>
</block>
</view>
</view>
<view class="row">
<view class="week_box">
<view wx:for="{{ [0,1,2,3,4,5,6] }}" data-index="{{ index }}" data-disabled="{{ timeBean.weekDayList[index].disabled }}" class="item column" bindtap="itemClick" wx:key="index">
<view class="weekType">{{timeBean.weekDayList[index].week}}</view>
</view>
</view>
<view class="date_box">
<view wx:for="{{ [0,1,2,3,4,5,6] }}" data-index="{{ index }}" data-disabled="{{ timeBean.weekDayList[index].disabled }}" class="item column {{ index==timeBean.selectDay?'select-column':'' }}" bindtap="itemClick" wx:key="index">
<view class="dateType {{timeBean.weekDayList[index].disabled ? 'dateType_disabled' : ''}}">
{{timeBean.weekDayList[index].day}}
<view class="empty" wx:if="{{ !timeBean.weekDayList[index].disabled && !timeBean.weekDayList[index].hasDailyValue }}">空</view>
</view>
</view>
</view>
</view>
<!-- <view class="line-shadow"></view> -->
<view class="suspension" bindtap="addMenuClick">
<text class="iconfont icon-tianjia" style="font-size:var(--fontSize60); color:#fff;"></text>
</view>
\ No newline at end of file \ No newline at end of file
{
"navigationStyle": "custom",
"usingComponents": {
"weekCalendar": "./components/weekCalendar/weekCalendar"
}
}
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/missingReception/missingReception.wxss */
page {
background: #f7f8fa;
}
.layout {
.flex {
display: flex;
align-items: center;
}
.box {
height: calc(100vh - 120rpx - constant(safe-area-inset-bottom));
height: calc(100vh - 120rpx - env(safe-area-inset-bottom));
box-sizing: border-box;
.nothing {
margin-top: 192rpx;
flex-direction: column;
color: #bec1c7;
font-size: 24rpx;
.no-data-img {
width: 172rpx;
height: 172rpx;
}
}
.content {
height: calc(100% - 269rpx);
.info {
height: 196rpx;
border-radius: 24rpx;
background: #ffffff;
margin: 24rpx 24rpx 8rpx;
padding: 0 48rpx;
justify-content: space-between;
&-item {
flex-shrink: 0;
color: #292d33;
font-size: 26rpx;
width: 104rpx;
.num {
margin-top: 8rpx;
color: #2c66f7;
font-size: 48rpx;
font-weight: 700;
line-height: 56rpx;
}
}
}
.title {
height: 88rpx;
padding: 0 36rpx;
font-weight: 500;
color: #292d33;
font-size: 28rpx;
}
.item {
height: 336rpx;
position: relative;
margin-bottom: 20rpx;
.num {
position: absolute;
top: 8rpx;
left: 16rpx;
height: 32rpx;
border-radius: 16rpx;
border: 2rpx solid #c9c9c9;
background: #5a5e66;
padding: 0 10rpx;
color: #ffffff;
font-size: 20rpx;
font-weight: 500;
}
.item-content {
height: 100%;
border-radius: 16rpx;
background: #ffffff;
box-shadow: 0 4rpx 20rpx 0 #0000001a;
margin: 0 20rpx 0 60rpx;
padding: 0 40rpx;
.label {
color: #292d33;
font-size: 28rpx;
line-height: 40rpx;
padding: 24rpx 0 16rpx;
.required {
color: #f24724;
}
}
.value {
height: 72rpx;
border-radius: 8rpx;
border: 2rpx solid #ececec;
background: #ffffff;
padding: 0 24rpx;
.placeholder {
font-size: 28rpx;
color: #dee0e3;
}
.error{
color: #f24724;
}
.picker,
.input {
width: 100%;
height: 100%;
font-size: 28rpx;
position: relative;
.reason {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
.arrow {
position: absolute;
right: 0;
top: 50%;
transform: translateY(-50%) scale(.5) rotate(90deg);
width: 24rpx;
height: 48rpx;
opacity: .5;
}
}
}
.disabled{
background: #f7f8fa;
}
}
}
.block {
width: 100%;
height: 20rpx;
}
.has-reception-report{
.required{
display: none;
}
}
}
}
.bespread{
height: calc(100vh - constant(safe-area-inset-bottom));
height: calc(100vh - env(safe-area-inset-bottom));
}
.footer {
height: 120rpx;
padding: 0 32rpx constant(safe-area-inset-bottom);
padding: 0 32rpx env(safe-area-inset-bottom);
gap: 0 16rpx;
font-size: 32rpx;
position: fixed;
bottom: 0;
left: 0;
.cancel {
width: 226rpx;
height: 80rpx;
border-radius: 12rpx;
border: 2rpx solid #347bff;
color: #347bff;
box-sizing: border-box;
justify-content: center;
}
.submit {
width: 444rpx;
height: 80rpx;
border-radius: 12rpx;
background: #347bff;
color: #ffffff;
justify-content: center;
}
}
}
\ No newline at end of file \ No newline at end of file
<view class="layout">
<navigation-bar navStyle="background: linear-gradient(to bottom, #DDE8FB 0%, #EBF1FB 100%);" bindback="jump" bindnavbarReady="navbarReady" showBack>
平板接待缺失报备
</navigation-bar>
<view class="box {{isDateWithin7Days && !detailObj[currentDate].hasReceptionReport && detailObj[currentDate].missingReceptionRecord ? '' : 'bespread'}}" style="padding-top:{{ navBarHeight }}px">
<weekCalendar timeBean="{{ timeBean }}" bind:lastWeek="lastWeek" bind:nextWeek="nextWeek" bind:dayClick="dayClick"></weekCalendar>
<scroll-view scroll-y class="content" scroll-top="{{scrollTop}}">
<view class="info flex">
<view class="info-item">
售前
<view class="num">{{detailObj[currentDate].preSalesCustomerCount || '0'}}</view>
</view>
<view class="info-item">
售后
<view class="num">{{detailObj[currentDate].afterSalesCustomerCount || '0'}}</view>
</view>
<view class="info-item">
总触客
<view class="num">{{detailObj[currentDate].totalSalesCustomerCount || '0'}}</view>
</view>
<view class="info-item">
录音
<view class="num">{{detailObj[currentDate].recordingCount || '0'}}</view>
</view>
</view>
<!-- 超过7天&没日报记录 -->
<block wx:if="{{!isDateWithin7Days && !detailObj[currentDate].hasReceptionReport}}">
<view class="nothing flex">
<image class="no-data-img" src="{{IMG_URL}}equity/reception/no-suggestions.png" />
<view>已超过 7 个自然日</view>
暂不支持补填操作
</view>
</block>
<block wx:else>
<block wx:if="{{detailObj[currentDate].hasDailyReport}}">
<block wx:if="{{detailObj[currentDate].missingReceptionRecord || list.length}}">
<view class="title flex">
{{detailObj[currentDate].hasReceptionReport?'已':'需'}}报备客户·{{detailObj[currentDate].hasReceptionReport ? total : list.length}}
</view>
<view class="list {{detailObj[currentDate].hasReceptionReport?'has-reception-report':''}}">
<block wx:for="{{list}}" wx:key="index">
<view class="item">
<view class="num flex">{{index + 1}}</view>
<view class="item-content">
<view class="label flex">客户姓名<view class="required">*</view>
</view>
<view class="value {{item.disabled?'disabled':''}}">
<input class="input" type="text" maxlength="20" value="{{item.customerName}}" placeholder="{{item.inputErrorText||'请输入'}}" placeholder-class="placeholder {{item.inputErrorText?'error':''}}" disabled="{{item.disabled}}" bindblur="inputBlur" data-index="{{index}}" />
</view>
<view class="label flex">缺失原因<view class="required">*</view>
</view>
<view class="value {{item.disabled?'disabled':''}}">
<picker class="picker" mode="selector" range="{{missingOptions}}" disabled="{{item.disabled}}" range-key="reason" bindchange="changeReason" data-index="{{index}}">
<view class="reason flex {{item.reasonText?'':'placeholder'}} {{item.errorText?'error':''}}">{{item.reasonText || item.errorText || '请选择'}}</view>
<view class="arrow">
<image src="/images/arrow-right.png"></image>
</view>
</picker>
</view>
</view>
</view>
</block>
</view>
<view class="block"></view>
</block>
<block wx:else>
<view class="nothing flex">
<image class="no-data-img" src="{{IMG_URL}}equity/reception/no-suggestions.png" />
该日期暂无缺失接待记录
</view>
</block>
</block>
<block wx:else>
<view class="nothing flex">
<image class="no-data-img" src="{{IMG_URL}}equity/reception/no-suggestions.png" />
请先填写驻店日报
</view>
</block>
</block>
</scroll-view>
</view>
<block wx:if="{{isDateWithin7Days && !detailObj[currentDate].hasReceptionReport && detailObj[currentDate].missingReceptionRecord}}">
<view class="footer flex">
<view class="cancel flex" bindtap="cancel">取消报备</view>
<view class="submit flex" bindtap="submit">提交报备</view>
</view>
</block>
</view>
\ No newline at end of file \ No newline at end of file
...@@ -25,4 +25,41 @@ module.exports = { ...@@ -25,4 +25,41 @@ module.exports = {
return api.post('dj.api.car.boutique.inspection.findCheckResultByBatchId', data) return api.post('dj.api.car.boutique.inspection.findCheckResultByBatchId', data)
}, },
/**
*
* 门店号是否是直营门店校验
*/
checkMerchantDirect(data) {
return api.post('dj.api.car.boutique.resident.direct.sale.merchant', data)
},
/**
* 查询给定日期如果填了日报是否缺失接待记录
*/
checkMissingReception(data) {
return api.post('dj.api.smartcarlife.staff.missing.reception.report.mini.check', data)
},
/**
* 查询所有缺失原因
*/
getMissingOptions() {
return api.post('dj.api.smartcarlife.staff.missing.reception.report.mini.reason.list', {})
},
/**
* 接待缺失报备提交
*/
addMissingReception(data) {
return api.post('dj.api.smartcarlife.staff.missing.reception.report.mini.add', data)
},
/**
* 接待缺失报备列表
*/
getMissingCustomerList(data = {}) {
data = {
sceneType: 0,
currentPage: 1,
pageSize: 999999,
...data
}
return api.post('dj.api.smartcarlife.staff.missing.reception.report.mini.list', data)
},
} }
\ No newline at end of file \ No newline at end of file
...@@ -22,6 +22,16 @@ class Request { ...@@ -22,6 +22,16 @@ class Request {
let _this = this let _this = this
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
wx.showNavigationBarLoading() wx.showNavigationBarLoading()
wx.getNetworkType({
success(res) {
if (res.networkType == "none") {
wx.hideLoading();
wx.showToast({
title: '网络异常',
icon: "none",
})
return;
}
if (!data) data = {} if (!data) data = {}
let header = let header =
RequestMethods === 'POST' ? { RequestMethods === 'POST' ? {
...@@ -96,6 +106,8 @@ class Request { ...@@ -96,6 +106,8 @@ class Request {
wx.hideNavigationBarLoading() wx.hideNavigationBarLoading()
} }
}) })
}
})
}) })
} }
getData(data, method, noSignAttr, merchant) { getData(data, method, noSignAttr, merchant) {
...@@ -114,7 +126,7 @@ class Request { ...@@ -114,7 +126,7 @@ class Request {
if (!apiName) { if (!apiName) {
throw new Error('apiName is null') throw new Error('apiName is null')
} }
if(apiName.split('.').length > 1) apiName = apiName.split('.')[0] if (apiName.split('.').length > 1) apiName = apiName.split('.')[0]
if (merchant) apiName = 'merchants' if (merchant) apiName = 'merchants'
const appKey = secretKey[apiName].appKey const appKey = secretKey[apiName].appKey
const secret = secretKey[apiName].secret const secret = secretKey[apiName].secret
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!