Commit 00d1f7ab by 前端

Merge branch 'SAAS+v5.5.3' into 'master'

上线合并

See merge request !5
2 parents fe4efe46 79f4e97e
Showing 35 changed files with 1150 additions and 147 deletions
...@@ -419,5 +419,9 @@ module.exports = { ...@@ -419,5 +419,9 @@ module.exports = {
// 查询订单是否支持状态变更 // 查询订单是否支持状态变更
getOrderRefundStep(data) { getOrderRefundStep(data) {
return api.post('dj.api.smartcarlife.refundApplyRecord.isExist', data) return api.post('dj.api.smartcarlife.refundApplyRecord.isExist', data)
},
// 获取员工日报/周报/月报模版
getStaffTemplate(data) {
return api.post('dj.api.carboutique.find.staff.good.news.template', data)
} }
} }
Component({
properties: {
show: {
type: Boolean,
value: false
},
templateList: {
type: Array,
value: []
}
},
methods: {
onModalBtn(e) {
// modal button click: 0 is Cancel
this.triggerEvent('cancel');
},
onSelect(e) {
const item = e.currentTarget.dataset.item;
this.triggerEvent('select', item);
}
}
})
{
"component": true,
"usingComponents": {
"modal": "/components/modal/modal",
"gl-image": "/components/GlImage/index"
}
}
<modal show="{{show}}" custom="{{true}}" tapTitle="选择模板" title="" btns="{{[]}}" binddidClickBtn="onModalBtn">
<view class="template-list">
<block wx:for="{{templateList}}" wx:key="index">
<view class="template-item" bindtap="onSelect" data-item="{{item}}">
<view class="item-name">{{item.name}}</view>
<view class="arrow-right">
<image src="/images/arrow-right.png" class="arrow-img" />
</view>
</view>
</block>
</view>
<view class="cancel-btn-box" bindtap="onModalBtn">
<view class="cancel-btn">取消</view>
</view>
</modal>
.template-list {
max-height: 900rpx;
overflow-y: scroll;
padding: 0 30rpx;
margin-top: 40rpx;
}
.template-item {
display: flex;
align-items: center;
justify-content: space-between;
padding: 32rpx;
margin-bottom: 24rpx;
background-color: #F7F8FA;
border-radius: 16rpx;
}
.item-name {
flex: 1;
color: #292d33;
font-size: 28rpx;
font-weight: 500;
}
.arrow-right {
width: 32rpx;
height: 32rpx;
display: flex;
align-items: center;
justify-content: center;
}
.arrow-img {
width: 13.2rpx;
height: 24rpx;
}
.cancel-btn-box {
padding: 0 32rpx 0;
border-top: 1px solid #ebedf0;
}
.cancel-btn {
height: 96rpx;
line-height: 96rpx;
text-align: center;
background-color: #fff;
color: #333333;
font-size: 32rpx;
font-weight: 500;
}
{ {
"name": "dj-car-boutique-work-wechat",
"lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "lockfileVersion": 1,
"": {
"dependencies": { "dependencies": {
"@vant/area-data": "^1.5.1", "@vant/area-data": {
"@vant/weapp": "^1.10.24", "version": "1.5.2",
"dayjs": "^1.11.11", "resolved": "https://registry.npmjs.org/@vant/area-data/-/area-data-1.5.2.tgz",
"glsk-applet-component": "^1.0.0", "integrity": "sha512-Gtxgt6Rjgopt6234ANpO0bBsSwtjZ23lBlVDHIy8Mi2NJqyoj1vgVWY0dri8/2LCZAWzQ6EnwRrUVViUZ0cvMA=="
"glsx-applet-component": "^1.1.29", },
"glsx-common-sdk": "^0.2.8", "@vant/weapp": {
"number-precision": "^1.6.0", "version": "1.11.7",
"rfdc": "^1.3.0" "resolved": "https://registry.npmjs.org/@vant/weapp/-/weapp-1.11.7.tgz",
} "integrity": "sha512-Rwn9BBnb4kHSV4XmvBicwtd42J+amEUfnFDcXJsGNPNX4a9c/DoT6YLsm4X1wB2+sQbdiQsbFBLAvGRBxCkD8g=="
}, },
"node_modules/@vant/area-data": { "dayjs": {
"version": "1.5.1", "version": "1.11.19",
"resolved": "https://registry.npmjs.org/@vant/area-data/-/area-data-1.5.1.tgz", "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.19.tgz",
"integrity": "sha512-gR5TPEzTbxN1cTK1aDhCoyikSCLX7DAacxyXoKyI4SAsYYTZrDl/nLgQFIm9vLsvWzlPIda8xV8/U3x7M9k6ww==" "integrity": "sha512-t5EcLVS6QPBNqM2z8fakk/NKel+Xzshgt8FFKAn+qwlD1pzZWxh0nVCrvFK7ZDb6XucZeF9z8C7CBWTRIVApAw=="
}, },
"node_modules/@vant/weapp": { "glsk-applet-component": {
"version": "1.10.24",
"resolved": "https://registry.npmmirror.com/@vant/weapp/-/weapp-1.10.24.tgz",
"integrity": "sha512-oovAaaJq3mlB+wto5bHVCn/rov8IgRDg+gJXy6hPX0A3c9WF1GqLqSmoXyaktgidJ9IaV1RADd3PAFlw4lUsnQ=="
},
"node_modules/dayjs": {
"version": "1.11.11",
"resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.11.tgz",
"integrity": "sha512-okzr3f11N6WuqYtZSvm+F776mB41wRZMhKP+hc34YdW+KmtYYK9iqvHSwo2k9FEH3fhGXvOPV6yz2IcSrfRUDg=="
},
"node_modules/glsk-applet-component": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/glsk-applet-component/-/glsk-applet-component-1.0.0.tgz", "resolved": "https://registry.npmjs.org/glsk-applet-component/-/glsk-applet-component-1.0.0.tgz",
"integrity": "sha512-ulz1OquWy4y4Q26Zu4FLDWzyqK+sInPWs4o8MKj2N8V/TnYQlUXoWkkgKh8fERK8A+rsusf3eiyZB0odchKk8g==" "integrity": "sha512-ulz1OquWy4y4Q26Zu4FLDWzyqK+sInPWs4o8MKj2N8V/TnYQlUXoWkkgKh8fERK8A+rsusf3eiyZB0odchKk8g=="
}, },
"node_modules/glsx-applet-component": { "glsx-applet-component": {
"version": "1.1.29", "version": "1.1.29",
"resolved": "https://registry.npmmirror.com/glsx-applet-component/-/glsx-applet-component-1.1.29.tgz", "resolved": "https://registry.npmjs.org/glsx-applet-component/-/glsx-applet-component-1.1.29.tgz",
"integrity": "sha512-HPzVayIRZvA3nvG2Lj9V9+S+BFiCer4XxjQwuZksta5Bs9JbbKaY4ztcIEe1Se3vw3rbPL0Dv2OsWvVz2b5jfw==" "integrity": "sha512-HPzVayIRZvA3nvG2Lj9V9+S+BFiCer4XxjQwuZksta5Bs9JbbKaY4ztcIEe1Se3vw3rbPL0Dv2OsWvVz2b5jfw=="
}, },
"node_modules/glsx-common-sdk": { "glsx-common-sdk": {
"version": "0.2.8", "version": "0.2.8",
"resolved": "https://registry.npmjs.org/glsx-common-sdk/-/glsx-common-sdk-0.2.8.tgz", "resolved": "https://registry.npmjs.org/glsx-common-sdk/-/glsx-common-sdk-0.2.8.tgz",
"integrity": "sha512-qCDUBRvJwE2Gs1PLwB+fHOSFPgB5W5fwYC3GSBSjMQOxs4keeOvd7o5wIb7bNakp0xF6ARPqpC/xm3hZ9TRW6A==" "integrity": "sha512-qCDUBRvJwE2Gs1PLwB+fHOSFPgB5W5fwYC3GSBSjMQOxs4keeOvd7o5wIb7bNakp0xF6ARPqpC/xm3hZ9TRW6A=="
}, },
"node_modules/number-precision": { "number-precision": {
"version": "1.6.0", "version": "1.6.0",
"resolved": "https://registry.npmmirror.com/number-precision/-/number-precision-1.6.0.tgz", "resolved": "https://registry.npmjs.org/number-precision/-/number-precision-1.6.0.tgz",
"integrity": "sha512-05OLPgbgmnixJw+VvEh18yNPUo3iyp4BEWJcrLu4X9W05KmMifN7Mu5exYvQXqxxeNWhvIF+j3Rij+HmddM/hQ==" "integrity": "sha512-05OLPgbgmnixJw+VvEh18yNPUo3iyp4BEWJcrLu4X9W05KmMifN7Mu5exYvQXqxxeNWhvIF+j3Rij+HmddM/hQ=="
}, },
"node_modules/rfdc": { "rfdc": {
"version": "1.3.0", "version": "1.4.1",
"resolved": "https://registry.npmmirror.com/rfdc/-/rfdc-1.3.0.tgz", "resolved": "https://registry.npmjs.org/rfdc/-/rfdc-1.4.1.tgz",
"integrity": "sha512-V2hovdzFbOi77/WajaSMXk2OLm+xNIeQdMMuB7icj7bk6zi2F8GGAxigcnDFpJHbNyNcgyJDiP+8nOrY5cZGrA==" "integrity": "sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA=="
} }
} }
} }
...@@ -24,7 +24,8 @@ page { ...@@ -24,7 +24,8 @@ page {
padding: 0 var(--fontSize23); padding: 0 var(--fontSize23);
.statistic_item { .statistic_item {
width: var(--fontSize176); // width: var(--fontSize176);
width: var(--fontSize150);
height: var(--fontSize90); height: var(--fontSize90);
opacity: 1; opacity: 1;
position: relative; position: relative;
...@@ -72,7 +73,7 @@ page { ...@@ -72,7 +73,7 @@ page {
.sub_title { .sub_title {
font-weight: 400; font-weight: 400;
color:#999999; color: #999999;
text-align: left; text-align: left;
font-size: var(--fontSize24); font-size: var(--fontSize24);
line-height: var(--fontSize34); line-height: var(--fontSize34);
...@@ -105,12 +106,14 @@ page { ...@@ -105,12 +106,14 @@ page {
margin-bottom: var(--fontSize16); margin-bottom: var(--fontSize16);
} }
} }
.date { .date {
color: #5A5E66; color: #5A5E66;
font-size: var(--fontSize25); font-size: var(--fontSize25);
flex-shrink: 0; flex-shrink: 0;
padding-bottom: var(--fontSize12); padding-bottom: var(--fontSize12);
} }
// 卡片顶部 // 卡片顶部
.card_top { .card_top {
display: flex; display: flex;
...@@ -120,10 +123,12 @@ page { ...@@ -120,10 +123,12 @@ page {
opacity: 1; opacity: 1;
background: linear-gradient(90deg, #2c66f700 0%, #2c66f70f 100%); background: linear-gradient(90deg, #2c66f700 0%, #2c66f70f 100%);
padding: var(--fontSize24) 0; padding: var(--fontSize24) 0;
&.white_bg { &.white_bg {
background: #FFFFFF; background: #FFFFFF;
padding: 0; padding: 0;
} }
.user_info { .user_info {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
...@@ -153,10 +158,12 @@ page { ...@@ -153,10 +158,12 @@ page {
display: flex; display: flex;
align-items: center; align-items: center;
padding-right: var(--fontSize16); padding-right: var(--fontSize16);
.phone_text { .phone_text {
color: #666666; color: #666666;
font-size: var(--fontSize26); font-size: var(--fontSize26);
} }
.phone_icon { .phone_icon {
width: var(--fontSize40); width: var(--fontSize40);
height: var(--fontSize40); height: var(--fontSize40);
...@@ -184,7 +191,7 @@ page { ...@@ -184,7 +191,7 @@ page {
background: #52c41a1a; background: #52c41a1a;
} }
// 人员不匹配状态 // 人员不符合状态
&.tag-mismatch { &.tag-mismatch {
color: #ff4d4f; color: #ff4d4f;
background: #ff4d4f1a; background: #ff4d4f1a;
...@@ -209,6 +216,7 @@ page { ...@@ -209,6 +216,7 @@ page {
gap: var(--fontSize8); gap: var(--fontSize8);
align-items: center; align-items: center;
margin-top: var(--fontSize8); // 推到底部 margin-top: var(--fontSize8); // 推到底部
.tag { .tag {
height: var(--fontSize40); height: var(--fontSize40);
line-height: var(--fontSize40); line-height: var(--fontSize40);
...@@ -222,6 +230,7 @@ page { ...@@ -222,6 +230,7 @@ page {
font-size: var(--fontSize24); font-size: var(--fontSize24);
color: #666666; color: #666666;
} }
.phone { .phone {
color: #666666; color: #666666;
font-size: var(--fontSize26); font-size: var(--fontSize26);
...@@ -253,9 +262,11 @@ page { ...@@ -253,9 +262,11 @@ page {
display: flex; display: flex;
line-height: 1.5; line-height: 1.5;
margin-bottom: var(--fontSize8); margin-bottom: var(--fontSize8);
&:last-child { &:last-child {
margin-bottom: 0; margin-bottom: 0;
} }
.label { .label {
color: #999999; color: #999999;
font-size: var(--fontSize26); font-size: var(--fontSize26);
...@@ -280,13 +291,17 @@ page { ...@@ -280,13 +291,17 @@ page {
.card_middle { .card_middle {
margin-bottom: var(--fontSize20); margin-bottom: var(--fontSize20);
font-size: var(--fontSize24); font-size: var(--fontSize24);
.label, .tips {
.label,
.tips {
color: #999ea8; color: #999ea8;
} }
.label { .label {
width: var(--fontSize120); width: var(--fontSize120);
flex-shrink: 0; flex-shrink: 0;
} }
.value { .value {
position: relative; position: relative;
width: 100%; width: 100%;
...@@ -294,9 +309,11 @@ page { ...@@ -294,9 +309,11 @@ page {
word-wrap: break-word; word-wrap: break-word;
word-break: break-all; word-break: break-all;
} }
.show { .show {
display: inline-block; display: inline-block;
} }
.btn-reason-all { .btn-reason-all {
position: absolute; position: absolute;
bottom: 0; bottom: 0;
...@@ -306,15 +323,18 @@ page { ...@@ -306,15 +323,18 @@ page {
background-color: #FFFFFF; background-color: #FFFFFF;
background: linear-gradient(90deg, #ffffff80 0%, #ffffff 100%); background: linear-gradient(90deg, #ffffff80 0%, #ffffff 100%);
} }
.reason-box { .reason-box {
display: flex; display: flex;
} }
} }
.card_content { .card_content {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
} }
.btn_group { .btn_group {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
...@@ -383,6 +403,21 @@ page { ...@@ -383,6 +403,21 @@ page {
margin-left: var(--fontSize20); margin-left: var(--fontSize20);
line-height: 1.5; line-height: 1.5;
} }
.ji {
display: inline-block;
width: 32rpx;
height: 32rpx;
margin-right: 10rpx;
}
.phone_icon {
display: inline-block;
width: 32rpx;
height: 32rpx;
margin-left: 10rpx;
vertical-align: middle;
}
} }
} }
} }
...@@ -449,20 +484,24 @@ page { ...@@ -449,20 +484,24 @@ page {
.radio { .radio {
display: flex; display: flex;
align-items: center; align-items: center;
&.mar-r20 { &.mar-r20 {
margin-right: var(--fontSize20); margin-right: var(--fontSize20);
} }
.cily { .cily {
width: var(--fontSize26); width: var(--fontSize26);
height: var(--fontSize26); height: var(--fontSize26);
border-radius: var(--fontSize14); border-radius: var(--fontSize14);
border: var(--fontSize2) solid #D0D2D6; border: var(--fontSize2) solid #D0D2D6;
} }
.radio-icon { .radio-icon {
flex-shrink: 0; flex-shrink: 0;
width: var(--fontSize32); width: var(--fontSize32);
height: var(--fontSize32); height: var(--fontSize32);
} }
.text { .text {
color: #222222; color: #222222;
font-size: var(--fontSize28); font-size: var(--fontSize28);
......
import Dialog from '@vant/weapp/dialog/dialog' import Dialog from '@vant/weapp/dialog/dialog'
const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/' const IMG_URL =
'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/'
import { import {
getDemandStoreListAPI, getDemandStoreListAPI,
getStaffDictListAPI, getStaffDictListAPI,
...@@ -9,7 +10,8 @@ import { ...@@ -9,7 +10,8 @@ import {
const FORM_FIELDS = { const FORM_FIELDS = {
MERCHANT: 0, // 门店 MERCHANT: 0, // 门店
QUANTITY: 2, // 招聘数量 QUANTITY: 2, // 招聘数量
DESCRIPTION: 4, // 需求描述 URGENT: 4, // 是否急招
DESCRIPTION: 5, // 需求描述
RECRUIT_TYPE: 3, // 招聘类型 RECRUIT_TYPE: 3, // 招聘类型
BUSINESS_TYPE: 1 // 业务类型 BUSINESS_TYPE: 1 // 业务类型
} }
...@@ -18,7 +20,11 @@ const VALIDATION_CONFIG = { ...@@ -18,7 +20,11 @@ const VALIDATION_CONFIG = {
[FORM_FIELDS.MERCHANT]: { tip: '请选择招聘门店', required: true }, [FORM_FIELDS.MERCHANT]: { tip: '请选择招聘门店', required: true },
[FORM_FIELDS.BUSINESS_TYPE]: { tip: '请选择业务类型', required: true }, [FORM_FIELDS.BUSINESS_TYPE]: { tip: '请选择业务类型', required: true },
[FORM_FIELDS.QUANTITY]: { tip: '请输入招聘数量', required: true }, [FORM_FIELDS.QUANTITY]: { tip: '请输入招聘数量', required: true },
[FORM_FIELDS.RECRUIT_TYPE]: { tip: '请选择招聘类型', required: true } [FORM_FIELDS.RECRUIT_TYPE]: { tip: '请选择招聘类型', required: true },
[FORM_FIELDS.DESCRIPTION]: {
tip: '请简单描述用人要求等信息',
required: false
}
} }
Page({ Page({
...@@ -29,13 +35,15 @@ Page({ ...@@ -29,13 +35,15 @@ Page({
{ id: 1, label: '业务类型', placeholder: '点击选择', options: [] }, { id: 1, label: '业务类型', placeholder: '点击选择', options: [] },
{ id: 2, label: '招聘数量', placeholder: '请输入' }, { id: 2, label: '招聘数量', placeholder: '请输入' },
{ id: 3, label: '招聘类型', placeholder: '点击选择', options: [] }, { id: 3, label: '招聘类型', placeholder: '点击选择', options: [] },
{ id: 4, label: '是否急招', value: 0 },
{ {
id: 4, id: 5,
label: '需求描述', label: '需求描述',
placeholder: '请简单描述用人要求等信息', placeholder: '请简单描述用人要求等信息',
textCount: 0 textCount: 0
} }
], ],
switch1Checked: false,
showPopup: false, showPopup: false,
currentItem: {}, currentItem: {},
currentIndex: -1, currentIndex: -1,
...@@ -47,6 +55,14 @@ Page({ ...@@ -47,6 +55,14 @@ Page({
searchTimer: null, // 防抖定时器 searchTimer: null, // 防抖定时器
isDialogShowing: false // Dialog显示状态 isDialogShowing: false // Dialog显示状态
}, },
onFormItemTap(e) {
const index = e.currentTarget.dataset.index
const item = this.data.formList && this.data.formList[index]
const id = item && item.id
// 需求描述(5)、招聘数量(2)、是否急招(4) 不需要点击弹窗
if (id === 5 || id === 2 || id === 4) return
return this.showPopup(e)
},
// 显示popup // 显示popup
async showPopup(e) { async showPopup(e) {
const index = e.currentTarget.dataset.index const index = e.currentTarget.dataset.index
...@@ -370,15 +386,57 @@ Page({ ...@@ -370,15 +386,57 @@ Page({
recruitmentQuantity: formList[FORM_FIELDS.QUANTITY].value, recruitmentQuantity: formList[FORM_FIELDS.QUANTITY].value,
recruitmentType: formList[FORM_FIELDS.RECRUIT_TYPE].value, recruitmentType: formList[FORM_FIELDS.RECRUIT_TYPE].value,
recruitmentTypeName: formList[FORM_FIELDS.RECRUIT_TYPE].displayValue, recruitmentTypeName: formList[FORM_FIELDS.RECRUIT_TYPE].displayValue,
requirementDescription: formList[FORM_FIELDS.DESCRIPTION].value || '' requirementDescription: formList[FORM_FIELDS.DESCRIPTION].value || '',
urgent: formList[FORM_FIELDS.URGENT].value
}
},
switch1Change(e) {
const checked = !!(e && e.detail && e.detail.value)
if (checked) {
// 如果是开启急招,需要弹窗确认
Dialog.confirm({
title: '提示',
message:
'申请急招,在招聘负责人推送简历后,需在24小时内完成简历跟进处理,否则将自动上报总部,请知悉!',
confirmButtonText: '确定'
})
.then(() => {
// 确认开启
this.updateUrgentStatus(true)
})
.catch(() => {
// 取消开启,需要重置开关状态
this.setData({
switch1Checked: false
})
})
} else {
// 关闭急招直接执行
this.updateUrgentStatus(false)
} }
}, },
updateUrgentStatus(checked) {
const urgent = checked ? 1 : 0
const { formList } = this.data
if (Array.isArray(formList) && formList[FORM_FIELDS.URGENT]) {
formList[FORM_FIELDS.URGENT].value = urgent
}
this.setData({
formList,
switch1Checked: checked
})
},
// 提交表单 // 提交表单
submit() { submit() {
// 验证表单 // 验证表单
if (!this.validateForm()) return if (!this.validateForm()) return
const { formList } = this.data
const isUrgent =
Array.isArray(formList) &&
formList[FORM_FIELDS.URGENT] &&
Number(formList[FORM_FIELDS.URGENT].value) === 1
// 设置Dialog显示状态为true // 设置Dialog显示状态为true
this.setData({ this.setData({
isDialogShowing: true isDialogShowing: true
...@@ -442,7 +500,7 @@ Page({ ...@@ -442,7 +500,7 @@ Page({
let { code, data } = res let { code, data } = res
if (code == 0) { if (code == 0) {
const options = data.map(item => ({ const options = data.map(item => ({
text: item.merchantName || '--', text: item.merchantName || '-',
value: item.merchantId value: item.merchantId
})) }))
// 只在非搜索模式下更新 formList(搜索时只更新临时列表) // 只在非搜索模式下更新 formList(搜索时只更新临时列表)
......
...@@ -4,12 +4,15 @@ page { ...@@ -4,12 +4,15 @@ page {
display: flex; display: flex;
background: #f7f8fa; background: #f7f8fa;
} }
.scrollarea { .scrollarea {
flex: 1; flex: 1;
overflow-y: auto; overflow-y: auto;
} }
.container { .container {
padding: 0 var(--fontSize20); padding: 0 var(--fontSize20);
.title { .title {
color: #292d33; color: #292d33;
height: var(--fontSize80); height: var(--fontSize80);
...@@ -19,6 +22,7 @@ page { ...@@ -19,6 +22,7 @@ page {
font-weight: 600; font-weight: 600;
line-height: var(--fontSize80); line-height: var(--fontSize80);
} }
.form { .form {
box-sizing: border-box; box-sizing: border-box;
min-height: var(--fontSize976); min-height: var(--fontSize976);
...@@ -27,12 +31,14 @@ page { ...@@ -27,12 +31,14 @@ page {
background: #ffffff; background: #ffffff;
box-shadow: 0 var(--fontSize4) var(--fontSize20) 0 #0000001a; box-shadow: 0 var(--fontSize4) var(--fontSize20) 0 #0000001a;
padding: 0 var(--fontSize44); padding: 0 var(--fontSize44);
.form-item { .form-item {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
height: var(--fontSize104); height: var(--fontSize104);
align-items: center; align-items: center;
font-size: var(--fontSize28); font-size: var(--fontSize28);
.required { .required {
color: #f24724; color: #f24724;
text-align: left; text-align: left;
...@@ -42,6 +48,7 @@ page { ...@@ -42,6 +48,7 @@ page {
top: var(--fontSize4); top: var(--fontSize4);
box-sizing: border-box; box-sizing: border-box;
} }
.placeholder { .placeholder {
width: var(--fontSize280); width: var(--fontSize280);
height: var(--fontSize36); height: var(--fontSize36);
...@@ -51,6 +58,7 @@ page { ...@@ -51,6 +58,7 @@ page {
text-align: right; text-align: right;
line-height: var(--fontSize36); line-height: var(--fontSize36);
} }
.display_value { .display_value {
width: var(--fontSize320); width: var(--fontSize320);
height: var(--fontSize36); height: var(--fontSize36);
...@@ -63,20 +71,65 @@ page { ...@@ -63,20 +71,65 @@ page {
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
} }
.value { .value {
display: flex; display: flex;
align-items: center; align-items: center;
switch {
transform: scale(0.67);
transform-origin: 100% 50%;
}
.wx-switch-input {
width: 140rpx !important;
height: 60rpx !important;
background: #dcdfe6 !important;
border-color: #dcdfe6 !important;
border-radius: 30rpx !important;
} }
.wx-switch-input::before {
width: 136rpx !important;
height: 56rpx !important;
background: #dcdfe6 !important;
border-radius: 28rpx !important;
}
.wx-switch-input::after {
width: 56rpx !important;
height: 56rpx !important;
border-radius: 28rpx !important;
top: 2rpx !important;
left: 2rpx !important;
}
.wx-switch-input-checked {
background: #347BFF !important;
border-color: #347BFF !important;
}
.wx-switch-input-checked::before {
background: #347BFF !important;
}
.wx-switch-input-checked::after {
transform: translateX(80rpx) !important;
}
}
.arrow_right { .arrow_right {
width: var(--fontSize32); width: var(--fontSize32);
height: var(--fontSize32); height: var(--fontSize32);
margin-left: var(--fontSize8); margin-left: var(--fontSize8);
} }
.unit { .unit {
color: #222222; color: #222222;
font-size: var(--fontSize28); font-size: var(--fontSize28);
margin-left: var(--fontSize16); margin-left: var(--fontSize16);
} }
.number-input { .number-input {
flex: 1; flex: 1;
height: var(--fontSize36); height: var(--fontSize36);
...@@ -87,19 +140,23 @@ page { ...@@ -87,19 +140,23 @@ page {
background: transparent; background: transparent;
} }
} }
.form-item-textarea { .form-item-textarea {
height: auto; height: auto;
min-height: var(--fontSize104); min-height: var(--fontSize104);
flex-direction: column; flex-direction: column;
align-items: flex-start; align-items: flex-start;
padding: var(--fontSize24) 0; padding: var(--fontSize24) 0;
.label { .label {
margin-bottom: var(--fontSize20); margin-bottom: var(--fontSize20);
} }
.textarea-wrapper { .textarea-wrapper {
width: 100%; width: 100%;
position: relative; position: relative;
} }
.textarea-input { .textarea-input {
width: 100%; width: 100%;
height: var(--fontSize440); height: var(--fontSize440);
...@@ -115,12 +172,14 @@ page { ...@@ -115,12 +172,14 @@ page {
overflow-y: scroll; overflow-y: scroll;
-webkit-overflow-scrolling: touch; -webkit-overflow-scrolling: touch;
scrollbar-width: none; scrollbar-width: none;
&::-webkit-scrollbar { &::-webkit-scrollbar {
width: 0; width: 0;
height: 0; height: 0;
display: none; display: none;
} }
} }
.textarea-count { .textarea-count {
position: absolute; position: absolute;
right: var(--fontSize16); right: var(--fontSize16);
...@@ -130,12 +189,14 @@ page { ...@@ -130,12 +189,14 @@ page {
} }
} }
} }
.footer { .footer {
margin-top:var(--fontSize200); margin-top: var(--fontSize150);
.btn { .btn {
margin:0 auto; margin: 0 auto;
width: var(--fontSize622); width: var(--fontSize622);
height:var(--fontSize88); height: var(--fontSize88);
border-radius: var(--fontSize24); border-radius: var(--fontSize24);
opacity: 1; opacity: 1;
background: #2C66F7; background: #2C66F7;
...@@ -146,6 +207,7 @@ page { ...@@ -146,6 +207,7 @@ page {
} }
} }
} }
/* popup样式 */ /* popup样式 */
.popup-content { .popup-content {
height: 100%; height: 100%;
...@@ -154,14 +216,17 @@ page { ...@@ -154,14 +216,17 @@ page {
position: relative; position: relative;
overflow: hidden; overflow: hidden;
} }
/* 设置popup顶部圆角 */ /* 设置popup顶部圆角 */
.van-popup--bottom { .van-popup--bottom {
border-radius: var(--fontSize20) var(--fontSize20) 0 0 !important; border-radius: var(--fontSize20) var(--fontSize20) 0 0 !important;
overflow: hidden; overflow: hidden;
} }
.popup-fixed-top { .popup-fixed-top {
flex: 0 0 auto; flex: 0 0 auto;
} }
.popup-fixed-bottom { .popup-fixed-bottom {
flex: 0 0 auto; flex: 0 0 auto;
padding: 0 var(--fontSize40); padding: 0 var(--fontSize40);
...@@ -188,6 +253,7 @@ page { ...@@ -188,6 +253,7 @@ page {
padding: var(--fontSize16) 0; padding: var(--fontSize16) 0;
border-bottom: var(--fontSize2) solid #eff0f2; border-bottom: var(--fontSize2) solid #eff0f2;
margin: 0 var(--fontSize40); margin: 0 var(--fontSize40);
.search-input { .search-input {
width: 100%; width: 100%;
display: flex; display: flex;
...@@ -236,9 +302,11 @@ page { ...@@ -236,9 +302,11 @@ page {
} }
} }
} }
.popup-options { .popup-options {
padding: var(--fontSize10) 0; padding: var(--fontSize10) 0;
} }
.option-item { .option-item {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
...@@ -248,15 +316,19 @@ page { ...@@ -248,15 +316,19 @@ page {
font-size: var(--fontSize28); font-size: var(--fontSize28);
} }
.option-item:active { .option-item:active {
background-color: #f2f3f5; background-color: #f2f3f5;
} }
.option-name { .option-name {
flex: 1; flex: 1;
} }
.option-item.checked .option-name { .option-item.checked .option-name {
color: #2C66F7; color: #2C66F7;
} }
.option-check { .option-check {
width: var(--fontSize40); width: var(--fontSize40);
height: var(--fontSize40); height: var(--fontSize40);
...@@ -264,6 +336,7 @@ page { ...@@ -264,6 +336,7 @@ page {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
} }
.option-check.checked { .option-check.checked {
color: #2C66F7; color: #2C66F7;
} }
...@@ -300,7 +373,8 @@ page { ...@@ -300,7 +373,8 @@ page {
padding: var(--fontSize20) 0; padding: var(--fontSize20) 0;
} }
.cancel-btn, .confirm-btn { .cancel-btn,
.confirm-btn {
width: var(--fontSize331); width: var(--fontSize331);
height: var(--fontSize80); height: var(--fontSize80);
border-radius: var(--fontSize24); border-radius: var(--fontSize24);
......
...@@ -3,22 +3,20 @@ ...@@ -3,22 +3,20 @@
<view class="container"> <view class="container">
<view class="title">请完善用人需求</view> <view class="title">请完善用人需求</view>
<view class="form"> <view class="form">
<block wx:for="{{ formList }}" wx:key="{{ index}}"> <block wx:for="{{ formList }}" wx:key="index">
<view <!-- bindtap="{{item.label === '需求描述' || item.label === '招聘数量' ? '' : 'showPopup'}}" -->
class="form-item {{ item.label === '需求描述' ? 'form-item-textarea' : '' }}" <view class="form-item {{ item.id === 5 ? 'form-item-textarea' : '' }}" bindtap="onFormItemTap" data-index="{{ index }}">
bindtap="{{item.label === '需求描述' || item.label === '招聘数量' ? '' : 'showPopup'}}"
data-index="{{ index }}"
>
<view class="label"> <view class="label">
{{item.label}} {{item.label}}
<text wx:if="{{ item.label !== '需求描述' }}" class="required">*</text> <text wx:if="{{ item.id !== 5 }}" class="required">*</text>
</view> </view>
<view class="value" wx:if="{{ item.label !== '需求描述' && item.label !== '招聘数量' }}"> <block wx:if="{{ item.id === 4 }}">
<text class="display_value" wx:if="{{ item.displayValue }}">{{item.displayValue}}</text> <view class="value">
<text class="placeholder" wx:else>{{item.placeholder}}</text> <switch checked="{{ switch1Checked }}" bindchange="switch1Change" />
<image class="arrow_right" src="/packageWorkspace/pages/image/arrow-right.png" mode="aspectFill" />
</view> </view>
<view class="value" wx:if="{{ item.label === '招聘数量' }}"> </block>
<block wx:elif="{{ item.id === 2 }}">
<view class="value">
<input <input
class="number-input" class="number-input"
type="number" type="number"
...@@ -30,8 +28,19 @@ ...@@ -30,8 +28,19 @@
/> />
<text class="unit">人</text> <text class="unit">人</text>
</view> </view>
</block>
<block wx:elif="{{ item.id === 5 }}">
<!-- 需求描述没有普通value部分 -->
</block>
<block wx:else>
<view class="value">
<text class="display_value" wx:if="{{ item.displayValue }}">{{item.displayValue}}</text>
<text class="placeholder" wx:else>{{item.placeholder}}</text>
<image class="arrow_right" src="/packageWorkspace/pages/image/arrow-right.png" mode="aspectFill" />
</view>
</block>
<block wx:if="{{ !showPopup }}"> <block wx:if="{{ !showPopup }}">
<view class="textarea-wrapper" wx:if="{{ item.label === '需求描述' }}"> <view class="textarea-wrapper" wx:if="{{ item.id === 5 }}">
<textarea <textarea
class="textarea-input" class="textarea-input"
placeholder="{{ item.placeholder }}" placeholder="{{ item.placeholder }}"
...@@ -95,7 +104,7 @@ ...@@ -95,7 +104,7 @@
> >
<view class="option-name">{{item.text}}</view> <view class="option-name">{{item.text}}</view>
<view class="option-check" wx:if="{{ item.checked }}"> <view class="option-check" wx:if="{{ item.checked }}">
<image src="{{IMG_URL}}checked.png" mode=""/> <image src="{{ IMG_URL }}checked.png" mode="" />
</view> </view>
</view> </view>
<view class="empty-tip" wx:if="{{ filteredOptions.length === 0 }}"> <view class="empty-tip" wx:if="{{ filteredOptions.length === 0 }}">
......
...@@ -28,6 +28,10 @@ export const statusList = [ ...@@ -28,6 +28,10 @@ export const statusList = [
{ {
confId: 3, confId: 3,
confName: '已驳回' confName: '已驳回'
},
{
confId: 4,
confName: '待督导确认'
} }
] ]
export const mentorshipFormData = [ export const mentorshipFormData = [
...@@ -125,22 +129,46 @@ export const statusTipConfig = { ...@@ -125,22 +129,46 @@ export const statusTipConfig = {
} }
} }
// // 获取状态提示文本
// export const getStatusTipText = function (item) {
// const config = statusTipConfig[item.status]
// if (!config || !config.show) {
// return null
// }
// // 如果有显示条件,先判断条件
// if (config.showCondition && !config.showCondition(item)) {
// return null
// }
// // 如果 text 是函数,执行函数获取文本
// if (typeof config.text === 'function') {
// return config.text(item)
// }
// return config.text
// }
// 获取状态提示文本 // 获取状态提示文本
export const getStatusTipText = function (item) { export const getStatusTipText = function (item) {
const config = statusTipConfig[item.status] const {
if (!config || !config.show) { status,
return null waitProcessResumeCount,
} confirmFlag,
trialWaitConfirmCount,
// 如果有显示条件,先判断条件 onboardingWaitConfirmCount
if (config.showCondition && !config.showCondition(item)) { } = item
return null
}
// 如果 text 是函数,执行函数获取文本 // 待处理提示文案显示逻辑
if (typeof config.text === 'function') { if (status == 1 && waitProcessResumeCount > 0) {
return config.text(item) return `您有${waitProcessResumeCount}份简历待处理,请及时跟进`
} else if (status == 1 && trialWaitConfirmCount > 0) {
return '您有新的试岗记录,请及时查看'
} else if (status == 1 && onboardingWaitConfirmCount > 0) {
return '您有新的入职记录,请及时查看'
} else if (status == 2 && confirmFlag == 'N') {
return '您的招聘需求已完成,请及时查看'
} else if (status == 3 && confirmFlag == 'N') {
return '您的招聘需求已拒绝,请及时查看'
} }
return null
return config.text
} }
...@@ -4,7 +4,8 @@ import { ...@@ -4,7 +4,8 @@ import {
getStatusTipText getStatusTipText
} from './constantData' } from './constantData'
import { getRecruitList, waitstaffstateAPI, confiremStaffFlagAPI } from '../api' import { getRecruitList, waitstaffstateAPI, confiremStaffFlagAPI } from '../api'
const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/' const IMG_URL =
'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/'
Page({ Page({
/** /**
* 页面的初始数据 * 页面的初始数据
...@@ -32,8 +33,8 @@ Page({ ...@@ -32,8 +33,8 @@ Page({
onLoad(options) { onLoad(options) {
let { mentorshipFormData } = this.data let { mentorshipFormData } = this.data
let userInfo = wx.$util.getUserInfo() let userInfo = wx.$util.getUserInfo()
this.getWaitstaffstate() // this.getWaitstaffstate()
this.search() // this.search()
// 非区域运营登录,打回到首页 // 非区域运营登录,打回到首页
//ll if (userInfo?.loginRole != 3) wx.reLaunch({ url: "/pages/loading/loading" }) //ll if (userInfo?.loginRole != 3) wx.reLaunch({ url: "/pages/loading/loading" })
if (userInfo?.isSuper) { if (userInfo?.isSuper) {
...@@ -80,6 +81,7 @@ Page({ ...@@ -80,6 +81,7 @@ Page({
// 标签切换 // 标签切换
tabClick(e) { tabClick(e) {
if (this.data.tabIndex === e.detail) return
this.setData( this.setData(
{ {
tabIndex: e.detail, tabIndex: e.detail,
...@@ -161,7 +163,7 @@ Page({ ...@@ -161,7 +163,7 @@ Page({
} }
) )
//仅已完成/以驳回可以调用flag接口 //仅已完成/以驳回可以调用flag接口
if (item.status == 0 || item.status == 1) return if (item.status == 0) return
confiremStaffFlagAPI({ id: item.id }).then(res => { confiremStaffFlagAPI({ id: item.id }).then(res => {
let { code } = res let { code } = res
if (code == 0) { if (code == 0) {
......
...@@ -97,6 +97,13 @@ page { ...@@ -97,6 +97,13 @@ page {
margin-bottom: var(--fontSize4); margin-bottom: var(--fontSize4);
justify-content: space-between; justify-content: space-between;
.ji {
display: inline-block;
width: 32rpx;
height: 32rpx;
margin-right: 10rpx;
}
.merchant-name { .merchant-name {
flex: 1; flex: 1;
min-width: 0; min-width: 0;
...@@ -121,6 +128,11 @@ page { ...@@ -121,6 +128,11 @@ page {
background: #eaf1ff; background: #eaf1ff;
} }
&.status-4 {
color: #2C66F7;
background: #eaf1ff;
}
// 招聘中 status = 1 // 招聘中 status = 1
&.status-1 { &.status-1 {
color: #ff9d0a; color: #ff9d0a;
......
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
data-item="{{ item }}" data-item="{{ item }}"
> >
<view class="item_header"> <view class="item_header">
<image wx:if="{{ item.urgent == 1 }}" class="ji" src="{{ IMG_URL }}ji.png" mode="aspectFill"></image>
<text class="merchant-name">{{item.merchantName}}</text> <text class="merchant-name">{{item.merchantName}}</text>
<text class="status-tag status-{{ item.status }}">{{item.statusName}}</text> <text class="status-tag status-{{ item.status }}">{{item.statusName}}</text>
</view> </view>
...@@ -46,7 +47,7 @@ ...@@ -46,7 +47,7 @@
</block> </block>
</view> </view>
<!-- 提示消息 --> <!-- 提示消息 -->
<view class="item_footer" wx:if="{{ tabIndex == 0 && item.showTip && item.confirmFlag == 'N' && item.status !== 0 }}"> <view class="item_footer" wx:if="{{ tabIndex == 0 && item.showTip }}">
<view class="msg_tips"> <view class="msg_tips">
<text>{{item.tipText}}</text> <text>{{item.tipText}}</text>
<image class="arrow_right" src="/packageWorkspace/pages/image/arrow-right.png" mode="aspectFill" /> <image class="arrow_right" src="/packageWorkspace/pages/image/arrow-right.png" mode="aspectFill" />
...@@ -66,7 +67,7 @@ ...@@ -66,7 +67,7 @@
</view> </view>
<!-- 添加招聘按钮 --> <!-- 添加招聘按钮 -->
<view class="insert_btn {{ btnVisible ? 'btn-visible' : 'btn-hidden' }}" bindtap="handleInsertRecruit"> <view class="insert_btn {{ btnVisible ? 'btn-visible' : 'btn-hidden' }}" bindtap="handleInsertRecruit">
<image class="insert_icon" src="{{IMG_URL}}new-recruitment.png" mode="widthFix" /> <image class="insert_icon" src="{{ IMG_URL }}new-recruitment.png" mode="widthFix" />
<view class="label"> <view class="label">
<text>新增招聘</text> <text>新增招聘</text>
</view> </view>
......
<!--tabWorkOrder/pages/residentManage/components/accountAllocation/index.wxml--> <!--tabWorkOrder/pages/residentManage/components/accountAllocation/index.wxml-->
<view class="container"> <view class="container">
<view class="search-input"> <view class="search-input">
<image src="/images/search.png" class="search-icon" /> <image src="/images/search.png" class="search-icon" />
<input type="text" placeholder="员工姓名/手机号查询" class="input" value="{{ keyword }}" placeholder-class="input-placeholder" bindinput="input" bindconfirm="search" /> <input
type="text"
placeholder="员工姓名/手机号查询"
class="input"
value="{{ keyword }}"
placeholder-class="input-placeholder"
bindinput="input"
bindconfirm="search"
/>
<block wx:if="{{ keyword }}"> <block wx:if="{{ keyword }}">
<image src="/images/clear.png" class="search-clear" bindtap="clear" /> <image src="/images/clear.png" class="search-clear" bindtap="clear" />
</block> </block>
</view> </view>
<view class="info">员工调店分配新门店账号,业务督导需要处理员工的账号管理,若旧门店账号不再使用,请禁用旧账号,请标记勾选员工所在店面</view> <view class="info">员工调店分配新门店账号,业务督导需要处理员工的账号管理,若旧门店账号不再使用,请禁用旧账号,请标记勾选员工所在店面</view>
<view class="title">账号列表<text>请勾选员工目前调岗在店的门店名称</text></view> <view class="title">
<block wx:if="{{isFlag}}"> 账号列表
<scroll-view class="account-box" style="height: calc(100vh - var(--fontSize640));" enhanced="{{true}}" show-scrollbar="{{false}}" scroll-y bindscrolltolower="mineReachBottom"> <text>请勾选员工目前调岗在店的门店名称</text>
<view class="list" wx:if="{{accountList.length>0}}"> </view>
<view class="item" wx:for="{{accountList}}" wx:key="index"> <block wx:if="{{ isFlag }}">
<scroll-view
class="account-box"
style="height: calc(100vh - var(--fontSize640));"
enhanced="{{ true }}"
show-scrollbar="{{ false }}"
scroll-y
bindscrolltolower="mineReachBottom"
>
<view class="list" wx:if="{{ accountList.length>0 }}">
<view class="item" wx:for="{{ accountList }}" wx:key="index">
<view class="header"> <view class="header">
<view class="left"> <view class="left">
<view class="name"><view class="staff">{{item.staffName}}</view><text>{{item.staffPhone}}</text></view> <view class="name">
<view class="staff">{{item.staffName}}</view>
<text>{{item.staffPhone}}</text>
</view>
<view class="tags"> <view class="tags">
<view class="tag" wx:for="{{item.labelArr}}" wx:for-item="tag" wx:for-index="key" wx:key="key">{{businessType[tag]}}</view> <view class="tag" wx:for="{{ item.labelArr }}" wx:for-item="tag" wx:for-index="key" wx:key="key">{{businessType[tag]}}</view>
</view> </view>
</view> </view>
<view class="right" bind:tap="goToStaff" data-index="{{index}}">新增员工账号</view> <view class="right" bind:tap="goToStaff" data-index="{{ index }}">新增员工账号</view>
</view> </view>
<view class="item-content"> <view class="item-content">
<view class="content-account" wx:for="{{item.staffAccountList}}" wx:for-item="account" wx:for-index="i" wx:key="i"> <view class="content-account" wx:for="{{ item.staffAccountList }}" wx:for-item="account" wx:for-index="i" wx:key="i">
<view class="account-header"> <view class="account-header">
<view class="park-name">账号{{i+1}}<view class="yqMerchant-box"><view class="text-hide">{{account.yqMerchantName}}</view>{{account.yqMerchantId}}</view></view> <view class="park-name">
账号{{i+1}}
<view class="yqMerchant-box">
<view class="text-hide">{{account.yqMerchantName}}</view>
{{account.yqMerchantId}}
</view>
</view>
<view class="operation"> <view class="operation">
<van-switch
<van-switch class="active-switch" checked="{{ account.deletedState }}" active-color="#2C66F7" inactive-color="#D0D2D6" data-index="{{index}}" data-account-index="{{i}}" bind:change="onChange" size="25px" /> class="active-switch"
checked="{{ account.deletedState }}"
active-color="#2C66F7"
inactive-color="#D0D2D6"
data-index="{{ index }}"
data-account-index="{{ i }}"
bind:change="onChange"
size="25px"
/>
<view class="switch-text"> <view class="switch-text">
<view class="active" wx:if="{{ account.deletedState}}">启用</view> <view class="active" wx:if="{{ account.deletedState }}">启用</view>
<view class="disabled" wx:else>禁用</view> <view class="disabled" wx:else>禁用</view>
</view> </view>
</view> </view>
</view> </view>
<view class="store-list"> <view class="store-list">
<view class="store" wx:for="{{account.unfold?account.checkList:account.staffConfigList}}" wx:for-item="store" wx:for-index="s" wx:key="s"> <view
class="store"
wx:for="{{ account.unfold?account.checkList:account.staffConfigList }}"
wx:for-item="store"
wx:for-index="s"
wx:key="s"
>
<view class="choose"> <view class="choose">
<view class="choose-open" wx:if="{{ account.deletedState}}" catch:tap="updateConfig" data-index="{{index}}" data-account-index="{{i}}" data-store-index="{{s}}"> <view
class="choose-open"
wx:if="{{ account.deletedState }}"
catch:tap="updateConfig"
data-index="{{ index }}"
data-account-index="{{ i }}"
data-store-index="{{ s }}"
>
<!-- <gl-image webp mode="widthFix" wx:if="{{store.deferredOpenState}}" class="select" src="/check.png" /> --> <!-- <gl-image webp mode="widthFix" wx:if="{{store.deferredOpenState}}" class="select" src="/check.png" /> -->
<image mode="widthFix" wx:if="{{store.deferredOpenState}}" class="select" src="{{IMG_URL2}}checkbox-checked.png" /> <image mode="widthFix" wx:if="{{ store.deferredOpenState }}" class="select" src="{{ IMG_URL2 }}checkbox-checked.png" />
<gl-image webp mode="widthFix" wx:else class="select" src="/no-check.png" /> <gl-image webp mode="widthFix" wx:else class="select" src="/no-check.png" />
</view> </view>
<view class="choose-open" wx:else> <view class="choose-open" wx:else>
<gl-image webp mode="widthFix" wx:if="{{store.deferredOpenState}}" class="select" src="/dis-check.png" /> <gl-image webp mode="widthFix" wx:if="{{ store.deferredOpenState }}" class="select" src="/dis-check.png" />
<gl-image webp mode="widthFix" wx:else class="select" src="/no-dis-check.png" /> <gl-image webp mode="widthFix" wx:else class="select" src="/no-dis-check.png" />
</view> </view>
</view> </view>
<view class="store-info"> <view class="store-info">
<view class="name"><view class="text-hide">{{store.merchantName}}</view>{{store.merchantId}}</view> <view class="name">
<view class="time" wx:if="{{store.startEffectiveTime}}">生效时间:{{store.startEffectiveTime?store.startEffectiveTime:'--'}}</view> <view class="text-hide">{{store.merchantName}}</view>
{{store.merchantId}}
</view>
<view class="time" wx:if="{{ store.startEffectiveTime }}">生效时间:{{store.startEffectiveTime?store.startEffectiveTime:'-'}}</view>
</view> </view>
</view> </view>
</view> </view>
<block wx:if="{{account.unfold}}"> <block wx:if="{{ account.unfold }}">
<view class="more" catchtap="packupList" data-index="{{index}}" data-account-index="{{i}}">查看员工更多可登录4s店 <view class="pack-up"> <view class="more" catchtap="packupList" data-index="{{ index }}" data-account-index="{{ i }}">
<image src="{{IMG_URL}}arrow.png" /> 查看员工更多可登录4s店
<view class="pack-up">
<image src="{{ IMG_URL }}arrow.png" />
</view> </view>
</view> </view>
</block> </block>
<block wx:else> <block wx:else>
<view class="more" catchtap="packupList" data-index="{{index}}" data-account-index="{{i}}">折叠无效非在岗门店 <view class="pack-up down"> <view class="more" catchtap="packupList" data-index="{{ index }}" data-account-index="{{ i }}">
<image src="{{IMG_URL}}arrow.png" /> 折叠无效非在岗门店
<view class="pack-up down">
<image src="{{ IMG_URL }}arrow.png" />
</view> </view>
</view> </view>
</block> </block>
</view> </view>
</view> </view>
</view> </view>
<block wx:if="{{nothing}}"> <block wx:if="{{ nothing }}">
<view class="list-nothing">到底了~</view> <view class="list-nothing">到底了~</view>
</block> </block>
</view> </view>
...@@ -80,10 +133,23 @@ ...@@ -80,10 +133,23 @@
</view> </view>
</scroll-view> </scroll-view>
</block> </block>
</view> </view>
<dialog show="{{showModal}}" confirmText="确定" cancelText="取消" showCancelButton success="{{success}}" bindconfirm="dialogConfirm" bindcancel="dialogClose" text="{{dialogText}}">
</dialog>
<time-picker show="{{showTimeModal}}" confirmText="确定" cancelText="取消" showCancelButton success="{{success}}" bindconfirm="timeConfirm" bindcancel="dialogTimeClose"></time-picker>
\ No newline at end of file \ No newline at end of file
<dialog
show="{{ showModal }}"
confirmText="确定"
cancelText="取消"
showCancelButton
success="{{ success }}"
bindconfirm="dialogConfirm"
bindcancel="dialogClose"
text="{{ dialogText }}"
></dialog>
<time-picker
show="{{ showTimeModal }}"
confirmText="确定"
cancelText="取消"
showCancelButton
success="{{ success }}"
bindconfirm="timeConfirm"
bindcancel="dialogTimeClose"
></time-picker>
\ No newline at end of file \ No newline at end of file
Component({
properties: {
year: {
type: Number,
value: new Date().getFullYear()
},
selectedMonth: {
type: Number,
value: new Date().getMonth() + 1
},
monthList: {
type: Array,
value: [] // 数组结构:{ month: 1, disabled: false, hasSubmit: true }
}
},
data: {
showNextYear: true
},
observers: {
'year': function(year) {
const currentYear = new Date().getFullYear();
this.setData({
showNextYear: year < currentYear
});
}
},
methods: {
lastYear() {
this.triggerEvent('lastYear')
},
nextYear() {
this.triggerEvent('nextYear')
},
itemClick(e) {
const { index, disabled } = e.currentTarget.dataset
if (disabled) return
this.triggerEvent('monthClick', { month: index + 1 })
}
}
})
\ 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
<view class="line"></view>
<view class="row year-select">
<view class="row last-year" bindtap="lastYear">
<gl-image class="icon left" src="{{ '/miniProgram/arrow-left.png' }}" webp></gl-image>
<view>上一年</view>
</view>
<view class="timeType">{{year}}年</view>
<view class="row next-year" bindtap="nextYear" style="visibility: {{showNextYear ? 'visible' : 'hidden'}}">
<!-- 下一年 -->
<view style="">下一年</view>
<gl-image class="icon right" src="{{ '/miniProgram/arrow-right.png' }}" webp></gl-image>
</view>
</view>
<scroll-view class="month-scroll" scroll-x="{{true}}" scroll-into-view="month-{{selectedMonth > 2 ? selectedMonth - 2 : 0}}">
<view class="month-container">
<block wx:for="{{monthList}}" wx:key="index">
<view
id="month-{{index}}"
class="month-item {{item.month == selectedMonth ? 'selected' : ''}} {{item.disabled ? 'disabled' : ''}}"
bindtap="itemClick"
data-index="{{index}}"
data-disabled="{{item.disabled}}"
>
<view class="month-text">{{item.month}}月</view>
<view class="empty-badge" wx:if="{{!item.hasSubmit && !item.disabled}}">空</view>
</view>
</block>
</view>
</scroll-view>
\ No newline at end of file \ No newline at end of file
.row {
display: flex;
flex-direction: column;
justify-content: space-around;
align-items: center;
background: #fff;
}
.year-select {
height: 80rpx;
flex-direction: row;
justify-content: space-between;
padding: 0 30rpx;
}
.last-year,
.next-year {
flex-direction: row;
font-size: 28rpx;
color: #666;
}
.icon {
width: 30rpx;
height: 30rpx;
}
.left {
margin-right: 10rpx;
}
.right {
margin-left: 10rpx;
}
.timeType {
font-size: 32rpx;
font-weight: 500;
color: #333;
}
.month-scroll {
width: 100%;
white-space: nowrap;
background: #fff;
}
.month-container {
display: flex;
padding: 40rpx 20rpx 20rpx 20rpx;
}
.month-item {
box-sizing: border-box;
padding: 20rpx 20rpx;
display: inline-flex;
flex-direction: column;
align-items: center;
justify-content: center;
width: 111rpx;
height: 64rpx;
margin: 0 10rpx;
border-radius: 364rpx;
position: relative;
flex-shrink: 0;
}
.month-text {
font-size: 30rpx;
color: #333;
}
.month-item.selected {
background-color: #347BFF;
}
.month-item.selected .month-text {
color: #fff;
}
.month-item.disabled .month-text {
color: #ccc;
}
.empty-badge {
position: absolute;
top: 0;
right: 0;
background-color: #F24724;
color: #fff;
height: 32rpx;
line-height: 32rpx;
font-size: 22rpx;
padding: 2rpx 6rpx;
border-radius: 16rpx;
transform: translate(30%, -30%);
z-index: 10;
white-space: nowrap;
}
\ No newline at end of file \ No newline at end of file
Component({
properties: {
year: {
type: Number,
value: new Date().getFullYear()
},
month: {
type: Number,
value: new Date().getMonth() + 1
},
selectedWeek: {
type: Number,
value: 1
},
weekList: {
type: Array,
value: [] // 数组结构:{ week: 1, label: '12月第1周', disabled: false, hasSubmit: true }
}
},
data: {
showNextMonth: true
},
observers: {
'year, month': function(year, month) {
const now = new Date();
const currentYear = now.getFullYear();
const currentMonth = now.getMonth() + 1;
let showNextMonth = true;
if (year > currentYear) {
showNextMonth = false;
} else if (year === currentYear && month >= currentMonth) {
showNextMonth = false;
}
this.setData({
showNextMonth
});
}
},
methods: {
lastMonth() {
this.triggerEvent('lastMonth')
},
nextMonth() {
this.triggerEvent('nextMonth')
},
itemClick(e) {
const { week, disabled } = e.currentTarget.dataset
if (disabled) return
this.triggerEvent('weekClick', { week: week })
}
}
})
\ 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
<view class="line"></view>
<view class="row year-select">
<view class="row last-year" bindtap="lastMonth">
<gl-image class="icon left" src="{{ '/miniProgram/arrow-left.png' }}" webp></gl-image>
<view>上个月</view>
</view>
<view class="timeType">{{year}}-{{month < 10 ? '0' + month : month}}</view>
<view class="row next-year" bindtap="nextMonth" style="visibility: {{showNextMonth ? 'visible' : 'hidden'}}">
<!-- 下一个月 -->
<view style="">下个月</view>
<gl-image class="icon right" src="{{ '/miniProgram/arrow-right.png' }}" webp></gl-image>
</view>
</view>
<scroll-view class="month-scroll" scroll-x="{{true}}" scroll-into-view="week-{{selectedWeek > 1 ? selectedWeek - 1 : 0}}">
<view class="month-container">
<block wx:for="{{weekList}}" wx:key="index">
<view
id="week-{{index}}"
class="month-item {{item.week == selectedWeek ? 'selected' : ''}} {{item.disabled ? 'disabled' : ''}}"
bindtap="itemClick"
data-index="{{index}}"
data-week="{{item.week}}"
data-disabled="{{item.disabled}}"
>
<view class="month-text">{{item.label}}</view>
<view class="empty-badge" wx:if="{{!item.hasSubmit && !item.disabled}}">空</view>
</view>
</block>
</view>
</scroll-view>
\ No newline at end of file \ No newline at end of file
.row {
display: flex;
flex-direction: column;
justify-content: space-around;
align-items: center;
background: #fff;
}
.line {
height: 1rpx;
width: 100%;
background-color: gainsboro;
}
.year-select {
height: 80rpx;
flex-direction: row;
justify-content: space-between;
padding: 0 30rpx;
}
.last-year,
.next-year {
flex-direction: row;
font-size: 28rpx;
color: #181A1F;
align-items: center;
}
.icon {
width: 36rpx;
height: 36rpx;
}
.left {
margin-right: 10rpx;
}
.left {
margin-left: 10rpx;
}
.right {
margin-right: 10rpx;
}
.timeType {
font-family: PingFangSC-Medium;
font-weight: 500;
font-size: 28rpx;
color: #181A1F;
width: 280rpx;
height: 64rpx;
text-align: center;
line-height: 64rpx;
border-radius: 20px;
background: #f2f3f5;
}
.month-scroll {
width: 100%;
white-space: nowrap;
background: #fff;
padding-top: 12rpx;
/* padding: 30rpx 0; */
}
.month-container {
display: flex;
padding: 15rpx 30rpx 30rpx 30rpx;
}
.month-item {
box-sizing: border-box;
padding: 10rpx 20rpx;
display: inline-flex;
flex-direction: column;
align-items: center;
justify-content: center;
/* width: 160rpx; */
min-width: 180rpx;
height: 64rpx;
margin: 0 10rpx;
border-radius: 364rpx;
position: relative;
flex-shrink: 0;
}
.month-text {
font-size: 28rpx;
color: #292D33;
}
.month-item.selected {
background-color: #347BFF;
}
.month-item.selected .month-text {
color: #fff;
}
.month-item.disabled .month-text {
color: #BEC1C7;
}
.empty-badge {
position: absolute;
top: 0;
right: 0;
background-color: #F24724;
color: #fff;
height: 32rpx;
line-height: 32rpx;
font-size: 22rpx;
padding: 2rpx 6rpx;
border-radius: 16rpx;
transform: translate(30%, -30%);
z-index: 10;
white-space: nowrap;
}
\ No newline at end of file \ No newline at end of file
// 日报/周报/月报 首次填写,默认填入的字段数据结构
export const reportFirstAutoObj = {
/** 1.1轻改区域日报模版 */
'qinggai-temp-001': {
/** 精品升级 - 角色 userInfo.userType == 2 && !(userInfo.isSuper|| userInfo.loginRole ==3),取值valueObj
* 精品升级 - 其余角色,取值valueObj
* 权益 - 取值valueObj
* */
list: [{
attrName: 'todayRegionalTotalOutput',
// 今日产值
valueObj: 'staffTodayTotal',
ortherValueObj: 'merchantTodayTotal',
}, {
attrName: 'monthRegionalTotalOutput',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}],
},
/** 2.3延保区域日报模版 */
'uuid-temp-001': {
list: [{
attrName: 'dailyCumulativeAchievement',
// 今日产值
valueObj: 'staffTodayTotal',
ortherValueObj: 'merchantTodayTotal',
}, {
attrName: 'monthlyCumulativeAchievement',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 2.1权益区域日报模版 */
'uuid-temp-011': {
list: [{
attrName: 'dailyCumulativeAchievement',
// 今日产值
valueObj: 'staffTodayTotal',
ortherValueObj: 'merchantTodayTotal',
}, {
attrName: 'monthlyCumulativeAchievement',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 2.1区域经理周报模版 */
'uuid-temp-012': {
list: [{
attrName: 'monthlyStoreCumulativeAchievement012',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 1.1区域经理周报模版 */
'uuid-temp-013': {
list: [{
attrName: 'monthlyStoreCumulativeAchievement013',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 2.3区域经理周报模版 */
'uuid-temp-014': {
list: [{
attrName: 'monthlyStoreCumulativeAchievement014',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 2.1运营主管周报模版 */
'uuid-temp-015': {
list: [{
attrName: 'monthlyOutput015',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 1.1运营主管周报模版 */
'uuid-temp-016': {
list: [{
attrName: 'monthlyOutput016',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 2.3运营主管周报模版 */
'uuid-temp-017': {
list: [{
attrName: 'monthlyOutput017',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 1.1区域经理月报模版 */
'uuid-temp-018': {
list: [{
attrName: 'actualAchievement018',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 2.1区域经理月报模版 */
'uuid-temp-019': {
list: [{
attrName: 'actualAchievement019',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 2.3区域经理月报模版 */
'uuid-temp-020': {
list: [{
attrName: 'actualAchievement020',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 2.1运营主管月报模版 */
'uuid-temp-021': {
list: [{
attrName: 'monthlyOutput021',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 1.1运营主管月报模版 */
'uuid-temp-022': {
list: [{
attrName: 'monthlyOutput022',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
},
/** 2.3运营主管月报模版 */
'uuid-temp-023': {
list: [{
attrName: 'monthlyOutput023',
// 本月产值
valueObj: 'staffMonthTotal',
ortherValueObj: 'merchantMonthTotal',
}]
}
}
\ No newline at end of file \ No newline at end of file
...@@ -4,6 +4,8 @@ ...@@ -4,6 +4,8 @@
"van-overlay": "@vant/weapp/overlay/index", "van-overlay": "@vant/weapp/overlay/index",
"weekCalendar": "./components/weekCalendar/weekCalendar", "weekCalendar": "./components/weekCalendar/weekCalendar",
"select-item-popup": "./components/selectItemPopup/selectItemPopup", "select-item-popup": "./components/selectItemPopup/selectItemPopup",
"select-popup": "./components/selectPopup/selectPopup" "select-popup": "./components/selectPopup/selectPopup",
"monthCalendar": "./components/monthCalendar/monthCalendar",
"weeklyCalendar": "./components/weeklyCalendar/weeklyCalendar"
}
} }
\ No newline at end of file \ No newline at end of file
}
\ No newline at end of file \ No newline at end of file
...@@ -70,7 +70,7 @@ page { ...@@ -70,7 +70,7 @@ page {
} }
.tab-item.active { .tab-item.active {
color: #2C66F7; color: #347bff;
} }
.tab-item.active::after { .tab-item.active::after {
position: absolute; position: absolute;
...@@ -79,7 +79,7 @@ page { ...@@ -79,7 +79,7 @@ page {
transform: translateX(-50%); transform: translateX(-50%);
width: 64rpx; width: 64rpx;
height: var(--fontSize4); height: var(--fontSize4);
background-color: #2C66F7; background-color: #347BFF;
content: ''; content: '';
} }
} }
...@@ -111,7 +111,7 @@ page { ...@@ -111,7 +111,7 @@ page {
margin-bottom: 8rpx; margin-bottom: 8rpx;
} }
.example-btn { .example-btn {
color: #2C66F7; color: #347bff;
font-size: 24rpx; font-size: 24rpx;
margin-left: 8rpx; margin-left: 8rpx;
} }
...@@ -165,8 +165,8 @@ page { ...@@ -165,8 +165,8 @@ page {
text-align: center; text-align: center;
font-size: var(--fontSize32); font-size: var(--fontSize32);
color: #FFFFFF; color: #FFFFFF;
background: #2C66F7; background: #347BFF;
border-radius: var(--fontSize24); border-radius: var(--fontSize12);
margin: var(--fontSize126) var(--fontSize64) var(--fontSize20); margin: var(--fontSize126) var(--fontSize64) var(--fontSize20);
} }
...@@ -237,7 +237,7 @@ page { ...@@ -237,7 +237,7 @@ page {
.btns .btns-con view { .btns .btns-con view {
border: var(--fontSize2) solid #0075F9; border: var(--fontSize2) solid #0075F9;
border-radius: var(--fontSize24); border-radius: var(--fontSize12);
height: var(--fontSize80); height: var(--fontSize80);
box-sizing: border-box; box-sizing: border-box;
} }
...@@ -251,11 +251,11 @@ page { ...@@ -251,11 +251,11 @@ page {
.btns.two-btns .btns-con view { .btns.two-btns .btns-con view {
width: 45%; width: 45%;
border: var(--fontSize2) solid #0075F9; border: var(--fontSize2) solid #0075F9;
border-radius: var(--fontSize24); border-radius: var(--fontSize12);
height: var(--fontSize80); height: var(--fontSize80);
box-sizing: border-box; box-sizing: border-box;
color: #fff; color: #fff;
background-color: #2C66F7; background-color: #347BFF;
} }
.btns-con .cancel { .btns-con .cancel {
...@@ -266,7 +266,7 @@ page { ...@@ -266,7 +266,7 @@ page {
.confirm { .confirm {
border: var(--fontSize2) solid #0075F9; border: var(--fontSize2) solid #0075F9;
border-radius: var(--fontSize24); border-radius: var(--fontSize12);
height: var(--fontSize80); height: var(--fontSize80);
box-sizing: border-box; box-sizing: border-box;
} }
...@@ -275,5 +275,5 @@ page { ...@@ -275,5 +275,5 @@ page {
// width: var(--fontSize480); // width: var(--fontSize480);
width: 100%; width: 100%;
color: #fff; color: #fff;
background-color: #2C66F7; background-color: #347BFF;
} }
\ No newline at end of file \ No newline at end of file
...@@ -6,7 +6,9 @@ ...@@ -6,7 +6,9 @@
</view> </view>
</navigation-bar> </navigation-bar>
<view style="margin-top:{{ navBarHeight }}px"> <view style="margin-top:{{ navBarHeight }}px">
<weekCalendar timeBean="{{ timeBean }}" bind:lastWeek="lastWeek" bind:nextWeek="nextWeek" bind:dayClick="dayClick"></weekCalendar> <weekCalendar wx:if="{{ !routeParams.reportTypeAttr || routeParams.reportTypeAttr == 'daily' }}" timeBean="{{ timeBean }}" bind:lastWeek="lastWeek" bind:nextWeek="nextWeek" bind:dayClick="dayClick"></weekCalendar>
<monthCalendar wx:if="{{ routeParams.reportTypeAttr == 'monthly' }}" year="{{ currentYear }}" selectedMonth="{{ selectedMonth }}" monthList="{{ monthList }}" bind:lastYear="onLastYear" bind:nextYear="onNextYear" bind:monthClick="onMonthClick"></monthCalendar>
<weeklyCalendar wx:if="{{ routeParams.reportTypeAttr == 'weekly' }}" year="{{ currentYear }}" month="{{ selectedMonth }}" selectedWeek="{{ selectedWeek }}" weekList="{{ weekList }}" bind:lastMonth="onLastMonth" bind:nextMonth="onNextMonth" bind:weekClick="onWeekClick"></weeklyCalendar>
</view> </view>
<view class="main {{ isFullSucreen ? 'isFullSucreen':'' }}"> <view class="main {{ isFullSucreen ? 'isFullSucreen':'' }}">
<view wx:if="{{tmlpInitData.length}}" style="margin-bottom: 100px;"> <view wx:if="{{tmlpInitData.length}}" style="margin-bottom: 100px;">
......
...@@ -2,7 +2,8 @@ ...@@ -2,7 +2,8 @@
const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/' const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/'
import { import {
getWaitAuditCountAPI, getWaitAuditCountAPI,
waitstaffstateAPI waitstaffstateAPI,
getStaffTemplate
} from '~/api/api' } from '~/api/api'
Page({ Page({
...@@ -25,18 +26,26 @@ Page({ ...@@ -25,18 +26,26 @@ Page({
icon: "resident-manage", icon: "resident-manage",
trackingCode: 'regional-assistant-resident-manage' trackingCode: 'regional-assistant-resident-manage'
}, { }, {
name: "轻改区域日报", name: "工作日报",
url: "packageWorkspace.supervisorDaily", url: "packageWorkspace.supervisorDaily",
icon: "modifications-supervisor-daily", icon: "warranty-supervisor-daily",
params: { reportTypeAttr: 'daily',
templateCode: 'qinggai-temp-001' reportTypeVal: '1',
},
trackingCode: 'regional-modifications-supervisor-daily' trackingCode: 'regional-modifications-supervisor-daily'
}, { }, {
name: "延保区域日报", name: "工作周报",
url: "packageWorkspace.supervisorDaily", url: "packageWorkspace.supervisorDaily",
icon: "warranty-supervisor-daily", icon: "modifications-supervisor-week",
trackingCode: 'regional-warranty-supervisor-daily' reportTypeAttr: 'weekly',
reportTypeVal: '2',
trackingCode: 'regional-modifications-supervisor-daily'
}, {
name: "工作月报",
url: "packageWorkspace.supervisorDaily",
icon: "modifications-supervisor-month",
reportTypeAttr: 'monthly',
reportTypeVal: '3',
trackingCode: 'regional-modifications-supervisor-daily'
}], }],
staffDevelopmentMenus: [{ staffDevelopmentMenus: [{
name: "招聘管理", name: "招聘管理",
...@@ -49,7 +58,10 @@ Page({ ...@@ -49,7 +58,10 @@ Page({
url: "packageWorkspace.talentAnalysis", url: "packageWorkspace.talentAnalysis",
icon: "talent-analysis", icon: "talent-analysis",
trackingCode: 'regional-assistant-talent-analysis' trackingCode: 'regional-assistant-talent-analysis'
}] }],
showReportPopup: false,
reportTemplateList: [],
currentReportItem: null,
}, },
/** /**
...@@ -79,6 +91,32 @@ Page({ ...@@ -79,6 +91,32 @@ Page({
}) })
}, },
onReportPopupCancel() {
this.setData({
showReportPopup: false,
});
},
onReportPopupSelect(e) {
const selectedTemplate = e.detail;
this.setData({
showReportPopup: false,
});
console.log(selectedTemplate, 'selectedTemplate---')
const item = this.data.currentReportItem;
if (!item) return;
// Merge params
const params = {
// ...(item.params || {}),
reportTypeAttr: item.reportTypeAttr,
...(selectedTemplate || {}),
};
wx.$router.go(item.url, {
params: params,
});
},
/** /**
* 生命周期函数--监听页面显示 * 生命周期函数--监听页面显示
*/ */
...@@ -142,7 +180,7 @@ Page({ ...@@ -142,7 +180,7 @@ Page({
data data
} = result } = result
if (code == 0) { if (code == 0) {
console.log("调统计招聘",data); console.log("调统计招聘", data);
this.setData({ this.setData({
[`staffDevelopmentMenus[${index}].tipsNum`]: data.waitProcessCount [`staffDevelopmentMenus[${index}].tipsNum`]: data.waitProcessCount
}) })
...@@ -159,8 +197,37 @@ Page({ ...@@ -159,8 +197,37 @@ Page({
this.throttledJump(e); // 调用节流后的函数 this.throttledJump(e); // 调用节流后的函数
}, },
openWorkReportTemp(targetItem) {
const tipTxtObj = {
'daily': '暂无可填日报模版,请找总部运营配置',
'weekly': '暂无可填周报模版,请找总部运营配置',
'monthly': '暂无可填月报模版,请找总部运营配置'
}
getStaffTemplate({ reportType: targetItem.reportTypeVal }).then(res => {
let { code, data } = res
console.log(data)
if (!data.length) {
wx.$util.showToast(tipTxtObj[targetItem.reportTypeAttr])
return
}
if (code == 0) {
this.setData({
showReportPopup: true,
reportTemplateList: data,
currentReportItem: targetItem || null
});
}
})
},
jumpTo(e) { jumpTo(e) {
let { url, query, trackingCode, params } = e.currentTarget.dataset.target let { url, query, trackingCode, params } = e.currentTarget.dataset.target
let item = e.currentTarget.dataset.target
console.log(item, '00000')
if (item.url == "packageWorkspace.supervisorDaily") {
this.openWorkReportTemp(item)
return;
}
let userInfo = wx.$util.getUserInfo() let userInfo = wx.$util.getUserInfo()
// 埋点 // 埋点
wx.$track.setTrackData(0, trackingCode, {}, '', userInfo?.sceneType) wx.$track.setTrackData(0, trackingCode, {}, '', userInfo?.sceneType)
......
{ {
"usingComponents": {}, "usingComponents": {
"report-template-popup": "/components/report-template-popup/report-template-popup"
},
"navigationStyle": "custom" "navigationStyle": "custom"
} }
\ No newline at end of file \ No newline at end of file
...@@ -44,4 +44,10 @@ ...@@ -44,4 +44,10 @@
</view> </view>
</view> </view>
<report-template-popup
show="{{showReportPopup}}"
templateList="{{reportTemplateList}}"
bind:cancel="onReportPopupCancel"
bind:select="onReportPopupSelect"
/>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!