对外报告管理页面布局

This commit is contained in:
zyx.net
2022-07-21 13:48:24 +08:00
parent 147a4fa06d
commit aac1a5028b
5 changed files with 658 additions and 336 deletions
+2
View File
@@ -1165,4 +1165,6 @@ module.exports = {
exportComparisonReport:'Export Comparison Report',
comparisonDifferenceComment:'Comparison Difference Comment',
fullTextComments:'Full text comments',
fileDeclaration:'file Declaration',
FileForDetails:'File For Details',
}
+2
View File
@@ -1169,4 +1169,6 @@ module.exports = {
exportComparisonReport:'导出对比报告',
comparisonDifferenceComment:'对比差异评论',
fullTextComments:'全文评论',
fileDeclaration:'文件说明',
FileForDetails:'文件详情',
}
@@ -1,316 +1,309 @@
<template>
<div class='diolag-area'>
<a-spin :spinning='spinLoading'>
<a-form-model
class='tag-module'
ref='ruleForm'
:model='formData'
:rules='rules'
:label-col='labelCol'
:wrapper-col='wrapperCol'
>
<a-row :gutter='24'>
<a-col :span='9'>
<a-form-model-item :label="$t('areaOfResponsibility')">
<j-dict-select-tag class="box-input" v-model="formData.dutyTerritory"
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
:type="'select'"
:triggerChange="false" :dictCode="'duty_territory'"/>
</a-form-model-item>
</a-col>
<a-col :span='9'>
<a-form-model-item :label="$t('RelatedItems')" prop='ListTitle'>
<a-select class="box-input" v-model="formData.projectNameId"
:placeholder="$t('PleaseSelect')+$t('RelatedItems')">
<a-select-option v-for="(element,index) in RelatedItemList" :key="element.id" :value="element.id">
{{element.projectName}}
</a-select-option>
</a-select>
</a-form-model-item>
</a-col>
<a-col :span='6' style='margin-top: 4px;'>
<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>
</a-row>
</a-form-model>
<a-modal
:title="title"
:maskClosable="false"
:width="800"
placement="right"
:closable="true"
@cancel="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<a-spin :spinning="confirmLoading">
<a-form>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text"
:title="$t('parameterTemplate')">{{$t('parameterTemplate')}}</span>
</div>
<a-form-model-item class="itemModel" prop="paramsTemplateName">
<a-input class="box-input"
:disabled="disabled"
v-model.trim="formInline.paramsTemplateName"
:placeholder="$t('PleaseEnter')+$t('parameterTemplate')"/>
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="Required">*</span>
<span class="title-text-text" :title="$t('zoneOfApplication')">{{$t('zoneOfApplication')}}</span>
</div>
<a-form-model-item class="itemModel" prop="region">
<j-dict-select-tag class="box-input" v-model="formInline.region"
:disabled="disabled"
:placeholder="$t('PleaseSelect')+$t('zoneOfApplication')"
:type="'select'"
:triggerChange="false" :dictCode="'region'"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('contentDescription')">{{$t('contentDescription')}}</span>
</div>
<a-form-model-item class="itemModel" prop="description">
<a-input class="box-input add-input"
type="textarea"
:disabled="disabled"
v-model="formInline.description"
:placeholder="$t('PleaseEnter')+$t('contentDescription')"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-form>
</a-spin>
<div class="table-operator" style='float: right;margin-top: -20px'>
<a-button type="primary" icon="download" @click="handleExportXls()">{{ $t('export') }}</a-button>
<div class="drawer-bootom-button">
<a-button style="margin-right: .8rem" @click="handleCancel">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
<!-- :rowSelection='{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}'-->
<a-table
class='table-area'
ref='table'
size='middle'
rowKey='id'
:columns='columns'
:dataSource='areaTable'
:pagination='false'
:loading='loading'
:scroll='{x: 600}'
@change='handleTableChange'>
<!-- <template slot="file" slot-scope="text, record">-->
<!-- <a class="action-edit" href="javascript:;" @click="dowloadfile(record)" v-has="'bqnrzdpzxlbj'">{{record.exportFileName}}</a>-->
<!-- </template>-->
</a-table>
<!-- <div class="page" style='display: flex;justify-content: flex-end;'>-->
<!-- <a-pagination-->
<!-- :show-total="total => $t('total')+` ${total} `+$t('strip')"-->
<!-- show-quick-jumper-->
<!-- show-size-changer-->
<!-- :page-size.sync="pageSize"-->
<!-- :total="total"-->
<!-- :current="pageNo"-->
<!-- @change="pageOnChange"-->
<!-- @showSizeChange="SizeChange"-->
<!-- />-->
<!-- </div>-->
<div class="table-operator" >
<a-button type="primary" v-if='this.opinionGather > 0' @click="handlecomments()">{{ $t('CommentsCollectionResultsForReference') }}</a-button>
<a-button type="primary" v-if='this.technologyEvaluation > 0' @click="handletechnical()">{{ $t('TechnicalEvaluationResultsForReference') }}</a-button>
</div>
<!-- <div class='drawer-bootom-button'>-->
<!-- <a-button style='margin-right: .8rem' @click='handleCancel'>{{ $t('cancel') }}</a-button>-->
<!-- <a-button @click='handleSubmit' type='primary' :loading='confirmLoading'>{{ $t('submit') }}</a-button>-->
<!-- </div>-->
</div>
</a-modal>
</template>
<script>
import { putAction, postAction, getAction, deleteAction ,downloadFile } from '@/api/manage'
import axios from 'axios'
import Vue from 'vue'
import { ACCESS_TOKEN } from '@/store/mutation-types'
import PersonnelSelection from '@/components/PersonnelSelection/index'
import { getAction, postAction, downloadFile, putAction } from '@/api/manage'
export default {
name: 'diolagArea',
components: {},
name: 'addModel',
components: {
PersonnelSelection
},
props: ['url'],
data() {
return {
token:Vue.ls.get(ACCESS_TOKEN),
title: this.$t('add'),
total: 0,
selectedRowKeysDate: {},
opinionGather:'',
technologyEvaluation:'',
loading: false,
editId: '',
RelatedItemList:[],
columns: [
{
title: this.$t('areaOfResponsibility'),
dataIndex: 'dutyTerritory_dicText',
width: 120,
align: 'center',
ellipsis: true
},
{
title: this.$t('RelatedItems'),
align: 'center',
width: 120,
dataIndex: 'projectName',
ellipsis: true
},
{
title: this.$t('designComplianceReview'),
align: 'center',
width: 250,
dataIndex: 'designStatus_dicText',
ellipsis: true
},
{
title: this.$t('preHomeConfirmation'),
align: 'center',
width: 270,
dataIndex: 'prehomoStatus_dicText',
ellipsis: true
},
{
title: this.$t('verificationComplianceReview'),
align: 'center',
width: 270,
dataIndex: 'verifyStatus_dicText',
scopedSlots: { customRender: 'file' },
ellipsis: true
}
],
newVisible: false,
labelCol: {
xs: { span: 24 },
sm: { span: 7 }
},
wrapperCol: {
xs: { span: 24 },
sm: { span: 14 }
},
form: {},
formData: {
projectName:'',
},
formInline: {},
confirmLoading: false,
visible: false,
rules: {
title: [
{ required: true, message: this.$t('enterTitle'), trigger: 'blur' }
paramsTemplateName:[
{ required: true, message: this.$t('PleaseEnter')+this.$t('parameterTemplate'), trigger: 'blur' },
{ min:1, max: 50, message: this.$t('cantExeed')+'50'+this.$t('characters'), trigger: 'blur' },
],
description:[
{ min:1, max: 300, message: this.$t('cantExeed')+'300'+this.$t('characters'), trigger: 'blur' },
],
state: [
{ required: true, message: this.$t('PleaseSelect')+this.$t('status'), trigger: 'change' },
],
region: [
{ required: true, message: this.$t('PleaseSelect')+this.$t('zoneOfApplication'), trigger: 'change' },
]
},
areaTable: [],
flag: false, //表单提交标识
spinLoading: false,
confirmLoading: false,
selectedRowKeys: [],
pageNo: 1,
pageSize: 10,
listVisible: false,
disabled: false,
projectNameList: [],
title: ''
}
},
props: {
item: {
type: Object,
default: '',
require: true
},
paramsManifestId: {
type: String,
default: '',
require: true
},
},
mounted() {
this.loadData()
this.getRelatedItemList()
this.getNameList()
},
methods: {
getRelatedItemList(){
getAction('/project/projectNameInfoEO/list', {}).then((res) => {
getNameList() {
getAction('project/projectNameInfoEO/list', {}).then((res) => {
if (res.success) {
this.RelatedItemList = res.result
this.projectNameList = res.result || []
} else {
this.projectNameList = []
}
})
},
pageOnChange(page, pageSize) {
this.pageNo = page
this.loadData()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.loadData()
},
// 法规意见收集列表
handlecomments(){
this.$router.push({
path: '/collectionOfRegulatoryOpinions',
query:{
serialNumber:this.item.serialNumber
}
addModel() {
this.visible = true
this.title = this.$t('UploadFile')
this.formInline = {}
this.$nextTick(() => {
this.$refs['ruleForm'].clearValidate()
})
},
// 法规技术评估列表
handletechnical(){
this.$router.push({
path: '/technologyAssessment',
query:{
serialNumber:this.item.serialNumber
}
editModel(value) {
this.visible = true
this.title = this.$t('edit')
this.$nextTick(() => {
this.formInline = value
this.$refs['ruleForm'].clearValidate()
})
},
loadData() {
let params = {
id:this.paramsManifestId,
dutyTerritory:this.formData.dutyTerritory?this.formData.dutyTerritory:'',
projectName:this.formData.projectName?this.formData.projectName:'',
projectNameId:this.formData.projectNameId?this.formData.projectNameId:'',
}
this.loading = true
getAction('project/lawsComplianceBoard/queryComplianceResultList', params).then((res) => {
if (res.success) {
this.areaTable = res.result.complianceResultList
this.opinionGather = res.result.opinionGather
this.technologyEvaluation = res.result.technologyEvaluation
this.loading = false
}else{
this.loading = false
}
})
},
//导出
handleExportXls(){
let query = {
id:this.paramsManifestId,
...this.formData
}
downloadFile('/project/lawsComplianceBoard/exportComplianceResultDetail', this.$t('complianceResults')+'.xls', query, this.Deselect)
},
searchQuery() {
this.loadData()
},
searchReset() {
this.formData = {}
this.loadData()
},
handleCancel() {
this.$emit('areaVisible', false)
this.visible = false
},
onSelectChange(selectedRowKeys, selectedRowKeysDate) {
this.selectedRowKeysDate = selectedRowKeysDate
this.selectedRowKeys = selectedRowKeys
handleSubmit() {
if(this.formInline.paramsTemplateName !== undefined) {
this.formInline.paramsTemplateName = this.formInline.paramsTemplateName.trim()
}
this.$refs.ruleForm.validate(valid => {
if (valid) {
let url = ''
let Action
if (this.formInline.id) {
url = this.url.edit
Action = putAction
} else {
url = this.url.add
Action = postAction
}
let query = JSON.parse(JSON.stringify(this.formInline))
Object.keys(query).forEach(res => {
if (query[res] && query[res] instanceof Array) {
query[res] = query[res].join(',')
}
})
this.confirmLoading = true
Action(url, query).then((res) => {
if (res.success) {
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.$emit('addModelList')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
})
},
handleTableChange(val) {
console.log(',,,')
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
showModal() {
this.title = this.$t('add')
this.newVisible = true
this.form = {}
PersonnelSelectionChange(value, id) {
this.formInline[value] = id
this.formInline = { ...this.formInline }
},
projectNameChange(value){
console.log(value)
},
},
watch: {
selectedRowKeyS(val) {
this.selectedRowKeys = val
}
}
}
</script>
<style lang='less' scoped>
@import '~@assets/less/common.less';
.diolag-area {
.table-area {
margin: 20px 0;
.action-edit {
margin-right: 10px;
}
}
.table-del {
color: red;
}
<style>
.formAdd .ant-form-item-label {
width: 130px;
}
.drawer-bootom-button{
.formAdd .ant-form-item-control-wrapper {
display: inline-block;
width: 100%;
}
/*.formAdd .ant-form-item {*/
/* margin-bottom: 20px;*/
/*}*/
.itemModel .ant-form-item-control-wrapper {
width: 100%;
}
.box-input .ant-select-selection--single {
height: 38px;
}
.box-input .ant-select-selection--multiple {
height: 38px;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
height: 38px;
}
.box-input .ant-select-selection--multiple .ant-select-selection__rendered > ul > li {
margin-top: 6px;
}
.box-input .ant-calendar-picker {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
height: 38px;
}
.box-input .ant-input-number-input-wrap {
line-height: 38px;
height: 38px;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
justify-content: center;
/*align-items: center;*/
}
.title-text {
width: 114px;
text-align: right;
display: inline-block;
font-weight: 500;
font-size: 14px;
margin-right: 16px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
height: 42px;
line-height: 48px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index:100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
/deep/.add-input{
min-height: 135px!important;
}
</style>
<style lang='less'>
.area-module {
.ant-modal-wrap {
.ant-modal {
.ant-modal-content {
.ant-modal-footer {
text-align: center;
}
}
}
}
<style>
.ant-input-disabled {
color: rgba(0, 0, 0, 0.65) !important;
}
</style>
@@ -0,0 +1,286 @@
<template>
<a-modal
:title="title"
:maskClosable="false"
:width="800"
placement="right"
:closable="true"
@cancel="handleCancel"
:visible="visible"
style="height: 80%;overflow: auto;padding-bottom: 53px;">
<!-- <a-spin :spinning="confirmLoading">-->
<a-form>
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
<a-row :gutter="24">
<a-col :span="12">
<div style='margin-left: 55px;width: 700px'>
<span :title="$t('parameterTemplate')">{{$t('parameterTemplate')}}</span>
<span style='margin-left: 5px' :title="$t('parameterTemplate')">{{$t('parameterTemplate')}}</span>
<a style='margin-left: 533px' @click="download(record)">{{$t('download')}}</a>
</div>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="24">
<div class="box-title-text" style='margin-top: 5px'>
<div class="title-text">
<span class="title-text-text"
:title="$t('fileDeclaration')">{{$t('fileDeclaration')}}</span>
</div>
<a-form-model-item class="itemModel" prop="description">
<a-input class="box-input add-input"
:readOnly="true"
type="textarea"
:disabled="disabled"
v-model="formInline.description"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
</a-form-model>
</a-form>
<!-- </a-spin>-->
<div class="drawer-bootom-button">
<a-button style="margin-right: .8rem" @click="handleCancel">{{$t('close')}}</a-button>
<!-- <a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{$t('close')}}</a-button>-->
</div>
</a-modal>
</template>
<script>
import PersonnelSelection from '@/components/PersonnelSelection/index'
import { getAction, postAction, downloadFile, putAction } from '@/api/manage'
export default {
name: 'addModel',
components: {
PersonnelSelection
},
props: ['url'],
data() {
return {
formInline: {},
confirmLoading: false,
visible: false,
rules: {
paramsTemplateName:[
{ required: true, message: this.$t('PleaseEnter')+this.$t('parameterTemplate'), trigger: 'blur' },
{ min:1, max: 50, message: this.$t('cantExeed')+'50'+this.$t('characters'), trigger: 'blur' },
],
description:[
{ min:1, max: 300, message: this.$t('cantExeed')+'300'+this.$t('characters'), trigger: 'blur' },
],
state: [
{ required: true, message: this.$t('PleaseSelect')+this.$t('status'), trigger: 'change' },
],
region: [
{ required: true, message: this.$t('PleaseSelect')+this.$t('zoneOfApplication'), trigger: 'change' },
]
},
disabled: false,
projectNameList: [],
title: ''
}
},
mounted() {
this.getNameList()
},
methods: {
getNameList() {
getAction('project/projectNameInfoEO/list', {}).then((res) => {
if (res.success) {
this.projectNameList = res.result || []
} else {
this.projectNameList = []
}
})
},
addModel() {
this.visible = true
this.title = this.$t('FileForDetails')
this.formInline = {}
this.$nextTick(() => {
this.$refs['ruleForm'].clearValidate()
})
},
editModel(value) {
this.visible = true
this.title = this.$t('edit')
this.$nextTick(() => {
this.formInline = value
this.$refs['ruleForm'].clearValidate()
})
},
handleCancel() {
this.visible = false
},
handleSubmit() {
if(this.formInline.paramsTemplateName !== undefined) {
this.formInline.paramsTemplateName = this.formInline.paramsTemplateName.trim()
}
this.$refs.ruleForm.validate(valid => {
if (valid) {
let url = ''
let Action
if (this.formInline.id) {
url = this.url.edit
Action = putAction
} else {
url = this.url.add
Action = postAction
}
let query = JSON.parse(JSON.stringify(this.formInline))
Object.keys(query).forEach(res => {
if (query[res] && query[res] instanceof Array) {
query[res] = query[res].join(',')
}
})
this.confirmLoading = true
Action(url, query).then((res) => {
if (res.success) {
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.$emit('addModelList')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
}
})
},
handleInput(value) {
this.$nextTick(() => {
this.formInline = { ...this.formInline }
this.$refs.ruleForm.validateField([value])
})
},
PersonnelSelectionChange(value, id) {
this.formInline[value] = id
this.formInline = { ...this.formInline }
},
projectNameChange(value){
console.log(value)
},
}
}
</script>
<style>
.formAdd .ant-form-item-label {
width: 130px;
}
.formAdd .ant-form-item-control-wrapper {
display: inline-block;
width: 100%;
}
/*.formAdd .ant-form-item {*/
/* margin-bottom: 20px;*/
/*}*/
.itemModel .ant-form-item-control-wrapper {
width: 100%;
}
.box-input .ant-select-selection--single {
height: 38px;
}
.box-input .ant-select-selection--multiple {
height: 38px;
}
.box-input .ant-select-selection__rendered {
line-height: 38px;
height: 38px;
}
.box-input .ant-select-selection--multiple .ant-select-selection__rendered > ul > li {
margin-top: 6px;
}
.box-input .ant-calendar-picker {
line-height: 38px;
height: 38px;
}
.box-input .ant-calendar-picker-input {
height: 38px;
}
.box-input .ant-input-number-input-wrap {
line-height: 38px;
height: 38px;
}
</style>
<style scoped>
.box-title-text {
line-height: 1.4;
display: flex;
/*align-items: center;*/
}
.title-text {
width: 114px;
text-align: right;
display: inline-block;
font-weight: 500;
font-size: 14px;
margin-right: 16px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
height: 42px;
line-height: 48px;
}
.box-input {
display: inline-block;
height: 38px;
width: 100%;
}
.itemModel {
width: calc(100% - 130px);
display: inline-block;
margin-top: 2px;
}
.Required {
color: red;
margin-right: 4px;
}
.title-text-text {
margin-top: 9px;
}
.formAdd {
margin-bottom: 40px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
width: 100%;
z-index:100;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
/deep/.add-input{
min-height: 135px!important;
}
</style>
<style>
.ant-input-disabled {
color: rgba(0, 0, 0, 0.65) !important;
}
</style>
+103 -64
View File
@@ -1,64 +1,49 @@
<template>
<div style='display:flex'>
<!-- <a-card>-->
<!-- <div style='width: 400px;background-color: red'></div>-->
<!-- </a-card>-->
<a-card :bordered="false">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('standard')">
<span>{{ $t('standard') }}</span>
<div class="title-text" :title="$t('fileName')">
<span>{{ $t('fileName') }}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('standard')"
v-model="queryParam.serialNumber"></a-input>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('fileName')"
v-model="queryParam.fileName"></a-input>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('title')">
<span>{{$t('title')}}</span>
<div class="title-text" :title="$t('uploadedBy')">
<span>{{$t('uploadedBy')}}</span>
</div>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('title')"
v-model="queryParam.title"></a-input>
<a-input class="box-input" :placeholder="$t('PleaseEnter')+$t('uploadedBy')"
v-model="queryParam.uploadedBy"></a-input>
</div>
</a-col>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('status')">
<span>{{ $t('status') }}</span>
<div class="title-text" :title="$t('uploadTime')">
<span>{{ $t('uploadTime') }}</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>
<a-col :md="6" :sm="8">
<div class="box-title-text">
<div class="title-text" :title="$t('technicalField')">
<span>{{ $t('technicalField') }}</span>
</div>
<a-tree-select
tree-node-filter-prop="title"
v-model="queryParam.technologyTerritory"
:maxTagCount="1"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
style="width: 100%"
:tree-data="CategoryTreeList"
tree-checkable
:placeholder="$t('PleaseSelect')+$t('technicalField')"
/>
<!-- <j-dict-select-tag class="box-input" v-model="queryParam.technologyTerritory"-->
<!-- :placeholder="$t('PleaseSelect')+$t('technicalField')"-->
<!-- :type="'select'"-->
<!-- :triggerChange="false" :dictCode="'duty_territory'"/>-->
<a-date-picker class="box-input"
:placeholder="$t('PleaseSelect')+$t('uploadTime')"
@change="onChange" @ok="onOk"
format="YYYY-MM-DD"
:getCalendarContainer="(trigger) => trigger.parentNode"
v-model="queryParam.uploadTime"
:disabled="false"/>
</div>
</a-col>
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
<a-col :md="6" :sm="24">
<globalAdvancedQuery ref="globalAdvancedQueryRef"
@handleSuperQuery="handleSuperQuery"
:fieldList="fieldList"/>
<!-- <globalAdvancedQuery ref="globalAdvancedQueryRef"-->
<!-- @handleSuperQuery="handleSuperQuery"-->
<!-- :fieldList="fieldList"/>-->
<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>
@@ -69,9 +54,13 @@
</div>
<div class="table-operator" style="overflow:hidden;margin-bottom: 20px">
<div style="float: right;margin-bottom: 0px;margin-left: 20px">
<div class="operator-text" @click="deriveconformanceresults()">
<a-icon type="solution"/>
{{ $t('Deriveconformanceresults') }}
<div class="operator-text" @click="handleuploadFile()">
<a-icon type="import"/>
{{ $t('UploadFile') }}
</div>
<div class="operator-text" @click="handleDel()">
<a-icon type="delete"/>
{{ $t('BatchDelete') }}
</div>
</div>
</div>
@@ -93,7 +82,10 @@
</a>
</span>
<span slot="operation" slot-scope="text,record">
<a class="text-operation" @click="handlecody(record)">{{$t('ViewConformanceResults')}}</a>
<a class="text-operation" @click="handlelist(record)">{{$t('view')}}</a>
<a class="text-operation" @click="download(record)">{{$t('download')}}</a>
<a class="text-operation" @click="handleEdit(record)">{{$t('edit')}}</a>
<a class="text-operation" @click="batchDel(record)">{{$t('delete')}}</a>
</span>
</a-table>
</div>
@@ -109,15 +101,18 @@
@showSizeChange="SizeChange"
/>
</div>
<!-- 导出历史模板-->
<a-modal class="show-drawer" :title="titleTag" width="1200px" v-model="drawerVisible" :footer="null">
<export-history v-if='drawerVisible' @areaVisible='drawerVisible = false' :paramsManifestId='paramsManifestId' :item='item'></export-history>
</a-modal>
<!-- 上传文件-->
<addModel :url="url" ref="addModelRef" @addModelList="addModelList"/>
<!-- 文件详情-->
<handleModel :url="url" ref="handleModelRef" />
</a-card>
</div>
</template>
<script>
import ExportHistory from './components/addModel'
import addModel from './components/addModel'
import handleModel from './components/handle'
import { getAction, postAction, downloadFile, deleteAction } from '@/api/manage'
import globalAdvancedQuery from '@/components/globalAdvancedQuery/index'
import axios from 'axios'
@@ -129,7 +124,8 @@ import moment from 'moment'
export default {
name: 'index',
components: {
ExportHistory,
addModel,
handleModel,
globalAdvancedQuery
},
data() {
@@ -162,22 +158,19 @@ export default {
title: '新增',
columns: [
{
title: this.$t('standard'),
title: this.$t('fileName'),
align: 'center',
dataIndex: 'serialNumber',
width: 180
},
{
title: this.$t('title'),
title: this.$t('fileDeclaration'),
align: 'center',
dataIndex: 'title',
width: 180
},
{
title: this.$t('status'),
title: this.$t('uploadedBy'),
align: 'center',
dataIndex: 'state_dicText',
width: 180
},
// {
// title: this.$t('category'),
@@ -185,12 +178,13 @@ export default {
// dataIndex: 'category'
// },
{
title: this.$t('technicalField'),
title: this.$t('uploadTime'),
align: 'center',
dataIndex: 'technologyTerritory_dicText'
dataIndex: 'technologyTerritory_dicText',
width: 250
},
{
title: this.$t('RegulatoryProcessEvaluationResults'),
title: this.$t('operation'),
align: 'center',
fixed: 'right',
width: 250,
@@ -268,12 +262,9 @@ export default {
}
downloadFile('/project/lawsComplianceBoard/exportComplianceResult', this.$t('complianceResults')+'.xls', query, this.Deselect)
},
// 导出历史
handlecody(e) {
this.drawerVisible = true
this.titleTag = e.serialNumber + this.$t('ComplianceConfirmationRecord')
this.paramsManifestId = e.id
this.item = {...e}
// 上传文件
handleuploadFile(e) {
this.$refs.addModelRef.addModel()
},
hideModal() {
this.visible = false
@@ -327,6 +318,54 @@ export default {
}
this.getList()
},
//查看
handlelist(){
this.$refs.handleModelRef.addModel()
},
//编辑
handleEdit(item) {
this.$refs.addModelRef.editModel(JSON.parse(JSON.stringify(item)))
},
//删除
batchDel(val) {
let _this = this
this.$confirm({
content: _this.$t('ConfirmDelete'),
onOk() {
getAction(_this.url.deleteBatch, { id: val.id }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.getList()
} else {
_this.$message.warning(_this.$t('operationFailed'))
}
})
}
})
},
//批量删除
handleDel() {
if (this.selectedRowKeys.length > 0) {
let _this = this
this.$confirm({
content: _this.$t('ConfirmBatchDeletion'),
onOk() {
let idList = JSON.parse(JSON.stringify(_this.selectedRowKeys))
getAction(_this.url.deleteBatch, { ids: idList.join(',') }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
_this.selectedRowKeys = []
_this.getList()
} else {
_this.$message.warning(res.message)
}
})
}
})
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
getList() {
let territory = ''
if (this.queryParam.technologyTerritory) {