Просмотр исходного кода

Merge branch 'dev' of https://git.citupro.com/zhengnaiwen_citu/menduner into dev

zhengnaiwen_citu 6 месяцев назад
Родитель
Сommit
e1c91d667e

+ 7 - 0
src/api/recruit/enterprise/jobFair.js

@@ -1,5 +1,12 @@
 import request from '@/config/axios'
 
+// 效验是否有权限参加招聘会
+export const getCheckJobFairPermission = async (id) => {
+  return await request.get({
+    url: '/app-api/menduner/system/recruit/job-fair/check/permission?jobFairId=' + id
+  })
+}
+
 // 获得招聘会列表
 export const getJobFairList = async () => {
   return await request.get({

+ 4 - 5
src/router/modules/components/recruit/enterprise.js

@@ -337,9 +337,8 @@ const enterprise = [
     path: '/recruit/enterprise/jobFair',
     component: Layout,
     name: 'jobFair',
-    // show: true, // 暂时隐藏
     meta: {
-      title: '双选会',
+      title: '招聘会',
       enName: 'Job Fair',
       icon: 'mdi-account-filter-outline'
     },
@@ -348,7 +347,7 @@ const enterprise = [
         path: '/recruit/enterprise/jobFair',
         show: true,
         meta: {
-          title: '双选会',
+          title: '招聘会',
           enName: 'Job Fair'
         },
         component: () => import('@/views/recruit/enterprise/jobFair/index.vue')
@@ -357,7 +356,7 @@ const enterprise = [
         path: '/recruit/enterprise/jobFair/details/:id',
         show: true,
         meta: {
-          title: '双选会详情',
+          title: '招聘会详情',
           enName: 'Job Fair Details'
         },
         component: () => import('@/views/recruit/enterprise/jobFair/detailsBox.vue'),
@@ -366,7 +365,7 @@ const enterprise = [
             path: '/recruit/enterprise/jobFair/details/:id',
             show: true,
             meta: {
-              title: '双选会详情',
+              title: '招聘会详情',
               enName: 'Job Fair Details'
             },
             component: () => import('@/views/recruit/enterprise/jobFair/details.vue'),

+ 1 - 2
src/store/user.js

@@ -199,8 +199,7 @@ export const useUserStore = defineStore('user',
       async checkEnterpriseBaseInfo () {
         try {
           const data = await getEnterpriseBaseInfo()
-          // debugger
-          if (data?.first === null || data?.first === 'null') {  // 首次登录才提示(只有null是,其他都不是)
+          if (data?.first !== false && data?.first !== 'false') {  // 首次登录才提示,不为false都属于首次登录
             localStorage.setItem('checkEnterpriseBaseInfoFalseHref', '/recruit/enterprise/entInfoSetting')
           }
           // // 检验必填信息

+ 6 - 28
src/views/recruit/enterprise/jobFair/index.vue

@@ -18,44 +18,22 @@ defineOptions({ name: 'jobFair'})
 import { ref } from 'vue'
 import { useRouter } from 'vue-router'
 import { getJobFairList } from '@/api/recruit/enterprise/jobFair'
+import { getCheckJobFairPermission } from '@/api/recruit/enterprise/jobFair'
+import Snackbar from '@/plugins/snackbar'
 
 const router = useRouter()
-const list = ref([
-  // {
-  //   id: 1,
-  //   url: 'https://minio.menduner.com/dev/menduner/jobFair.jfif',
-  //   title: '中瑞实习双选会',
-  //   desc: '2024年中瑞实习双选会,旨在为毕业生提供更多的就业机会和职业发展机会。'
-  // },
-  // {
-  //   id: 2,
-  //   url: 'https://minio.menduner.com/dev/menduner/jobFair2.jfif',
-  //   title: '2025年春季校园招聘会',
-  //   desc: '2025年春季校园招聘会,旨在为毕业生提供更多的就业机会和职业发展机会。'
-  // },
-  // {
-  //   id: 3,
-  //   url: 'https://minio.menduner.com/dev/menduner/jobFair2.jfif',
-  //   title: '2025年春季校园招聘会',
-  //   desc: '2025年春季校园招聘会,旨在为毕业生提供更多的就业机会和职业发展机会。'
-  // },
-  // {
-  //   id: 4,
-  //   url: 'https://minio.menduner.com/dev/menduner/jobFair2.jfif',
-  //   title: '2025年春季校园招聘会',
-  //   desc: '2025年春季校园招聘会,旨在为毕业生提供更多的就业机会和职业发展机会。'
-  // }
-])
+const list = ref([])
 
 const getList = async () => {
   const data = await getJobFairList()
-  // console.log(data, 'data')
   list.value = data
 }
 getList()
 
 // 立即加入
-const handleBlockEnterprise = (id) => {
+const handleBlockEnterprise = async (id) => {
+  const data = await getCheckJobFairPermission(id)
+  if (!data) return Snackbar.warning('您没有权限参加该招聘会') // 只有返回true才能进入双选会
   router.push(`/recruit/enterprise/jobFair/details/${id}`)
 }
 </script>

+ 1 - 2
src/views/recruit/enterprise/jobFair/job/item.vue

@@ -4,7 +4,6 @@
       <div class="d-flex justify-space-between cursor-pointer" style="padding: 10px 20px;" @click="handleEdit(val)">
         <div class="position">
           <div class="d-flex align-center">
-            <!-- <span v-if="val.name.indexOf('style')" v-html="val.name" class="position-name"></span> -->
             <span class="position-name">{{ val.name }}</span>
           </div>
           <div :class="['mt-3', 'other-info', 'ellipsis']">
@@ -26,7 +25,7 @@
         <div class="d-flex">
           <span class="cursor-pointer actions" @click="handleEdit(val)">编辑</span>
           <span class="lines"></span>
-          <span class="cursor-pointer actions" @click="handleRemove(val)">移出双选会</span>
+          <span class="cursor-pointer actions" @click="handleRemove(val)">移出招聘会</span>
         </div>
       </div>
     </div>

+ 2 - 1
src/views/recruit/enterprise/positionManagement/components/add.vue

@@ -130,7 +130,8 @@ if (route.query && route.query.id) {
 // 取消
 const handleCancel = () => {
   itemData.value = {}
-  router.push({ path: '/recruit/enterprise/position' })
+  const currentPage = router.currentRoute.value.path
+  router.push({ path: currentPage.indexOf('jobFair') !== -1 ? '/recruit/enterprise/jobFair' : '/recruit/enterprise/position' })
   // 新增职位发布需更新账户信息
   if (route.query && !route.query?.id) {
     setTimeout(async () => {