Browse Source

登录页轮播图跳转优选集团页面

Xiao_123 4 tháng trước cách đây
mục cha
commit
6ee4396d79
1 tập tin đã thay đổi với 8 bổ sung1 xóa
  1. 8 1
      src/views/login/index.vue

+ 8 - 1
src/views/login/index.vue

@@ -114,16 +114,23 @@ onMounted(async () => {
 
 // 获取轮播图、背景图
 const logoBgUrl = ref('')
+const preferred = ref({})
 const carouselList = ref([])
 const getSystemWebContent = async () => {
   const data = await getWebContent()
   logoBgUrl.value = data.pcLoginBackground && data.pcLoginBackground.length ? data.pcLoginBackground[0].img : 'https://minio.menduner.com/dev/menduner/login-bgc.jpg'
   carouselList.value = data.pcLoginCarousel || []
+  preferred.value = data.appPreferredGroup || {}
 }
 getSystemWebContent()
 
 const handleClick = (item) => {
-  if (item.link) window.open(item.link)
+  if (!item.link) return
+  if (item.link.includes('http')) return window.open(item.link)
+
+  // 优选集团
+  if (preferred.value && Object.keys(preferred.value).length > 0 && preferred.value[item.link]) window.open(`/recruit/personal/advertisement/${item.link}`)
+  else window.open(`/recruit/personal/company/details/${item.link}?key=briefIntroduction`)
 }
 
 const { t } = useI18n()