Commit bbd9f6a3 by 张立顺

Merge branch 'SAAS+V5.5.2' into 'SAAS+v5.5.3'

fix bug

See merge request !4
2 parents 05c35287 53f270e8
{ {
"name": "regional-assistant", "name": "dj-car-boutique-work-wechat",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
......
// packageEquity/pages/recruitManage/pages/recruitDetail/recruitDetail.js
import { unix } from 'dayjs'
import { getRecruitDetailAPI, processResumeAPI } from '../api'
const IMG_URL =
'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/'
// 统计列表配置映射
const STATISTICS_CONFIG = [
{ title: '需求数量', field: 'recruitmentQuantity' },
{ title: '投递简历数', field: 'resumeCount' },
{ title: '处理简历数', field: 'processResumeCount' },
{ title: '试岗人数', field: 'trialOnboardingCount' },
{ title: '入职人数', field: 'entryCount' }
]
// 入职计划卡片字段配置
const ONBOARDING_FIELDS_CONFIG = [
{ label: '性格', field: 'personalityName' },
{ label: '能力表现', field: 'abilityPerformanceName' },
{ label: '学历', field: 'educationLevelName' },
{ label: '形象', field: 'appearanceName' },
{ label: '岗位匹配度', field: 'positionMatchDegreeName' }
]
// 招聘信息字段配置
const RECRUITMENT_INFO_CONFIG = [
{ label: '门店名称', field: 'merchantName' },
{ label: '业务类型', field: 'businessTypeName' },
{ label: '招聘类型', field: 'recruitmentTypeName' },
{ label: '需求描述', field: 'requirementDescription' },
{ label: '招聘负责人', field: 'recruiterName' },
{ label: '技术督导', field: 'technicalSupervisorName' },
{ label: '申请时间', field: 'createdDate' },
{ label: '拒绝理由', field: 'recallReason' }
]
// 招聘状态映射配置
const RECRUIT_STATUS_CONFIG = {
// mixResult状态映射
0: { text: '待处理', class: 'pending', canProcess: true },
1: { text: '人员不符合', class: 'mismatch', canProcess: false },
2: { text: '面试通过', class: 'pass', canProcess: false },
3: { text: '面试不通过', class: 'fail', canProcess: false }
}
Page({
/**
* 格式化时间戳为 YYYY-MM-DD 格式
*/
formatDate(timestamp) {
if (!timestamp) return ''
const date = new Date(timestamp)
const year = date.getFullYear()
const month = String(date.getMonth() + 1).padStart(2, '0')
const day = String(date.getDate()).padStart(2, '0')
return `${year}-${month}-${day}`
},
/**
* 获取招聘状态信息
*/
getRecruitStatus(mixResult) {
return RECRUIT_STATUS_CONFIG[mixResult] || RECRUIT_STATUS_CONFIG[0]
},
/**
* 页面的初始数据
*/
data: {
IMG_URL,
reasonMaxLen: 37,
item: {},
recruitment: [],
statisticsList: [],
onboardingPlans: [],
recruitmentPlans: [],
trialOnboardingPlans: [],
recruitmentInfoConfig: RECRUITMENT_INFO_CONFIG,
onboardingFieldsConfig: ONBOARDING_FIELDS_CONFIG,
handleShowMessagePop: false, // 控制弹窗显示
timeShow: false, // 控制时间选择器显示
currentDate: new Date().getTime(),
today: new Date().getTime(), // 当前日期,用于限制日期选择器的最大值
formData: {}, // 弹窗表单数据
detailLoaded: false, // 标识是否已加载详情
curDataId: '',
isProcessing: false, // 是否正在处理中,防止重复提交
pageScrollTop: 0, // 保存页面滚动位置
// 时间选择器列表子项展示-格式化处理
formatter(type, value) {
if (type === 'year') {
return `${value}年`
}
if (type === 'month') {
return `${value}月`
}
if (type === 'day') {
return `${value}日`
}
return value
}
},
/**
* 显示时间选择器
*/
showTimePicker(e) {
if (e) {
e.stopPropagation && e.stopPropagation()
}
// 保存当前页面滚动位置(如果还没保存的话)
if (!this.data.pageScrollTop) {
const query = wx.createSelectorQuery()
query.selectViewport().scrollOffset()
query.exec(res => {
if (res && res[0]) {
this.setData({
pageScrollTop: res[0].scrollTop
})
}
})
}
// 重置为当前日期
this.setData({
timeShow: true,
currentDate: new Date().getTime()
})
},
/**
* 确认选择时间
*/
bindDateChange(event) {
const timestamp = event.detail
const date = new Date(timestamp)
const year = date.getFullYear()
const month = String(date.getMonth() + 1).padStart(2, '0')
const day = String(date.getDate()).padStart(2, '0')
const formattedDate = `${year}年${month}月${day}日`
const formattedFull = new Date(timestamp)
const { formData, pageScrollTop } = this.data
formData.interviewTime = `${year}-${month}-${day} 00:00:00`
formData.dipalyTime = formattedDate
this.setData(
{
formData,
timeShow: false,
currentDate: timestamp
},
() => {
// 恢复页面滚动位置(时间选择器关闭但主弹窗还开着的情况)
if (this.data.showPopup && pageScrollTop > 0) {
wx.pageScrollTo({
scrollTop: pageScrollTop,
duration: 0 // 立即恢复,无动画
})
}
}
)
},
/**
* 电话拨打
*/
phoneCall(e) {
let { phone } = e.currentTarget.dataset
wx.makePhoneCall({
phoneNumber: phone
})
},
/**
* 推荐理由
*/
handleShowReason(e) {
let { index } = e.currentTarget.dataset
const obj = this.data.recruitmentPlans[index]
const { reasonMaxLen } = this.data
this.setData({
[`recruitmentPlans[${index}].recommendedReasonTxt`]: obj.isShowReasonAll
? obj.recommendedReason.slice(0, reasonMaxLen) + '...'
: obj.recommendedReason,
[`recruitmentPlans[${index}].isShowReasonAll`]: !obj.isShowReasonAll
})
},
/**
* 取消选择时间
*/
calcelDate() {
const { pageScrollTop } = this.data
this.setData(
{
timeShow: false
},
() => {
// 恢复页面滚动位置
if (pageScrollTop > 0) {
wx.pageScrollTo({
scrollTop: pageScrollTop,
duration: 0 // 立即恢复,无动画
})
}
// 如果主弹窗也关闭了,重置保存的滚动位置
if (!this.data.showPopup) {
this.setData({
pageScrollTop: 0
})
}
}
)
},
/**
* 查看简历
*/
handleViewResume(e) {
// 节流控制:1秒内只能触发一次
const now = Date.now()
const throttleTime = 1000 // 节流时间:1秒
if (
this.lastViewResumeTime &&
now - this.lastViewResumeTime < throttleTime
) {
return
}
this.lastViewResumeTime = now
wx.showLoading({
title: '加载中',
mask: true
})
let { url } = e.currentTarget.dataset
let _this = this
if (!url) {
wx.$util.showToast('暂无简历信息')
return
}
const resumeType = url.split('.')[url.split('.').length - 1]
if (resumeType == 'png') {
wx.previewImage({
urls: [url], // 图片地址数组
current: url // 当前显示图片的链接
})
wx.hideLoading()
return true
}
wx.downloadFile({
// 示例 url,并非真实存在
url: url,
success: function (res) {
const manage = wx.getFileSystemManager()
let file = url.split('/')
let fileName = file[file.length - 1]
console.log('fileName', fileName)
console.log('manage', manage)
manage.saveFile({
tempFilePath: res.tempFilePath,
filePath: wx.env.USER_DATA_PATH + '/' + fileName,
success: function (res) {
console.log('保存成功')
wx.openDocument({
filePath: wx.env.USER_DATA_PATH + '/' + fileName,
fileType: 'pdf',
showMenu: true,
success: function (res) {
console.log('打开文档成功')
}
})
},
fail: function (err) {
console.log('异常', err)
},
complete: function () {
wx.hideLoading()
}
})
// console.log(wx.env.USER_DATA_PATH + "/" + fileName,'wx.env.USER_DATA_PATH + "/" + fileName');
}
})
},
// 获取简历详情
getDetail(id) {
// 标记为已加载,避免重复调用
this.setData({
detailLoaded: true
})
getRecruitDetailAPI({
id: id
})
.then(res => {
let {
stat,
onboardingPlans,
recruitmentPlans,
recruitment,
trialOnboardingPlans
} = res.data
const { reasonMaxLen } = this.data
// 格式化 recruitmentPlans 中的 createdDate
if (recruitmentPlans && recruitmentPlans.length > 0) {
recruitmentPlans = recruitmentPlans.map(item => ({
...item,
createdDate: this.formatDate(item.createdDate),
recommendedReasonTxt: item.recommendedReason
? item.recommendedReason.length > reasonMaxLen
? item.recommendedReason.slice(0, reasonMaxLen) + '...'
: item.recommendedReason
: '-',
isShowReasonAll: false
}))
}
// 格式化 onboardingPlans 中的 onboardingDate
if (onboardingPlans && onboardingPlans.length > 0) {
onboardingPlans = onboardingPlans.map(item => ({
...item,
onboardingDate: this.formatDate(item.onboardingDate)
}))
}
// 格式化 trialOnboardingPlans 中的 onboardingDate
if (trialOnboardingPlans && trialOnboardingPlans?.length > 0) {
trialOnboardingPlans = trialOnboardingPlans.map(item => ({
...item,
onboardingDate: this.formatDate(item.onboardingDate)
}))
}
// 格式化 recruitment 中的 createdDate
if (recruitment && recruitment.createdDate) {
recruitment.createdDate = this.formatDate(recruitment.createdDate)
}
// 根据 businessType 动态过滤招聘信息配置
// 当 businessType == 1 时,显示拒绝理由;否则过滤掉拒绝理由项
const filteredRecruitmentInfoConfig = RECRUITMENT_INFO_CONFIG.filter(
item => {
// 特殊处理:拒绝理由字段仅在招聘状态为被驳回status:3时显示
if (item.field === 'recallReason') {
return recruitment.status == 3
}
return true
}
)
// 将stat数据更新到statisticsList(使用配置映射,代码更简洁)
this.setData({
statisticsList: STATISTICS_CONFIG.map(item => ({
title: item.title,
count: stat[item.field] || 0
})),
onboardingPlans: onboardingPlans,
recruitmentPlans: recruitmentPlans,
item: recruitment,
recruitment: recruitment,
recruitmentInfoConfig: filteredRecruitmentInfoConfig
})
})
.catch(err => { })
},
/**
* 处理按钮点击
*/
handleProcess(e) {
let { id } = e.currentTarget.dataset
// 保存当前页面滚动位置
const query = wx.createSelectorQuery()
query.selectViewport().scrollOffset()
query.exec(res => {
if (res && res[0]) {
this.setData({
pageScrollTop: res[0].scrollTop
})
}
})
this.setData({
showPopup: true,
currentDate: new Date().getTime(), // 重置当前时间为今天
formData: {
id: id,
processResult: '', // 处理结果
interviewTime: '', // 面试时间
description: '', // 说明
descriptionLength: 0 // 说明字数
}
})
},
/**
* 选择标签
*/
selectTag(e) {
const { field, value } = e.currentTarget.dataset
const { formData } = this.data
// 如果点击已选中的标签,则取消选中;否则选中
if (formData[field] === value) {
formData[field] = ''
} else {
formData[field] = value
}
// 当切换"处理结果"标签时,初始化相关表单数据
if (field === 'processResult') {
// 切换到"人员不符合"时,清空面试相关字段
if (value == 1) {
formData.interviewTime = ''
formData.dipalyTime = ''
formData.interviewResult = ''
}
// 切换到"已完成面试"时,初始化面试相关字段为空
if (value == 2) {
formData.interviewTime = ''
formData.dipalyTime = ''
formData.interviewResult = ''
}
}
this.setData({
formData
})
},
/**
* 输入框输入
*/
handleInput(e) {
const { field } = e.currentTarget.dataset
const { value } = e.detail
const { formData } = this.data
formData[field] = value
this.setData({
formData
})
},
/**
* Textarea 输入处理(带字数统计)- 禁止空格和换行
*/
handleTextareaInput(e) {
const { field } = e.currentTarget.dataset
let value = e.detail.value
const { formData } = this.data
// 过滤掉空格
value = value.replace(/ /g, '')
// 限制最多200个字符
if (value.length > 200) {
value = value.substring(0, 200)
}
formData[field] = value
formData[field + 'Length'] = value.length // 统计字数
this.setData({
formData
})
},
/**
* 隐藏弹窗
*/
hidePopup() {
const { pageScrollTop } = this.data
this.setData(
{
showPopup: false,
timeShow: false,
isProcessing: false // 重置处理状态
},
() => {
// 恢复页面滚动位置
if (pageScrollTop > 0) {
wx.pageScrollTo({
scrollTop: pageScrollTop,
duration: 0 // 立即恢复,无动画
})
}
// 重置保存的滚动位置,供下次使用
this.setData({
pageScrollTop: 0
})
}
)
},
/**
* 阻止触摸移动事件(防止弹窗背景滚动)
*/
preventTouchMove(e) {
return false
},
/**
* 阻止事件冒泡
*/
stopPropagation() {
// 空方法,仅用于阻止事件冒泡
},
/**
* 确认处理
*/
confirmProcess() {
const { formData, isProcessing } = this.data
// 防止重复提交
if (isProcessing) return
// 验证必填项
if (!formData.processResult) {
wx.showToast({
title: '请选择处理结果',
icon: 'none'
})
return
}
// 对于面试通过和面试不通过,都需要选择面试时间
if (
(formData.processResult == 2 || formData.processResult == 3) &&
!formData.interviewTime
) {
wx.showToast({
title: '请选择面试时间',
icon: 'none'
})
return
}
// 对于面试通过和面试不通过,都需要选择面试时间
if (
(formData.processResult == 2 || formData.processResult == 3) &&
!formData.interviewResult
) {
wx.showToast({
title: '请选择面试结果',
icon: 'none'
})
return
}
// 设置处理状态为true,防止重复提交
this.setData({
isProcessing: true
})
let requestParams = {
id: formData.id,
processResult: formData?.processResult,
interviewTime: formData?.interviewTime,
interviewResult: formData?.interviewResult,
description: formData?.description
}
processResumeAPI(requestParams)
.then(result => {
let { code, message, data } = result
if (code == 0) {
// 处理成功刷新页面数据
this.getDetail(this.curDataId)
wx.showToast({
title: '处理成功',
icon: 'success'
})
// 处理完成后关闭弹窗
this.hidePopup()
} else {
// 处理失败,重置处理状态
this.setData({
isProcessing: false
})
wx.showToast({
title: message || '处理失败',
icon: 'error'
})
}
})
.catch(error => {
// 处理失败,重置处理状态
this.setData({
isProcessing: false
})
wx.showToast({
title: '处理失败',
icon: 'error'
})
})
},
// 更新数据(弹窗确认回调)
updateMentorShip(e) {
this.hidePopup()
},
// 生命周期函数--监听页面加载
onLoad(options) {
if (options?.id) {
const recruitId = options?.id
this.curDataId = options.id
this.getDetail(recruitId)
} else {
// 通过 eventChannel 接收参数(使用完整路径 / 开头时)
wx.$router.getData(res => {
const recruitId = res.id
this.curDataId = res.id || options.id
this.getDetail(recruitId)
})
}
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() { },
/**
* 生命周期函数--监听页面显示
*/
onShow() { },
/**
* 生命周期函数--监听页面隐藏
*/
onHide() { },
/**
* 生命周期函数--监听页面卸载
*/
onUnload() { },
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() { },
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() { },
/**
* 用户点击右上角分享
*/
onShareAppMessage() { }
})
{
"navigationBarTitleText": "招聘详情",
"disableScroll": false,
"usingComponents": {
"van-datetime-picker": "@vant/weapp/datetime-picker/index",
"van-popup": "@vant/weapp/popup/index",
"empty-card": "../components/emptyCard/emptyCard",
}
}
\ No newline at end of file \ No newline at end of file
/* packageEquity/pages/recruitManage/pages/recruitDetail/recruitDetail.wxss */
page {
background-color: #F7F8FA;
}
.container_page {
&.page-locked {
position: fixed;
width: 100%;
overflow: hidden;
}
.content_top {
height: var(--fontSize138);
opacity: 1;
background: #ffffff;
.statistics {
display: flex;
align-items: center;
justify-content: center;
gap: var(--fontSize20);
height: 100%;
padding: 0 var(--fontSize23);
.statistic_item {
width: var(--fontSize150);
height: var(--fontSize90);
opacity: 1;
position: relative;
text-align: center;
.title {
color: #5a5e66;
font-size: var(--fontSize24);
}
.count {
color: #347bff;
font-size: var(--fontSize36);
font-weight: Bold;
line-height: var(--fontSize44);
margin-top: var(--fontSize12);
}
&:not(:last-child)::after {
content: '';
position: absolute;
right: calc(var(--fontSize20) / -2);
top: 50%;
transform: translateY(-50%);
width: 1px;
height: var(--fontSize60);
background-color: #f1f1f1e1;
}
}
}
}
.content_main {
padding: 0 var(--fontSize36);
.block_title {
box-sizing: border-box;
color: #292d33;
font-weight: 600;
font-size: var(--fontSize28);
padding: var(--fontSize20) 0;
min-height: var(--fontSize80);
}
.sub_title {
color: #999ea8;
text-align: left;
font-size: var(--fontSize24);
line-height: var(--fontSize34);
padding-top: var(--fontSize4);
}
// 卡片公共样式
.card,
.card-empty {
padding: var(--fontSize24) var(--fontSize20);
background: #ffffff;
box-sizing: border-box;
border-radius: var(--fontSize16);
box-shadow: 0 var(--fontSize4) var(--fontSize20) 0 #0000001a;
margin-bottom: var(--fontSize20);
}
.card-empty {
height: var(--fontSize224);
display: flex;
align-items: center;
flex-direction: column;
justify-content: center;
color: #999999;
font-size: var(--fontSize24);
.icon {
width: var(--fontSize128);
height: var(--fontSize80);
margin-bottom: var(--fontSize16);
}
}
// 卡片顶部
.card_top {
display: flex;
align-items: flex-end; // 所有子元素底部对齐
margin-bottom: var(--fontSize20);
.user_info {
display: flex;
flex-direction: column;
justify-content: space-between;
flex: 1;
min-height: var(--fontSize96); // 与头像高度保持一致
margin-left: var(--fontSize16);
.user_top {
display: flex;
justify-content: space-between;
align-items: flex-start;
.name {
line-height: 1.2;
color: #292d33;
font-size: var(--fontSize30);
flex: 1;
font-weight: 600;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
max-width: var(--fontSize460);
}
.tag {
display: inline-block;
padding: var(--fontSize4) var(--fontSize12);
font-size: var(--fontSize20);
border-radius: var(--fontSize4);
margin-left: var(--fontSize8);
// 待处理状态
&.tag-pending {
color: #ff9d0a;
background: #fff5e6;
}
// 已完成状态
&.tag-completed {
color: #52c41a;
background: #52c41a1a;
}
// 人员不符合状态
&.tag-mismatch {
color: #ff4d4f;
background: #ff4d4f1a;
}
// 面试通过状态
&.tag-pass {
color: #52c41a;
background: #52c41a1a;
}
// 面试不通过状态
&.tag-fail {
color: #ff4d4f;
background: #ff4d4f1a;
}
}
}
.user_bottom {
display: flex;
justify-content: space-between;
align-items: flex-end;
margin-top: auto; // 推到底部
.phone {
color: #333333;
font-size: var(--fontSize26);
margin-top: auto;
font-weight: 550;
.phone_text {
line-height: var(--fontSize50);
}
.phone_icon {
width: var(--fontSize48);
height: var(--fontSize48);
}
}
.date {
color: #5A5E66;
font-size: var(--fontSize25);
text-align: right;
flex-shrink: 0;
margin-left: var(--fontSize16);
padding-bottom: var(--fontSize10);
}
}
}
.user_icon {
width: var(--fontSize96);
height: var(--fontSize96);
border-radius: var(--fontSize8);
}
}
.card_middle {
margin-bottom: var(--fontSize20);
font-size: var(--fontSize24);
.label,
.tips {
color: #999ea8;
}
.label {
width: var(--fontSize120);
flex-shrink: 0;
}
.value {
position: relative;
width: 100%;
color: #292d33;
word-wrap: break-word;
word-break: break-all;
}
.show {
display: inline-block;
}
.btn-reason-all {
position: absolute;
bottom: 0;
right: 0;
text-align: right;
width: var(--fontSize144);
background-color: #FFFFFF;
background: linear-gradient(90deg, #ffffff80 0%, #ffffff 100%);
}
.reason-box {
display: flex;
}
}
// 入职计划模块
.entry_plan {
.card_content {
display: flex;
flex-wrap: wrap;
gap: var(--fontSize16) 0;
.item {
width: 50%;
display: flex;
line-height: 1.5;
.label {
color: #999ea8;
font-size: var(--fontSize24);
flex-shrink: 0;
}
.value {
color: #292d33;
font-size: var(--fontSize24);
word-wrap: break-word;
word-break: break-all;
flex: 1;
}
}
}
}
// 招聘计划模块
.recruit_plan {
.card {
min-height: var(--fontSize282);
}
.btn_group {
display: flex;
justify-content: space-between;
align-items: center;
gap: var(--fontSize20);
.btn {
width: var(--fontSize327);
height: var(--fontSize60);
border-radius: var(--fontSize532);
display: flex;
align-items: center;
justify-content: center;
font-size: var(--fontSize26);
cursor: pointer;
-webkit-tap-highlight-color: transparent;
// 当只有一个按钮时,自动扩展宽度
&:only-child {
width: var(--fontSize670);
}
}
.btn_outline {
background: #347bff1a;
color: #347bff;
}
.btn_primary {
background: #347bff;
color: #ffffff;
}
}
}
// 招聘信息模块
.recruit_info {
.info_item {
display: flex;
justify-content: space-between;
align-items: flex-start;
padding: var(--fontSize16) 0;
// align-items: center;
&:last-child {
border-bottom: none;
}
.label {
color: #999ea8;
font-size: var(--fontSize28);
flex-shrink: 0;
line-height: 1.5;
}
.value {
color: #292d33;
font-size: var(--fontSize28);
text-align: right;
word-wrap: break-word;
word-break: break-all;
margin-left: var(--fontSize20);
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;
}
}
}
}
}
.popup_content {
.title {
height: var(--fontSize110);
opacity: 1;
background: #ffffff;
box-shadow: inset 0 -0.5px 0 0 #e8e8ea;
line-height: var(--fontSize110);
color: #292d33;
font-size: var(--fontSize32);
text-align: center;
font-weight: 600;
}
.form {
padding: var(--fontSize20);
.form_item {
display: flex;
justify-content: space-between;
align-items: center;
min-height: var(--fontSize104);
padding: var(--fontSize20) 0;
box-sizing: border-box;
border-bottom: 1px solid #f5f5f5;
&:last-child {
border-bottom: none;
}
.label {
display: flex;
align-items: center;
color: #292d33;
font-size: var(--fontSize28);
flex-shrink: 0;
line-height: 1;
.required {
color: #ff4d4f;
margin-left: var(--fontSize4);
line-height: var(--fontSize24);
}
}
.value {
flex: 1;
display: flex;
flex-wrap: wrap;
justify-content: flex-end;
align-items: center;
gap: var(--fontSize16);
margin-left: var(--fontSize20);
.arrow_right {
width: var(--fontSize14);
height: var(--fontSize28);
padding-top: var(--fontSize2);
}
.tag {
padding: var(--fontSize8) var(--fontSize20);
background: #f7f8fa;
color: #5a5e66;
font-size: var(--fontSize26);
border-radius: var(--fontSize8);
border: 1px solid transparent;
transition: all 0.3s;
cursor: pointer;
-webkit-tap-highlight-color: transparent;
&.active {
background: #e8f4ff;
color: #347bff;
border-color: #347bff;
}
}
input {
flex: 1;
text-align: right;
color: #292d33;
font-size: var(--fontSize28);
&::placeholder {
color: #999ea8;
}
}
.time_text {
color: #292d33;
font-size: var(--fontSize28);
}
.placeholder_text {
color: #999ea8;
font-size: var(--fontSize28);
}
}
}
// textarea 特殊样式
.form_item_textarea {
align-items: flex-start;
flex-direction: column;
.label {
margin-bottom: var(--fontSize16);
}
.value {
width: 100%;
margin-left: 0;
.textarea_wrapper {
position: relative;
width: var(--fontSize710);
height: var(--fontSize440);
textarea {
width: 100%;
height: 100%;
padding: var(--fontSize20);
box-sizing: border-box;
border-radius: var(--fontSize16);
border: 1px solid #eff0f2;
color: #292d33;
font-size: var(--fontSize28);
line-height: 1.5;
&::placeholder {
color: #999ea8;
}
}
.char_count {
position: absolute;
right: var(--fontSize20);
bottom: var(--fontSize20);
color: #999ea8;
font-size: var(--fontSize24);
}
}
}
}
}
.popup_footer {
display: flex;
padding: 0 var(--fontSize20);
gap: var(--fontSize20);
background: #ffffff;
.btn {
flex: 1;
height: var(--fontSize80);
display: flex;
align-items: center;
justify-content: center;
border-radius: var(--fontSize8);
font-size: var(--fontSize30);
cursor: pointer;
-webkit-tap-highlight-color: transparent;
}
.btn_cancel {
background: #f7f8fa;
color: #5a5e66;
}
.btn_confirm {
background: #347bff;
color: #ffffff;
&.btn_disabled {
background: #cccccc;
color: #ffffff;
opacity: 0.8;
pointer-events: none;
}
}
}
}
// 时间选择器弹窗优化
.van-popup {
z-index: 10000 !important;
}
// 时间选择器工具栏样式优化
page {
padding-bottom: var(--fontSize96);
// 确认按钮样式
.van-picker__confirm {
color: #347BFF !important;
font-size: var(--fontSize28) !important; // 14px
padding-top: var(--fontSize36) !important; // 18px
height: auto !important;
line-height: normal !important;
}
// 工具栏内的确认按钮
.van-picker__toolbar {
.van-picker__confirm {
color: #347BFF !important;
font-size: var(--fontSize28) !important;
padding-top: var(--fontSize36) !important;
}
}
}
\ No newline at end of file \ No newline at end of file
<!--packageEquity/pages/recruitManage/recruitDetail/recruitDetail.wxml-->
<!-- 招聘详情 -->
<glsx-privacy appletName="招聘详情" bind:agreeClick="agreeClick" bind:disagreeClick="disagreeClick"></glsx-privacy>
<view class="container_page {{ showPopup || timeShow ? 'page-locked' : '' }}" style="{{ showPopup || timeShow ? 'top: -' + pageScrollTop + 'px;' : '' }}">
<!-- 顶部数据统计 -->
<view class="content_top">
<view class="statistics">
<view class="statistic_item" wx:for="{{ statisticsList }}" wx:key="index">
<view class="title">{{ item.title }}</view>
<view class="count">{{ item.count }}</view>
</view>
</view>
</view>
<!-- 主模块 -->
<view class="content_main">
<!-- 入职计划模块 -->
<view class="entry_plan">
<view class="block_title">入职计划</view>
<block wx:if="{{ onboardingPlans.length }}">
<block wx:for="{{ onboardingPlans }}" wx:key="index">
<view class="card">
<view class="card_top">
<image class="user_icon" src="/packageEquity/pages/image/staff-icon.png" mode="aspectFill" />
<view class="user_info">
<view class="user_top">
<view class="name">{{item.personName }}</view>
</view>
<view class="user_bottom">
<view class="phone" data-phone="{{ item.phoneNumber }}" bind:tap="phoneCall">
<text class="phone_text"> {{ item.phoneNumber}}</text>
<image class="phone_icon" src="/packageEquity/pages/image/call-icon.png" mode="widthFix" />
</view>
<view class="date">入职时间: {{ item.onboardingDate}}</view>
</view>
</view>
</view>
<view class="card_content">
<view class="item" wx:for="{{ onboardingFieldsConfig }}" wx:key="field" wx:for-item="fieldItem">
<text class="label"> {{ fieldItem.label }}:</text>
<text class="value"> {{ item[fieldItem.field]}}</text>
</view>
</view>
</view>
</block>
</block>
<block wx:else>
<view class="card-empty">
<image class="icon" src="/packageEquity/pages/image/card_empty_icon.png" mode="aspectFill" />
<text>暂无内容</text>
</view>
</block>
</view>
<!-- 试岗计划 -->
<view class="entry_plan">
<view class="block_title">试岗计划</view>
<block wx:if="{{ trialOnboardingPlans.length }}">
<block wx:for="{{ trialOnboardingPlans }}" wx:key="index">
<view class="card">
<view class="card_top">
<image class="user_icon" src="/packageEquity/pages/image/staff-icon.png" mode="aspectFill" />
<view class="user_info">
<view class="user_top">
<view class="name">{{item.personName }}</view>
</view>
<view class="user_bottom">
<view class="phone" data-phone="{{ item.phoneNumber }}" bind:tap="phoneCall">
<text class="phone_text"> {{ item.phoneNumber}}</text>
<image class="phone_icon" src="/packageEquity/pages/image/call-icon.png" mode="widthFix" />
</view>
<view class="date">入职时间: {{ item.onboardingDate}}</view>
</view>
</view>
</view>
<!-- <view class="card_content">
<view class="item" wx:for="{{ onboardingFieldsConfig }}" wx:key="field" wx:for-item="fieldItem">
<text class="label"> {{ fieldItem.label }}:</text>
<text class="value"> {{ item[fieldItem.field]}}</text>
</view>
</view> -->
</view>
</block>
</block>
<block wx:else>
<view class="card-empty">
<image class="icon" src="/packageEquity/pages/image/card_empty_icon.png" mode="aspectFill" />
<text>暂无内容</text>
</view>
</block>
</view>
<!-- 招聘计划模块 -->
<view class="recruit_plan">
<view class="block_title">
招聘计划
<view class="sub_title">请及时跟进简历处理结果:获取简历后,若人员初评不匹配可及时退回;若简历合适,可在面试完成后完善面试结果。</view>
</view>
<block wx:if="{{ recruitmentPlans.length }}">
<block wx:for="{{ recruitmentPlans }}" wx:key="index">
<view class="card">
<view class="card_top">
<image class="user_icon" src="/packageEquity/pages/image/staff-icon.png" mode="aspectFill" />
<view class="user_info">
<view class="user_top">
<view class="name">{{ item.personName }}</view>
<view class="tag tag-{{ item.processResult == null ? 'pending' : (item.processResult == 1 ? 'mismatch' : (item.processResult == 2 && item.interviewResult == null ? 'pending' : (item.interviewResult == 0 ? 'fail' : (item.interviewResult == 1 ? 'pass' : '')))) }}">
{{ item.processResult == null ? '待处理' : (item.processResult == 1 ? '人员不符合' : (item.processResult == 2 && item.interviewResult == null ? '待面试' : (item.interviewResult == 0 ? '面试不通过' : (item.interviewResult == 1 ? '面试通过' : '')))) }}
</view>
</view>
<view class="user_bottom">
<view class="phone" data-phone="{{ item.phoneNumber }}" bind:tap="phoneCall">
<text class="phone_text"> {{ item.phoneNumber }}</text>
<image class="phone_icon" src="/packageEquity/pages/image/call-icon.png" mode="widthFix" />
</view>
<view class="date">投递时间: {{ item.createdDate }}</view>
</view>
</view>
</view>
<view class="card_middle">
<view class="reason-box">
<view class="label">推荐理由:</view>
<view class="value">
{{item.recommendedReasonTxt}}
<view wx:if="{{ item.recommendedReason && item.recommendedReason.length > reasonMaxLen }}" class="{{ ['tips', item.isShowReasonAll ? 'show' : ''] }}" bind:tap="handleShowReason" data-index="{{ index }}">
<text wx:if="{{ item.isShowReasonAll }}">收起</text>
<view wx:else class="btn-reason-all">查看全部</view>
</view>
</view>
</view>
</view>
<view class="card_content">
<view class="btn_group">
<view class="btn btn_outline" bindtap="handleViewResume" data-url="{{ item.resumeUrl }}">查看简历</view>
<view wx:if="{{ item.processResult == null }}" class="btn btn_primary" bindtap="handleProcess" data-id="{{ item.id }}">处理</view>
<!-- <van-button wx:if="{{item.status === 0}}"class="btn btn_primary"bindtap="handleProcess"data-id="{{item.id}}"plain type="primary">处理</van-button>-->
</view>
</view>
</view>
</block>
</block>
<block wx:else>
<view class="card-empty">
<image class="icon" src="/packageEquity/pages/image/card_empty_icon.png" mode="aspectFill" />
<text>暂无内容</text>
</view>
</block>
</view>
<view class="recruit_info">
<view class="block_title">招聘信息</view>
<block wx:if="{{ recruitmentInfoConfig }}">
<view class="card">
<view class="info_item" wx:for="{{ recruitmentInfoConfig }}" wx:key="field" wx:for-item="infoItem">
<text class="label"> {{ infoItem.label }}</text>
<view class="value value_box" wx:if="{{ infoItem.label === '门店名称' }}">
<text> {{recruitment[infoItem.field] || '-'}}</text>
<image class="ji" wx:if="{{ recruitment.urgent == 1 }}" src="{{ IMG_URL }}miniProgram/ji.png" mode="aspectFill" />
</view>
<view class="value value_box" wx:elif="{{ infoItem.label === '招聘负责人' || infoItem.label === '技术督导' }}">
<text> {{recruitment[infoItem.field] || '-'}}</text>
<image class="phone_icon" wx:if="{{ (infoItem.label === '招聘负责人' && recruitment.recruiterPhone) || (infoItem.label === '技术督导' && recruitment.technicalSupervisorPhone) }}" src="/packageEquity/pages/image/call-icon.png" mode="widthFix" catchtap="phoneCall" data-phone="{{ infoItem.label === '招聘负责人' ? recruitment.recruiterPhone : recruitment.technicalSupervisorPhone }}" />
</view>
<text class="value" wx:else> {{ recruitment[infoItem.field] || '-' }}</text>
</view>
</view>
</block>
<block wx:else>
<view class="card-empty">
<image class="icon" src="/packageEquity/pages/image/card_empty_icon.png" mode="aspectFill" />
<text>暂无内容</text>
</view>
</block>
</view>
</view>
</view>
<edit-popup wx:if="{{ handleShowMessagePop }}" formData="{{ formData }}" bindconfirm="updateMentorShip" bindcancel="hidePopup"></edit-popup>
<van-popup show="{{ showPopup }}" position="bottom" bind:close="hidePopup" lock-scroll="{{ true }}" round catchtouchmove="preventTouchMove">
<view class="popup_content">
<view class="title">简历处理</view>
<scroll-view scroll-y style="height: var(--fontSize887);" bindtouchmove="stopPropagation">
<view class="form">
<view class="form_item">
<view class="label">
处理结果
<text class="required">*</text>
</view>
<view class="value">
<text class="tag {{ formData.processResult == 1 ? 'active' : '' }}" bindtap="selectTag" data-field="processResult" data-value="1">人员不符合</text>
<text class="tag {{ formData.processResult == 2 ? 'active' : '' }}" bindtap="selectTag" data-field="processResult" data-value="2">已完成面试</text>
</view>
</view>
<view class="form_item" wx:if="{{ formData.processResult == 2 }}">
<view class="label">
面试时间
<text class="required">*</text>
</view>
<view class="value" catchtap="showTimePicker">
<view class="{{ formData.dipalyTime ? 'time_text' : 'placeholder_text' }}">{{ formData.dipalyTime || '请选择面试时间'}}</view>
<image class="arrow_right" src="/packageEquity/pages/image/arrow-right.png" mode="aspectFill" />
</view>
</view>
<view class="form_item" wx:if="{{ formData.processResult == 2 }}">
<view class="label">
面试结果
<text class="required">*</text>
</view>
<view class="value">
<text class="tag {{ formData.interviewResult == '1' ? 'active' : '' }}" bindtap="selectTag" data-field="interviewResult" data-value="1">通过</text>
<text class="tag {{ formData.interviewResult == '0' ? 'active' : '' }}" bindtap="selectTag" data-field="interviewResult" data-value="0">不通过</text>
</view>
</view>
<view class="form_item form_item_textarea">
<view class="label">说明</view>
<view class="value">
<view class="textarea_wrapper">
<textarea placeholder="请输入说明" value="{{ formData.description }}" bindinput="handleTextareaInput" maxlength="200" data-field="description" />
<view class="char_count">{{ formData.descriptionLength || 0 }}/200</view>
</view>
</view>
</view>
</view>
</scroll-view>
<view class="popup_footer">
<view class="btn btn_cancel" bindtap="hidePopup">取消</view>
<view class="btn btn_confirm {{ isProcessing ? 'btn_disabled' : '' }}" bindtap="confirmProcess">{{ isProcessing ? '处理中...': '确认'}}</view>
</view>
</view>
</van-popup>
<!-- 时间选择器 -->
<van-popup show="{{ timeShow }}" position="bottom" bind:close="calcelDate" close-on-click-overlay="{{ true }}" z-index="10000" round catchtouchmove="preventTouchMove">
<van-datetime-picker bind:input="onInput" bind:cancel="calcelDate" value="{{ currentDate }}" formatter="{{ formatter }}" max-date="{{ today }}" bind:confirm="bindDateChange" />
</van-popup>
\ No newline at end of file \ No newline at end of file
// packageWorkspace/pages/recruitManage/pages/recruitDetail/recruitDetail.js // packageWorkspace/pages/recruitManage/pages/recruitDetail/recruitDetail.js
import { unix } from 'dayjs' import { unix } from 'dayjs'
import { getRecruitDetailAPI, processResumeAPI } from '../api' import { getRecruitDetailAPI, processResumeAPI } from '../api'
const IMG_URL = const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/'
'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/'
// 统计列表配置映射 // 统计列表配置映射
const STATISTICS_CONFIG = [ const STATISTICS_CONFIG = [
{ title: '需求数量', field: 'recruitmentQuantity' }, { title: '需求数量', field: 'recruitmentQuantity' },
{ title: '投递简历数', field: 'resumeCount' }, { title: '投递简历数', field: 'resumeCount' },
{ title: '处理简历数', field: 'processResumeCount' }, { title: '处理简历数', field: 'processResumeCount' },
{ title: '试岗人数', field: 'trialOnboardingCount' },
{ title: '入职人数', field: 'entryCount' } { title: '入职人数', field: 'entryCount' }
] ]
// 入职计划卡片字段配置 // 入职计划卡片字段配置
const ONBOARDING_FIELDS_CONFIG = [ const ONBOARDING_FIELDS_CONFIG = [
{ label: '性格', field: 'personalityName' }, { label: '性格', field: 'personalityName' },
{ label: '能力表现', field: 'abilityPerformanceName' } { label: '能力表现', field: 'abilityPerformanceName' },
// { label: '学历', field: 'educationLevelName' }, // { label: '学历', field: 'educationLevelName' },
// { label: '形象', field: 'appearanceName' }, // { label: '形象', field: 'appearanceName' },
// { label: '岗位匹配度', field: 'positionMatchDegreeName' } // { label: '岗位匹配度', field: 'positionMatchDegreeName' }
] ]
// 学历 岗位匹配度 形象tag // 学历 岗位匹配度 形象tag
const TAGLIST = [ const TAGLIST = ['educationLevelName', 'appearanceName', 'positionMatchDegreeName']
'educationLevelName',
'appearanceName',
'positionMatchDegreeName'
]
// 招聘信息字段配置 // 招聘信息字段配置
const RECRUITMENT_INFO_CONFIG = [ const RECRUITMENT_INFO_CONFIG = [
...@@ -34,7 +28,6 @@ const RECRUITMENT_INFO_CONFIG = [ ...@@ -34,7 +28,6 @@ const RECRUITMENT_INFO_CONFIG = [
{ label: '业务类型', field: 'businessTypeName' }, { label: '业务类型', field: 'businessTypeName' },
{ label: '招聘类型', field: 'recruitmentTypeName' }, { label: '招聘类型', field: 'recruitmentTypeName' },
{ label: '招聘负责人', field: 'recruiterName' }, { label: '招聘负责人', field: 'recruiterName' },
{ label: '技术督导', field: 'technicalSupervisorName' },
{ label: '申请时间', field: 'createdDate' }, { label: '申请时间', field: 'createdDate' },
{ label: '需求描述', field: 'requirementDescription' }, { label: '需求描述', field: 'requirementDescription' },
{ label: '拒绝理由', field: 'recallReason' } { label: '拒绝理由', field: 'recallReason' }
...@@ -44,7 +37,7 @@ const RECRUITMENT_INFO_CONFIG = [ ...@@ -44,7 +37,7 @@ const RECRUITMENT_INFO_CONFIG = [
const RECRUIT_STATUS_CONFIG = { const RECRUIT_STATUS_CONFIG = {
// mixResult状态映射 // mixResult状态映射
0: { text: '待处理', class: 'pending', canProcess: true }, 0: { text: '待处理', class: 'pending', canProcess: true },
1: { text: '人员不符合', class: 'mismatch', canProcess: false }, 1: { text: '人员不匹配', class: 'mismatch', canProcess: false },
2: { text: '面试通过', class: 'pass', canProcess: false }, 2: { text: '面试通过', class: 'pass', canProcess: false },
3: { text: '面试不通过', class: 'fail', canProcess: false } 3: { text: '面试不通过', class: 'fail', canProcess: false }
} }
...@@ -79,14 +72,12 @@ Page({ ...@@ -79,14 +72,12 @@ Page({
statisticsList: [], statisticsList: [],
onboardingPlans: [], onboardingPlans: [],
recruitmentPlans: [], recruitmentPlans: [],
trialOnboardingPlans: [],
recruitmentInfoConfig: RECRUITMENT_INFO_CONFIG, recruitmentInfoConfig: RECRUITMENT_INFO_CONFIG,
onboardingFieldsConfig: ONBOARDING_FIELDS_CONFIG, onboardingFieldsConfig: ONBOARDING_FIELDS_CONFIG,
handleShowMessagePop: false, // 控制弹窗显示 handleShowMessagePop: false, // 控制弹窗显示
timeShow: false, // 控制时间选择器显示 timeShow: false, // 控制时间选择器显示
currentDate: new Date().getTime(), currentDate: new Date().getTime(),
minDate: new Date().getTime(), // 最小日期 today: new Date().getTime(), // 当前日期,用于限制日期选择器的最大值
maxDate: new Date().getTime(), // 最大日期
formData: {}, // 弹窗表单数据 formData: {}, // 弹窗表单数据
detailLoaded: false, // 标识是否已加载详情 detailLoaded: false, // 标识是否已加载详情
curDataId: '', curDataId: '',
...@@ -103,12 +94,6 @@ Page({ ...@@ -103,12 +94,6 @@ Page({
if (type === 'day') { if (type === 'day') {
return `${value}日` return `${value}日`
} }
if (type === 'hour') {
return `${value}时`
}
if (type === 'minute') {
return `${value}分`
}
return value return value
} }
}, },
...@@ -134,26 +119,10 @@ Page({ ...@@ -134,26 +119,10 @@ Page({
}) })
} }
const { popupType } = this.data
const now = new Date().getTime()
let minDate, maxDate
if (popupType === 'initial') {
// 预计面试时间:当前及之后
minDate = now
maxDate = now + 10 * 365 * 24 * 60 * 60 * 1000 // 10年后
} else {
// 面试时间:当前及之前
minDate = now - 10 * 365 * 24 * 60 * 60 * 1000 // 10年前
maxDate = now
}
// 重置为当前日期 // 重置为当前日期
this.setData({ this.setData({
timeShow: true, timeShow: true,
currentDate: now, currentDate: new Date().getTime()
minDate,
maxDate
}) })
}, },
...@@ -167,19 +136,10 @@ Page({ ...@@ -167,19 +136,10 @@ Page({
const month = String(date.getMonth() + 1).padStart(2, '0') const month = String(date.getMonth() + 1).padStart(2, '0')
const day = String(date.getDate()).padStart(2, '0') const day = String(date.getDate()).padStart(2, '0')
const formattedDate = `${year}年${month}月${day}日` const formattedDate = `${year}年${month}月${day}日`
const apiDate = `${year}-${month}-${day} 00:00:00` const formattedFull = new Date(timestamp)
const { formData, pageScrollTop } = this.data
const { formData, pageScrollTop, popupType } = this.data formData.interviewTime = `${year}-${month}-${day} 00:00:00`
// 根据 popupType 设置不同的字段
if (popupType === 'initial') {
formData.expectedInterviewTime = apiDate
} else if (popupType === 'interview') {
formData.interviewTime = apiDate
}
formData.dipalyTime = formattedDate formData.dipalyTime = formattedDate
this.setData( this.setData(
{ {
formData, formData,
...@@ -214,9 +174,7 @@ Page({ ...@@ -214,9 +174,7 @@ Page({
const obj = this.data.recruitmentPlans[index] const obj = this.data.recruitmentPlans[index]
const { reasonMaxLen } = this.data const { reasonMaxLen } = this.data
this.setData({ this.setData({
[`recruitmentPlans[${index}].recommendedReasonTxt`]: obj.isShowReasonAll [`recruitmentPlans[${index}].recommendedReasonTxt`]: obj.isShowReasonAll ? (obj.recommendedReason.slice(0, reasonMaxLen) + '...') : obj.recommendedReason,
? obj.recommendedReason.slice(0, reasonMaxLen) + '...'
: obj.recommendedReason,
[`recruitmentPlans[${index}].isShowReasonAll`]: !obj.isShowReasonAll [`recruitmentPlans[${index}].isShowReasonAll`]: !obj.isShowReasonAll
}) })
}, },
...@@ -264,7 +222,7 @@ Page({ ...@@ -264,7 +222,7 @@ Page({
this.lastViewResumeTime = now this.lastViewResumeTime = now
wx.showLoading({ wx.showLoading({
title: '加载中', title: '加载中',
mask: true mask:true
}) })
let { url } = e.currentTarget.dataset let { url } = e.currentTarget.dataset
let _this = this let _this = this
...@@ -272,7 +230,7 @@ Page({ ...@@ -272,7 +230,7 @@ Page({
wx.$util.showToast('暂无简历信息') wx.$util.showToast('暂无简历信息')
return return
} }
const resumeType = url.split('.')[url.split('.').length - 1] const resumeType = url.split(".")[url.split(".").length - 1]
if (resumeType == 'png') { if (resumeType == 'png') {
wx.previewImage({ wx.previewImage({
urls: [url], // 图片地址数组 urls: [url], // 图片地址数组
...@@ -288,8 +246,8 @@ Page({ ...@@ -288,8 +246,8 @@ Page({
const manage = wx.getFileSystemManager() const manage = wx.getFileSystemManager()
let file = url.split('/') let file = url.split('/')
let fileName = file[file.length - 1] let fileName = file[file.length - 1]
console.log('fileName', fileName) console.log('fileName',fileName)
console.log('manage', manage) console.log('manage',manage)
manage.saveFile({ manage.saveFile({
tempFilePath: res.tempFilePath, tempFilePath: res.tempFilePath,
filePath: wx.env.USER_DATA_PATH + '/' + fileName, filePath: wx.env.USER_DATA_PATH + '/' + fileName,
...@@ -305,9 +263,8 @@ Page({ ...@@ -305,9 +263,8 @@ Page({
}) })
}, },
fail: function (err) { fail: function (err) {
console.log('异常', err) console.log("异常",err);
}, },complete: function() {
complete: function () {
wx.hideLoading() wx.hideLoading()
} }
}) })
...@@ -326,24 +283,14 @@ Page({ ...@@ -326,24 +283,14 @@ Page({
id: id id: id
}) })
.then(res => { .then(res => {
let { let { stat, onboardingPlans, recruitmentPlans, recruitment } = res.data
stat,
onboardingPlans,
recruitmentPlans,
recruitment,
trialOnboardingPlans
} = res.data
const { reasonMaxLen } = this.data const { reasonMaxLen } = this.data
// 格式化 recruitmentPlans 中的 createdDate // 格式化 recruitmentPlans 中的 createdDate
if (recruitmentPlans && recruitmentPlans.length > 0) { if (recruitmentPlans && recruitmentPlans.length > 0) {
recruitmentPlans = recruitmentPlans.map(item => ({ recruitmentPlans = recruitmentPlans.map(item => ({
...item, ...item,
createdDate: this.formatDate(item.createdDate), createdDate: this.formatDate(item.createdDate),
recommendedReasonTxt: item.recommendedReason recommendedReasonTxt: item.recommendedReason ? (item.recommendedReason.length > reasonMaxLen ? (item.recommendedReason.slice(0, reasonMaxLen) + '...') : item.recommendedReason) : '-',
? item.recommendedReason.length > reasonMaxLen
? item.recommendedReason.slice(0, reasonMaxLen) + '...'
: item.recommendedReason
: '-',
isShowReasonAll: false isShowReasonAll: false
})) }))
} }
...@@ -354,13 +301,6 @@ Page({ ...@@ -354,13 +301,6 @@ Page({
onboardingDate: this.formatDate(item.onboardingDate) onboardingDate: this.formatDate(item.onboardingDate)
})) }))
} }
// 格式化 trialOnboardingPlans 中的 onboardingDate
if (trialOnboardingPlans && trialOnboardingPlans?.length > 0) {
trialOnboardingPlans = trialOnboardingPlans.map(item => ({
...item,
onboardingDate: this.formatDate(item.trialTime)
}))
}
// 格式化 recruitment 中的 createdDate // 格式化 recruitment 中的 createdDate
if (recruitment && recruitment.createdDate) { if (recruitment && recruitment.createdDate) {
...@@ -387,7 +327,6 @@ Page({ ...@@ -387,7 +327,6 @@ Page({
})), })),
onboardingPlans: onboardingPlans, onboardingPlans: onboardingPlans,
recruitmentPlans: recruitmentPlans, recruitmentPlans: recruitmentPlans,
trialOnboardingPlans: trialOnboardingPlans,
recruitment: recruitment, recruitment: recruitment,
recruitmentInfoConfig: filteredRecruitmentInfoConfig recruitmentInfoConfig: filteredRecruitmentInfoConfig
}) })
...@@ -398,14 +337,7 @@ Page({ ...@@ -398,14 +337,7 @@ Page({
* 处理按钮点击 * 处理按钮点击
*/ */
handleProcess(e) { handleProcess(e) {
const { index } = e.currentTarget.dataset let { id } = e.currentTarget.dataset
const item = this.data.recruitmentPlans[index]
// Determine popup type based on item status
let popupType = 'initial'
if (item.processResult == 2 && item.interviewResult == null) {
popupType = 'interview'
}
// 保存当前页面滚动位置 // 保存当前页面滚动位置
const query = wx.createSelectorQuery() const query = wx.createSelectorQuery()
...@@ -420,10 +352,9 @@ Page({ ...@@ -420,10 +352,9 @@ Page({
this.setData({ this.setData({
showPopup: true, showPopup: true,
popupType,
currentDate: new Date().getTime(), // 重置当前时间为今天 currentDate: new Date().getTime(), // 重置当前时间为今天
formData: { formData: {
id: item.id, id: id,
processResult: '', // 处理结果 processResult: '', // 处理结果
interviewTime: '', // 面试时间 interviewTime: '', // 面试时间
description: '', // 说明 description: '', // 说明
...@@ -447,7 +378,7 @@ Page({ ...@@ -447,7 +378,7 @@ Page({
// 当切换"处理结果"标签时,初始化相关表单数据 // 当切换"处理结果"标签时,初始化相关表单数据
if (field === 'processResult') { if (field === 'processResult') {
// 切换到"人员不符合"时,清空面试相关字段 // 切换到"人员不匹配"时,清空面试相关字段
if (value == 1) { if (value == 1) {
formData.interviewTime = '' formData.interviewTime = ''
formData.dipalyTime = '' formData.dipalyTime = ''
...@@ -547,13 +478,12 @@ Page({ ...@@ -547,13 +478,12 @@ Page({
* 确认处理 * 确认处理
*/ */
confirmProcess() { confirmProcess() {
const { formData, isProcessing, popupType, recruitment } = this.data const { formData, isProcessing } = this.data
// 防止重复提交 // 防止重复提交
if (isProcessing) return if (isProcessing) return
if (popupType === 'initial') { // 验证必填项
// 简历处理阶段验证
if (!formData.processResult) { if (!formData.processResult) {
wx.showToast({ wx.showToast({
title: '请选择处理结果', title: '请选择处理结果',
...@@ -561,31 +491,28 @@ Page({ ...@@ -561,31 +491,28 @@ Page({
}) })
return return
} }
// 人员符合(2)时,预计面试时间必填 // 对于面试通过和面试不通过,都需要选择面试时间
if (formData.processResult == 2 && !formData.expectedInterviewTime) { if (
(formData.processResult == 2 || formData.processResult == 3) &&
!formData.interviewTime
) {
wx.showToast({ wx.showToast({
title: '请选择预计面试时间', title: '请选择面试时间',
icon: 'none' icon: 'none'
}) })
return return
} }
} else if (popupType === 'interview') { // 对于面试通过和面试不通过,都需要选择面试时间
// 面试反馈阶段验证 if (
if (!formData.interviewResult) { (formData.processResult == 2 || formData.processResult == 3) &&
!formData.interviewResult
) {
wx.showToast({ wx.showToast({
title: '请选择面试结果', title: '请选择面试结果',
icon: 'none' icon: 'none'
}) })
return return
} }
if (!formData.interviewTime) {
wx.showToast({
title: '请选择面试时间',
icon: 'none'
})
return
}
}
// 设置处理状态为true,防止重复提交 // 设置处理状态为true,防止重复提交
this.setData({ this.setData({
...@@ -594,21 +521,10 @@ Page({ ...@@ -594,21 +521,10 @@ Page({
let requestParams = { let requestParams = {
id: formData.id, id: formData.id,
technicalSupervisorName: recruitment.technicalSupervisorName, processResult: formData?.processResult,
technicalSupervisorPhone: recruitment.technicalSupervisorPhone, interviewTime: formData?.interviewTime,
processResult: formData?.processResult interviewResult: formData?.interviewResult,
} description: formData?.description
if (popupType === 'initial') {
requestParams.processResult = formData?.processResult
if (formData.processResult == 2) {
requestParams.expectedInterviewTime = formData.expectedInterviewTime
}
requestParams.description = formData?.description
} else {
requestParams.interviewTime = formData?.interviewTime
requestParams.interviewResult = formData?.interviewResult
requestParams.interviewExplanation = formData?.description
} }
processResumeAPI(requestParams) processResumeAPI(requestParams)
......
...@@ -24,8 +24,7 @@ page { ...@@ -24,8 +24,7 @@ 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;
...@@ -73,7 +72,7 @@ page { ...@@ -73,7 +72,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);
...@@ -106,14 +105,12 @@ page { ...@@ -106,14 +105,12 @@ 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;
...@@ -123,12 +120,10 @@ page { ...@@ -123,12 +120,10 @@ 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;
...@@ -158,12 +153,10 @@ page { ...@@ -158,12 +153,10 @@ 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);
...@@ -191,7 +184,7 @@ page { ...@@ -191,7 +184,7 @@ page {
background: #52c41a1a; background: #52c41a1a;
} }
// 人员不符合状态 // 人员不匹配状态
&.tag-mismatch { &.tag-mismatch {
color: #ff4d4f; color: #ff4d4f;
background: #ff4d4f1a; background: #ff4d4f1a;
...@@ -216,7 +209,6 @@ page { ...@@ -216,7 +209,6 @@ 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);
...@@ -230,7 +222,6 @@ page { ...@@ -230,7 +222,6 @@ 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);
...@@ -262,11 +253,9 @@ page { ...@@ -262,11 +253,9 @@ 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);
...@@ -291,17 +280,13 @@ page { ...@@ -291,17 +280,13 @@ 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%;
...@@ -309,11 +294,9 @@ page { ...@@ -309,11 +294,9 @@ 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;
...@@ -323,18 +306,15 @@ page { ...@@ -323,18 +306,15 @@ 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;
...@@ -403,21 +383,6 @@ page { ...@@ -403,21 +383,6 @@ 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;
}
} }
} }
} }
...@@ -484,24 +449,20 @@ page { ...@@ -484,24 +449,20 @@ 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);
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
<view class="card"> <view class="card">
<view class="date">入职时间:{{item.onboardingDate}}</view> <view class="date">入职时间:{{item.onboardingDate}}</view>
<view class="card_top"> <view class="card_top">
<image class="user_icon" src="{{ IMG_URL }}staff-icon.png" mode="aspectFill" /> <image class="user_icon" src="{{IMG_URL}}staff-icon.png" mode="aspectFill" />
<view class="user_info"> <view class="user_info">
<view class="user_top"> <view class="user_top">
<view class="name">{{item.personName}}</view> <view class="name">{{item.personName}}</view>
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
</view> </view>
</view> </view>
<view class="user_bottom"> <view class="user_bottom">
<view class="tag" wx:for="{{ TAGLIST }}" wx:for-item="subItem" wx:key="subIndex">{{item[subItem]}}</view> <view class="tag" wx:for="{{TAGLIST}}" wx:for-item="subItem" wx:key="subIndex">{{item[subItem]}}</view>
</view> </view>
</view> </view>
</view> </view>
...@@ -49,42 +49,11 @@ ...@@ -49,42 +49,11 @@
</block> </block>
<block wx:else> <block wx:else>
<view class="card-empty"> <view class="card-empty">
<image class="icon" src="{{ IMG_URL }}empty-data.png" mode="aspectFill" /> <image class="icon" src="{{IMG_URL}}empty-data.png" mode="aspectFill" />
<text>暂无数据</text> <text>暂无数据</text>
</view> </view>
</block> </block>
</view> </view>
<!-- 试岗计划 -->
<view class="entry_plan">
<view class="block_title">试岗计划</view>
<block wx:if="{{ trialOnboardingPlans.length }}">
<block wx:for="{{ trialOnboardingPlans }}" wx:key="index">
<view class="card">
<view class="card_top">
<image class="user_icon" src="{{ IMG_URL }}staff-icon.png" mode="aspectFill" />
<view class="user_info">
<view class="user_top">
<view class="name">{{item.personName }}</view>
</view>
<view class="user_bottom">
<view class="phone" data-phone="{{ item.phoneNumber }}" bind:tap="phoneCall">
<text class="phone_text"> {{ item.phoneNumber}}</text>
<image class="phone_icon" src="/packageWorkspace/pages/image/call-icon.png" mode="widthFix" />
</view>
<view class="date">入职时间: {{ item.onboardingDate}}</view>
</view>
</view>
</view>
</view>
</block>
</block>
<block wx:else>
<view class="card-empty">
<image class="icon" src="{{ IMG_URL }}empty-data.png" mode="aspectFill" />
<text>暂无内容</text>
</view>
</block>
</view>
<!-- 招聘计划模块 --> <!-- 招聘计划模块 -->
<view class="recruit_plan"> <view class="recruit_plan">
<view class="block_title"> <view class="block_title">
...@@ -102,8 +71,7 @@ ...@@ -102,8 +71,7 @@
<view <view
class="tag tag-{{ item.mixResult !== undefined ? (item.mixResult === 0 ? 'pending' : item.mixResult === 1 ? 'mismatch' : item.mixResult === 2 ? 'pass' : 'fail') : 'completed' }}" class="tag tag-{{ item.mixResult !== undefined ? (item.mixResult === 0 ? 'pending' : item.mixResult === 1 ? 'mismatch' : item.mixResult === 2 ? 'pass' : 'fail') : 'completed' }}"
> >
<!-- {{item.mixResult !== undefined ? (item.mixResult === 0 ? '待处理' : item.mixResult === 1 ? '人员不符合' : item.mixResult === 2 ? '面试通过' : '面试不通过') : (item.status === 0 ? '待处理' : '已完成')}} --> {{item.mixResult !== undefined ? (item.mixResult === 0 ? '待处理' : item.mixResult === 1 ? '人员不匹配' : item.mixResult === 2 ? '面试通过' : '面试不通过') : (item.status === 0 ? '待处理' : '已完成')}}
{{ item.processResult == null ? '待处理' : (item.processResult == 1 ? '人员不符合' : (item.processResult == 2 && item.interviewResult == null ? '待面试' : (item.interviewResult == 0 ? '面试不通过' : (item.interviewResult == 1 ? '面试通过' : '')))) }}
</view> </view>
</view> </view>
<view class="user_bottom"> <view class="user_bottom">
...@@ -119,31 +87,18 @@ ...@@ -119,31 +87,18 @@
<view class="label">推荐理由:</view> <view class="label">推荐理由:</view>
<view class="value"> <view class="value">
{{item.recommendedReasonTxt}} {{item.recommendedReasonTxt}}
<view <view wx:if="{{ item.recommendedReason && item.recommendedReason.length > reasonMaxLen }}" class="{{['tips', item.isShowReasonAll ? 'show' : '']}}" bind:tap="handleShowReason" data-index="{{ index }}">
wx:if="{{ item.recommendedReason && item.recommendedReason.length > reasonMaxLen }}" <text wx:if="{{item.isShowReasonAll}}">收起</text>
class="{{ ['tips', item.isShowReasonAll ? 'show' : ''] }}"
bind:tap="handleShowReason"
data-index="{{ index }}"
>
<text wx:if="{{ item.isShowReasonAll }}">收起</text>
<view wx:else class="btn-reason-all">查看全部</view> <view wx:else class="btn-reason-all">查看全部</view>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view class="card_content"> <view class="card_content">
<view class="date"> <view class="date"><text style="margin-right: var(--fontSize8);">投递于</text>{{item.createdDate}}</view>
<text style="margin-right: var(--fontSize8);">投递于</text>
{{item.createdDate}}
</view>
<view class="btn_group"> <view class="btn_group">
<view class="btn btn_outline" bindtap="handleViewResume" data-url="{{ item.resumeUrl }}">查看简历</view> <view class="btn btn_outline" bindtap="handleViewResume" data-url="{{ item.resumeUrl }}">查看简历</view>
<view <view wx:if="{{ item.status === 0 }}" class="btn btn_primary" bindtap="handleProcess" data-id="{{ item.id }}">处理</view>
wx:if="{{ item.processResult == null || (item.processResult == 2 && item.interviewResult == null) }}"
class="btn btn_primary"
bindtap="handleProcess"
data-index="{{ index }}"
>处理</view>
<!-- <van-button wx:if="{{item.status === 0}}" class="btn btn_primary" bindtap="handleProcess" data-id="{{item.id}}" plain type="primary">处理</van-button> --> <!-- <van-button wx:if="{{item.status === 0}}" class="btn btn_primary" bindtap="handleProcess" data-id="{{item.id}}" plain type="primary">处理</van-button> -->
</view> </view>
</view> </view>
...@@ -152,7 +107,7 @@ ...@@ -152,7 +107,7 @@
</block> </block>
<block wx:else> <block wx:else>
<view class="card-empty"> <view class="card-empty">
<image class="icon" src="{{ IMG_URL }}empty-data.png" mode="aspectFill" /> <image class="icon" src="{{IMG_URL}}empty-data.png" mode="aspectFill" />
<text>暂无数据</text> <text>暂无数据</text>
</view> </view>
</block> </block>
...@@ -163,28 +118,13 @@ ...@@ -163,28 +118,13 @@
<view class="card"> <view class="card">
<view class="info_item" wx:for="{{ recruitmentInfoConfig }}" wx:key="field" wx:for-item="infoItem"> <view class="info_item" wx:for="{{ recruitmentInfoConfig }}" wx:key="field" wx:for-item="infoItem">
<text class="label">{{infoItem.label}}</text> <text class="label">{{infoItem.label}}</text>
<view class="value value_box" wx:if="{{ infoItem.label === '门店名称' }}"> <text class="value">{{recruitment[infoItem.field] || '--'}}</text>
<text> {{recruitment[infoItem.field] || '--'}}</text>
<image class="ji" wx:if="{{ recruitment.urgent == 1 }}" src="{{ IMG_URL }}ji.png" mode="aspectFill" />
</view>
<view class="value value_box" wx:elif="{{ infoItem.label === '招聘负责人' || infoItem.label === '技术督导' }}">
<text> {{recruitment[infoItem.field] || '--'}}</text>
<image
class="phone_icon"
wx:if="{{ (infoItem.label === '招聘负责人' && recruitment.recruiterPhone) || (infoItem.label === '技术督导' && recruitment.technicalSupervisorPhone) }}"
src="/packageWorkspace/pages/image/call-icon.png"
mode="widthFix"
catchtap="phoneCall"
data-phone="{{ infoItem.label === '招聘负责人' ? recruitment.recruiterPhone : recruitment.technicalSupervisorPhone }}"
/>
</view>
<text class="value" wx:else>{{recruitment[infoItem.field] || '--'}}</text>
</view> </view>
</view> </view>
</block> </block>
<block wx:else> <block wx:else>
<view class="card-empty"> <view class="card-empty">
<image class="icon" src="{{ IMG_URL }}empty-data.png" mode="aspectFill" /> <image class="icon" src="{{IMG_URL}}empty-data.png" mode="aspectFill" />
<text>暂无数据</text> <text>暂无数据</text>
</view> </view>
</block> </block>
...@@ -200,71 +140,55 @@ ...@@ -200,71 +140,55 @@
catchtouchmove="preventTouchMove" catchtouchmove="preventTouchMove"
> >
<view class="popup_content"> <view class="popup_content">
<view class="title">{{ popupType == 'initial' ? '简历处理' : '面试反馈' }}</view> <view class="title">简历处理</view>
<scroll-view scroll-y style="height: var(--fontSize807);" bindtouchmove="stopPropagation"> <scroll-view scroll-y style="height: var(--fontSize807);" bindtouchmove="stopPropagation">
<view class="form"> <view class="form">
<!-- Initial Processing -->
<block wx:if="{{ popupType == 'initial' }}">
<view class="form_item"> <view class="form_item">
<view class="label"> <view class="label">
处理结果 处理结果
<text class="required">*</text> <text class="required">*</text>
</view> </view>
<view class="value"> <view class="value">
<view class="radio mar-r20" bindtap="selectTag" data-field="processResult" data-value="{{ 2 }}"> <view class="radio mar-r20" bindtap="selectTag" data-field="processResult" data-value="1">
<image class="radio-icon" wx:if="{{ formData.processResult == 2 }}" src="{{ IMG_URL }}radio-checked.png" /> <image class="radio-icon" wx:if="{{formData.processResult == 1}}" src="{{IMG_URL}}radio-checked.png" mode=""/>
<view class="cily" wx:else></view> <view class="cily" wx:else></view>
<view class="text">人员符合</view> <view class="text">人员不匹配</view>
</view> </view>
<view class="radio" bindtap="selectTag" data-field="processResult" data-value="{{ 1 }}"> <view class="radio" bindtap="selectTag" data-field="processResult" data-value="2">
<image class="radio-icon" wx:if="{{ formData.processResult == 1 }}" src="{{ IMG_URL }}radio-checked.png" /> <image class="radio-icon" wx:if="{{formData.processResult == 2}}" src="{{IMG_URL}}radio-checked.png" mode=""/>
<view class="cily" wx:else></view> <view class="cily" wx:else></view>
<view class="text">人员不符合</view> <view class="text">已完成面试</view>
</view> </view>
</view> </view>
</view> </view>
<view class="form_item"> <view class="form_item" wx:if="{{ formData.processResult == 2 }}">
<view class="label"> <view class="label">
预计面试时间 面试时间
<text class="required">*</text> <text class="required">*</text>
</view> </view>
<view class="value" bindtap="showTimePicker"> <view class="value" catchtap="showTimePicker">
<view class="{{ formData.dipalyTime ? 'time_text' : 'placeholder_text' }}">{{formData.dipalyTime || '点击选择'}}</view> <view class="{{ formData.dipalyTime ? 'time_text' : 'placeholder_text' }}">{{formData.dipalyTime || '点击选择'}}</view>
<image class="arrow_right" src="{{ IMG_URL }}arrow_right.png" mode="aspectFill" /> <image class="arrow_right" src="/packageWorkspace/pages/image/arrow-right.png" mode="aspectFill" />
</view> </view>
</view> </view>
</block> <view class="form_item" wx:if="{{ formData.processResult == 2 }}">
<!-- Interview Feedback -->
<block wx:if="{{ popupType == 'interview' }}">
<view class="form_item">
<view class="label"> <view class="label">
面试结果 面试结果
<text class="required">*</text> <text class="required">*</text>
</view> </view>
<view class="value"> <view class="value">
<view class="radio mar-r20" bindtap="selectTag" data-field="interviewResult" data-value="{{ 1 }}"> <view class="radio mar-r20" bindtap="selectTag" data-field="interviewResult" data-value="1">
<image class="radio-icon" wx:if="{{ formData.interviewResult == 1 }}" src="{{ IMG_URL }}radio-checked.png" /> <image class="radio-icon" wx:if="{{formData.interviewResult == '1'}}" src="{{IMG_URL}}radio-checked.png" mode=""/>
<view class="cily" wx:else></view> <view class="cily" wx:else></view>
<view class="text">通过</view> <view class="text">通过</view>
</view> </view>
<view class="radio" bindtap="selectTag" data-field="interviewResult" data-value="{{ 0 }}"> <view class="radio" bindtap="selectTag" data-field="interviewResult" data-value="0">
<image class="radio-icon" wx:if="{{ formData.interviewResult === 0 }}" src="{{ IMG_URL }}radio-checked.png" /> <image class="radio-icon" wx:if="{{formData.interviewResult == '0'}}" src="{{IMG_URL}}radio-checked.png" mode=""/>
<view class="cily" wx:else></view> <view class="cily" wx:else></view>
<view class="text">不通过</view> <view class="text">不通过</view>
</view> </view>
</view> </view>
</view> </view>
<view class="form_item">
<view class="label">
面试时间
<text class="required">*</text>
</view>
<view class="value" bindtap="showTimePicker">
<view class="{{ formData.dipalyTime ? 'time_text' : 'placeholder_text' }}">{{formData.dipalyTime || '点击选择'}}</view>
<image class="arrow_right" src="{{ IMG_URL }}arrow_right.png" mode="aspectFill" />
</view>
</view>
</block>
<view class="form_item form_item_textarea"> <view class="form_item form_item_textarea">
<view class="label">说明</view> <view class="label">说明</view>
<view class="value"> <view class="value">
...@@ -272,10 +196,10 @@ ...@@ -272,10 +196,10 @@
<textarea <textarea
placeholder="请输入" placeholder="请输入"
value="{{ formData.description }}" value="{{ formData.description }}"
data-field="description"
bindinput="handleTextareaInput" bindinput="handleTextareaInput"
maxlength="200" maxlength="200"
></textarea> data-field="description"
/>
<view class="char_count">{{formData.descriptionLength || 0}}/200</view> <view class="char_count">{{formData.descriptionLength || 0}}/200</view>
</view> </view>
</view> </view>
...@@ -289,15 +213,24 @@ ...@@ -289,15 +213,24 @@
</view> </view>
</van-popup> </van-popup>
<!-- 时间选择器 --> <!-- 时间选择器 -->
<van-popup show="{{ timeShow }}" position="bottom" round bind:close="calcelDate" catchtouchmove="preventTouchMove"> <van-popup
show="{{ timeShow }}"
position="bottom"
bind:close="calcelDate"
close-on-click-overlay="{{ true }}"
z-index="10000"
round
catchtouchmove="preventTouchMove"
>
<van-datetime-picker <van-datetime-picker
type="date" type="date"
bind:input="onInput"
bind:cancel="calcelDate"
confirm-button-text="确定"
value="{{ currentDate }}" value="{{ currentDate }}"
formatter="{{ formatter }}" formatter="{{ formatter }}"
min-date="{{ minDate }}" max-date="{{ today }}"
max-date="{{ maxDate }}"
bind:confirm="bindDateChange" bind:confirm="bindDateChange"
bind:cancel="calcelDate"
/> />
</van-popup> </van-popup>
</view> </view>
\ No newline at end of file \ No newline at end of file
...@@ -9,8 +9,7 @@ import { ...@@ -9,8 +9,7 @@ import {
const FORM_FIELDS = { const FORM_FIELDS = {
MERCHANT: 0, // 门店 MERCHANT: 0, // 门店
QUANTITY: 2, // 招聘数量 QUANTITY: 2, // 招聘数量
URGENT: 4, // 是否急招 DESCRIPTION: 4, // 需求描述
DESCRIPTION: 5, // 需求描述
RECRUIT_TYPE: 3, // 招聘类型 RECRUIT_TYPE: 3, // 招聘类型
BUSINESS_TYPE: 1 // 业务类型 BUSINESS_TYPE: 1 // 业务类型
} }
...@@ -19,11 +18,7 @@ const VALIDATION_CONFIG = { ...@@ -19,11 +18,7 @@ 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({
...@@ -34,15 +29,13 @@ Page({ ...@@ -34,15 +29,13 @@ 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: 5, id: 4,
label: '需求描述', label: '需求描述',
placeholder: '请简单描述用人要求等信息', placeholder: '请简单描述用人要求等信息',
textCount: 0 textCount: 0
} }
], ],
switch1Checked: false,
showPopup: false, showPopup: false,
currentItem: {}, currentItem: {},
currentIndex: -1, currentIndex: -1,
...@@ -54,14 +47,6 @@ Page({ ...@@ -54,14 +47,6 @@ 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 label = item && item.label
if (label === '需求描述' || label === '招聘数量' || label === '是否急招')
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
...@@ -385,54 +370,15 @@ Page({ ...@@ -385,54 +370,15 @@ 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
...@@ -441,9 +387,7 @@ Page({ ...@@ -441,9 +387,7 @@ Page({
// 显示确认对话框 // 显示确认对话框
Dialog.confirm({ Dialog.confirm({
title: '提示', title: '提示',
message: isUrgent message: '是否确定提交招聘需求?',
? '申请急招,在招聘负责人推送简历后,需在24小时内完成简历跟进处理,否则将自动上报总部,请知悉!'
: '是否确定提交招聘需求?',
className: 'custom-dialog', className: 'custom-dialog',
confirmButtonText: '确定' confirmButtonText: '确定'
}) })
...@@ -544,7 +488,7 @@ Page({ ...@@ -544,7 +488,7 @@ Page({
resolve(options) resolve(options)
} }
}) })
.catch(err => { }) .catch(err => {})
} catch (err) { } catch (err) {
console.error('获取字典列表失败', err) console.error('获取字典列表失败', err)
reject(err) reject(err)
......
...@@ -4,15 +4,12 @@ page { ...@@ -4,15 +4,12 @@ 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);
...@@ -22,7 +19,6 @@ page { ...@@ -22,7 +19,6 @@ 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);
...@@ -31,14 +27,12 @@ page { ...@@ -31,14 +27,12 @@ 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;
...@@ -48,7 +42,6 @@ page { ...@@ -48,7 +42,6 @@ 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);
...@@ -58,7 +51,6 @@ page { ...@@ -58,7 +51,6 @@ 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);
...@@ -71,65 +63,20 @@ page { ...@@ -71,65 +63,20 @@ 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);
...@@ -140,23 +87,19 @@ page { ...@@ -140,23 +87,19 @@ 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);
...@@ -172,14 +115,12 @@ page { ...@@ -172,14 +115,12 @@ 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);
...@@ -189,14 +130,12 @@ page { ...@@ -189,14 +130,12 @@ page {
} }
} }
} }
.footer { .footer {
margin-top: var(--fontSize150); margin-top:var(--fontSize200);
.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;
...@@ -207,7 +146,6 @@ page { ...@@ -207,7 +146,6 @@ page {
} }
} }
} }
/* popup样式 */ /* popup样式 */
.popup-content { .popup-content {
height: 100%; height: 100%;
...@@ -216,17 +154,14 @@ page { ...@@ -216,17 +154,14 @@ 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);
...@@ -253,7 +188,6 @@ page { ...@@ -253,7 +188,6 @@ 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;
...@@ -302,11 +236,9 @@ page { ...@@ -302,11 +236,9 @@ 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;
...@@ -316,19 +248,15 @@ page { ...@@ -316,19 +248,15 @@ 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);
...@@ -336,7 +264,6 @@ page { ...@@ -336,7 +264,6 @@ page {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
} }
.option-check.checked { .option-check.checked {
color: #2C66F7; color: #2C66F7;
} }
...@@ -373,8 +300,7 @@ page { ...@@ -373,8 +300,7 @@ page {
padding: var(--fontSize20) 0; padding: var(--fontSize20) 0;
} }
.cancel-btn, .cancel-btn, .confirm-btn {
.confirm-btn {
width: var(--fontSize331); width: var(--fontSize331);
height: var(--fontSize80); height: var(--fontSize80);
border-radius: var(--fontSize24); border-radius: var(--fontSize24);
......
...@@ -3,24 +3,22 @@ ...@@ -3,24 +3,22 @@
<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}}">
<!-- bindtap="{{item.label === '需求描述' || item.label === '招聘数量' ? '' : 'showPopup'}}" -->
<view <view
class="form-item {{ item.label === '需求描述' ? 'form-item-textarea' : '' }}" class="form-item {{ item.label === '需求描述' ? 'form-item-textarea' : '' }}"
bindtap="onFormItemTap" bindtap="{{item.label === '需求描述' || item.label === '招聘数量' ? '' : 'showPopup'}}"
data-index="{{ index }}" 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.label !== '需求描述' }}" class="required">*</text>
</view> </view>
<block wx:if="{{ item.label === '是否急招' }}"> <view class="value" wx:if="{{ item.label !== '需求描述' && item.label !== '招聘数量' }}">
<view class="value"> <text class="display_value" wx:if="{{ item.displayValue }}">{{item.displayValue}}</text>
<switch checked="{{ switch1Checked }}" bindchange="switch1Change" /> <text class="placeholder" wx:else>{{item.placeholder}}</text>
<image class="arrow_right" src="/packageWorkspace/pages/image/arrow-right.png" mode="aspectFill" />
</view> </view>
</block> <view class="value" wx:if="{{ item.label === '招聘数量' }}">
<block wx:elif="{{ item.label === '招聘数量' }}">
<view class="value">
<input <input
class="number-input" class="number-input"
type="number" type="number"
...@@ -32,17 +30,6 @@ ...@@ -32,17 +30,6 @@
/> />
<text class="unit">人</text> <text class="unit">人</text>
</view> </view>
</block>
<block wx:elif="{{ item.label === '需求描述' }}">
<!-- 需求描述没有普通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.label === '需求描述' }}">
<textarea <textarea
...@@ -108,7 +95,7 @@ ...@@ -108,7 +95,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,10 +28,6 @@ export const statusList = [ ...@@ -28,10 +28,6 @@ export const statusList = [
{ {
confId: 3, confId: 3,
confName: '已驳回' confName: '已驳回'
},
{
confId: 4,
confName: '待督导确认'
} }
] ]
export const mentorshipFormData = [ export const mentorshipFormData = [
...@@ -129,50 +125,22 @@ export const statusTipConfig = { ...@@ -129,50 +125,22 @@ 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 { const config = statusTipConfig[item.status]
status, if (!config || !config.show) {
waitProcessResumeCount, return null
confirmFlag,
trialWaitConfirmCount,
onboardingWaitConfirmCount
} = item
// 待处理提示文案显示逻辑
if (status == 1 && waitProcessResumeCount > 0) {
return `您有${waitProcessResumeCount}份简历待处理,请及时跟进`
} else if (status == 1 && confirmFlag == 'N' && trialWaitConfirmCount > 0) {
return '您有新的试岗记录,请及时查看'
} else if (
status == 1 &&
confirmFlag == 'N' &&
onboardingWaitConfirmCount > 0
) {
return '您有新的入职记录,请及时查看'
} else if (status == 2 && confirmFlag == 'N') {
return '您的招聘需求已完成,请及时查看'
} else if (status == 3 && confirmFlag == 'N') {
return '您的招聘需求已拒绝,请及时查看'
} }
// 如果有显示条件,先判断条件
if (config.showCondition && !config.showCondition(item)) {
return null return null
}
// 如果 text 是函数,执行函数获取文本
if (typeof config.text === 'function') {
return config.text(item)
}
return config.text
} }
...@@ -4,8 +4,7 @@ import { ...@@ -4,8 +4,7 @@ import {
getStatusTipText getStatusTipText
} from './constantData' } from './constantData'
import { getRecruitList, waitstaffstateAPI, confiremStaffFlagAPI } from '../api' import { getRecruitList, waitstaffstateAPI, confiremStaffFlagAPI } from '../api'
const IMG_URL = const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/'
'https://img02.glsx.com.cn/weapp/resource/miniprogram/regional-assistant/'
Page({ Page({
/** /**
* 页面的初始数据 * 页面的初始数据
...@@ -33,8 +32,8 @@ Page({ ...@@ -33,8 +32,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) {
...@@ -81,7 +80,6 @@ Page({ ...@@ -81,7 +80,6 @@ Page({
// 标签切换 // 标签切换
tabClick(e) { tabClick(e) {
if (this.data.tabIndex === e.detail) return
this.setData( this.setData(
{ {
tabIndex: e.detail, tabIndex: e.detail,
...@@ -163,7 +161,7 @@ Page({ ...@@ -163,7 +161,7 @@ Page({
} }
) )
//仅已完成/以驳回可以调用flag接口 //仅已完成/以驳回可以调用flag接口
if (item.status == 0) return if (item.status == 0 || item.status == 1) 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) {
......
...@@ -96,12 +96,7 @@ page { ...@@ -96,12 +96,7 @@ page {
align-items: center; align-items: center;
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;
......
...@@ -33,7 +33,6 @@ ...@@ -33,7 +33,6 @@
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>
...@@ -47,7 +46,7 @@ ...@@ -47,7 +46,7 @@
</block> </block>
</view> </view>
<!-- 提示消息 --> <!-- 提示消息 -->
<view class="item_footer" wx:if="{{ tabIndex == 0 && item.showTip }}"> <view class="item_footer" wx:if="{{ tabIndex == 0 && item.showTip && item.confirmFlag == 'N' && item.status !== 0 }}">
<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" />
...@@ -67,7 +66,7 @@ ...@@ -67,7 +66,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>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!