bug修复

This commit is contained in:
LHD_HY 2025-11-26 18:25:40 +08:00
parent 5c416d7559
commit c344954779
5 changed files with 1225 additions and 15 deletions

View File

@ -0,0 +1,59 @@
import request from '@/utils/request'
/**
* 解析规则配置接口统一处理解析规则相关数据交互
*/
// 1. 查询解析规则配置列表支持按模板ID、规则类型等筛选
export function listAnalysisRuleSet(query) {
return request({
url: '/smartBid/analysisRuleSet/list',
method: 'get',
params: query
})
}
// 2. 查询解析规则配置详情携带解析规则ID包含关联定位查询规则信息
export function getAnalysisRuleSetDetail(params) {
return request({
url: '/smartBid/analysisRuleSet/detail',
method: 'get',
params: params
})
}
// 3. 新增解析规则配置携带解析名称、模板ID等基础信息
export function addAnalysisRuleSet(data) {
return request({
url: '/smartBid/analysisRuleSet/add',
method: 'post',
data: data
})
}
// 4. 修改解析规则配置携带解析规则ID更新配置信息
export function updateAnalysisRuleSet(data) {
return request({
url: '/smartBid/analysisRuleSet/edit',
method: 'post',
data: data
})
}
// 5. 删除解析规则配置携带解析规则ID级联删除关联的定位查询规则
export function delAnalysisRuleSet(params) {
return request({
url: '/smartBid/analysisRuleSet/delete',
method: 'post',
data: params
})
}
// 6. 校验解析规则名称唯一性(新增/编辑时使用,避免重复)
export function checkAnalysisNameUnique(params) {
return request({
url: '/smartBid/analysisRuleSet/checkNameUnique',
method: 'get',
params: params
})
}

File diff suppressed because it is too large Load Diff

View File

@ -48,6 +48,7 @@
<ProjectFile <ProjectFile
ref="projectFileRef" ref="projectFileRef"
title="项目文件" title="项目文件"
:is-edit-mode="type === 'edit'"
/> />
</el-col> </el-col>
</el-row> </el-row>
@ -57,6 +58,7 @@
<SectionFile <SectionFile
ref="sectionFileRef" ref="sectionFileRef"
title="标段/标包文件" title="标段/标包文件"
:is-edit-mode="type === 'edit'"
/> />
</el-col> </el-col>
</el-row> </el-row>
@ -254,8 +256,6 @@ export default {
// //
this.$refs.basicInfoRef.setFormData(detail); this.$refs.basicInfoRef.setFormData(detail);
// detail.projectFiles detail.sectionFiles
// setFormData
this.$refs.projectFileRef.setFormData(detail.projectFiles || []); this.$refs.projectFileRef.setFormData(detail.projectFiles || []);
this.$refs.sectionFileRef.setFormData(detail.sectionFiles || []); this.$refs.sectionFileRef.setFormData(detail.sectionFiles || []);
this.$refs.analysisLabelRef.setFormData(detail); this.$refs.analysisLabelRef.setFormData(detail);

View File

@ -21,7 +21,7 @@
type="card" type="card"
class="file-tabs" class="file-tabs"
@tab-remove="handleRemoveTab" @tab-remove="handleRemoveTab"
@tab-click="handleTabChange" v-on="isEditMode ? { 'tab-click': handleTabChange } : {}"
> >
<el-tab-pane <el-tab-pane
v-for="(tab, index) in fileTabs" v-for="(tab, index) in fileTabs"
@ -103,6 +103,11 @@ export default {
title: { title: {
type: String, type: String,
default: '模板组成-标段/标包文件' default: '模板组成-标段/标包文件'
},
isEditMode: {
type: Boolean,
default: false
} }
}, },
data() { data() {

View File

@ -43,7 +43,6 @@
<!-- 操作按钮调整更多按钮样式增加菜单项 --> <!-- 操作按钮调整更多按钮样式增加菜单项 -->
<template slot="handle" slot-scope="{ data }"> <template slot="handle" slot-scope="{ data }">
<!-- 解析规则按钮保持原有样式 -->
<el-button <el-button
type="text" type="text"
v-hasPermi="['template:info:detail']" v-hasPermi="['template:info:detail']"
@ -244,16 +243,14 @@ export default {
// //
handleDetail(data) { handleDetail(data) {
if (data && data.templateId) { this.$router.push({
console.log('关联的组成数据:', data.compositionList); name: "AnalysisRule",
const encryptedId = encryptWithSM4(data.templateId.toString()); query: {
this.$router.push({ analysisLabelId: encryptWithSM4(data.analysisLabelId.toString()),
name: 'TemplateRule', templateId: encryptWithSM4(data.templateId.toString())
query: { templateId: encryptedId } },
}); title: '解析规则'
} else { });
this.$modal.msgError('获取模板ID失败请重试');
}
}, },
// //
@ -280,7 +277,7 @@ export default {
this.$modal.confirm(`是否确认删除“${row.templateName}”模板?`) this.$modal.confirm(`是否确认删除“${row.templateName}”模板?`)
.then(() => { .then(() => {
delTemplateInfo({ delTemplateInfo({
templateId: encryptWithSM4(row.templateId.toString()) templateId: row.templateId
}).then(res => { }).then(res => {
if (res.code === 200) { if (res.code === 200) {
this.$modal.msgSuccess('删除成功'); this.$modal.msgSuccess('删除成功');