对接文档详情的法规清单

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 <a-table
:columns="columns" :columns="columns"
rowKey="id" rowKey="id"
:scroll="{x: 1500}"
:data-source="dataList" :data-source="dataList"
:pagination="false" :pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" :row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
@@ -84,11 +85,13 @@
{ {
title: this.$t('standard'), title: this.$t('standard'),
dataIndex: 'serial_number', dataIndex: 'serial_number',
ellipsis: true,
align: 'center' align: 'center'
}, },
{ {
title: this.$t('title'), title: this.$t('title'),
dataIndex: 'title', dataIndex: 'title',
ellipsis: true,
align: 'center' align: 'center'
}, },
{ {
@@ -9,15 +9,49 @@
:visible="visible" :visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;"> style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px"> <div style="margin-bottom: 60px">
<currencySearch <div class="table-page-search-wrapper">
:flag="'1'" <a-row :gutter="24">
:url="url" <a-col :md="12" :sm="8">
@searchQuery="searchQuery" <div class="box-title-text">
@searchReset="searchReset" <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 <a-table
:columns="columns" :columns="columns"
rowKey="id" rowKey="id"
:scroll="{x: 1200}"
:data-source="dataList" :data-source="dataList"
:pagination="false" :pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" :row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
@@ -53,45 +87,54 @@
components: { components: {
currencySearch currencySearch
}, },
props:['url'],
data() { data() {
return { return {
visible: false, visible: false,
queryParam:{},
confirmLoading: false, confirmLoading: false,
selectedRowKeys: [], selectedRowKeys: [],
columns: [ columns: [
{ {
title: this.$t('standard'), title: this.$t('standard'),
dataIndex: 'serial_number', dataIndex: 'serialNumber',
align: 'center' align: 'center',
ellipsis: true
}, },
{ {
title: this.$t('title'), title: this.$t('title'),
dataIndex: 'title', dataIndex: 'title',
align: 'center' align: 'center',
ellipsis: true
}, },
{ {
title: this.$t('status'), title: this.$t('status'),
dataIndex: 'state', dataIndex: 'state_dictText',
align: 'center' align: 'center',
ellipsis: true
}, },
{ {
title: this.$t('technicalField'), title: this.$t('technicalField'),
dataIndex: 'technicalField', dataIndex: 'technologyTerritory_dictText',
align: 'center' align: 'center',
}, { ellipsis: true
title: this.$t('functionalAreas'),
dataIndex: 'functionalAreas',
align: 'center'
}, },
// {
// title: this.$t('functionalAreas'),
// dataIndex: 'functionalAreas',
// align: 'center'
// },
{ {
title: this.$t('StandardImplementationDate'), title: this.$t('StandardImplementationDate'),
dataIndex: 'StandardImplementationDate', dataIndex: 'xin1Che1Xing2Shi2Shi1Ri4Qi1',
align: 'center' align: 'center',
ellipsis: true
}, },
{ {
title: this.$t('correspondingStandard'), title: this.$t('correspondingStandard'),
dataIndex: 'correspondingStandard', dataIndex: 'correspondingStandard',
align: 'center' align: 'center',
ellipsis: true
} }
], ],
dataList: [], dataList: [],
@@ -100,9 +143,6 @@
pageNo: 1, pageNo: 1,
pageSize: 10, pageSize: 10,
total: 0, total: 0,
url: {
seachList: 'document/bussDocumentLibraryEO/queryCondition' //搜索字段
}
} }
}, },
mounted() { mounted() {
@@ -111,21 +151,17 @@
methods: { methods: {
addModel() { addModel() {
this.visible = true this.visible = true
this.queryParam = {}
this.selectedRowKeys = [] this.selectedRowKeys = []
this.replacePage() this.replacePage()
}, },
searchQuery(queryParam) { searchQuery() {
let queryParamQuery = JSON.parse(JSON.stringify(queryParam)) this.pageNo = 1
Object.keys(queryParamQuery).forEach(res => {
if (queryParamQuery[res] instanceof Array) {
queryParamQuery[res] = queryParamQuery[res].join(',')
}
})
this.queryParam = queryParamQuery
this.replacePage() this.replacePage()
}, },
searchReset(queryParam) { searchReset() {
this.queryParam = queryParam this.pageNo = 1
this.queryParam = {}
this.replacePage() this.replacePage()
}, },
onChange(page, pageSize) { onChange(page, pageSize) {
@@ -138,7 +174,21 @@
this.replacePage() this.replacePage()
}, },
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) { onSelectChange(value) {
this.selectedRowKeys = value this.selectedRowKeys = value
@@ -148,6 +198,20 @@
}, },
handleSubmit() { handleSubmit() {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) { 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 this.visible = false
} else { } else {
this.$message.warning(this.$t('selectLeastOne')) this.$message.warning(this.$t('selectLeastOne'))
@@ -174,4 +238,37 @@
background: #fff; background: #fff;
border-radius: 0 0 2px 2px; 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> </style>
@@ -16,10 +16,10 @@
<div class="title-text"> <div class="title-text">
<span class="title-text-text" :title="$t('standard')">{{$t('standard')}}</span> <span class="title-text-text" :title="$t('standard')">{{$t('standard')}}</span>
</div> </div>
<a-form-model-item class="itemModel" prop="standard"> <a-form-model-item class="itemModel" prop="serialNumber">
<a-input class="box-input" <a-input class="box-input"
:disabled="true" :disabled="true"
v-model="formInline.standard" v-model="formInline.serialNumber"
:placeholder="$t('PleaseEnter')+$t('standard')"/> :placeholder="$t('PleaseEnter')+$t('standard')"/>
</a-form-model-item> </a-form-model-item>
</div> </div>
@@ -46,7 +46,7 @@
</div> </div>
<a-form-model-item class="itemModel" prop="subtitle"> <a-form-model-item class="itemModel" prop="subtitle">
<a-input class="box-input" <a-input class="box-input"
:disabled="true" :disabled="false"
v-model="formInline.subtitle" v-model="formInline.subtitle"
:placeholder="$t('PleaseEnter')+$t('subtitle')"/> :placeholder="$t('PleaseEnter')+$t('subtitle')"/>
</a-form-model-item> </a-form-model-item>
@@ -57,10 +57,10 @@
<div class="title-text"> <div class="title-text">
<span class="title-text-text" :title="'WVTA ID'">WVTA ID</span> <span class="title-text-text" :title="'WVTA ID'">WVTA ID</span>
</div> </div>
<a-form-model-item class="itemModel" prop="WVTAID"> <a-form-model-item class="itemModel" prop="wvtaId">
<a-input class="box-input" <a-input class="box-input"
:disabled="true" :disabled="false"
v-model="formInline.WVTAID" v-model="formInline.wvtaId"
:placeholder="$t('PleaseEnter')+'WVTA ID'"/> :placeholder="$t('PleaseEnter')+'WVTA ID'"/>
</a-form-model-item> </a-form-model-item>
</div> </div>
@@ -74,12 +74,10 @@
:title="$t('correspondingStandard')">{{$t('correspondingStandard')}}</span> :title="$t('correspondingStandard')">{{$t('correspondingStandard')}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="'correspondingStandard'"> <a-form-model-item class="itemModel" :prop="'correspondingStandard'">
<Standardselection :query="{db_field_name:'correspondingStandard', <a-input class="box-input"
db_field_txt:$t('correspondingStandard'),}" :disabled="true"
@change="StandardselectionChange" v-model="formInline.correspondingStandard"
:disabled="disabled" :placeholder="$t('PleaseEnter')+$t('correspondingStandard')"/>
:standard="formInline"
v-model="formInline.correspondingStandard"/>
</a-form-model-item> </a-form-model-item>
</div> </div>
</a-col> </a-col>
@@ -89,13 +87,13 @@
<span class="title-text-text" <span class="title-text-text"
:title="$t('implementationCategory')">{{$t('implementationCategory')}}</span> :title="$t('implementationCategory')">{{$t('implementationCategory')}}</span>
</div> </div>
<a-form-model-item class="itemModel" prop="implementationCategory"> <a-form-model-item class="itemModel" prop="implementType">
<j-dict-select-tag class="box-input" v-model="formInline.implementationCategory" <j-dict-select-tag class="box-input" v-model="formInline.implementType"
:disabled="disabled" :disabled="disabled"
@input="handleInput('implementationCategory')" @input="handleInput('implementType')"
:placeholder="$t('PleaseSelect')+$t('implementationCategory')" :placeholder="$t('PleaseSelect')+$t('implementationCategory')"
:type="'select'" :type="'select'"
:triggerChange="false" :dictCode="'dict_field'"/> :triggerChange="false" :dictCode="'implement_type'"/>
</a-form-model-item> </a-form-model-item>
</div> </div>
</a-col> </a-col>
@@ -107,13 +105,13 @@
<span class="title-text-text" <span class="title-text-text"
:title="$t('vehicleInProductionDate')">{{$t('vehicleInProductionDate')}}</span> :title="$t('vehicleInProductionDate')">{{$t('vehicleInProductionDate')}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="'vehicleInProductionDate'"> <a-form-model-item class="itemModel" :prop="'implementTime'">
<a-date-picker class="box-input" <a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('vehicleInProductionDate')" :placeholder="$t('PleaseSelect')+$t('vehicleInProductionDate')"
@change="dateChange({db_field_name:'vehicleInProductionDate'})" @change="dateChange({db_field_name:'implementTime'})"
format="YYYY-MM-DD" format="YYYY-MM-DD"
v-model="formInline.vehicleInProductionDate" v-model="formInline.implementTime"
:disabled="disabled" :disabled="true"
style="width: 100%"/> style="width: 100%"/>
</a-form-model-item> </a-form-model-item>
</div> </div>
@@ -123,13 +121,13 @@
<div class="title-text"> <div class="title-text">
<span class="title-text-text" :title="$t('ImplementationDate')">{{$t('ImplementationDate')}}</span> <span class="title-text-text" :title="$t('ImplementationDate')">{{$t('ImplementationDate')}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="'ImplementationDate'"> <a-form-model-item class="itemModel">
<a-date-picker class="box-input" <a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('ImplementationDate')" :placeholder="$t('PleaseSelect')+$t('ImplementationDate')"
@change="dateChange({db_field_name:'ImplementationDate'})" @change="dateChange({db_field_name:'xin1Che1Xing2Shi2Shi1Ri4Qi1'})"
format="YYYY-MM-DD" format="YYYY-MM-DD"
v-model="formInline.ImplementationDate" v-model="formInline.xin1Che1Xing2Shi2Shi1Ri4Qi1"
:disabled="disabled" :disabled="true"
style="width: 100%"/> style="width: 100%"/>
</a-form-model-item> </a-form-model-item>
</div> </div>
@@ -142,13 +140,13 @@
<span class="title-text-text" <span class="title-text-text"
:title="$t('certificationType')">{{$t('certificationType')}}</span> :title="$t('certificationType')">{{$t('certificationType')}}</span>
</div> </div>
<a-form-model-item class="itemModel" prop="certificationType"> <a-form-model-item class="itemModel" prop="attestationType">
<j-dict-select-tag class="box-input" v-model="formInline.certificationType" <j-dict-select-tag class="box-input" v-model="formInline.attestationType"
:disabled="disabled" :disabled="disabled"
@input="handleInput('certificationType')" @input="handleInput('attestationType')"
:placeholder="$t('PleaseSelect')+$t('certificationType')" :placeholder="$t('PleaseSelect')+$t('certificationType')"
:type="'select'" :type="'select'"
:triggerChange="false" :dictCode="'dict_field'"/> :triggerChange="false" :dictCode="'attestation_type'"/>
</a-form-model-item> </a-form-model-item>
</div> </div>
</a-col> </a-col>
@@ -158,13 +156,13 @@
<span class="title-text-text" <span class="title-text-text"
:title="$t('certificationLevel')">{{$t('certificationLevel')}}</span> :title="$t('certificationLevel')">{{$t('certificationLevel')}}</span>
</div> </div>
<a-form-model-item class="itemModel" prop="certificationLevel"> <a-form-model-item class="itemModel" prop="attestationRank">
<j-dict-select-tag class="box-input" v-model="formInline.certificationLevel" <j-dict-select-tag class="box-input" v-model="formInline.attestationRank"
:disabled="disabled" :disabled="disabled"
@input="handleInput('certificationLevel')" @input="handleInput('attestationRank')"
:placeholder="$t('PleaseSelect')+$t('certificationLevel')" :placeholder="$t('PleaseSelect')+$t('certificationLevel')"
:type="'select'" :type="'select'"
:triggerChange="false" :dictCode="'dict_field'"/> :triggerChange="false" :dictCode="'attestation_rank'"/>
</a-form-model-item> </a-form-model-item>
</div> </div>
</a-col> </a-col>
@@ -177,12 +175,11 @@
:title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span> :title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
</div> </div>
<a-form-model-item class="itemModel" prop="areaOfResponsibility"> <a-form-model-item class="itemModel" prop="areaOfResponsibility">
<j-dict-select-tag class="box-input" v-model="formInline.areaOfResponsibility" <j-multi-select-tag class="box-input" v-model="formInline.dutyTerritory"
:disabled="disabled" :disabled="disabled"
@input="handleInput('areaOfResponsibility')" :placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')" :type="'select'"
:type="'select'" :triggerChange="false" :dictCode="'duty_territory'"/>
:triggerChange="false" :dictCode="'dict_field'"/>
</a-form-model-item> </a-form-model-item>
</div> </div>
</a-col> </a-col>
@@ -107,7 +107,7 @@
</span> </span>
</a-table> </a-table>
</div> </div>
<listAddModel :url="url" ref="addModelRef"/> <listAddModel :url="url" @addModelList="addModelList" ref="addModelRef"/>
<listEditModel :url="url" ref="editModelRef"/> <listEditModel :url="url" ref="editModelRef"/>
</a-card> </a-card>
</template> </template>
@@ -324,8 +324,9 @@
selectedRowKeys: [], selectedRowKeys: [],
queryParam: {}, queryParam: {},
url: { url: {
addModelList: '/document/bussDocumentLibraryEO/queryPageInfoDummy',
list: '/project/projectLawsInventoryEO/list', list: '/project/projectLawsInventoryEO/list',
add: 'project/projectLawsInventoryEO/add', addModel: 'project/projectLawsInventoryEO/add',
edit: '/project/projectLawsInventoryEO/edit', edit: '/project/projectLawsInventoryEO/edit',
deleteBatch: '/project/projectLawsInventoryEO/deleteBatch', deleteBatch: '/project/projectLawsInventoryEO/deleteBatch',
deleteOne: '/project/projectLawsInventoryEO/delete' deleteOne: '/project/projectLawsInventoryEO/delete'
@@ -404,6 +405,9 @@
this.queryParam = {} this.queryParam = {}
this.getList() this.getList()
}, },
addModelList() {
this.getList()
},
getList() { getList() {
let query = { let query = {
...this.queryParam, ...this.queryParam,