对接文档详情的法规清单

This commit is contained in:
qq787203167
2022-04-18 10:32:22 +08:00
parent 0564957ca1
commit 50a716b998
4 changed files with 175 additions and 74 deletions
@@ -27,6 +27,7 @@
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: 1500}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
@@ -84,11 +85,13 @@
{
title: this.$t('standard'),
dataIndex: 'serial_number',
ellipsis: true,
align: 'center'
},
{
title: this.$t('title'),
dataIndex: 'title',
ellipsis: true,
align: 'center'
},
{
@@ -9,15 +9,49 @@
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<currencySearch
:flag="'1'"
:url="url"
@searchQuery="searchQuery"
@searchReset="searchReset"
/>
<div class="table-page-search-wrapper">
<a-row :gutter="24">
<a-col :md="12" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('standard')">
<span>{{$t('standard')}}</span>
</div>
<j-input class="box-input" :placeholder="$t('PleaseEnter')+$t('standard')"
v-model="queryParam.serial_number"></j-input>
</div>
</a-col>
<a-col :md="12" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('title')">
<span>{{$t('title')}}</span>
</div>
<j-input class="box-input" :placeholder="$t('PleaseEnter')+$t('title')"
v-model="queryParam.title"></j-input>
</div>
</a-col>
<a-col :md="12" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('status')">
<span>{{$t('status')}}</span>
</div>
<j-dict-select-tag class="box-input" v-model="queryParam.state"
:placeholder="$t('PleaseSelect')+$t('status')"
:type="'select'"
:triggerChange="false" :dictCode="'state'"/>
</div>
</a-col>
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
<a-col :md="12" :sm="24">
<a-button class="box-button" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" @click="searchReset">{{$t('reset')}}</a-button>
</a-col>
</span>
</a-row>
</div>
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: 1200}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
@@ -53,45 +87,54 @@
components: {
currencySearch
},
props:['url'],
data() {
return {
visible: false,
queryParam:{},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('standard'),
dataIndex: 'serial_number',
align: 'center'
dataIndex: 'serialNumber',
align: 'center',
ellipsis: true
},
{
title: this.$t('title'),
dataIndex: 'title',
align: 'center'
align: 'center',
ellipsis: true
},
{
title: this.$t('status'),
dataIndex: 'state',
align: 'center'
dataIndex: 'state_dictText',
align: 'center',
ellipsis: true
},
{
title: this.$t('technicalField'),
dataIndex: 'technicalField',
align: 'center'
}, {
title: this.$t('functionalAreas'),
dataIndex: 'functionalAreas',
align: 'center'
dataIndex: 'technologyTerritory_dictText',
align: 'center',
ellipsis: true
},
// {
// title: this.$t('functionalAreas'),
// dataIndex: 'functionalAreas',
// align: 'center'
// },
{
title: this.$t('StandardImplementationDate'),
dataIndex: 'StandardImplementationDate',
align: 'center'
dataIndex: 'xin1Che1Xing2Shi2Shi1Ri4Qi1',
align: 'center',
ellipsis: true
},
{
title: this.$t('correspondingStandard'),
dataIndex: 'correspondingStandard',
align: 'center'
align: 'center',
ellipsis: true
}
],
dataList: [],
@@ -100,9 +143,6 @@
pageNo: 1,
pageSize: 10,
total: 0,
url: {
seachList: 'document/bussDocumentLibraryEO/queryCondition' //搜索字段
}
}
},
mounted() {
@@ -111,21 +151,17 @@
methods: {
addModel() {
this.visible = true
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
searchQuery(queryParam) {
let queryParamQuery = JSON.parse(JSON.stringify(queryParam))
Object.keys(queryParamQuery).forEach(res => {
if (queryParamQuery[res] instanceof Array) {
queryParamQuery[res] = queryParamQuery[res].join(',')
}
})
this.queryParam = queryParamQuery
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset(queryParam) {
this.queryParam = queryParam
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
@@ -138,7 +174,21 @@
this.replacePage()
},
replacePage() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
...this.queryParam
}
this.loading = true
postAction(this.url.addModelList, query).then((res) => {
if (res.success) {
this.dataList = res.result.records || []
this.total = res.result.total
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
@@ -148,6 +198,20 @@
},
handleSubmit() {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
postAction(this.url.addModel, { ids: selectedRowKeys.join(','),projectLibraryId: this.$route.query.id }).then((res) => {
if (res.success) {
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.selectedRowKeys = []
this.$emit('addModelList')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
this.visible = false
} else {
this.$message.warning(this.$t('selectLeastOne'))
@@ -174,4 +238,37 @@
background: #fff;
border-radius: 0 0 2px 2px;
}
.box-title-text {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text {
width: 20%;
min-width: 110px;
color: #000F16;
display: inline-block;
font-weight: 500;
font-size: 14px;
margin-right: 16px;
margin-top: 3px;
text-align: right;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.box-input {
display: inline-block;
width: 70%;
height: 38px;
margin-top: 2px;
}
.box-button {
height: 38px;
}
</style>
@@ -16,10 +16,10 @@
<div class="title-text">
<span class="title-text-text" :title="$t('standard')">{{$t('standard')}}</span>
</div>
<a-form-model-item class="itemModel" prop="standard">
<a-form-model-item class="itemModel" prop="serialNumber">
<a-input class="box-input"
:disabled="true"
v-model="formInline.standard"
v-model="formInline.serialNumber"
:placeholder="$t('PleaseEnter')+$t('standard')"/>
</a-form-model-item>
</div>
@@ -46,7 +46,7 @@
</div>
<a-form-model-item class="itemModel" prop="subtitle">
<a-input class="box-input"
:disabled="true"
:disabled="false"
v-model="formInline.subtitle"
:placeholder="$t('PleaseEnter')+$t('subtitle')"/>
</a-form-model-item>
@@ -57,10 +57,10 @@
<div class="title-text">
<span class="title-text-text" :title="'WVTA ID'">WVTA ID</span>
</div>
<a-form-model-item class="itemModel" prop="WVTAID">
<a-form-model-item class="itemModel" prop="wvtaId">
<a-input class="box-input"
:disabled="true"
v-model="formInline.WVTAID"
:disabled="false"
v-model="formInline.wvtaId"
:placeholder="$t('PleaseEnter')+'WVTA ID'"/>
</a-form-model-item>
</div>
@@ -74,12 +74,10 @@
:title="$t('correspondingStandard')">{{$t('correspondingStandard')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'correspondingStandard'">
<Standardselection :query="{db_field_name:'correspondingStandard',
db_field_txt:$t('correspondingStandard'),}"
@change="StandardselectionChange"
:disabled="disabled"
:standard="formInline"
v-model="formInline.correspondingStandard"/>
<a-input class="box-input"
:disabled="true"
v-model="formInline.correspondingStandard"
:placeholder="$t('PleaseEnter')+$t('correspondingStandard')"/>
</a-form-model-item>
</div>
</a-col>
@@ -89,13 +87,13 @@
<span class="title-text-text"
:title="$t('implementationCategory')">{{$t('implementationCategory')}}</span>
</div>
<a-form-model-item class="itemModel" prop="implementationCategory">
<j-dict-select-tag class="box-input" v-model="formInline.implementationCategory"
<a-form-model-item class="itemModel" prop="implementType">
<j-dict-select-tag class="box-input" v-model="formInline.implementType"
:disabled="disabled"
@input="handleInput('implementationCategory')"
@input="handleInput('implementType')"
:placeholder="$t('PleaseSelect')+$t('implementationCategory')"
:type="'select'"
:triggerChange="false" :dictCode="'dict_field'"/>
:triggerChange="false" :dictCode="'implement_type'"/>
</a-form-model-item>
</div>
</a-col>
@@ -107,13 +105,13 @@
<span class="title-text-text"
:title="$t('vehicleInProductionDate')">{{$t('vehicleInProductionDate')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'vehicleInProductionDate'">
<a-form-model-item class="itemModel" :prop="'implementTime'">
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('vehicleInProductionDate')"
@change="dateChange({db_field_name:'vehicleInProductionDate'})"
@change="dateChange({db_field_name:'implementTime'})"
format="YYYY-MM-DD"
v-model="formInline.vehicleInProductionDate"
:disabled="disabled"
v-model="formInline.implementTime"
:disabled="true"
style="width: 100%"/>
</a-form-model-item>
</div>
@@ -123,13 +121,13 @@
<div class="title-text">
<span class="title-text-text" :title="$t('ImplementationDate')">{{$t('ImplementationDate')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'ImplementationDate'">
<a-form-model-item class="itemModel">
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('ImplementationDate')"
@change="dateChange({db_field_name:'ImplementationDate'})"
@change="dateChange({db_field_name:'xin1Che1Xing2Shi2Shi1Ri4Qi1'})"
format="YYYY-MM-DD"
v-model="formInline.ImplementationDate"
:disabled="disabled"
v-model="formInline.xin1Che1Xing2Shi2Shi1Ri4Qi1"
:disabled="true"
style="width: 100%"/>
</a-form-model-item>
</div>
@@ -142,13 +140,13 @@
<span class="title-text-text"
:title="$t('certificationType')">{{$t('certificationType')}}</span>
</div>
<a-form-model-item class="itemModel" prop="certificationType">
<j-dict-select-tag class="box-input" v-model="formInline.certificationType"
<a-form-model-item class="itemModel" prop="attestationType">
<j-dict-select-tag class="box-input" v-model="formInline.attestationType"
:disabled="disabled"
@input="handleInput('certificationType')"
@input="handleInput('attestationType')"
:placeholder="$t('PleaseSelect')+$t('certificationType')"
:type="'select'"
:triggerChange="false" :dictCode="'dict_field'"/>
:triggerChange="false" :dictCode="'attestation_type'"/>
</a-form-model-item>
</div>
</a-col>
@@ -158,13 +156,13 @@
<span class="title-text-text"
:title="$t('certificationLevel')">{{$t('certificationLevel')}}</span>
</div>
<a-form-model-item class="itemModel" prop="certificationLevel">
<j-dict-select-tag class="box-input" v-model="formInline.certificationLevel"
<a-form-model-item class="itemModel" prop="attestationRank">
<j-dict-select-tag class="box-input" v-model="formInline.attestationRank"
:disabled="disabled"
@input="handleInput('certificationLevel')"
@input="handleInput('attestationRank')"
:placeholder="$t('PleaseSelect')+$t('certificationLevel')"
:type="'select'"
:triggerChange="false" :dictCode="'dict_field'"/>
:triggerChange="false" :dictCode="'attestation_rank'"/>
</a-form-model-item>
</div>
</a-col>
@@ -177,12 +175,11 @@
:title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
</div>
<a-form-model-item class="itemModel" prop="areaOfResponsibility">
<j-dict-select-tag class="box-input" v-model="formInline.areaOfResponsibility"
:disabled="disabled"
@input="handleInput('areaOfResponsibility')"
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
:type="'select'"
:triggerChange="false" :dictCode="'dict_field'"/>
<j-multi-select-tag class="box-input" v-model="formInline.dutyTerritory"
:disabled="disabled"
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
:type="'select'"
:triggerChange="false" :dictCode="'duty_territory'"/>
</a-form-model-item>
</div>
</a-col>
@@ -107,7 +107,7 @@
</span>
</a-table>
</div>
<listAddModel :url="url" ref="addModelRef"/>
<listAddModel :url="url" @addModelList="addModelList" ref="addModelRef"/>
<listEditModel :url="url" ref="editModelRef"/>
</a-card>
</template>
@@ -324,8 +324,9 @@
selectedRowKeys: [],
queryParam: {},
url: {
addModelList: '/document/bussDocumentLibraryEO/queryPageInfoDummy',
list: '/project/projectLawsInventoryEO/list',
add: 'project/projectLawsInventoryEO/add',
addModel: 'project/projectLawsInventoryEO/add',
edit: '/project/projectLawsInventoryEO/edit',
deleteBatch: '/project/projectLawsInventoryEO/deleteBatch',
deleteOne: '/project/projectLawsInventoryEO/delete'
@@ -404,6 +405,9 @@
this.queryParam = {}
this.getList()
},
addModelList() {
this.getList()
},
getList() {
let query = {
...this.queryParam,