[update 标准分解单组件] 增加条款内容搜索条件

This commit is contained in:
danshihao
2024-08-05 11:35:10 +08:00
parent 8ffe1d6c0e
commit 263561af78
+43 -5
View File
@@ -1,5 +1,25 @@
<template>
<a-spin :spinning="loading">
<!-- 搜索条件 -->
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24" style="margin: 0;">
<!--条款内容-->
<a-col :md="6" :sm="12">
<a-form-item :label="$t('clauseSelect.clauseContent')">
<a-input :placeholder="$t('pleaseEnter') + $t('clauseSelect.clauseContent')"
v-model="queryParam.item_content"></a-input>
</a-form-item>
</a-col>
<div class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search" style="margin-left: 8px" v-has="'split:sarFileSplitInfo:search'">
{{ $t('query') }}
</a-button>
<a-button type="primary" @click="searchReset" icon="reload" ghost>{{ $t('reset') }}</a-button>
</div>
</a-row>
</a-form>
</div>
<!-- 拖拽中不能选中内容 -->
<div class="sheet-box" :class="{ disabledSelect: isDragging }" ref="sheetBoxRef">
<!--标准目录-->
@@ -140,6 +160,7 @@ export default {
clauseLabelHideField: ['item_content'],
needDictField: [FieldType.USER_SINGLE.value, FieldType.ORGAN_SINGLE.value, FieldType.STANDARD_MORE.value, FieldType.ORGAN_MORE.value, FieldType.OPTION_SINGLE.value, FieldType.OPTION_MORE.value, FieldType.TREE.value],
queryParams: {},
queryParam: {}, // 变更增加:输入的查询条件
isDragging: false, // 是否拖拽中
standardCatalogueRefX: 280, // 标准目录默认宽度
sheetContainerRefX: 0, // 标准内容默认宽度
@@ -195,16 +216,33 @@ export default {
}
})
},
initDetailInfo () {
// 查询
searchQuery () {
const query = Object.assign({}, this.queryParam)
query.serial_number = this.spiltInfo.serialNumber
this.initDetailInfo(query)
},
// 重置
searchReset () {
this.queryParam = {}
this.initDetailInfo()
},
// 清除选中状态
clearSelect () {
this.selectedTreeKeys = []
this.hightMenuId = null
this.clauseLabelInfo = {}
},
initDetailInfo (query) {
this.loading = true
const params = {
...this.queryParams
}
const params = Object.assign({}, this.queryParams, query)
if (this.horizontalOverstep) {
params.horizontalOverstep = true
}
previewDocSplit(params).then(res => {
if (res.success) {
// 清除选中
this.clearSelect()
const data = res.result || {}
this.treeData = data.sarFileSplitMenuEO || []
this.spiltInfo = data.documentSplitInfo || {}
@@ -309,7 +347,7 @@ export default {
.sheet-box {
overflow-x: auto;
width: 100%;
height: 100%;
height: calc(100% - 56px);
display: flex;
justify-content: space-between;