feat(knowledge): 实现知识库文件上传自定义功能

- 新增 datasetsExPages 和 uploadFileByCustom 接口
- 实现文件上传功能,支持自定义文件和通用知识文件模板
- 添加预处理结果预览功能
- 优化文件上传组件,支持拖拽上传和进度显示
This commit is contained in:
陈昱达
2025-04-14 11:03:31 +08:00
parent 6895c35827
commit 0fd180a1e2
11 changed files with 367 additions and 186 deletions

View File

@@ -12,7 +12,7 @@
</el-steps>
<div class="components">
<step-preprocessing v-if="active === 0" @getForm="getForm"></step-preprocessing>
<step-preprocessing v-if="active === 0" @getForm="getForm" @getDocumentId="getDocumentId"></step-preprocessing>
<split-config v-if="active === 1"></split-config>
<words v-if="active === 2"></words>
</div>
@@ -27,9 +27,10 @@
</div>
</el-card>
<el-drawer :visible.sync="visible" size="80%" title="预处理结果预览">
<!-- 添加预处理结果预览对话框 -->
<el-drawer :visible.sync="visible" size="80%" title="预处理结果预览" :before-close="handleClose">
<div style="height:calc(100% - 55px);">
<r-miner-u></r-miner-u>
<r-miner-u :documentId="documentId"></r-miner-u>
</div>
</el-drawer>
</div>
@@ -44,7 +45,8 @@ export default {
data() {
return {
visible: true,
active: 0
active: 0,
documentId: ''
}
},
props: {},
@@ -57,7 +59,10 @@ export default {
filters: {},
methods: {
getForm() {},
fetchApi() {}
fetchApi() {},
getDocumentId(id) {
this.documentId = id
}
},
created() {},
mounted() {},