|
@@ -5,17 +5,6 @@
|
|
|
<div class="action-box">
|
|
|
<div>
|
|
|
<el-button @click="addBuild" icon="el-icon-plus" size="small" type="default"/>
|
|
|
- <!-- <el-popover-->
|
|
|
- <!-- placement="top"-->
|
|
|
- <!-- width="160"-->
|
|
|
- <!-- v-model="visible">-->
|
|
|
- <!-- <p>确定删除吗?</p>-->
|
|
|
- <!-- <div style="text-align: right; margin: 0">-->
|
|
|
- <!-- <el-button size="mini" type="text" @click="visible = false">取消</el-button>-->
|
|
|
- <!-- <el-button type="primary" size="mini" @click="delBuild">确定</el-button>-->
|
|
|
- <!-- </div>-->
|
|
|
- <!-- <el-button slot="reference" icon="el-icon-minus" size="small" type="default"/>-->
|
|
|
- <!-- </el-popover>-->
|
|
|
<el-button @click="delBuild" icon="el-icon-minus" size="small" type="default"
|
|
|
:disabled="!buildList.length"/>
|
|
|
<el-button @click="editBuild" icon="el-icon-edit-outline" size="small" type="default"
|
|
@@ -25,12 +14,13 @@
|
|
|
<h4>建筑</h4>
|
|
|
<div class="build-list">
|
|
|
<div :class="{'floor-item':true,active:item.active}"
|
|
|
- :key="item.BuildID"
|
|
|
+ :key="item.id"
|
|
|
@click="changeBuild(index)"
|
|
|
+ style="cursor: pointer"
|
|
|
v-for="(item,index) in buildList">
|
|
|
<span>
|
|
|
- {{ item.BuildLocalName || item.BuildName }}
|
|
|
- <el-badge :value="item.Count" class="mark" v-if="item.Count>0"/>
|
|
|
+ {{ item.localName || item.name }}
|
|
|
+ <el-badge :value="item.count" class="mark" v-if="item.count>0"/>
|
|
|
</span>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -44,10 +34,10 @@
|
|
|
<el-table :data="tableData" :header-cell-style="headerStyle" height="100%" style="width: 100%"
|
|
|
v-loading="loading">
|
|
|
<el-table-column label="楼层本地名">
|
|
|
- <template slot-scope="scope">{{ scope.row.FloorLocalName || scope.row.FloorName }}</template>
|
|
|
+ <template slot-scope="scope">{{ scope.row.localName }}</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column label="楼层顺序号">
|
|
|
- <template slot-scope="scope">{{ scope.row.FloorSequenceID }}</template>
|
|
|
+ <template slot-scope="scope">{{ scope.row.floorSequenceID }}</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column label="楼层信息">
|
|
|
<template slot-scope="scope">
|
|
@@ -56,14 +46,14 @@
|
|
|
</el-table-column>
|
|
|
<el-table-column label="平面图" prop="dataSource">
|
|
|
<template slot-scope="scope">
|
|
|
- <p @click="checkDrawImg(scope.row,2)" v-if="scope.row.Sign>0">
|
|
|
+ <p @click="checkDrawImg(scope.row,2)" v-if="scope.row.sign>0">
|
|
|
<el-badge is-dot>
|
|
|
<i class="iconfont icon-floorplan"/>
|
|
|
</el-badge>
|
|
|
平面图重复
|
|
|
</p>
|
|
|
<p @click="checkDrawImg(scope.row,1)"
|
|
|
- v-else-if="scope.row.StructureInfo?scope.row.StructureInfo.FloorMap:false">
|
|
|
+ v-else-if="scope.row.infos?scope.row.infos.floorMap:false">
|
|
|
<i class="iconfont icon-floorplan"/>
|
|
|
查看平面图
|
|
|
</p>
|
|
@@ -77,7 +67,7 @@
|
|
|
<template slot-scope="scope">
|
|
|
<span
|
|
|
style="margin-right:20px">{{
|
|
|
- scope.row.FloorThroughList ? scope.row.FloorThroughList.length : 0
|
|
|
+ scope.row.floorThroughList ? scope.row.floorThroughList.length : 0
|
|
|
}}</span>
|
|
|
<el-button @click="changeConnection(scope.row)" icon="el-icon-edit-outline" plain size="mini"/>
|
|
|
</template>
|
|
@@ -200,7 +190,7 @@ export default {
|
|
|
methods: {
|
|
|
init() {
|
|
|
let bdParam = {
|
|
|
- Orders: "BuildLocalName asc",
|
|
|
+ Orders: "localName asc",
|
|
|
PageNumber: 1,
|
|
|
PageSize: 500
|
|
|
};
|
|
@@ -219,8 +209,8 @@ export default {
|
|
|
return item;
|
|
|
});
|
|
|
this.buildList[index].active = true;
|
|
|
- this.curBuildId = this.buildList[index].BuildID;
|
|
|
- this.curBuildName = this.buildList[index].BuildLocalName || this.buildList[index].BuildName;
|
|
|
+ this.curBuildId = this.buildList[index].id;
|
|
|
+ this.curBuildName = this.buildList[index].localName || this.buildList[index].name;
|
|
|
this.getFloorTableData();
|
|
|
this.$forceUpdate();
|
|
|
},
|
|
@@ -234,7 +224,7 @@ export default {
|
|
|
},
|
|
|
handleSearchBuildKey() {
|
|
|
let params = {
|
|
|
- type: 'Building',
|
|
|
+ type: 'building',
|
|
|
// orders: "sort asc,infoPointCode asc",
|
|
|
pageNumber: 1,
|
|
|
pageSize: 1000
|
|
@@ -245,12 +235,13 @@ export default {
|
|
|
let list = res.content.filter(i => (i.firstName !== '工作历') && (i.firstName !== '能耗信息') && (i.firstName !== '人员信息'))
|
|
|
list.map(item => {
|
|
|
if ((item.inputMode === 'D1' || item.inputMode === 'D2' || item.inputMode === 'E2' || item.inputMode === 'D1L') && item.dataSource) {
|
|
|
- item.options = JSON.parse(item.dataSource)
|
|
|
+ // item.options = JSON.parse(item.dataSource)
|
|
|
+ item.options = item.dataSource
|
|
|
if (item.options[0] && item.options[0].content) {
|
|
|
item.props = {
|
|
|
- value: 'Code',
|
|
|
- label: 'Name',
|
|
|
- children: 'Content',
|
|
|
+ value: 'code',
|
|
|
+ label: 'name',
|
|
|
+ children: 'content',
|
|
|
checkStrictly: true
|
|
|
}
|
|
|
}
|
|
@@ -259,22 +250,18 @@ export default {
|
|
|
} else {
|
|
|
first[item.firstName] = []
|
|
|
}
|
|
|
- if (
|
|
|
- item.path !== 'BuildingInfo.AreaInfo.AreaTree' &&
|
|
|
- item.path !== 'DefaultQRCode' &&
|
|
|
- item.path !== 'BuildQRCode'
|
|
|
- ) {
|
|
|
+ if (item.path !== 'infos.areaTree') { //DefaultQRCode,BuildQRCode 不再维护
|
|
|
first[item.firstName].push({
|
|
|
- InfoPointName: item.infoPointName,
|
|
|
- InfoPointCode: item.infoPointCode,
|
|
|
+ InfoPointName: item.name,
|
|
|
+ InfoPointCode: item.code,
|
|
|
Visible: item.visible,
|
|
|
UnDisabled: item.unDisabled,
|
|
|
SecondName: item.secondName ? item.secondName : "",
|
|
|
inputMode: item.inputMode,
|
|
|
- options: item.options,
|
|
|
+ options: item.dataSource,
|
|
|
props: item.props,
|
|
|
Unit: item.unit,
|
|
|
- path: item.path
|
|
|
+ Path: item.path
|
|
|
})
|
|
|
}
|
|
|
})
|
|
@@ -291,7 +278,7 @@ export default {
|
|
|
editBuild() {
|
|
|
this.buildTitle = '编辑建筑';
|
|
|
this.handleSearchBuildKey()
|
|
|
- let list = this.currentBuildList.filter(i => i.BuildID === this.curBuildId)
|
|
|
+ let list = this.currentBuildList.filter(i => i.id === this.curBuildId)
|
|
|
let obj = {}
|
|
|
for (let i = 0; i < list.length; i++) {
|
|
|
obj = list[i]
|
|
@@ -306,7 +293,7 @@ export default {
|
|
|
let Param = {
|
|
|
content: [newform]
|
|
|
}
|
|
|
- if (newform.BuildID) {
|
|
|
+ if (newform.id) {
|
|
|
objectUpdateBuild(Param, res => {
|
|
|
this.$message.success('更新成功')
|
|
|
this.$refs.addBuildDialog.closeDialog()
|
|
@@ -335,7 +322,7 @@ export default {
|
|
|
handleDelete(floor) {
|
|
|
this.delText = "楼层";
|
|
|
this.delDialogVis = true;
|
|
|
- this.curFloorId = floor.FloorID;
|
|
|
+ this.curFloorId = floor.id;
|
|
|
},
|
|
|
//确认删除弹窗关闭
|
|
|
handleClose() {
|
|
@@ -348,17 +335,17 @@ export default {
|
|
|
// 获取列表
|
|
|
getFloorTableData() {
|
|
|
let floorParam = {
|
|
|
- Cascade: [{Name: "floorThroughList"}],
|
|
|
- Orders: "FloorSequenceID desc",
|
|
|
- PageNumber: this.page.pageNumber,
|
|
|
- PageSize: this.page.pageSize,
|
|
|
- Filters: `BuildID='${this.curBuildId}'`
|
|
|
+ cascade: [{name: "floorThroughList"}],
|
|
|
+ orders: "floorSequenceID desc",
|
|
|
+ pageNumber: this.page.pageNumber,
|
|
|
+ pageSize: this.page.pageSize,
|
|
|
+ filters: `buildingId='${this.curBuildId}'`
|
|
|
};
|
|
|
floorQueryAndSign(floorParam, res => {
|
|
|
this.tableData = res.content;
|
|
|
this.page.total = res.total;
|
|
|
this.alreadyRelatedModel = res.content.map(t => {
|
|
|
- return t.ModelId
|
|
|
+ return t.modelId
|
|
|
}).filter(t => t);
|
|
|
});
|
|
|
},
|
|
@@ -374,7 +361,7 @@ export default {
|
|
|
confirmDel() {
|
|
|
this.buildDisabled = true
|
|
|
if (this.delText == "楼层") {
|
|
|
- let delParam = [{FloorID: this.curFloorId}];
|
|
|
+ let delParam = [{id: this.curFloorId}];
|
|
|
this.delDialogVis = false;
|
|
|
manageDeleteFloor(delParam, res => {
|
|
|
this.$message.success("删除成功");
|
|
@@ -388,7 +375,7 @@ export default {
|
|
|
this.$message.error("当前建筑中包含楼层,不可删除");
|
|
|
this.delDialogVis = false;
|
|
|
} else {
|
|
|
- let param = [{BuildId: this.curBuildId}];
|
|
|
+ let param = [{id: this.curBuildId}];
|
|
|
this.delDialogVis = false;
|
|
|
objectDeleteBuild(param, res => {
|
|
|
this.$message.success("删除成功");
|
|
@@ -402,8 +389,9 @@ export default {
|
|
|
},
|
|
|
// 修改楼层信息
|
|
|
editFloorData(floor) {
|
|
|
+ console.log(floor, 'floor')
|
|
|
this.floorTitle = "编辑楼层信息";
|
|
|
- this.curFloorId = floor.FloorID;
|
|
|
+ this.curFloorId = floor.id;
|
|
|
this.$refs.addFloorDialog.showDialog(floor);
|
|
|
},
|
|
|
// 修改楼层贯通关系
|
|
@@ -417,12 +405,13 @@ export default {
|
|
|
this.$refs.checkGraphy.showDialog(row);
|
|
|
this.modelId = "";
|
|
|
} else if (index == 1) {
|
|
|
- this.modelId = row.StructureInfo.FloorMap
|
|
|
- let pa = {modelId: this.modelId, FloorID: row.FloorID, BuildID: row.BuildID, BuildName: this.curBuildName};
|
|
|
+ // this.modelId = row.StructureInfo.FloorMap
|
|
|
+ this.modelId = row.infos.floorMap
|
|
|
+ let pa = {modelId: this.modelId, FloorID: row.id, BuildID: row.buildingId, BuildName: this.curBuildName};
|
|
|
this.$router.push({name: "repetitionGraphy", query: pa});
|
|
|
} else {
|
|
|
- this.modelId = row.ModelId;
|
|
|
- let pa = {modelId: this.modelId, FloorID: row.FloorID, BuildID: row.BuildID, BuildName: this.curBuildName};
|
|
|
+ this.modelId = row.modelId;
|
|
|
+ let pa = {modelId: this.modelId, FloorID: row.id, BuildID: row.buildingId, BuildName: this.curBuildName};
|
|
|
this.$router.push({name: "repetitionGraphy", query: pa});
|
|
|
}
|
|
|
},
|
|
@@ -435,7 +424,7 @@ export default {
|
|
|
PageSize: 500
|
|
|
};
|
|
|
objectQueryBuild(param, res => {
|
|
|
- this.currentBuildList = res.Content
|
|
|
+ this.currentBuildList = res.content
|
|
|
});
|
|
|
},
|
|
|
|