|
@@ -59,7 +59,7 @@
|
|
|
>解析</el-button>
|
|
|
<el-button v-else type="warning" link @click="handleStore(scope.row, true)">详情</el-button>
|
|
|
<el-button
|
|
|
- v-if="scope.row.task_status === '成功' && scope.row.parse_result"
|
|
|
+ v-if="scope.row.task_status === '成功'"
|
|
|
link
|
|
|
type="primary"
|
|
|
@click="handleStore(scope.row)"
|
|
@@ -247,9 +247,17 @@ const handleWebAnalysis = (list) => {
|
|
|
|
|
|
// 入库
|
|
|
const StorePageRef = ref(null)
|
|
|
-const handleStore = ({ task_type, parse_result, id }, isDetail = false) => {
|
|
|
- if (!parse_result) return message.warning(isDetail ? '暂无详情查看' : '暂无解析数据可入库')
|
|
|
- StorePageRef.value.open(task_type, parse_result, id, isDetail)
|
|
|
+const handleStore = ({ task_type, parse_result, id, task_source }, isDetail = false) => {
|
|
|
+ const txt = isDetail ? '暂无详情查看' : '暂无解析数据可入库'
|
|
|
+ const isRecruitment = Boolean(task_type === '招聘')
|
|
|
+ if (isRecruitment) {
|
|
|
+ if (!task_source?.data) return message.warning(txt)
|
|
|
+ } else {
|
|
|
+ if (!parse_result) return message.warning(txt)
|
|
|
+ }
|
|
|
+
|
|
|
+const list = isRecruitment ? { results: JSON.parse(task_source.data) } : parse_result // 解析的人才列表
|
|
|
+ StorePageRef.value.open(task_type, list, id, isDetail)
|
|
|
}
|
|
|
|
|
|
// 任务解析
|