|
@@ -81,17 +81,27 @@
|
|
@handleMore="handleGetMore"
|
|
@handleMore="handleGetMore"
|
|
@handleAgree="handleAgree"
|
|
@handleAgree="handleAgree"
|
|
@handleRefuse="handleRefuse"
|
|
@handleRefuse="handleRefuse"
|
|
|
|
+ @handlePreview="handlePreview"
|
|
|
|
+ @handleSendResume="handleSendResume"
|
|
>
|
|
>
|
|
<template #tools>
|
|
<template #tools>
|
|
<v-btn
|
|
<v-btn
|
|
v-for="tool in tools"
|
|
v-for="tool in tools"
|
|
:key="tool.name"
|
|
:key="tool.name"
|
|
size="small"
|
|
size="small"
|
|
- :prepend-icon="tool.icon"
|
|
|
|
class="mr-3"
|
|
class="mr-3"
|
|
:color="tool.color"
|
|
:color="tool.color"
|
|
@click="tool.handle(tool)"
|
|
@click="tool.handle(tool)"
|
|
>
|
|
>
|
|
|
|
+ <v-progress-circular
|
|
|
|
+ v-if="tool.loading"
|
|
|
|
+ :width="2"
|
|
|
|
+ :size="16"
|
|
|
|
+ color="white"
|
|
|
|
+ class="mr-2"
|
|
|
|
+ indeterminate
|
|
|
|
+ ></v-progress-circular>
|
|
|
|
+ <v-icon v-else class="mr-2">{{ tool.icon }}</v-icon>
|
|
{{ tool.name }}
|
|
{{ tool.name }}
|
|
</v-btn>
|
|
</v-btn>
|
|
</template>
|
|
</template>
|
|
@@ -102,6 +112,16 @@
|
|
<CtDialog :visible="showInvite" :widthType="2" titleClass="text-h6" title="邀请面试" @close="showInvite = false" @submit="handleSubmit">
|
|
<CtDialog :visible="showInvite" :widthType="2" titleClass="text-h6" title="邀请面试" @close="showInvite = false" @submit="handleSubmit">
|
|
<InvitePage v-if="showInvite" ref="inviteRef" :item-data="itemData" :position="positionList"></InvitePage>
|
|
<InvitePage v-if="showInvite" ref="inviteRef" :item-data="itemData" :position="positionList"></InvitePage>
|
|
</CtDialog>
|
|
</CtDialog>
|
|
|
|
+
|
|
|
|
+ <CtDialog :visible="showResume" :widthType="2" titleClass="text-h6" title="发送简历" @close="showResume = false; selectResume = null " @submit="handleSubmitResume">
|
|
|
|
+
|
|
|
|
+ <div style="position: relative; min-height: 200px">
|
|
|
|
+ <v-radio-group v-model="selectResume">
|
|
|
|
+ <v-radio v-for="val in resumeList" :key="val.id" :value="val.id" :label="val.title" color="primary"></v-radio>
|
|
|
|
+ </v-radio-group>
|
|
|
|
+ </div>
|
|
|
|
+
|
|
|
|
+ </CtDialog>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script setup>
|
|
<script setup>
|
|
@@ -124,6 +144,8 @@ import { dealDictArrayData } from '@/utils/position'
|
|
import { saveInterviewInvite } from '@/api/recruit/enterprise/interview'
|
|
import { saveInterviewInvite } from '@/api/recruit/enterprise/interview'
|
|
import { useI18n } from '@/hooks/web/useI18n'
|
|
import { useI18n } from '@/hooks/web/useI18n'
|
|
import { userInterviewInviteReject, userInterviewInviteConsent } from '@/api/recruit/personal/personalCenter'
|
|
import { userInterviewInviteReject, userInterviewInviteConsent } from '@/api/recruit/personal/personalCenter'
|
|
|
|
+import { getPersonResumeCv } from '@/api/recruit/personal/resume'
|
|
|
|
+import { previewFile } from '@/utils'
|
|
import Confirm from '@/plugins/confirm'
|
|
import Confirm from '@/plugins/confirm'
|
|
|
|
|
|
const { t } = useI18n()
|
|
const { t } = useI18n()
|
|
@@ -151,6 +173,29 @@ const itemData = ref({})
|
|
|
|
|
|
const inviteRef = ref()
|
|
const inviteRef = ref()
|
|
|
|
|
|
|
|
+// 发送简历
|
|
|
|
+const showResume = ref(false)
|
|
|
|
+const resumeList = ref([])
|
|
|
|
+const selectResume = ref(null)
|
|
|
|
+
|
|
|
|
+// 求职者面试列表
|
|
|
|
+const interview = ref([])
|
|
|
|
+
|
|
|
|
+const showRightNoData = ref(false)
|
|
|
|
+
|
|
|
|
+const info = ref({})
|
|
|
|
+
|
|
|
|
+const enterpriseTools = ref([
|
|
|
|
+ { name: '求简历', icon: 'mdi-email', color:"primary", loading: false, handle: handleRequest },
|
|
|
|
+ { name: '面试邀约', icon: 'mdi-email', color:"primary", loading: false, handle: handleInvite }
|
|
|
|
+])
|
|
|
|
+
|
|
|
|
+const userTools = ref([
|
|
|
|
+ { name: '发送简历', icon: 'mdi-email', color:"primary", loading: false, handle: handleSendResume }
|
|
|
|
+])
|
|
|
|
+
|
|
|
|
+const tools = isEnterprise ? enterpriseTools.value : userTools.value
|
|
|
|
+
|
|
if (!IM) {
|
|
if (!IM) {
|
|
console.log('IM is disconnected')
|
|
console.log('IM is disconnected')
|
|
}
|
|
}
|
|
@@ -193,8 +238,7 @@ const {
|
|
chatRef.value.scrollBottom()
|
|
chatRef.value.scrollBottom()
|
|
})
|
|
})
|
|
|
|
|
|
-// 求职者面试列表
|
|
|
|
-const interview = ref([])
|
|
|
|
|
|
+
|
|
const getInterviewInviteList = async () => {
|
|
const getInterviewInviteList = async () => {
|
|
if (!info.value.userId) return
|
|
if (!info.value.userId) return
|
|
const data = await getInterviewInviteListByInviteUserId(info.value.userId)
|
|
const data = await getInterviewInviteListByInviteUserId(info.value.userId)
|
|
@@ -221,24 +265,6 @@ watch(
|
|
)
|
|
)
|
|
|
|
|
|
|
|
|
|
-const showRightNoData = ref(false)
|
|
|
|
-
|
|
|
|
-const info = ref({})
|
|
|
|
-
|
|
|
|
-const handleUpdate = (val) => {
|
|
|
|
- send(val.value, channelItem.value)
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
-
|
|
|
|
-const enterpriseTools = ref([
|
|
|
|
- { name: '面试邀约', icon: 'mdi-email', color:"primary", loading: false, handle: handleInvite }
|
|
|
|
-])
|
|
|
|
-
|
|
|
|
-const userTools = ref([
|
|
|
|
-])
|
|
|
|
-
|
|
|
|
-const tools = isEnterprise ? enterpriseTools.value : userTools.value
|
|
|
|
-
|
|
|
|
async function handleChange (items) {
|
|
async function handleChange (items) {
|
|
// console.log([...items])
|
|
// console.log([...items])
|
|
try {
|
|
try {
|
|
@@ -251,6 +277,7 @@ async function handleChange (items) {
|
|
const userId = userInfoVo.userInfoResp.userId
|
|
const userId = userInfoVo.userInfoResp.userId
|
|
const enterpriseId = userInfoVo.userInfoResp.enterpriseId || undefined
|
|
const enterpriseId = userInfoVo.userInfoResp.enterpriseId || undefined
|
|
const { channel, list, more } = await initChart(userId, enterpriseId)
|
|
const { channel, list, more } = await initChart(userId, enterpriseId)
|
|
|
|
+ // console.log('--------',list)
|
|
channelItem.value = channel.value
|
|
channelItem.value = channel.value
|
|
messageItems.value = list.value
|
|
messageItems.value = list.value
|
|
hasMore.value = more
|
|
hasMore.value = more
|
|
@@ -267,6 +294,77 @@ async function handleChange (items) {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+// 普通消息
|
|
|
|
+const handleUpdate = (val) => {
|
|
|
|
+ send(val.value, channelItem.value)
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+// 获取简历
|
|
|
|
+async function handleSendResume (item) {
|
|
|
|
+ try {
|
|
|
|
+ item.loading = true
|
|
|
|
+ // showResume.value = true
|
|
|
|
+ // 获取简历列表
|
|
|
|
+ const result = await getPersonResumeCv()
|
|
|
|
+ if (result.length === 0) {
|
|
|
|
+ Snackbar.error(t('resume.resumeYetSubmit'))
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ resumeList.value = result
|
|
|
|
+ showResume.value = true
|
|
|
|
+ } finally {
|
|
|
|
+ item.loading = false
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+/**
|
|
|
|
+ * 发送简历
|
|
|
|
+ * text param
|
|
|
|
+ * {
|
|
|
|
+ * remark: 备注
|
|
|
|
+ * query: {} 自定义参数 access -1 未确定 0 拒绝 1 同意
|
|
|
|
+ * type: 1 => 发送简历
|
|
|
|
+ * 2 => 索要简历
|
|
|
|
+ * 3 => 信息描述
|
|
|
|
+ * }
|
|
|
|
+ */
|
|
|
|
+function handleSubmitResume () {
|
|
|
|
+ if (!selectResume.value) {
|
|
|
|
+ Snackbar.error(t('resume.selectResumeToSubmit'))
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ const _info = resumeList.value.find((item) => item.id === selectResume.value)
|
|
|
|
+ const text = {
|
|
|
|
+ remark: '发送简历',
|
|
|
|
+ query: {
|
|
|
|
+ src: _info.url,
|
|
|
|
+ title: _info.title,
|
|
|
|
+ id: _info.id,
|
|
|
|
+ },
|
|
|
|
+ type: 1
|
|
|
|
+ }
|
|
|
|
+ send (JSON.stringify(text), channelItem.value, 105)
|
|
|
|
+ showResume.value = false
|
|
|
|
+}
|
|
|
|
+// 求简历
|
|
|
|
+function handleRequest () {
|
|
|
|
+ const text = {
|
|
|
|
+ remark: '求简历',
|
|
|
|
+ query: {
|
|
|
|
+ src: '',
|
|
|
|
+ title: '',
|
|
|
|
+ id: '',
|
|
|
|
+ },
|
|
|
|
+ type: 2
|
|
|
|
+ }
|
|
|
|
+ send (JSON.stringify(text), channelItem.value, 105)
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+// 简历预览
|
|
|
|
+const handlePreview = (val) => {
|
|
|
|
+ previewFile(val.content.query.src)
|
|
|
|
+}
|
|
|
|
+
|
|
const handleGetMore = async () => {
|
|
const handleGetMore = async () => {
|
|
try {
|
|
try {
|
|
chatRef.value.changeLoading(true)
|
|
chatRef.value.changeLoading(true)
|