Pārlūkot izejas kodu

更新版本号

Xiao_123 5 mēneši atpakaļ
vecāks
revīzija
04e2ed88f4

+ 2 - 2
src/version.js

@@ -1,2 +1,2 @@
-// 版本号 1810
-export const vue_version = 'v24.11.29.1810'
+// 版本号 0941
+export const vue_version = 'v24.12.03.0941'

+ 119 - 0
src/views/recruit/personal/PersonalCenter/resume/online/analysis/base.vue

@@ -0,0 +1,119 @@
+<template>
+  <div class="resume-box mb-3 elevation-2" id="basicInfo">
+    <div class="resume-header">
+      <div class="resume-title">{{ $t('resume.basicInfo') }}</div>
+    </div>
+    <div class="d-flex align-start mt-5">
+      <!-- 头像 -->
+      <div class="avatarsBox">
+        <div style="width: 130px; height: 130px;">
+          <v-img :src="data.avatarData" width="130" height="130" style="border-radius: 6px;"></v-img>
+        </div>
+      </div>
+      <!-- 基础信息 -->
+      <div style="flex: 1;" class="mr-8">
+        <div>
+          <span class="ml-50" style="font-size: 20px; font-weight: 600;color: var(--color-666);">
+            {{ data?.name || data?.phone }}
+          </span>
+          <div class="mt-3 d-flex">
+            <div class="listBox ml-50">
+              <div>
+                <span>性别:</span>
+                <span>{{ data?.genderInf || '' }}</span>
+              </div>
+              <div>
+                <span></span>
+                <span>{{ baseInfo?.phone || userInfo?.phone || $t('common.currentlyUnavailable') }}</span>
+              </div>
+              <div>
+                <span class="mdi mdi-email-outline"></span>
+                <span>{{ baseInfo?.email || $t('common.currentlyUnavailable') }}</span>
+              </div>
+              <div>
+                <span class="mdi mdi-calendar-blank-outline"></span>
+                <span>{{ baseInfo?.expTypeText || $t('common.currentlyUnavailable') }}</span>
+              </div>
+              <div>
+                <span class="mdi mdi-school-outline"></span>
+                <span>{{ baseInfo?.eduTypeText || $t('common.currentlyUnavailable') }}</span>
+              </div>
+              <div>
+                <span class="mdi mdi-tag-outline"></span>
+                <span>{{ baseInfo?.jobStatusText || $t('common.currentlyUnavailable') }}</span>
+              </div>
+              <div>
+                <span class="mdi mdi-cake-variant-outline"></span>
+                <span>{{ baseInfo?.birthdayText || $t('common.currentlyUnavailable') }}</span>
+              </div>
+              <div>
+                <span class="mdi mdi-home-map-marker"></span>
+                <span>{{ baseInfo?.regName || $t('common.currentlyUnavailable') }}</span>
+              </div>
+              <div>
+                <span class="mdi mdi-account-heart"></span>
+                <span>{{ baseInfo?.maritalText || $t('common.currentlyUnavailable') }}</span>
+              </div>
+              <div>
+                <span>{{ $t('resume.firstWorkTime') }}:</span>
+                <span>{{ baseInfo?.firstWorkTimeText || $t('common.currentlyUnavailable') }}</span>
+              </div>
+            </div>
+          </div>
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script setup>
+defineProps({
+  data: Object
+})
+</script>
+
+<style lang="scss" scoped>
+.jobTypeCardBox {
+  position: absolute;
+  top: -22px;
+  left: 0;
+}
+.ml-50 {
+  margin-left: 50px;
+}
+.avatarsBox {
+  height: 150px;
+  width: 120px;
+  position: relative;
+  cursor: pointer;
+  margin: 0 32px;
+  .camera {
+    color: #fff;
+    font-size: 42px;
+    position: absolute;
+    top: 50%;
+    left: 50%;
+    transform: translate(-50%, -50%);
+  }
+}
+
+.listBox {
+  display: flex;
+  flex-wrap: wrap; /* 允许换行 */
+  width: 100%; /* 设置容器宽度 */
+  overflow: hidden;
+  color: var(--color-666);
+  div {
+    width: 50%;
+    margin-bottom: 10px;
+    span {
+      height: 32px;
+      line-height: 32px;
+    }
+    .mdi {
+      font-size: 22px;
+      margin-right: 8px;
+    }
+  }
+}
+</style>

+ 61 - 0
src/views/recruit/personal/PersonalCenter/resume/online/analysis/eduExp.vue

