|
@@ -1,39 +1,49 @@
|
|
|
<template>
|
|
|
- <div>
|
|
|
- <div v-if="items.length" class="mt-3">
|
|
|
- <div class="positionItem elevation-2" v-for="(item, index) in items" :key="index" @mouseenter="item.active = true" @mouseleave="item.active = false">
|
|
|
- <div class="position-and-company">
|
|
|
- <div class="position">
|
|
|
- <div class="float-left">
|
|
|
- <v-img :src="getUserAvatar(item?.contact.avatar, item?.contact.sex)" :width="40" style="height: 40px;border-radius: 4px;"/>
|
|
|
+ <div style="position: relative; height: 60vh;">
|
|
|
+ <div v-if="userInfo?.entitlement?.viewersList && userInfo?.vipFlag && userInfo?.vipExpireDate && userInfo?.vipExpireDate > Date.now()">
|
|
|
+ <div v-if="items.length" class="mt-3">
|
|
|
+ <div class="positionItem elevation-2" v-for="(item, index) in items" :key="index" @mouseenter="item.active = true" @mouseleave="item.active = false">
|
|
|
+ <div class="position-and-company">
|
|
|
+ <div class="position">
|
|
|
+ <div class="float-left">
|
|
|
+ <v-img :src="getUserAvatar(item?.contact.avatar, item?.contact.sex)" :width="40" style="height: 40px;border-radius: 4px;"/>
|
|
|
+ </div>
|
|
|
+ <div class="company-info">
|
|
|
+ <h3 class="title1">{{ item.contact.name }}</h3>
|
|
|
+ <p class="mt-2">{{ item?.post?.nameCn }}</p>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
- <div class="company-info">
|
|
|
- <h3 class="title1">{{ item.contact.name }}</h3>
|
|
|
- <p class="mt-2">{{ item?.post?.nameCn }}</p>
|
|
|
+ <div class="company" @click="handleEnterprise(item)">
|
|
|
+ <div class="float-left">
|
|
|
+ <v-img :src="item?.enterprise.logoUrl || 'https://minio.citupro.com/dev/menduner/company-avatar.png'" :alt="item.enterprise.anotherName" :width="40" style="height: 40px;border-radius: 4px;"/>
|
|
|
+ </div>
|
|
|
+ <div class="company-info">
|
|
|
+ <h3 :class="{'default-active': item.active }" class="title1 cursor-pointer">{{ item.enterprise.anotherName }}</h3>
|
|
|
+ <p class="mt-2">{{ item.enterprise.scaleName }}<span class="mx-2">|</span>{{ item.enterprise.industryName }}</p>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="company" @click="handleEnterprise(item)">
|
|
|
- <div class="float-left">
|
|
|
- <v-img :src="item?.enterprise.logoUrl || 'https://minio.citupro.com/dev/menduner/company-avatar.png'" :alt="item.enterprise.anotherName" :width="40" style="height: 40px;border-radius: 4px;"/>
|
|
|
- </div>
|
|
|
- <div class="company-info">
|
|
|
- <h3 :class="{'default-active': item.active }" class="title1 cursor-pointer">{{ item.enterprise.anotherName }}</h3>
|
|
|
- <p class="mt-2">{{ item.enterprise.scaleName }}<span class="mx-2">|</span>{{ item.enterprise.industryName }}</p>
|
|
|
- </div>
|
|
|
+ <div class="footer">
|
|
|
+ {{ $t('position.viewTime') + timesTampChange(item.updateTime) }}
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="footer">
|
|
|
- {{ $t('position.viewTime') + timesTampChange(item.updateTime) }}
|
|
|
- </div>
|
|
|
+ <CtPagination
|
|
|
+ :total="total"
|
|
|
+ :page="page.pageNo"
|
|
|
+ :limit="page.pageSize"
|
|
|
+ @handleChange="handleChangePage"
|
|
|
+ ></CtPagination>
|
|
|
</div>
|
|
|
- <CtPagination
|
|
|
- :total="total"
|
|
|
- :page="page.pageNo"
|
|
|
- :limit="page.pageSize"
|
|
|
- @handleChange="handleChangePage"
|
|
|
- ></CtPagination>
|
|
|
+ <Empty v-else :elevation="false"></Empty>
|
|
|
+ </div>
|
|
|
+ <div v-else class="mt-8 tips">
|
|
|
+ <span class="color-error" v-if="userInfo?.vipExpireDate > Date.now() && !userInfo?.entitlement?.viewersList">
|
|
|
+ 当前会员套餐的福利不包含谁看过我,<span class="text-decoration-underline cursor-pointer" @click="goBuy">去升级</span>
|
|
|
+ </span>
|
|
|
+ <span class="color-error" v-if="!userInfo?.vipExpireDate || (userInfo?.vipExpireDate && userInfo?.vipExpireDate < Date.now())">
|
|
|
+ 谁看过我为会员福利内容,<span class="text-decoration-underline cursor-pointer" @click="goBuy">去开通</span>
|
|
|
+ </span>
|
|
|
</div>
|
|
|
- <Empty v-else :elevation="false"></Empty>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -47,6 +57,7 @@ import { timesTampChange } from '@/utils/date'
|
|
|
import Empty from '@/components/Empty'
|
|
|
import { getUserAvatar } from '@/utils/avatar'
|
|
|
import { useRouter } from 'vue-router'
|
|
|
+import { useUserStore } from '@/store/user'
|
|
|
|
|
|
const router = useRouter()
|
|
|
const total = ref(0)
|
|
@@ -56,6 +67,12 @@ const page = ref({
|
|
|
pageSize: 10
|
|
|
})
|
|
|
|
|
|
+const userStore = useUserStore()
|
|
|
+let userInfo = ref(JSON.parse(localStorage.getItem('userInfo')) || {})
|
|
|
+userStore.$subscribe((mutation, state) => {
|
|
|
+ if (state.userInfo && Object.keys(state.userInfo).length) userInfo.value = state?.userInfo
|
|
|
+})
|
|
|
+
|
|
|
const getData = async () => {
|
|
|
const res = await getInterestedMePage(page.value)
|
|
|
items.value = res.list.map(e => {
|
|
@@ -78,6 +95,9 @@ const handleEnterprise = (item) => {
|
|
|
router.push(`/recruit/personal/company/details/${id}?key=briefIntroduction`)
|
|
|
}
|
|
|
|
|
|
+const goBuy = () => {
|
|
|
+ router.push('/recruit/personal/personalCenter/memberBenefits/membershipPackage')
|
|
|
+}
|
|
|
</script>
|
|
|
|
|
|
<style scoped lang="scss">
|
|
@@ -135,4 +155,10 @@ const handleEnterprise = (item) => {
|
|
|
color: var(--color-999);
|
|
|
background: linear-gradient(90deg, #f5fcfc 0, #fcfbfa 100%);
|
|
|
}
|
|
|
+.tips {
|
|
|
+ position: absolute;
|
|
|
+ top: 50%;
|
|
|
+ left: 50%;
|
|
|
+ transform: translate(-50%, -50%);
|
|
|
+}
|
|
|
</style>
|