|
@@ -2,8 +2,8 @@
|
|
|
<div v-loading="saveLoading">
|
|
|
<el-row :gutter="10">
|
|
|
<el-col :span="12">
|
|
|
- <el-tabs type="border-card">
|
|
|
- <el-tab-pane label="简历解析" v-loading="loading">
|
|
|
+ <el-tabs v-model="activeName" type="border-card">
|
|
|
+ <el-tab-pane label="简历解析" v-loading="loading" name="resumeAnalysis">
|
|
|
<div v-if="fileUrl">
|
|
|
<div class="text-right m-b-10px">
|
|
|
<el-button @click="handleText">查看文本信息</el-button>
|
|
@@ -35,19 +35,19 @@
|
|
|
:http-request="httpRequest"
|
|
|
accept=".pdf, doc, .docx"
|
|
|
drag
|
|
|
- style="flex: 1;"
|
|
|
+ class="flex-1"
|
|
|
>
|
|
|
<i class="el-icon-upload"></i>
|
|
|
<div class="el-upload__text">上传附件, 将文件拖到此处,或 <em>点击上传</em></div>
|
|
|
<template #tip>
|
|
|
- <div class="el-upload__tip" style="color: red">
|
|
|
+ <div class="el-upload__tip color-red">
|
|
|
提示:仅允许导入 pdf、doc、docx 格式文件!
|
|
|
</div>
|
|
|
</template>
|
|
|
</el-upload>
|
|
|
</el-tab-pane>
|
|
|
- <el-tab-pane label="人员搜索">
|
|
|
- <Search @detail="handleDetail" />
|
|
|
+ <el-tab-pane label="人员搜索" name="personnelSearch">
|
|
|
+ <Search @detail="handleDetail" :searchName="result?.person?.name" />
|
|
|
</el-tab-pane>
|
|
|
</el-tabs>
|
|
|
</el-col>
|
|
@@ -63,7 +63,7 @@
|
|
|
<Training v-model="result.trainList" :isEdit="isEdit" />
|
|
|
<div class="text-center m-t-30px">
|
|
|
<el-affix position="bottom" :offset="20">
|
|
|
- <el-button @click="push('/headhunting/menduner/system/talentMap/talentMap')" type="warning" plain size="large" class="!w-120px">取 消</el-button>
|
|
|
+ <!-- <el-button @click="push('/headhunting/menduner/system/talentMap/talentMap')" type="warning" plain size="large" class="!w-120px">取 消</el-button> -->
|
|
|
<el-button v-if="id === 'add'" type="primary" @click="handleSave" size="large" class="!w-120px">保 存</el-button>
|
|
|
</el-affix>
|
|
|
</div>
|
|
@@ -111,6 +111,7 @@ import Search from './components/search.vue'
|
|
|
|
|
|
const { push } = useRouter()
|
|
|
const loading = ref(false)
|
|
|
+const activeName = ref('resumeAnalysis')
|
|
|
const saveLoading = ref(false)
|
|
|
const result = ref(cloneDeep(DefaultData))
|
|
|
const fileUrl = ref('') // https://minio.menduner.com/dev/person/229988673960153088/attachment/ee3eb21f45e13ede3557a03d18585ed80c5b4212ac5634e3436e309afaa8fe6a.pdf
|
|
@@ -157,7 +158,7 @@ const getTalentMap = async () => {
|
|
|
if (!data || !Object.keys(data).length) return
|
|
|
if (data.person?.resumeUrl) {
|
|
|
fileUrl.value = !data.person?.resumeUrl.includes('.pdf') ? `${baseUrl}/onlinePreview?url=${encodeURIComponent(Base64.encode(data.person?.resumeUrl))}` : data.person?.resumeUrl
|
|
|
- }
|
|
|
+ } else activeName.value = 'personnelSearch'
|
|
|
result.value = data
|
|
|
result.value.person.interestedAreaIdList = result.value.person.interestedAreaIdList && result.value.person.interestedAreaIdList.length ? result.value.person.interestedAreaIdList.map(e => Number(e)) : []
|
|
|
} catch (error) {
|
|
@@ -251,12 +252,12 @@ const handleSave = async () => {
|
|
|
console.log(result.value, 'result-add')
|
|
|
|
|
|
// 效验基本信息中必填项是否有填写
|
|
|
- // if (!result.value?.person.name || !result.value.person.phone) {
|
|
|
- // message.notifyWarning('请将必填项填写完整')
|
|
|
- // InfoRef.value.formRef.validate()
|
|
|
- // content.value.scrollTo({ top: 0, behavior: 'smooth' })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (!result.value?.person?.name) {
|
|
|
+ message.notifyWarning('请填写用户姓名后再提交!')
|
|
|
+ InfoRef.value.formRef.validate()
|
|
|
+ content.value.scrollTo({ top: -100, behavior: 'smooth' })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
saveLoading.value = true
|
|
|
try {
|