mirror of
http://112.124.100.131/ebiz-ai/ebiz-ai-knowledge-manage.git
synced 2025-12-10 03:16:49 +08:00
refactor(knowledge): 重构知识库创建流程
- 修改步骤组件的引用和命名 - 优化"下一步"按钮的逻辑,增加表单校验 - 新增 execSplit API 用于拆分规则的下一步校验
This commit is contained in:
@@ -13,8 +13,8 @@
|
||||
|
||||
<div class="components">
|
||||
<step-preprocessing v-if="active === 0" @getForm="getForm" @getDocumentId="getDocumentId" @beMinerU="beMinerU"></step-preprocessing>
|
||||
<split-config v-if="active === 1"></split-config>
|
||||
<words v-if="active === 2"></words>
|
||||
<step-split-config ref="splitConfig" v-if="active === 1"></step-split-config>
|
||||
<step-words v-if="active === 2"></step-words>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
</el-button>
|
||||
<el-button type="primary" size="medium" v-if="active === 2">确定</el-button>
|
||||
<el-button size="medium" @click="active--" v-if="active >= 1">上一步</el-button>
|
||||
<el-button type="primary" size="medium" @click="active++" v-if="active < 2">下一步</el-button>
|
||||
<!-- <el-button type="primary" size="medium" @click="active++" v-if="active < 2">下一步</el-button>-->
|
||||
<el-button type="primary" size="medium" @click="nextStep" v-if="active < 2">下一步</el-button>
|
||||
<el-button type="primary" size="medium">取消</el-button>
|
||||
</div>
|
||||
</el-card>
|
||||
@@ -54,9 +55,9 @@ export default {
|
||||
props: {},
|
||||
watch: {},
|
||||
components: {
|
||||
SplitConfig,
|
||||
StepSplitConfig: SplitConfig,
|
||||
StepPreprocessing,
|
||||
Words
|
||||
StepWords: Words
|
||||
},
|
||||
filters: {},
|
||||
methods: {
|
||||
@@ -67,6 +68,13 @@ export default {
|
||||
fetchApi() {},
|
||||
getDocumentId(id) {
|
||||
this.documentId = id
|
||||
},
|
||||
nextStep() {
|
||||
if (this.active === 0) {
|
||||
this.active++
|
||||
} else if (this.active === 1) {
|
||||
this.$refs.splitConfig.nextStep()
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {},
|
||||
|
||||
Reference in New Issue
Block a user