Xiao_123 2 meses atrás
pai
commit
f2ba459b1f

+ 0 - 7
pages/index/position.vue

@@ -59,13 +59,6 @@ import { getRewardEventList } from '@/utils/eventList'
 import { getMorningNewsArticle } from '@/api/content'
 import { getWebContent } from '@/api/common'
 
-// setTimeout(() => { // 测试
-//   const url = '/pagesB/jobFair/jobFairEntShare?jobFairId=1889880551008010241&enterpriseId=1'
-//   uni.navigateTo({
-//     url
-//   })
-// }, 100)
-
 onLoad(() => {
   wx.showShareMenu({
     withShareTicket: true,

+ 11 - 0
pagesB/jobFair/enterprisesClassification.vue

@@ -69,6 +69,7 @@ import { dealDictArrayData } from '@/utils/position'
 import { getJobFairEnterprisePage, getJobFair } from '@/api/jobFair'
 import SwiperAd from '@/components/SwiperAd'
 import { formatName } from '@/utils/getText'
+import { getShareQueryById } from '@/api/jobFair.js'
 
 const more = ref('more')
 const listData = ref([])
@@ -81,6 +82,16 @@ const query = reactive({
 const showShareBtn = ref(false)
 
 onLoad(async (options) => {
+  // 海报二维码分享
+	if (options.scene) {
+    const scene = decodeURIComponent(options.scene)
+    console.log(scene, 'scene')
+    const key = scene.split('=')[1]
+    if (!key) return
+    const res = await getShareQueryById({key})
+    console.log(res, 'result')
+    options.jobFairId = res?.data?.jobFairId
+  }
   if (options?.jobFairId) {
     query.jobFairId = options.jobFairId
     getJobFairDetail()

+ 1 - 1
pagesB/jobFair/jobFairShare.vue

@@ -123,7 +123,7 @@ const handleShareCode = async () => {
   const result = await saveShareQuery({ jobFairId })
 	const query = {
 		scene: 'id=' + result.data,
-    path: `pagesB/jobFair/${isEnt ? 'enterprisesClassification' : 'positionClassification'}`,
+    path: `pagesB/jobFair/${!isEnt ? 'enterprisesClassification' : 'positionClassification'}`,
 		width: 200,
 		autoColor: false,
 		checkPath: true,

+ 3 - 1
pagesB/jobFair/positionClassification.vue

@@ -68,12 +68,14 @@ const entName = ref('')
 const showShareBtn = ref(false)
 
 onLoad(async (options) => {
-  // 网站二维码分享
+  // 海报二维码分享
 	if (options.scene) {
     const scene = decodeURIComponent(options.scene)
+    console.log(scene, 'scene')
     const key = scene.split('=')[1]
     if (!key) return
     const res = await getShareQueryById({key})
+    console.log(res, 'result')
     options.jobFairId = res?.data?.jobFairId
     options.enterpriseId = res?.data?.enterpriseId
     options.backgroundColor = res?.data?.backgroundColor