Compare commits
2 Commits
e6e1b6ada1
...
43eb458c6a
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
43eb458c6a | ||
|
|
809e57347a |
@@ -53,6 +53,24 @@
|
|||||||
</radio-group>
|
</radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
<!-- 薪资 -->
|
||||||
|
<view v-if="activeTab === 'salary'" class="content-section">
|
||||||
|
<radio-group @change="(e) => handleSelect('salary', e)">
|
||||||
|
<label
|
||||||
|
v-for="option in salaryOptions"
|
||||||
|
:key="option.value"
|
||||||
|
class="radio-item"
|
||||||
|
:class="{ checked: selectedValues['salary'] === String(option.value) }"
|
||||||
|
>
|
||||||
|
<radio
|
||||||
|
:value="String(option.value)"
|
||||||
|
:checked="selectedValues['salary'] === String(option.value)"
|
||||||
|
/>
|
||||||
|
<text class="option-label">{{ option.label }}</text>
|
||||||
|
</label>
|
||||||
|
</radio-group>
|
||||||
|
</view>
|
||||||
|
|
||||||
<!-- 公司规模 -->
|
<!-- 公司规模 -->
|
||||||
<view v-if="activeTab === 'scale'" class="content-section">
|
<view v-if="activeTab === 'scale'" class="content-section">
|
||||||
<radio-group @change="(e) => handleSelect('scale', e)">
|
<radio-group @change="(e) => handleSelect('scale', e)">
|
||||||
@@ -143,6 +161,7 @@ const getJobTypeData = () => {
|
|||||||
const tabs = [
|
const tabs = [
|
||||||
{ key: 'education', label: '学历要求' },
|
{ key: 'education', label: '学历要求' },
|
||||||
{ key: 'experience', label: '工作经验' },
|
{ key: 'experience', label: '工作经验' },
|
||||||
|
{ key: 'salary', label: '薪资' },
|
||||||
{ key: 'scale', label: '公司规模' },
|
{ key: 'scale', label: '公司规模' },
|
||||||
{ key: 'jobType', label: '岗位类型' },
|
{ key: 'jobType', label: '岗位类型' },
|
||||||
{ key: 'area', label: '地区' }
|
{ key: 'area', label: '地区' }
|
||||||
@@ -155,6 +174,7 @@ const activeTab = ref('education');
|
|||||||
const selectedValues = reactive({
|
const selectedValues = reactive({
|
||||||
education: '',
|
education: '',
|
||||||
experience: '',
|
experience: '',
|
||||||
|
salary: '',
|
||||||
scale: '',
|
scale: '',
|
||||||
area: '',
|
area: '',
|
||||||
jobType: ''
|
jobType: ''
|
||||||
@@ -167,6 +187,16 @@ const scaleOptions = ref([]);
|
|||||||
const areaOptions = ref([]);
|
const areaOptions = ref([]);
|
||||||
const jobTypeOptions = ref([]);
|
const jobTypeOptions = ref([]);
|
||||||
|
|
||||||
|
// 薪资区间数据(单位:元/月),min/max 为空表示该侧不设限
|
||||||
|
const salaryOptions = ref([
|
||||||
|
{ label: '3K以下', value: '0-3000', min: '', max: 3000 },
|
||||||
|
{ label: '3-5K', value: '3000-5000', min: 3000, max: 5000 },
|
||||||
|
{ label: '5-10K', value: '5000-10000', min: 5000, max: 10000 },
|
||||||
|
{ label: '10-20K', value: '10000-20000', min: 10000, max: 20000 },
|
||||||
|
{ label: '20-50K', value: '20000-50000', min: 20000, max: 50000 },
|
||||||
|
{ label: '50K以上', value: '50000-0', min: 50000, max: '' },
|
||||||
|
]);
|
||||||
|
|
||||||
// 加载状态
|
// 加载状态
|
||||||
const loading = ref(true);
|
const loading = ref(true);
|
||||||
|
|
||||||
@@ -202,8 +232,23 @@ const handleClear = () => {
|
|||||||
|
|
||||||
// 确认筛选
|
// 确认筛选
|
||||||
const handleConfirm = () => {
|
const handleConfirm = () => {
|
||||||
console.log('selectedValues:', selectedValues);
|
const payload = { ...selectedValues };
|
||||||
emit('confirm', selectedValues);
|
// 将选中的薪资区间转换为 minSalary / maxSalary 参数
|
||||||
|
// 始终带上 minSalary / maxSalary(含空值),便于父组件在清除时移除旧值
|
||||||
|
let minSalary = '';
|
||||||
|
let maxSalary = '';
|
||||||
|
if (payload.salary) {
|
||||||
|
const selected = salaryOptions.value.find((item) => item.value === payload.salary);
|
||||||
|
if (selected) {
|
||||||
|
minSalary = selected.min;
|
||||||
|
maxSalary = selected.max;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
payload.minSalary = minSalary;
|
||||||
|
payload.maxSalary = maxSalary;
|
||||||
|
delete payload.salary;
|
||||||
|
console.log('selectedValues:', payload);
|
||||||
|
emit('confirm', payload);
|
||||||
handleClose();
|
handleClose();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
50
package-lock.json
generated
50
package-lock.json
generated
@@ -1,11 +1,13 @@
|
|||||||
{
|
{
|
||||||
|
"name": "ks-app-employment-service",
|
||||||
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@dcloudio/uni-ui": "^1.5.11",
|
"@dcloudio/uni-ui": "^1.5.11",
|
||||||
|
"crypto-js": "^3.3.0",
|
||||||
"dayjs": "^1.11.19",
|
"dayjs": "^1.11.19",
|
||||||
"mp-html": "^2.5.2",
|
|
||||||
"sm-crypto": "^0.3.13"
|
"sm-crypto": "^0.3.13"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
@@ -13,40 +15,36 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@dcloudio/uni-ui": {
|
"node_modules/@dcloudio/uni-ui": {
|
||||||
"lockfileVersion": 1,
|
"version": "1.5.12",
|
||||||
"dependencies": {
|
"resolved": "https://registry.npmjs.org/@dcloudio/uni-ui/-/uni-ui-1.5.12.tgz",
|
||||||
"@dcloudio/uni-ui": {
|
"integrity": "sha512-mGDl2OZSz7D8xcUAzJegWDHOqB4MEFBSW9Esb/oJiu2/3Gk9+P/Z4bA4JZ9jv9VWBYbMrYwaTfK1Z728kABdYg==",
|
||||||
"version": "1.5.11",
|
"license": "Apache-2.0"
|
||||||
"resolved": "https://registry.npmmirror.com/@dcloudio/uni-ui/-/uni-ui-1.5.11.tgz",
|
|
||||||
"integrity": "sha512-DBtk046ofmeFd82zRI7d89SoEwrAxYzUN3WVPm1DIBkpLPG5F5QDNkHMnZGu2wNrMEmGBjBpUh3vqEY1L3jaMw=="
|
|
||||||
},
|
},
|
||||||
"node_modules/crypto-js": {
|
"node_modules/crypto-js": {
|
||||||
"version": "4.2.0",
|
"version": "4.2.0",
|
||||||
"resolved": "https://registry.npmmirror.com/crypto-js/-/crypto-js-4.2.0.tgz",
|
"resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.2.0.tgz",
|
||||||
"integrity": "sha512-KALDyEYgpY+Rlob/iriUtjV6d5Eq+Y191A5g4UqLAi8CyGP9N1+FdVbkc1SxKc2r4YAYqG8JzO2KGL+AizD70Q==",
|
"integrity": "sha512-KALDyEYgpY+Rlob/iriUtjV6d5Eq+Y191A5g4UqLAi8CyGP9N1+FdVbkc1SxKc2r4YAYqG8JzO2KGL+AizD70Q==",
|
||||||
"dev": true
|
"dev": true,
|
||||||
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/dayjs": {
|
"node_modules/dayjs": {
|
||||||
"crypto-js": {
|
"version": "1.11.21",
|
||||||
"version": "3.3.0",
|
"resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.21.tgz",
|
||||||
"resolved": "https://registry.npmmirror.com/crypto-js/-/crypto-js-3.3.0.tgz",
|
"integrity": "sha512-98IT+HOahAisibz/yjKbzuOBwYcjJ7BCLPzARyHiyEBmRz4fatF+KPJszEHXsGYjUG234aH/cOjW1wwTbKUZlA==",
|
||||||
"integrity": "sha512-DIT51nX0dCfKltpRiXV+/TVZq+Qq2NgF4644+K7Ttnla7zEzqc+kjJyiB96BHNyUTBxyjzRcZYpUdZa+QAqi6Q=="
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"dayjs": {
|
"node_modules/jsbn": {
|
||||||
"version": "1.11.19",
|
|
||||||
"resolved": "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.19.tgz",
|
|
||||||
"integrity": "sha512-t5EcLVS6QPBNqM2z8fakk/NKel+Xzshgt8FFKAn+qwlD1pzZWxh0nVCrvFK7ZDb6XucZeF9z8C7CBWTRIVApAw=="
|
|
||||||
},
|
|
||||||
"jsbn": {
|
|
||||||
"version": "1.1.0",
|
"version": "1.1.0",
|
||||||
"resolved": "https://registry.npmmirror.com/jsbn/-/jsbn-1.1.0.tgz",
|
"resolved": "https://registry.npmjs.org/jsbn/-/jsbn-1.1.0.tgz",
|
||||||
"integrity": "sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A=="
|
"integrity": "sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A==",
|
||||||
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"sm-crypto": {
|
"node_modules/sm-crypto": {
|
||||||
"version": "0.3.13",
|
"version": "0.3.14",
|
||||||
"resolved": "https://registry.npmmirror.com/sm-crypto/-/sm-crypto-0.3.13.tgz",
|
"resolved": "https://registry.npmjs.org/sm-crypto/-/sm-crypto-0.3.14.tgz",
|
||||||
"integrity": "sha512-ztNF+pZq6viCPMA1A6KKu3bgpkmYti5avykRHbcFIdSipFdkVmfUw2CnpM2kBJyppIalqvczLNM3wR8OQ0pT5w==",
|
"integrity": "sha512-sR7NuGAJH93Om8keAF2/rj1EqFzEiUey4aKGyDo3nQ2BiVqhgq8UkiIoIp5qhV9w4pG7qArhfqyewcG8AbhXbg==",
|
||||||
"requires": {
|
"license": "MIT",
|
||||||
|
"dependencies": {
|
||||||
"jsbn": "^1.1.0"
|
"jsbn": "^1.1.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,12 +10,7 @@
|
|||||||
<view class="card-content">
|
<view class="card-content">
|
||||||
<!-- 企业图标 -->
|
<!-- 企业图标 -->
|
||||||
<view class="company-icon">
|
<view class="company-icon">
|
||||||
<image
|
<image v-if="companyInfo.avatar" :src="companyInfo.avatar" class="logo-image" mode="aspectFit" />
|
||||||
v-if="companyInfo.avatar"
|
|
||||||
:src="companyInfo.avatar"
|
|
||||||
class="logo-image"
|
|
||||||
mode="aspectFit"
|
|
||||||
/>
|
|
||||||
<view v-else class="default-logo">
|
<view v-else class="default-logo">
|
||||||
<uni-icons type="home-filled" size="32" color="#256BFA"></uni-icons>
|
<uni-icons type="home-filled" size="32" color="#256BFA"></uni-icons>
|
||||||
</view>
|
</view>
|
||||||
@@ -25,7 +20,9 @@
|
|||||||
<view class="company-info">
|
<view class="company-info">
|
||||||
<view class="company-name">{{ companyInfo.name || '企业名称' }}</view>
|
<view class="company-name">{{ companyInfo.name || '企业名称' }}</view>
|
||||||
<view class="company-details">
|
<view class="company-details">
|
||||||
<text class="size">企业规模: {{ getDictLabel('scale', companyInfo.scale) || '暂无规模数据' }}</text>
|
<text class="size">
|
||||||
|
企业规模: {{ getDictLabel('scale', companyInfo.scale) || '暂无规模数据' }}
|
||||||
|
</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@@ -41,10 +38,7 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view
|
<view class="nav-hidden hidden-animation" :class="{ 'hidden-height': shouldHideTop }">
|
||||||
class="nav-hidden hidden-animation"
|
|
||||||
:class="{ 'hidden-height': shouldHideTop }"
|
|
||||||
>
|
|
||||||
<view class="container-search" v-if="shouldShowJobSeekerContent">
|
<view class="container-search" v-if="shouldShowJobSeekerContent">
|
||||||
<view class="search-input button-click" @click="navTo('/pages/search/search')">
|
<view class="search-input button-click" @click="navTo('/pages/search/search')">
|
||||||
<uni-icons class="iconsearch" color="#666666" type="search" size="18"></uni-icons>
|
<uni-icons class="iconsearch" color="#666666" type="search" size="18"></uni-icons>
|
||||||
@@ -81,7 +75,6 @@
|
|||||||
<view class="h5-action-btn press-button" @click="handleServiceClick('resume-creation')">
|
<view class="h5-action-btn press-button" @click="handleServiceClick('resume-creation')">
|
||||||
<view class="btn-text">简历指导</view>
|
<view class="btn-text">简历指导</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
<!-- #endif -->
|
<!-- #endif -->
|
||||||
<!-- 服务功能网格 -->
|
<!-- 服务功能网格 -->
|
||||||
@@ -186,11 +179,15 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="service-title">评价机构信息</view>
|
<view class="service-title">评价机构信息</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="service-item press-button" style="justify-content:normal" @click="goRc()">
|
<view class="service-item press-button" style="justify-content: normal" @click="goRc()">
|
||||||
<view class="service-icon service-icon-9">
|
<view class="service-icon service-icon-9">
|
||||||
<IconfontIcon name="Graduation-simple-" :size="32" color="#FFFFFF" />
|
<IconfontIcon name="Graduation-simple-" :size="32" color="#FFFFFF" />
|
||||||
</view>
|
</view>
|
||||||
<view class="service-title" style="overflow:unset">高校毕业生<br/>智慧就业服务</view>
|
<view class="service-title" style="overflow: unset">
|
||||||
|
高校毕业生
|
||||||
|
<br />
|
||||||
|
智慧就业服务
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- #endif -->
|
<!-- #endif -->
|
||||||
@@ -234,25 +231,16 @@
|
|||||||
<!-- 吸顶筛选区域占位 -->
|
<!-- 吸顶筛选区域占位 -->
|
||||||
<view class="filter-placeholder" v-if="shouldStickyFilter && shouldShowJobSeekerContent"></view>
|
<view class="filter-placeholder" v-if="shouldStickyFilter && shouldShowJobSeekerContent"></view>
|
||||||
|
|
||||||
|
|
||||||
<view class="nav-filter" :class="{ 'sticky-filter': shouldStickyFilter }" v-if="shouldShowJobSeekerContent">
|
<view class="nav-filter" :class="{ 'sticky-filter': shouldStickyFilter }" v-if="shouldShowJobSeekerContent">
|
||||||
<view class="filter-top">
|
<view class="filter-top">
|
||||||
<scroll-view :scroll-x="true" :show-scrollbar="false" class="tab-scroll">
|
<scroll-view :scroll-x="true" :show-scrollbar="false" class="tab-scroll">
|
||||||
<view class="jobs-left">
|
<view class="jobs-left">
|
||||||
<view
|
<view class="job button-click" :class="{ active: state.tabIndex === 'all' }"
|
||||||
class="job button-click"
|
@click="choosePosition('all')">
|
||||||
:class="{ active: state.tabIndex === 'all' }"
|
|
||||||
@click="choosePosition('all')"
|
|
||||||
>
|
|
||||||
全部
|
全部
|
||||||
</view>
|
</view>
|
||||||
<view
|
<view class="job button-click" :class="{ active: state.tabIndex === index }"
|
||||||
class="job button-click"
|
v-for="(item, index) in userInfo.jobTitle" :key="index" @click="choosePosition(index)">
|
||||||
:class="{ active: state.tabIndex === index }"
|
|
||||||
v-for="(item, index) in userInfo.jobTitle"
|
|
||||||
:key="index"
|
|
||||||
@click="choosePosition(index)"
|
|
||||||
>
|
|
||||||
{{ item }}
|
{{ item }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -262,20 +250,16 @@
|
|||||||
<uni-icons class="iconsearch" color="#666D7F" type="plusempty" size="18"></uni-icons>
|
<uni-icons class="iconsearch" color="#666D7F" type="plusempty" size="18"></uni-icons>
|
||||||
<text>添加</text>
|
<text>添加</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="jobs-add button-click" @click="navTo('/packageA/pages/city-select/index')" style="padding-right:0;">
|
<view class="jobs-add button-click" @click="navTo('/packageA/pages/city-select/index')"
|
||||||
|
style="padding-right: 0">
|
||||||
<text>{{ selectedCity.name || '地区' }}</text>
|
<text>{{ selectedCity.name || '地区' }}</text>
|
||||||
<image class="right-sx" :class="{ active: showFilter }" src="@/static/icon/shaixun.png"></image>
|
<image class="right-sx" :class="{ active: showFilter }" src="@/static/icon/shaixun.png"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="filter-bottom">
|
<view class="filter-bottom">
|
||||||
<view class="btm-left">
|
<view class="btm-left">
|
||||||
<view
|
<view class="button-click filterbtm" :class="{ active: pageState.search.order === item.value }"
|
||||||
class="button-click filterbtm"
|
v-for="item in rangeOptions" @click="handelHostestSearch(item)" :key="item.value">
|
||||||
:class="{ active: pageState.search.order === item.value }"
|
|
||||||
v-for="item in rangeOptions"
|
|
||||||
@click="handelHostestSearch(item)"
|
|
||||||
:key="item.value"
|
|
||||||
>
|
|
||||||
{{ item.text }}
|
{{ item.text }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -286,40 +270,23 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="table-list">
|
<view class="table-list">
|
||||||
<scroll-view
|
<scroll-view :scroll-y="true" class="falls-scroll" @scroll="handleScroll" @scrolltolower="scrollBottom"
|
||||||
:scroll-y="true"
|
:enable-back-to-top="false" :scroll-with-animation="false">
|
||||||
class="falls-scroll"
|
|
||||||
@scroll="handleScroll"
|
|
||||||
@scrolltolower="scrollBottom"
|
|
||||||
:enable-back-to-top="false"
|
|
||||||
:scroll-with-animation="false"
|
|
||||||
>
|
|
||||||
<view class="falls" v-if="list.length">
|
<view class="falls" v-if="list.length">
|
||||||
<!-- #ifdef MP-WEIXIN -->
|
<!-- #ifdef MP-WEIXIN -->
|
||||||
<!-- 小程序使用具名插槽 -->
|
<!-- 小程序使用具名插槽 -->
|
||||||
<custom-waterfalls-flow
|
<custom-waterfalls-flow :column="columnCount" :columnSpace="columnSpace" ref="waterfallsFlowRef"
|
||||||
:column="columnCount"
|
:value="list">
|
||||||
:columnSpace="columnSpace"
|
|
||||||
ref="waterfallsFlowRef"
|
|
||||||
:value="list"
|
|
||||||
>
|
|
||||||
<view v-for="(job, index) in list" :key="index" :slot="`slot${index}`">
|
<view v-for="(job, index) in list" :key="index" :slot="`slot${index}`">
|
||||||
<view class="item" v-if="!job.recommend">
|
<view class="item" v-if="!job.recommend">
|
||||||
<view
|
<view class="falls-card" :class="{
|
||||||
class="falls-card"
|
'disabled-card': Number(job.isPublish) === 0,
|
||||||
:class="{
|
}" @click="Number(job.isPublish) === 1 ? nextDetail(job) : null">
|
||||||
'disabled-card': Number(job.isPublish) === 0
|
|
||||||
}"
|
|
||||||
@click="Number(job.isPublish) === 1 ? nextDetail(job) : null"
|
|
||||||
>
|
|
||||||
<view class="falls-card-pay">
|
<view class="falls-card-pay">
|
||||||
<view class="fl_1 falls-card-title">{{ job.jobTitle }}</view>
|
<view class="fl_1 falls-card-title">{{ job.jobTitle }}</view>
|
||||||
<view class="fr_1 pay-text">
|
<view class="fr_1 pay-text">
|
||||||
<Salary-Expectation
|
<Salary-Expectation :max-salary="job.maxSalary" :min-salary="job.minSalary"
|
||||||
:max-salary="job.maxSalary"
|
:is-month="true"></Salary-Expectation>
|
||||||
:min-salary="job.minSalary"
|
|
||||||
:is-month="true"
|
|
||||||
></Salary-Expectation>
|
|
||||||
</view>
|
</view>
|
||||||
<image v-if="job.isHot" class="flame" src="/static/icon/flame.png"></image>
|
<image v-if="job.isHot" class="flame" src="/static/icon/flame.png"></image>
|
||||||
</view>
|
</view>
|
||||||
@@ -343,16 +310,11 @@
|
|||||||
<view class="falls-card-pepleNumber">
|
<view class="falls-card-pepleNumber">
|
||||||
<view>
|
<view>
|
||||||
<image class="point2" src="/static/icon/pintDate.png"></image>
|
<image class="point2" src="/static/icon/pintDate.png"></image>
|
||||||
<view class="fl_1">
|
<view class="fl_1">发布日期:{{ job.postingDate || '暂无数据' }}</view>
|
||||||
发布日期:{{ job.postingDate || '暂无数据' }}
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
<view>
|
<view>
|
||||||
|
|
||||||
<image class="point3" src="/static/icon/pointpeople.png"></image>
|
<image class="point3" src="/static/icon/pointpeople.png"></image>
|
||||||
<view class="fl_1">
|
<view class="fl_1">招聘人数:{{ vacanciesTo(job.vacancies) }}</view>
|
||||||
招聘人数:{{ vacanciesTo(job.vacancies) }}
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="falls-card-company2">
|
<view class="falls-card-company2">
|
||||||
@@ -360,19 +322,16 @@
|
|||||||
<view class="fl_1">
|
<view class="fl_1">
|
||||||
{{ job.companyName }}
|
{{ job.companyName }}
|
||||||
</view>
|
</view>
|
||||||
<view class="fr-1" v-if="job.regionName">
|
<view class="fr-1" v-if="job.regionName">地区:{{ job.regionName }}</view>
|
||||||
地区:{{ job.regionName }}
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
<!-- 未通过审核状态显示 -->
|
<!-- 未通过审核状态显示 -->
|
||||||
<view class="unpublished-badge" v-if="Number(job.isPublish) === 0">
|
<view class="unpublished-badge" v-if="Number(job.isPublish) === 0">未通过审核</view>
|
||||||
未通过审核
|
|
||||||
</view>
|
|
||||||
<!-- 招聘者显示上下架开关 -->
|
<!-- 招聘者显示上下架开关 -->
|
||||||
<view class="falls-card-actions" v-if="isRecruiter && Number(job.isPublish) === 1">
|
<view class="falls-card-actions" v-if="isRecruiter && Number(job.isPublish) === 1">
|
||||||
<view class="job-status-switch" @click.stop="toggleJobStatus(job)">
|
<view class="job-status-switch" @click.stop="toggleJobStatus(job)">
|
||||||
<view class="switch-track" :class="{ 'active': Number(job.jobStatus) === 0 }">
|
<view class="switch-track" :class="{ active: Number(job.jobStatus) === 0 }">
|
||||||
<view class="switch-thumb" :class="{ 'active': Number(job.jobStatus) === 0 }"></view>
|
<view class="switch-thumb"
|
||||||
|
:class="{ active: Number(job.jobStatus) === 0 }"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="switch-label">
|
<view class="switch-label">
|
||||||
{{ Number(job.jobStatus) === 0 ? '已上架' : '已下架' }}
|
{{ Number(job.jobStatus) === 0 ? '已上架' : '已下架' }}
|
||||||
@@ -403,29 +362,20 @@
|
|||||||
<!-- #endif -->
|
<!-- #endif -->
|
||||||
<!-- #ifndef MP-WEIXIN -->
|
<!-- #ifndef MP-WEIXIN -->
|
||||||
<!-- H5/App使用作用域插槽 -->
|
<!-- H5/App使用作用域插槽 -->
|
||||||
<custom-waterfalls-flow
|
<custom-waterfalls-flow :column="columnCount" :columnSpace="columnSpace" ref="waterfallsFlowRef"
|
||||||
:column="columnCount"
|
:value="list">
|
||||||
:columnSpace="columnSpace"
|
|
||||||
ref="waterfallsFlowRef"
|
|
||||||
:value="list"
|
|
||||||
>
|
|
||||||
<template v-slot:default="job">
|
<template v-slot:default="job">
|
||||||
<view class="item" v-if="!job.recommend">
|
<view class="item" v-if="!job.recommend">
|
||||||
<view
|
<view class="falls-card" :class="{
|
||||||
class="falls-card"
|
'disabled-card':
|
||||||
:class="{
|
(Number(job.jobStatus) === 1 || Number(job.isPublish) === 0) &&
|
||||||
'disabled-card': (Number(job.jobStatus) === 1 || Number(job.isPublish) === 0) && currentUserType !== 0
|
currentUserType !== 0,
|
||||||
}"
|
}" @click="Number(job.isPublish) === 1 ? nextDetail(job) : null">
|
||||||
@click="Number(job.isPublish) === 1 ? nextDetail(job) : null"
|
|
||||||
>
|
|
||||||
<view class="falls-card-pay">
|
<view class="falls-card-pay">
|
||||||
<view class="fl_1 falls-card-title">{{ job.jobTitle }}</view>
|
<view class="fl_1 falls-card-title">{{ job.jobTitle }}</view>
|
||||||
<view class="fr_1 pay-text">
|
<view class="fr_1 pay-text">
|
||||||
<Salary-Expectation
|
<Salary-Expectation :max-salary="job.maxSalary" :min-salary="job.minSalary"
|
||||||
:max-salary="job.maxSalary"
|
:is-month="true"></Salary-Expectation>
|
||||||
:min-salary="job.minSalary"
|
|
||||||
:is-month="true"
|
|
||||||
></Salary-Expectation>
|
|
||||||
</view>
|
</view>
|
||||||
<image v-if="job.isHot" class="flame" src="/static/icon/flame.png"></image>
|
<image v-if="job.isHot" class="flame" src="/static/icon/flame.png"></image>
|
||||||
</view>
|
</view>
|
||||||
@@ -446,9 +396,7 @@
|
|||||||
<view class="falls-card-pepleNumber">
|
<view class="falls-card-pepleNumber">
|
||||||
<view>
|
<view>
|
||||||
<image class="point2" src="/static/icon/pintDate.png"></image>
|
<image class="point2" src="/static/icon/pintDate.png"></image>
|
||||||
<view class="fl_1">
|
<view class="fl_1">发布日期:{{ job.postingDate || '暂无数据' }}</view>
|
||||||
发布日期:{{ job.postingDate || '暂无数据' }}
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
<view>
|
<view>
|
||||||
<image class="point3" src="/static/icon/pointpeople.png"></image>
|
<image class="point3" src="/static/icon/pointpeople.png"></image>
|
||||||
@@ -462,19 +410,16 @@
|
|||||||
<view class="fl_1">
|
<view class="fl_1">
|
||||||
{{ job.companyName }}
|
{{ job.companyName }}
|
||||||
</view>
|
</view>
|
||||||
<view class="fr-1" v-if="job.regionName">
|
<view class="fr-1" v-if="job.regionName">地区:{{ job.regionName }}</view>
|
||||||
地区:{{ job.regionName }}
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
<!-- 未通过审核状态显示 -->
|
<!-- 未通过审核状态显示 -->
|
||||||
<view class="unpublished-badge" v-if="Number(job.isPublish) === 0">
|
<view class="unpublished-badge" v-if="Number(job.isPublish) === 0">未通过审核</view>
|
||||||
未通过审核
|
|
||||||
</view>
|
|
||||||
<!-- 招聘者显示上下架开关 -->
|
<!-- 招聘者显示上下架开关 -->
|
||||||
<view class="falls-card-actions" v-if="isRecruiter && Number(job.isPublish) === 1">
|
<view class="falls-card-actions" v-if="isRecruiter && Number(job.isPublish) === 1">
|
||||||
<view class="job-status-switch" @click.stop="toggleJobStatus(job)">
|
<view class="job-status-switch" @click.stop="toggleJobStatus(job)">
|
||||||
<view class="switch-track" :class="{ 'active': Number(job.jobStatus) === 0 }">
|
<view class="switch-track" :class="{ active: Number(job.jobStatus) === 0 }">
|
||||||
<view class="switch-thumb" :class="{ 'active': Number(job.jobStatus) === 0 }"></view>
|
<view class="switch-thumb"
|
||||||
|
:class="{ active: Number(job.jobStatus) === 0 }"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="switch-label">
|
<view class="switch-label">
|
||||||
{{ Number(job.jobStatus) === 0 ? '已上架' : '已下架' }}
|
{{ Number(job.jobStatus) === 0 ? '已上架' : '已下架' }}
|
||||||
@@ -511,14 +456,8 @@
|
|||||||
<!-- 筛选 -->
|
<!-- 筛选 -->
|
||||||
<select-filter ref="selectFilterModel" />
|
<select-filter ref="selectFilterModel" />
|
||||||
<!-- 新筛选页面 -->
|
<!-- 新筛选页面 -->
|
||||||
<new-filter-page
|
<new-filter-page :show="showNewFilter" @confirm="handleNewFilterConfirm" @close="handleNewFilterClose"
|
||||||
:show="showNewFilter"
|
@update:show="(value) => (showNewFilter = value)" />
|
||||||
@confirm="handleNewFilterConfirm"
|
|
||||||
@close="handleNewFilterClose"
|
|
||||||
@update:show="(value) => showNewFilter = value"
|
|
||||||
/>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- <view class="maskFristEntry" v-if="maskFristEntry">
|
<!-- <view class="maskFristEntry" v-if="maskFristEntry">
|
||||||
<view class="entry-content">
|
<view class="entry-content">
|
||||||
@@ -568,7 +507,7 @@ const companyInfo = reactive({
|
|||||||
avatar: '',
|
avatar: '',
|
||||||
industry: '',
|
industry: '',
|
||||||
scale: '',
|
scale: '',
|
||||||
isVerified: false
|
isVerified: false,
|
||||||
});
|
});
|
||||||
|
|
||||||
// 计算是否显示企业卡片
|
// 计算是否显示企业卡片
|
||||||
@@ -653,7 +592,7 @@ import { useRecommedIndexedDBStore, jobRecommender } from '@/stores/useRecommedI
|
|||||||
import { useScrollDirection } from '@/hook/useScrollDirection';
|
import { useScrollDirection } from '@/hook/useScrollDirection';
|
||||||
import { useColumnCount } from '@/hook/useColumnCount';
|
import { useColumnCount } from '@/hook/useColumnCount';
|
||||||
|
|
||||||
import IconfontIcon from '@/components/IconfontIcon/IconfontIcon.vue'
|
import IconfontIcon from '@/components/IconfontIcon/IconfontIcon.vue';
|
||||||
// 企业卡片组件已内联到模板中
|
// 企业卡片组件已内联到模板中
|
||||||
// 滚动状态管理
|
// 滚动状态管理
|
||||||
const shouldHideTop = ref(false);
|
const shouldHideTop = ref(false);
|
||||||
@@ -751,9 +690,9 @@ const state = reactive({
|
|||||||
const helpClick = () => {
|
const helpClick = () => {
|
||||||
navTo('/packageB/priority/helpFilter');
|
navTo('/packageB/priority/helpFilter');
|
||||||
};
|
};
|
||||||
const helpTaskClick = () =>{
|
const helpTaskClick = () => {
|
||||||
navTo('/packageB/priority/index');
|
navTo('/packageB/priority/index');
|
||||||
}
|
};
|
||||||
//招聘会模块跳转
|
//招聘会模块跳转
|
||||||
const handleJobFairClick = () => {
|
const handleJobFairClick = () => {
|
||||||
if (checkLogin()) {
|
if (checkLogin()) {
|
||||||
@@ -782,7 +721,7 @@ const rangeOptions = ref([
|
|||||||
{ value: 1, text: '最热' },
|
{ value: 1, text: '最热' },
|
||||||
{ value: 2, text: '最新发布' },
|
{ value: 2, text: '最新发布' },
|
||||||
// { value: 3, text: '疆外' },
|
// { value: 3, text: '疆外' },
|
||||||
{ value: 4, text: '零工市场' }
|
{ value: 4, text: '零工岗位' },
|
||||||
]);
|
]);
|
||||||
const isLoaded = ref(false);
|
const isLoaded = ref(false);
|
||||||
const isInitialized = ref(false); // 添加初始化标志
|
const isInitialized = ref(false); // 添加初始化标志
|
||||||
@@ -833,7 +772,7 @@ const getCompanyInfo = () => {
|
|||||||
name: companyInfo.name,
|
name: companyInfo.name,
|
||||||
industry: companyInfo.industry,
|
industry: companyInfo.industry,
|
||||||
size: companyInfo.scale,
|
size: companyInfo.scale,
|
||||||
isVerified: companyInfo.isVerified
|
isVerified: companyInfo.isVerified,
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
console.log('缓存中没有company字段,企业信息已重置');
|
console.log('缓存中没有company字段,企业信息已重置');
|
||||||
@@ -854,7 +793,6 @@ const goToCompanyInfo = () => {
|
|||||||
navTo('/packageA/pages/company-mine/company-info');
|
navTo('/packageA/pages/company-mine/company-info');
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
// 组件初始化时加载数据
|
// 组件初始化时加载数据
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
// 获取企业信息
|
// 获取企业信息
|
||||||
@@ -906,11 +844,15 @@ onShow(() => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// 监听用户信息变化,当登录状态改变时重新获取企业信息
|
// 监听用户信息变化,当登录状态改变时重新获取企业信息
|
||||||
watch([hasLogin, userInfo], () => {
|
watch(
|
||||||
|
[hasLogin, userInfo],
|
||||||
|
() => {
|
||||||
if (hasLogin.value) {
|
if (hasLogin.value) {
|
||||||
getCompanyInfo();
|
getCompanyInfo();
|
||||||
}
|
}
|
||||||
}, { deep: true });
|
},
|
||||||
|
{ deep: true }
|
||||||
|
);
|
||||||
|
|
||||||
// 登录检查函数
|
// 登录检查函数
|
||||||
const checkLogin = () => {
|
const checkLogin = () => {
|
||||||
@@ -931,7 +873,7 @@ const handleLoginSuccess = () => {
|
|||||||
// 重新获取企业信息
|
// 重新获取企业信息
|
||||||
getCompanyInfo();
|
getCompanyInfo();
|
||||||
//四级联动单点及权限
|
//四级联动单点及权限
|
||||||
getIsFourLevelLinkagePurview()
|
getIsFourLevelLinkagePurview();
|
||||||
};
|
};
|
||||||
// H5环境下从URL获取token并自动登录
|
// H5环境下从URL获取token并自动登录
|
||||||
// onLoad 函数已移至下方,包含筛选参数处理
|
// onLoad 函数已移至下方,包含筛选参数处理
|
||||||
@@ -940,29 +882,25 @@ const handleLoginSuccess = () => {
|
|||||||
const handleNearbyClick = () => {
|
const handleNearbyClick = () => {
|
||||||
navTo('/packageA/pages/nearby/nearby');
|
navTo('/packageA/pages/nearby/nearby');
|
||||||
};
|
};
|
||||||
const handleNoticeClick = () =>{
|
const handleNoticeClick = () => {
|
||||||
if (checkLogin()) {
|
if (checkLogin()) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url:'/packageB/notice/index'
|
url: '/packageB/notice/index',
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
function handleInstitutionClick(type){
|
function handleInstitutionClick(type) {
|
||||||
|
|
||||||
if (checkLogin()) {
|
if (checkLogin()) {
|
||||||
if(type=='evaluate'){
|
if (type == 'evaluate') {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url:'/packageB/institution/evaluationAgency'
|
url: '/packageB/institution/evaluationAgency',
|
||||||
})
|
});
|
||||||
}else if (type=='training'){
|
} else if (type == 'training') {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url:'/packageB/institution/trainingInstitution'
|
url: '/packageB/institution/trainingInstitution',
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
// 处理服务功能点击
|
// 处理服务功能点击
|
||||||
const handleServiceClick = (serviceType) => {
|
const handleServiceClick = (serviceType) => {
|
||||||
@@ -975,29 +913,29 @@ const handleServiceClick = (serviceType) => {
|
|||||||
// 处理直播按钮点击
|
// 处理直播按钮点击
|
||||||
const handleLiveClick = () => {
|
const handleLiveClick = () => {
|
||||||
// #ifdef MP-WEIXIN
|
// #ifdef MP-WEIXIN
|
||||||
const feedId = "sphKH1AEeLfTJJE";
|
const feedId = 'sphKH1AEeLfTJJE';
|
||||||
|
|
||||||
// 使用微信原生 API 打开视频号主页
|
// 使用微信原生 API 打开视频号主页
|
||||||
if (typeof wx !== "undefined" && wx.openChannelsUserProfile) {
|
if (typeof wx !== 'undefined' && wx.openChannelsUserProfile) {
|
||||||
wx.openChannelsUserProfile({
|
wx.openChannelsUserProfile({
|
||||||
finderUserName: feedId,
|
finderUserName: feedId,
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
console.log("打开视频号成功", res);
|
console.log('打开视频号成功', res);
|
||||||
},
|
},
|
||||||
fail: (err) => {
|
fail: (err) => {
|
||||||
console.error("打开视频号失败", err);
|
console.error('打开视频号失败', err);
|
||||||
$api.msg(err.errMsg || "无法打开直播,请稍后重试");
|
$api.msg(err.errMsg || '无法打开直播,请稍后重试');
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果 API 不存在,提示用户更新微信版本
|
// 如果 API 不存在,提示用户更新微信版本
|
||||||
$api.msg("请更新微信版本以使用该功能");
|
$api.msg('请更新微信版本以使用该功能');
|
||||||
}
|
}
|
||||||
// #endif
|
// #endif
|
||||||
|
|
||||||
// #ifndef MP-WEIXIN
|
// #ifndef MP-WEIXIN
|
||||||
// 非微信小程序环境提示
|
// 非微信小程序环境提示
|
||||||
$api.msg("该功能仅在微信小程序中可用");
|
$api.msg('该功能仅在微信小程序中可用');
|
||||||
// #endif
|
// #endif
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -1007,7 +945,7 @@ const handleSalaryInfoClick = () => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const handleH5SalaryClick = () => {
|
const handleH5SalaryClick = () => {
|
||||||
const salaryUrl = "https://www.mohrss.gov.cn/SYrlzyhshbzb/laodongguanxi_/fwyd/202506/t20250627_544623.html";
|
const salaryUrl = 'https://www.mohrss.gov.cn/SYrlzyhshbzb/laodongguanxi_/fwyd/202506/t20250627_544623.html';
|
||||||
window.location.assign(salaryUrl);
|
window.location.assign(salaryUrl);
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -1108,9 +1046,12 @@ function navToService(serviceType) {
|
|||||||
'employment-news': '/packageA/pages/service/employment-news',
|
'employment-news': '/packageA/pages/service/employment-news',
|
||||||
'more-services': '/packageA/pages/service/more-services',
|
'more-services': '/packageA/pages/service/more-services',
|
||||||
};
|
};
|
||||||
if((serviceType=='skill-training'||serviceType=='skill-evaluation')&&!uni.getStorageSync('userInfo').idCard){
|
if (
|
||||||
|
(serviceType == 'skill-training' || serviceType == 'skill-evaluation') &&
|
||||||
|
!uni.getStorageSync('userInfo').idCard
|
||||||
|
) {
|
||||||
$api.msg('请先完善信息');
|
$api.msg('请先完善信息');
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
const route = serviceRoutes[serviceType];
|
const route = serviceRoutes[serviceType];
|
||||||
if (route) {
|
if (route) {
|
||||||
@@ -1144,7 +1085,9 @@ function handleNewFilterConfirm(values) {
|
|||||||
showNewFilter.value = false;
|
showNewFilter.value = false;
|
||||||
getJobList('refresh');
|
getJobList('refresh');
|
||||||
// 短暂延迟后解除交互锁,避免数据刷新导致顶部区域回弹
|
// 短暂延迟后解除交互锁,避免数据刷新导致顶部区域回弹
|
||||||
setTimeout(() => { isInteractingWithFilter.value = false; }, 400);
|
setTimeout(() => {
|
||||||
|
isInteractingWithFilter.value = false;
|
||||||
|
}, 400);
|
||||||
emits('onShowTabbar', true);
|
emits('onShowTabbar', true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1180,7 +1123,9 @@ onLoad((options) => {
|
|||||||
function handleNewFilterClose() {
|
function handleNewFilterClose() {
|
||||||
showNewFilter.value = false;
|
showNewFilter.value = false;
|
||||||
emits('onShowTabbar', true);
|
emits('onShowTabbar', true);
|
||||||
setTimeout(() => { isInteractingWithFilter.value = false; }, 200);
|
setTimeout(() => {
|
||||||
|
isInteractingWithFilter.value = false;
|
||||||
|
}, 200);
|
||||||
}
|
}
|
||||||
|
|
||||||
function handleFilterConfirm(e) {
|
function handleFilterConfirm(e) {
|
||||||
@@ -1203,7 +1148,11 @@ function choosePosition(index) {
|
|||||||
inputText.value = '';
|
inputText.value = '';
|
||||||
getJobList('refresh');
|
getJobList('refresh');
|
||||||
}
|
}
|
||||||
nextTick(() => { setTimeout(() => { isInteractingWithFilter.value = false; }, 300); });
|
nextTick(() => {
|
||||||
|
setTimeout(() => {
|
||||||
|
isInteractingWithFilter.value = false;
|
||||||
|
}, 300);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
const isShowJw = ref(0);
|
const isShowJw = ref(0);
|
||||||
function handelHostestSearch(val) {
|
function handelHostestSearch(val) {
|
||||||
@@ -1211,7 +1160,7 @@ function handelHostestSearch(val) {
|
|||||||
isShowJw.value = val.value;
|
isShowJw.value = val.value;
|
||||||
pageState.search.order = val.value;
|
pageState.search.order = val.value;
|
||||||
pageState.search.jobType = val.value === 3 ? 1 : 0;
|
pageState.search.jobType = val.value === 3 ? 1 : 0;
|
||||||
if(val.value === 4) {
|
if (val.value === 4) {
|
||||||
pageState.search.type = 4;
|
pageState.search.type = 4;
|
||||||
} else {
|
} else {
|
||||||
delete pageState.search.type;
|
delete pageState.search.type;
|
||||||
@@ -1222,7 +1171,11 @@ function handelHostestSearch(val) {
|
|||||||
} else {
|
} else {
|
||||||
getJobList('refresh');
|
getJobList('refresh');
|
||||||
}
|
}
|
||||||
nextTick(() => { setTimeout(() => { isInteractingWithFilter.value = false; }, 300); });
|
nextTick(() => {
|
||||||
|
setTimeout(() => {
|
||||||
|
isInteractingWithFilter.value = false;
|
||||||
|
}, 300);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function getJobRecommend(type = 'add') {
|
function getJobRecommend(type = 'add') {
|
||||||
@@ -1247,7 +1200,7 @@ function getJobRecommend(type = 'add') {
|
|||||||
const cachedUserInfo = uni.getStorageSync('userInfo') || {};
|
const cachedUserInfo = uni.getStorageSync('userInfo') || {};
|
||||||
const cachedIsCompanyUser = cachedUserInfo.isCompanyUser;
|
const cachedIsCompanyUser = cachedUserInfo.isCompanyUser;
|
||||||
const userType = storeIsCompanyUser !== undefined ? Number(storeIsCompanyUser) : Number(cachedIsCompanyUser);
|
const userType = storeIsCompanyUser !== undefined ? Number(storeIsCompanyUser) : Number(cachedIsCompanyUser);
|
||||||
console.log('---------userType-----', userType)
|
console.log('---------userType-----', userType);
|
||||||
// 只有企业用户(isCompanyUser=0)才添加current字段
|
// 只有企业用户(isCompanyUser=0)才添加current字段
|
||||||
if (userType === 0) {
|
if (userType === 0) {
|
||||||
params.current = pageNull.value;
|
params.current = pageNull.value;
|
||||||
@@ -1258,7 +1211,8 @@ function getJobRecommend(type = 'add') {
|
|||||||
params.isPublish = 1;
|
params.isPublish = 1;
|
||||||
}
|
}
|
||||||
let comd = { recommend: true, jobCategory: '', tip: '确认你的兴趣,为您推荐更多合适的岗位' };
|
let comd = { recommend: true, jobCategory: '', tip: '确认你的兴趣,为您推荐更多合适的岗位' };
|
||||||
$api.createRequest('/app/job/recommend', params).then((resData) => {
|
$api.createRequest('/app/job/recommend', params)
|
||||||
|
.then((resData) => {
|
||||||
const { data, total } = resData;
|
const { data, total } = resData;
|
||||||
pageState.total = 0;
|
pageState.total = 0;
|
||||||
if (type === 'add') {
|
if (type === 'add') {
|
||||||
@@ -1305,7 +1259,8 @@ function getJobRecommend(type = 'add') {
|
|||||||
if (!data.length) {
|
if (!data.length) {
|
||||||
useUserStore().initSeesionId();
|
useUserStore().initSeesionId();
|
||||||
}
|
}
|
||||||
}).finally(() => {
|
})
|
||||||
|
.finally(() => {
|
||||||
isRecommendLoading.value = false;
|
isRecommendLoading.value = false;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -1374,10 +1329,11 @@ const jobUp = (encryptJobId) => {
|
|||||||
|
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
title: '处理中...',
|
title: '处理中...',
|
||||||
mask: true
|
mask: true,
|
||||||
});
|
});
|
||||||
|
|
||||||
$api.createRequest(`/app/job/jobUp/${encryptJobId}`, {}, 'PUT', true).then((res) => {
|
$api.createRequest(`/app/job/jobUp/${encryptJobId}`, {}, 'PUT', true)
|
||||||
|
.then((res) => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
$api.msg('上架成功');
|
$api.msg('上架成功');
|
||||||
// 刷新数据
|
// 刷新数据
|
||||||
@@ -1386,7 +1342,8 @@ const jobUp = (encryptJobId) => {
|
|||||||
} else {
|
} else {
|
||||||
getJobList('refresh');
|
getJobList('refresh');
|
||||||
}
|
}
|
||||||
}).catch((err) => {
|
})
|
||||||
|
.catch((err) => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
console.error('上架失败:', err);
|
console.error('上架失败:', err);
|
||||||
$api.msg('上架失败,请重试');
|
$api.msg('上架失败,请重试');
|
||||||
@@ -1399,10 +1356,11 @@ const jobDown = (encryptJobId) => {
|
|||||||
|
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
title: '处理中...',
|
title: '处理中...',
|
||||||
mask: true
|
mask: true,
|
||||||
});
|
});
|
||||||
|
|
||||||
$api.createRequest(`/app/job/jobDown/${encryptJobId}`, {}, 'PUT', true).then((res) => {
|
$api.createRequest(`/app/job/jobDown/${encryptJobId}`, {}, 'PUT', true)
|
||||||
|
.then((res) => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
$api.msg('下架成功');
|
$api.msg('下架成功');
|
||||||
// 刷新数据
|
// 刷新数据
|
||||||
@@ -1411,7 +1369,8 @@ const jobDown = (encryptJobId) => {
|
|||||||
} else {
|
} else {
|
||||||
getJobList('refresh');
|
getJobList('refresh');
|
||||||
}
|
}
|
||||||
}).catch((err) => {
|
})
|
||||||
|
.catch((err) => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
console.error('下架失败:', err);
|
console.error('下架失败:', err);
|
||||||
$api.msg('下架失败,请重试');
|
$api.msg('下架失败,请重试');
|
||||||
@@ -1424,19 +1383,20 @@ const toggleJobStatus = (job) => {
|
|||||||
|
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
title: '处理中...',
|
title: '处理中...',
|
||||||
mask: true
|
mask: true,
|
||||||
});
|
});
|
||||||
|
|
||||||
// 根据当前状态决定调用哪个接口
|
// 根据当前状态决定调用哪个接口
|
||||||
const isCurrentlyUp = Number(job.jobStatus) === 0; // 0: 已上架, 1: 已下架
|
const isCurrentlyUp = Number(job.jobStatus) === 0; // 0: 已上架, 1: 已下架
|
||||||
const apiUrl = isCurrentlyUp ? `/app/job/jobDown/${job.encryptJobId}` : `/app/job/jobUp/${job.encryptJobId}`;
|
const apiUrl = isCurrentlyUp ? `/app/job/jobDown/${job.encryptJobId}` : `/app/job/jobUp/${job.encryptJobId}`;
|
||||||
|
|
||||||
$api.createRequest(apiUrl, {}, 'PUT', true).then((res) => {
|
$api.createRequest(apiUrl, {}, 'PUT', true)
|
||||||
|
.then((res) => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
$api.msg(isCurrentlyUp ? '下架成功' : '上架成功');
|
$api.msg(isCurrentlyUp ? '下架成功' : '上架成功');
|
||||||
|
|
||||||
// 更新本地数据状态,避免立即刷新整个列表
|
// 更新本地数据状态,避免立即刷新整个列表
|
||||||
const jobIndex = list.value.findIndex(item => item.encryptJobId === job.encryptJobId);
|
const jobIndex = list.value.findIndex((item) => item.encryptJobId === job.encryptJobId);
|
||||||
if (jobIndex !== -1) {
|
if (jobIndex !== -1) {
|
||||||
// 更新状态
|
// 更新状态
|
||||||
list.value[jobIndex].jobStatus = isCurrentlyUp ? 1 : 0;
|
list.value[jobIndex].jobStatus = isCurrentlyUp ? 1 : 0;
|
||||||
@@ -1448,27 +1408,34 @@ const toggleJobStatus = (job) => {
|
|||||||
// } else {
|
// } else {
|
||||||
// getJobList('refresh');
|
// getJobList('refresh');
|
||||||
// }
|
// }
|
||||||
}).catch((err) => {
|
})
|
||||||
|
.catch((err) => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
console.error('操作失败:', err);
|
console.error('操作失败:', err);
|
||||||
$api.msg(isCurrentlyUp ? '下架失败,请重试' : '上架失败,请重试');
|
$api.msg(isCurrentlyUp ? '下架失败,请重试' : '上架失败,请重试');
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
const isFourLevelLinkagePurview=ref(false)
|
const isFourLevelLinkagePurview = ref(false);
|
||||||
const getIsFourLevelLinkagePurview=()=>{
|
const getIsFourLevelLinkagePurview = () => {
|
||||||
let userInfo = uni.getStorageSync('userInfo')
|
let userInfo = uni.getStorageSync('userInfo');
|
||||||
if(userInfo){
|
if (userInfo) {
|
||||||
$api.myRequest('/auth/login2/ks',{userid: userInfo.dwUserid, idcardno: userInfo.idCard},"POST",9100,{}).then(res=>{
|
$api.myRequest(
|
||||||
if(res.code == 200){
|
'/auth/login2/ks',
|
||||||
uni.setStorageSync('fourLevelLinkage-token',res.data.access_token)
|
{ userid: userInfo.dwUserid, idcardno: userInfo.idCard },
|
||||||
let roleIdList= ['103','106','107']
|
'POST',
|
||||||
if(res.data.roleIdList.some(item=>roleIdList.includes(item))){
|
9100,
|
||||||
isFourLevelLinkagePurview.value=true
|
{}
|
||||||
|
).then((res) => {
|
||||||
|
if (res.code == 200) {
|
||||||
|
uni.setStorageSync('fourLevelLinkage-token', res.data.access_token);
|
||||||
|
let roleIdList = ['103', '106', '107'];
|
||||||
|
if (res.data.roleIdList.some((item) => roleIdList.includes(item))) {
|
||||||
|
isFourLevelLinkagePurview.value = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
function dataToImg(data) {
|
function dataToImg(data) {
|
||||||
const result = data.map((item) => ({
|
const result = data.map((item) => ({
|
||||||
...item,
|
...item,
|
||||||
@@ -1481,49 +1448,48 @@ function dataToImg(data) {
|
|||||||
// import { loginRc } from '@/apiRc/login/login.js';
|
// import { loginRc } from '@/apiRc/login/login.js';
|
||||||
import storeRc from '@/utilsRc/store/index.js';
|
import storeRc from '@/utilsRc/store/index.js';
|
||||||
// 跳转到高校毕业页面
|
// 跳转到高校毕业页面
|
||||||
function goRc(){
|
function goRc() {
|
||||||
if (checkLogin()) {
|
if (checkLogin()) {
|
||||||
let userInfo = uni.getStorageSync('userInfo')
|
let userInfo = uni.getStorageSync('userInfo');
|
||||||
if(userInfo.isCompanyUser == 2){
|
if (userInfo.isCompanyUser == 2) {
|
||||||
storeRc.dispatch('LoginByID', userInfo.dwUserid || 2025111679160750).then(res => {
|
storeRc.dispatch('LoginByID', userInfo.dwUserid || 2025111679160750).then((res) => {
|
||||||
// storeRc.dispatch('LoginByID', 2025111679160750).then(res => {
|
// storeRc.dispatch('LoginByID', 2025111679160750).then(res => {
|
||||||
storeRc.dispatch('GetInfo').then(res => {
|
storeRc.dispatch('GetInfo').then((res) => {
|
||||||
navTo('/packageRc/pages/daiban/daiban');
|
navTo('/packageRc/pages/daiban/daiban');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
// test0001 202511491561998
|
// test0001 202511491561998
|
||||||
// test0002 202511381669113
|
// test0002 202511381669113
|
||||||
// test0003 2025111679160750
|
// test0003 2025111679160750
|
||||||
}else if(userInfo.isCompanyUser == 1){
|
} else if (userInfo.isCompanyUser == 1) {
|
||||||
storeRc.dispatch('LoginByUserInfo', userInfo).then(res => {
|
storeRc.dispatch('LoginByUserInfo', userInfo).then((res) => {
|
||||||
navTo('/packageRc/pages/index/index');
|
navTo('/packageRc/pages/index/index');
|
||||||
})
|
});
|
||||||
}else{
|
} else {
|
||||||
showToast('企业账号无法查看此模块~');
|
showToast('企业账号无法查看此模块~');
|
||||||
}
|
}
|
||||||
// storeRc.dispatch('LoginByID', userInfo.userId).then(res => {
|
// storeRc.dispatch('LoginByID', userInfo.userId).then(res => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 跳转到素质测评
|
// 跳转到素质测评
|
||||||
function goCa(){
|
function goCa() {
|
||||||
if (checkLogin()) {
|
if (checkLogin()) {
|
||||||
let userInfo = uni.getStorageSync('userInfo')
|
let userInfo = uni.getStorageSync('userInfo');
|
||||||
storeRc.dispatch('LoginByUserInfo', userInfo).then(res => {
|
storeRc.dispatch('LoginByUserInfo', userInfo).then((res) => {
|
||||||
navTo(`/packageCa/search/search?name=${userInfo.name}&userId=${userInfo.idCard}`);
|
navTo(`/packageCa/search/search?name=${userInfo.name}&userId=${userInfo.idCard}`);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 跳转到AI面试
|
// 跳转到AI面试
|
||||||
function goCaAI(){
|
function goCaAI() {
|
||||||
if (checkLogin()) {
|
if (checkLogin()) {
|
||||||
let userInfo = uni.getStorageSync('userInfo')
|
let userInfo = uni.getStorageSync('userInfo');
|
||||||
storeRc.dispatch('LoginByUserInfo', userInfo).then(res => {
|
storeRc.dispatch('LoginByUserInfo', userInfo).then((res) => {
|
||||||
navTo(`/packageCa/search/AIAudition?name=${userInfo.name}&userId=${userInfo.idCard}`);
|
navTo(`/packageCa/search/AIAudition?name=${userInfo.name}&userId=${userInfo.idCard}`);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
defineExpose({ loadData });
|
defineExpose({ loadData });
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user