瀏覽代碼

招聘会:根据环境设置展示的标签key

Xiao_123 2 月之前
父節點
當前提交
e02f761910

+ 1 - 1
components.d.ts

@@ -47,7 +47,7 @@ declare module 'vue' {
     IndustryTypeCard: typeof import('./src/components/industryTypeCard/index.vue')['default']
     Info: typeof import('./src/components/Enterprise/info.vue')['default']
     InitPay: typeof import('./src/components/personalRecharge/initPay.vue')['default']
-    Item: typeof import('./src/components/PositionLongStrip/item.vue')['default']
+    Item: typeof import('./src/components/Position/item.vue')['default']
     JobTypeCard: typeof import('./src/components/jobTypeCard/index.vue')['default']
     ListGroup: typeof import('./src/components/FormUI/nestedListGroup/components/listGroup.vue')['default']
     Loading: typeof import('./src/components/Loading/index.vue')['default']

+ 12 - 3
src/views/recruit/personal/jobFair/details/components/entCard1.vue

@@ -12,9 +12,16 @@
 							<span>{{ val.scaleName }}</span>
 						</p>
 						<div class="flex-nowrap overflow-hidden pl-3" style="height: 35px;">
-							<v-chip v-for="(job, index) in val.lastJobTop5" :key="index" class="mr-2 mb-4 display-inline-block" variant="flat" color="primary" size="small">
-								{{ formatName(job.name) }}
-							</v-chip>
+							<template v-if="env === 'production'">
+								<v-chip v-for="(welfare, index) in val.welfareList" :key="index" class="mr-2 mb-4 display-inline-block" color="primary" size="small">
+									{{ welfare }}
+								</v-chip>
+							</template>
+							<template v-else>
+								<v-chip v-for="(job, index) in val.lastJobTop5" :key="index" class="mr-2 mb-4 display-inline-block" variant="flat" color="primary" size="small">
+									{{ formatName(job.name) }}
+								</v-chip>
+							</template>
 						</div>
 					</div>
 				</div>
@@ -37,6 +44,8 @@ const props = defineProps({
 	isMobile: Boolean
 })
 
+const env = import.meta.env.VITE_NODE_ENV
+
 const handleClickEnterprise = (id) => {
 	window.open(`/recruit/personal/jobFair/entPosition/${props.jobFairId}?enterpriseId=${id}`)
 }

+ 2 - 1
src/views/recruit/personal/jobFair/details/enterprises.vue

@@ -148,9 +148,10 @@ const getList = async () => {
 	loadingType.value = 1
 
   // 有类别的添加筛选条件
+  const env = import.meta.env.VITE_NODE_ENV
   if (jobFair.value?.tag && jobFair.value?.tag.length) {
     const key = jobFair.value.tag[tab.value].key
-    const value = jobFair.value.tag[tab.value].content.map(e => e.value)
+    const value = env === 'production' ? jobFair.value.tag[tab.value].value : jobFair.value.tag[tab.value].content.map(e => e.value)
     query[key] = value
   }