|
@@ -609,20 +609,24 @@ export default {
|
|
|
let param = {
|
|
|
Content: [],
|
|
|
Projection: []
|
|
|
- }
|
|
|
+ }, keyList = []
|
|
|
//生成要修改字段列表
|
|
|
change.map(item => {
|
|
|
- if (item[1] && param.Projection.indexOf(item[1]) == -1) {
|
|
|
- if (item[1].split(".")[0] == "flowBuild") {
|
|
|
- param.Projection.push("BuildingId","FloorId")
|
|
|
- } else {
|
|
|
- param.Projection.push(item[1].split(".")[0])
|
|
|
- }
|
|
|
+ let key = item[1].split(".")[0]
|
|
|
+ if (item[1] && keyList.indexOf(key) == -1) {
|
|
|
+ keyList.push(key)
|
|
|
+ }
|
|
|
+ if (item[1] && item[3] == "" && param.Projection.indexOf(key) == -1) {
|
|
|
+ param.Projection.push(key)
|
|
|
+ }
|
|
|
+ if (key == "flowBuild" && keyList.indexOf(key) == -1) {
|
|
|
+ keyList.push("BuildingId","FloorId")
|
|
|
+ param.Projection.push("BuildingId","FloorId")
|
|
|
}
|
|
|
})
|
|
|
//生成对应修改数据
|
|
|
data.map((item, index) => {
|
|
|
- param.Projection.map(value => {
|
|
|
+ keyList.map(value => {
|
|
|
if (value == "BuildingId") {
|
|
|
let itemData = tools.dataForKey(item, "flowBuild")
|
|
|
if (itemData == "") {
|
|
@@ -643,11 +647,9 @@ export default {
|
|
|
let itemData = tools.dataForKey(item, value)
|
|
|
tools.setDataForKey(item, value, itemData == "" ? null : itemData)
|
|
|
}
|
|
|
-
|
|
|
});
|
|
|
param.Content.push(item)
|
|
|
})
|
|
|
- param.Projection = []
|
|
|
updateProperty(param, res => { })
|
|
|
},
|
|
|
//修改资产类型
|
|
@@ -795,7 +797,6 @@ export default {
|
|
|
},
|
|
|
//获取被筛选掉的行号
|
|
|
trimmedRows() {
|
|
|
- debugger
|
|
|
var plugin = this.hot.getPlugin("trimRows").trimmedRows;
|
|
|
let dataLength = this.tableData.length;
|
|
|
let dataArr = new Array();
|