@@ -0,0 +1,61 @@
+<template>
+  <div class="resume-box elevation-2 mb-3">
+    <div class="resume-header mb-3">
+      <div class="resume-title">{{ $t('resume.educationExp') }}</div>
+    </div>
+    <div v-for="(item, index) in data.educationObjs" :key="'educationExp' + index" :class="[' mx-n2', {'mt-5': index }]">
+      <div class="educExpItem">
+        <div class="level1 d-flex align-center justify-space-between" style="height: 40px;">
+          <div>
+            <span style="font-size: 18px; font-weight: bold;">{{ item.eduCollege }}</span>
+            <span class="color6 font15 ml-5">
+              <span>{{ item.startDate }}</span>
+              <span class="mx-1">至</span>
+              <span>{{ item.endDate }}</span>
+            </span>
+          </div>
+        </div>
+        <div class="level2 my-2">
+          <span class="color6 font15">{{ item.eduMajor }}</span>
+          <span class="septal-line"  v-if="item.eduMajor && item.eduDegree"></span>
+          <span class="color6 font15">{{ item.eduDegree }}</span>
+        </div>
+        <div class="level3">
+          <span class="color6 font15">
+            在校经历:
+            <p v-if="item.eduContent" v-html="item.eduContent.replace(/\n/g, '</br>')"></p>
+            <span v-else>暂无描述</span>
+          </span>
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script setup name="EduExp">
+defineProps({
+  data: Object
+})
+</script>
+
+<style scoped lang="scss">
+.font15 { font-size: 15px;; }
+.color9 { color: var(--color-999); }
+.color6 { color: var(--color-666); }
+.educExpItem {
+  cursor: pointer;
+  border-radius: 6px;
+  padding: 2px 10px 8px;
+  &:hover {
+    background-color: var(--color-f8);
+  }
+}
+.educExpItem-edit {
+  border-radius: 6px;
+  padding: 2px 10px 8px;
+  background-color: var(--color-f8);
+}
+:deep(.el-input--large .el-input__wrapper) {
+  background-color: #f8f8f8;
+}
+</style>

+ 24 - 0
src/views/recruit/personal/PersonalCenter/resume/online/analysis/evaluation.vue

@@ -0,0 +1,24 @@
+<template>
+  <div class="resume-box elevation-2 mb-3" id="selfEvaluation">
+    <div class="resume-header">
+      <div class="resume-title">{{ $t('resume.personalAdvantages') }}</div>
+    </div>
+    <div class="content-list mt-3">
+      <div v-if="data.contMyDesc" class="resumeNoDataText" v-html="data.contMyDesc.replace(/\n/g, '</br>')"></div>
+    </div>
+  </div>
+</template>
+
+<script setup>
+defineOptions({ name: 'Evaluation'})
+
+defineProps({
+  data: Object
+})
+</script>
+
+<style scoped lang="scss">
+.content-list {
+  white-space: pre-line;
+}
+</style>

+ 57 - 0
src/views/recruit/personal/PersonalCenter/resume/online/analysis/workExp.vue

@@ -0,0 +1,57 @@
+<template>
+  <div class="resume-box elevation-2 mb-3">
+    <div class="resume-header mb-3">
+      <div class="resume-title">
+        {{ $t('resume.workExperience') }}
+      </div>
+    </div>
+    <div v-for="(item, index) in data.jobExpObjs" :key="'workExperience' + index">
+      <div class="educExpItem">
+        <div class="level1 d-flex align-center justify-space-between" style="height: 40px;">
+          <div>
+            <span style="font-size: 18px; font-weight: bold;">{{ item.jobCpy }}</span>
+            <span class="color6 font15 ml-5">
+              <span>{{ item.startDate }}</span>
+              <span class="mx-1">至</span>
+              <span>{{ item.endDate }}</span>
+            </span>
+          </div>
+        </div>
+        <div class="level2 my-2">
+          <span class="color6 font15">{{ item.jobPosition }}</span>
+        </div>
+        <div class="level3">
+          <span class="color6 font15">{{ $t('resume.jobContent') }}<p v-if="item.jobContent" v-html="item.jobContent.replace(/\n/g, '</br>')"></p></span>
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script setup name="WorkExp">
+defineProps({
+  data: Object
+})
+</script>
+
+<style scoped lang="scss">
+.font15 { font-size: 15px;; }
+.color9 { color: var(--color-999); }
+.color6 { color: var(--color-666); }
+.educExpItem {
+  cursor: pointer;
+  border-radius: 6px;
+  padding: 2px 10px 8px;
+  &:hover {
+    background-color: var(--color-f8);
+  }
+}
+.educExpItem-edit {
+  border-radius: 6px;
+  padding: 2px 10px 8px;
+  background-color: var(--color-f8);
+}
+:deep(.el-input--large .el-input__wrapper) {
+  background-color: #f8f8f8;
+}
+</style>

+ 19 - 4
src/views/recruit/personal/PersonalCenter/resume/online/index.vue

@@ -27,8 +27,9 @@
     </div>
   </div>
 
+  <Loading :visible="loading"></Loading>
   <selectResumeDialog v-model="showAttachment" title="请选择已有的简历导入" :list="attachmentList" @submit="handleAttachmentSubmit" @close="showAttachment = false" />
-  <resumeAnalysis v-model="showAnalysis" :url="selectAttachment" @submit="handleResumeAnalysisSubmit" @close="showAnalysis = false" />
+  <resumeAnalysis v-model="showAnalysis" :data="result" :url="selectAttachment" @submit="handleResumeAnalysisSubmit" @close="showAnalysis = false" />
 </template>
 
 <script setup>
