|
@@ -76,7 +76,7 @@ import { saveResumeInfo, resumeParser2 } from '@/api/recruit/personal/resume'
|
|
import { useUserStore } from '@/store/user'
|
|
import { useUserStore } from '@/store/user'
|
|
import attachmentPage from '../attachment'
|
|
import attachmentPage from '../attachment'
|
|
import { Base64 } from 'js-base64'
|
|
import { Base64 } from 'js-base64'
|
|
-import { analyzeTestData } from './analyzeTestData.js'
|
|
|
|
|
|
+// import { analyzeTestData } from './analyzeTestData.js'
|
|
const { t } = useI18n()
|
|
const { t } = useI18n()
|
|
const props = defineProps({
|
|
const props = defineProps({
|
|
data: {
|
|
data: {
|
|
@@ -135,8 +135,7 @@ const transformToLIst = async (result) => {
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
-// const result = ref({}) // ref(JSON.parse(JSON.stringify(analyzeTestData))) // 测试
|
|
|
|
-const result = ref(JSON.parse(JSON.stringify(analyzeTestData))) // 测试
|
|
|
|
|
|
+const result = ref({}) // ref(JSON.parse(JSON.stringify(analyzeTestData))) // 测试
|
|
const fileUrl = ref('')
|
|
const fileUrl = ref('')
|
|
const showSelect = ref(true)
|
|
const showSelect = ref(true)
|
|
const handleAnalysis = async (url) => {
|
|
const handleAnalysis = async (url) => {
|
|
@@ -147,8 +146,8 @@ const handleAnalysis = async (url) => {
|
|
const baseUrl = import.meta.env.VITE_PREVIEW_URL
|
|
const baseUrl = import.meta.env.VITE_PREVIEW_URL
|
|
fileUrl.value = !url.includes('.pdf') ? `${baseUrl}/onlinePreview?url=${encodeURIComponent(Base64.encode(url))}` : url
|
|
fileUrl.value = !url.includes('.pdf') ? `${baseUrl}/onlinePreview?url=${encodeURIComponent(Base64.encode(url))}` : url
|
|
try {
|
|
try {
|
|
- // const data = await resumeParser2({ fileUrl: url })
|
|
|
|
- // result.value = data || {}
|
|
|
|
|
|
+ const data = await resumeParser2({ fileUrl: url })
|
|
|
|
+ result.value = data || {}
|
|
await transformToLIst(result.value)
|
|
await transformToLIst(result.value)
|
|
} catch (error) {
|
|
} catch (error) {
|
|
console.log(error)
|
|
console.log(error)
|