|
@@ -115,7 +115,8 @@
|
|
|
<i class="iconfont icon-doc-line"/>
|
|
|
{{values.currentNum}} 0
|
|
|
</p>
|
|
|
- <a href="/api/datacenter/graphic/template-downloads">
|
|
|
+ <!-- <a href="/api/datacenter/graphic/template-downloads">-->
|
|
|
+ <a :href="downloadProject('excel')">
|
|
|
<el-button
|
|
|
type="primary"
|
|
|
class="mt-10"
|
|
@@ -133,6 +134,7 @@
|
|
|
drag
|
|
|
action="/api/datacenter/graphic/import"
|
|
|
multiple
|
|
|
+ :show-file-list='false'
|
|
|
name="file"
|
|
|
:headers="headers"
|
|
|
:data="dataId"
|
|
@@ -169,7 +171,7 @@
|
|
|
</el-timeline>
|
|
|
</div>
|
|
|
<!-- 下载报告-->
|
|
|
- <a href="/api/datacenter//graphic/report-downloads">
|
|
|
+ <a :href="downloadProject('report')">
|
|
|
<el-button>{{values.downloadFile}}</el-button>
|
|
|
</a>
|
|
|
<footer
|
|
@@ -193,7 +195,7 @@
|
|
|
|
|
|
export default {
|
|
|
name: "RelationMaintain",
|
|
|
- props: ['values', 'isComputed', 'source', 'TableVisibleMoreLoading'],
|
|
|
+ props: ['values', 'isComputed', 'source', 'TableVisibleMoreLoading', 'ManualMaintenance'],
|
|
|
created() {
|
|
|
|
|
|
},
|
|
@@ -223,7 +225,7 @@
|
|
|
icon: 'el-icon-check',
|
|
|
color: '#0bbd87'
|
|
|
}, {
|
|
|
- content: '数据处理失败',
|
|
|
+ content: '数据处理成功',
|
|
|
color: '#0bbd87',
|
|
|
icon: 'el-icon-check',
|
|
|
size: 'large',
|
|
@@ -242,9 +244,6 @@
|
|
|
},
|
|
|
computed:{
|
|
|
...mapGetters('layout', ['projectId']),
|
|
|
- fileHeaders() {
|
|
|
- return {'Content-Type': 'multipart/form-data'}
|
|
|
- },
|
|
|
headers() {
|
|
|
return {
|
|
|
'ProjectId': this.projectId,
|
|
@@ -254,6 +253,8 @@
|
|
|
},
|
|
|
dataId() {
|
|
|
return {
|
|
|
+ relType: this.ManualMaintenance.RelationType || '',
|
|
|
+ zoneType: this.ManualMaintenance.ZoneType || '',
|
|
|
projectId:this.projectId
|
|
|
}
|
|
|
},
|
|
@@ -296,6 +297,18 @@
|
|
|
deepCopy(obj) {
|
|
|
return JSON.parse(JSON.stringify(obj))
|
|
|
},
|
|
|
+ downloadProject(str) {
|
|
|
+ let relType = this.ManualMaintenance.RelationType ? `?relType=${this.ManualMaintenance.RelationType}` : ''
|
|
|
+ let zoneType = this.ManualMaintenance.ZoneType ? `&zoneType=${this.ManualMaintenance.ZoneType}` : ''
|
|
|
+ let url;
|
|
|
+ if (str === 'excel') {
|
|
|
+ relType = this.ManualMaintenance.RelationType ? `&relType=${this.ManualMaintenance.RelationType}` : ''
|
|
|
+ url = `/api/datacenter/graphic/export?code=对象ID${relType}${zoneType}`
|
|
|
+ } else {
|
|
|
+ url = `/api/datacenter/graphic/report-downloads${relType}${zoneType}`
|
|
|
+ }
|
|
|
+ return url
|
|
|
+ },
|
|
|
progress(event, file, fileList) {
|
|
|
// console.log(event.file, fileList)
|
|
|
},
|
|
@@ -323,8 +336,8 @@
|
|
|
},
|
|
|
promptly() {
|
|
|
if(this.isComputed.IsAutomatic && !this.isComputed.IsSource) { //需要自动计算并且不需要配置云末端
|
|
|
- console.log(this.isComputed.CalcUrl,'this.isComputed.CalcUrl')
|
|
|
- this.$emit('CalcUrl',this.isComputed.CalcUrl, this.isComputed.ZoneTime)
|
|
|
+ console.log(this.isComputed.RelationType, 'this.isComputed.RelationType')
|
|
|
+ this.$emit('RelationType', this.isComputed.RelationType, this.isComputed.ZoneType)
|
|
|
|
|
|
}
|
|
|
this.dialogTableVisible = false
|
|
@@ -337,7 +350,7 @@
|
|
|
this.deepCopy(this.list).forEach(item => this.secondary.push(...item.Items))
|
|
|
//最终过滤
|
|
|
let filterList = this.secondary.filter(item => this.idArr.includes(item.lId))
|
|
|
- // 组合成接口需要的数据格式
|
|
|
+ //组合成接口需要的数据格式
|
|
|
let result = []
|
|
|
filterList.forEach(item => {
|
|
|
let {BlockId, BuildingId, Domain, Id, MepSystemType, ProjectId, Source, SourceId, Type, Statistics} = item
|
|
@@ -345,7 +358,7 @@
|
|
|
BlockId,
|
|
|
BuildingId,
|
|
|
Domain,
|
|
|
- // Id,
|
|
|
+ Id,
|
|
|
MepSystemType,
|
|
|
ProjectId,
|
|
|
Source,
|