wujingjing
2024-09-10 bcfac298673fc92d953e6636bbab5a49f5c960d7
src/views/project/yw/dataManage/graph/AddGraph.vue
@@ -1,7 +1,7 @@
<template>
   <div class="h100 overflow-y-auto p-[16px]">
      <div class="mb-[10px] flex items-center">
         <el-button style="margin-left: 8px; width: 40px" text @click="handleExitFlow">
         <el-button style="margin-left: 8px; width: 40px" link @click="handleExitFlow">
            <el-icon style="font-size: 24px !important">
               <ArrowLeft />
            </el-icon>
@@ -43,22 +43,6 @@
                           </template>
                        </el-upload>
                     </el-form-item>
                     <el-form-item label="文档识别:">
                        <div
                           class="bg-[#f6f5ff] border-[1px] border-solid border-[#0062be] py-[12px] w-[215px] px-[16px] rounded-lg cursor-pointer"
                        >
                           <el-radio-group v-model="state.categoryForm.DocumentRecognition">
                              <el-radio value="1" size="large">
                                 <span class="font-[700] text[14px]">文档智能解析</span>
                              </el-radio>
                           </el-radio-group>
                           <el-tooltip :content="state.demoDesc" placement="top" effect="light" popper-class="set_tooltip_demo">
                              <div class="text-[#878aab] text-[12px] mx-0 mt-[2px] mb-0 set-desc">
                                 {{ state.demoDesc }}
                              </div>
                           </el-tooltip>
                        </div>
                     </el-form-item>
                  </el-form>
                  <div class="set-form-footer">
@@ -75,7 +59,7 @@
<script setup lang="ts">
import type { UploadUserFile } from 'element-plus';
import { ElMessage } from 'element-plus';
import { reactive, ref } from 'vue';
import { onMounted, reactive, ref } from 'vue';
import { useRoute, useRouter } from 'vue-router';
import { add_knowledge_file } from '/@/api/knowledge/group';
const uploadFileChange = (rule, value, callback) => {
@@ -89,7 +73,7 @@
const state = reactive({
   detailTitle: '导入数据',
   categoryForm: {
      ImportCategory: '默认类目',
      ImportCategory: '',
      CategoryType: '本地类目',
      DocumentRecognition: '1',
   },
@@ -97,7 +81,6 @@
   allowType: 'md',
   limit: 5,
   size: 5,
   demoDesc: '使用阿里云文档智能解析服务据解析文档,抽取文档内容、层级结构等信息。',
   categoryFormRules: {
      importType: [{ required: true, validator: uploadFileChange, trigger: 'change' }],
   },
@@ -150,6 +133,10 @@
      }
   });
};
onMounted(() => {
   const group_title = route.query.title;
   state.categoryForm.ImportCategory = group_title;
});
</script>
<style scoped lang="scss">
.set-form-height {