@@ -43,7 +44,7 @@ import educationExp from './components/educationExp.vue'
 import workExperience from './components/workExperience.vue'
 // import projectExperience from './components/projectExperience.vue'
 import vocationalSkills from './components/vocationalSkills.vue'
-import { resumePersonFillAll, getPersonResumeCv } from '@/api/recruit/personal/resume'
+import { resumePersonFillAll, getPersonResumeCv, resumeParser } from '@/api/recruit/personal/resume'
 import Snackbar from '@/plugins/snackbar'
 import { useRouter } from 'vue-router'
 import selectResumeDialog from '@/views/recruit/personal/position/components/jobDetails/selectResumeDialog.vue'
@@ -53,6 +54,7 @@ const router = useRouter()
 const { t } = useI18n()
 const scrollBox = ref()
 const tab = ref(0)
+const loading = ref(false)
 const paths = [basicInfo, selfEvaluation, jobIntention, educationExp, workExperience, vocationalSkills, trainingExperience]
 const items = ref([
   { text: t('resume.basicInfo'), id: 'basicInfo', status: false },
@@ -125,13 +127,26 @@ const handleImportAttachment = () => {
   showAttachment.value = true
 }
 
+const result = ref({})
+// const fileUrl = 'https://minio.menduner.com/test/person/1/attachment/7cde29dc69c1403649be55d4c2bfd3d8304c088dc79ab25afe9c4bf55d3b382f.docx'
+// const fileUrl = 'https://minio.menduner.com/dev/person/546458957531713536/attachment/a71eeef077f41bb9edc9eae904f6cc8337c01431435c319612c7ce5d9258a808.pdf'
+const fileUrl = 'https://minio.menduner.com/dev/person/744285421114101760/attachment/8908069ceead39d55852f126c0a46dc5f338c1c9aae5c8e7b6838cddf2d57deb.pdf'
 const selectAttachment = ref('')
 const showAnalysis = ref(false)
-const handleAttachmentSubmit = (val) => {
+const handleAttachmentSubmit = async (val) => {
   if (!val) return
   selectAttachment.value = attachmentList.value.find(e => e.id === val).url
   showAttachment.value = false
-  showAnalysis.value = true
+  loading.value = true
+  try {
+    const data = await resumeParser({ fileUrl })
+    result.value = data.result
+  } catch (error) {
+    console.log(error)
+  } finally {
+    loading.value = false
+    showAnalysis.value = true
+  }
 }
 
 const handleResumeAnalysisSubmit = () => {}

+ 13 - 17
src/views/recruit/personal/PersonalCenter/resume/online/resumeAnalysis.vue

@@ -2,44 +2,40 @@
 <template>
   <CtDialog
     :visible="show"
-    :widthType="2"
+    :widthType="0"
+    :footer="false"
     titleClass="text-h6"
     title="附件简历解析内容"
     @close="emit('close')"
-    @submit="emit('submit')"
   >
-  111
+    <Evaluation v-if="data.contMyDesc" :data="data" />
+    <WorkExp v-if="data.jobExpObjs && data.jobExpObjs.length" :data="data" />
+    <EduExp v-if="data.educationObjs && data.educationObjs.length" :data="data" />
   </CtDialog>
 </template>
 
 <script setup>
 defineOptions({name: 'position-details-selectResumeDialog'})
 import { watch, computed } from 'vue'
-import { resumeParser } from '@/api/recruit/personal/resume'
+import WorkExp from './analysis/workExp.vue'
+import EduExp from './analysis/eduExp.vue'
+import Evaluation from './analysis/evaluation.vue'
 
+const emit = defineEmits(['update:modelValue', 'close'])
 const props = defineProps({
   modelValue: [Boolean, Number],
-  url: {
-    type: String,
-    default: ''
+  data: {
+    type: Object,
+    default: () => ({})
   }
 })
-const emit = defineEmits(['update:modelValue', 'submit', 'close'])
+
 const show = computed(() => {
   return props.modelValue
 })
 
-const fileUrl = 'https://minio.menduner.com/test/person/1/attachment/7cde29dc69c1403649be55d4c2bfd3d8304c088dc79ab25afe9c4bf55d3b382f.docx'
-// const fileUrl = 'https://minio.menduner.com/dev/person/270960672278450176/attachment/ade0423206dfeabb6955ad9a885c0ad206e41e89bc375cc78d21eb2eb13d0e59.pdf'
-// const fileUrl = 'https://minio.menduner.com/dev/person/795358459037093888/attachment/2d48cb1b3e07df73765c41eba3852e7b147d9beb67722ff233c46fc933096cfd.pdf'
-const handleResumeParser = async () => {
-  const data = await resumeParser({ fileUrl })
-  console.log(data, '简历解析', props.url)
-}
-
 watch(() => show.value, (newVal) => {
   emit('update:modelValue', newVal)
-  if (newVal) handleResumeParser()
 })
 </script>