|
@@ -282,8 +282,8 @@ export default {
|
|
let param = {
|
|
let param = {
|
|
projectId: this.projectId,
|
|
projectId: this.projectId,
|
|
data: {
|
|
data: {
|
|
- Content: [],
|
|
|
|
- Projection: []
|
|
|
|
|
|
+ content: [],
|
|
|
|
+ projection: []
|
|
}
|
|
}
|
|
}, keyList = [];
|
|
}, keyList = [];
|
|
//生成要修改字段列表
|
|
//生成要修改字段列表
|
|
@@ -292,8 +292,8 @@ export default {
|
|
if (item[1] && keyList.indexOf(key) == -1) {
|
|
if (item[1] && keyList.indexOf(key) == -1) {
|
|
keyList.push(key)
|
|
keyList.push(key)
|
|
}
|
|
}
|
|
- if (item[1] && item[3] == "" && param.data.Projection.indexOf(key) == -1) {
|
|
|
|
- param.data.Projection.push(key)
|
|
|
|
|
|
+ if (item[1] && item[3] == "" && param.data.projection.indexOf(key) == -1) {
|
|
|
|
+ param.data.projection.push(key)
|
|
}
|
|
}
|
|
})
|
|
})
|
|
//生成对应修改数据
|
|
//生成对应修改数据
|
|
@@ -311,9 +311,9 @@ export default {
|
|
// } else {
|
|
// } else {
|
|
// item[keyarr[0]] = item[keyarr[0]] != "" ? item[keyarr[0]] : null;
|
|
// item[keyarr[0]] = item[keyarr[0]] != "" ? item[keyarr[0]] : null;
|
|
// }
|
|
// }
|
|
- param.data.Content.push(item);
|
|
|
|
|
|
+ param.data.content.push(item);
|
|
});
|
|
});
|
|
- param.Projection = []
|
|
|
|
|
|
+ param.projection = []
|
|
await updateParts(param, res => {
|
|
await updateParts(param, res => {
|
|
});
|
|
});
|
|
},
|
|
},
|
|
@@ -327,11 +327,11 @@ export default {
|
|
//保存元空间关联
|
|
//保存元空间关联
|
|
async saveSpaceList() {
|
|
async saveSpaceList() {
|
|
let data = {
|
|
let data = {
|
|
- ShaftId: this.shaftId,
|
|
|
|
- SpaceId: this.spaceList
|
|
|
|
|
|
+ shaftId: this.shaftId,
|
|
|
|
+ spaceId: this.spaceList
|
|
};
|
|
};
|
|
const params = {
|
|
const params = {
|
|
- ProjId: this.projectId,
|
|
|
|
|
|
+ projId: this.projectId,
|
|
secret: this.secret,
|
|
secret: this.secret,
|
|
data: data
|
|
data: data
|
|
};
|
|
};
|
|
@@ -486,20 +486,21 @@ export default {
|
|
},
|
|
},
|
|
//选择型号修改
|
|
//选择型号修改
|
|
firmChange(data) {
|
|
firmChange(data) {
|
|
- tools.setDataForKey(this.tableData[this.row], "dpManufacturerId", data.venderId)//生产商ID
|
|
|
|
- tools.setDataForKey(this.tableData[this.row], "dpBrandId", data.brandId)//品牌ID
|
|
|
|
- tools.setDataForKey(this.tableData[this.row], "dpSpecificationId", data.specificationId)//型号ID
|
|
|
|
- tools.setDataForKey(this.tableData[this.row], "LedgerParam.equipManufactor.manufacturer", data.venderName)
|
|
|
|
- tools.setDataForKey(this.tableData[this.row], "LedgerParam.equipManufactor.Brand", data.brandName)
|
|
|
|
- tools.setDataForKey(this.tableData[this.row], "LedgerParam.equipManufactor.Specification", data.name)
|
|
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "dpManufacturerId", data.venderId); //生产商ID
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "dpBrandId", data.brandId); //品牌ID
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "dpSpecificationId", data.specificationId); //型号ID
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "testReport", data.venderName);
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "infos.manufacturer", data.venderName);
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "infos.brand", data.name);
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "infos.specification", data.brandName);
|
|
this.handleUpdataTable(
|
|
this.handleUpdataTable(
|
|
[
|
|
[
|
|
[this.row, "dpManufacturerId", null, data.venderId],
|
|
[this.row, "dpManufacturerId", null, data.venderId],
|
|
[this.row, "dpBrandId", null, data.brandId],
|
|
[this.row, "dpBrandId", null, data.brandId],
|
|
[this.row, "dpSpecificationId", null, data.specificationId],
|
|
[this.row, "dpSpecificationId", null, data.specificationId],
|
|
- [this.row, "LedgerParam.equipManufactor.manufacturer", null, data.venderName],
|
|
|
|
- [this.row, "LedgerParam.equipManufactor.Brand", null, data.brandName],
|
|
|
|
- [this.row, "LedgerParam.equipManufactor.Specification", null, data.name]
|
|
|
|
|
|
+ [this.row, "infos.manufacturer", null, data.venderName],
|
|
|
|
+ [this.row, "infos.brand", null, data.brandName],
|
|
|
|
+ [this.row, "infos.specification", null, data.name]
|
|
],
|
|
],
|
|
"edit"
|
|
"edit"
|
|
)
|
|
)
|
|
@@ -508,25 +509,44 @@ export default {
|
|
},
|
|
},
|
|
//供应商变更
|
|
//供应商变更
|
|
supplierChange(data) {
|
|
supplierChange(data) {
|
|
- tools.setDataForKey(this.tableData[this.row], "dpSupplierId", data.venderId)
|
|
|
|
- tools.setDataForKey(this.tableData[this.row], "LedgerParam.SupplyPurchase.Supplier", data.name)
|
|
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "dpSupplierId", data.venderId);
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "infos.supplier", data.name);
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.supplierPhone', data.contacts[0]?data.contacts[0].phone:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.supplierContactor', data.contacts[0]?data.contacts[0].name:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.supplierWeb', data.website?data.website:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.supplierEmail', data.contacts[0]?data.contacts[0].email:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.supplierFax', data.contacts[0]?data.contacts[0].fax:null)
|
|
this.handleUpdataTable(
|
|
this.handleUpdataTable(
|
|
[
|
|
[
|
|
[this.row, "dpSupplierId", null, data.venderId],
|
|
[this.row, "dpSupplierId", null, data.venderId],
|
|
- [this.row, "LedgerParam.SupplyPurchase.Supplier", null, data.name]
|
|
|
|
|
|
+ [this.row, "infos.supplier", null, data.name],
|
|
|
|
+ [this.row, 'infos.supplierPhone', null, data.contacts[0]?data.contacts[0].phone:null],
|
|
|
|
+ [this.row, 'infos.supplierContactor', null, data.contacts[0]?data.contacts[0].name:null],
|
|
|
|
+ [this.row, 'infos.supplierWeb', null, data.website?data.website:null],
|
|
|
|
+ [this.row, 'infos.supplierEmail', null, data.contacts[0]?data.contacts[0].email:null],
|
|
|
|
+ [this.row, 'infos.supplierFax', null, data.contacts[0]?data.contacts[0].fax:null],
|
|
],
|
|
],
|
|
"edit"
|
|
"edit"
|
|
)
|
|
)
|
|
- // this.handleUpdataTable([[this.row, "LedgerParam.SupplyPurchase.Supplier", null, data.name]], "edit")
|
|
|
|
},
|
|
},
|
|
//保险商变更
|
|
//保险商变更
|
|
changeInsurer(data) {
|
|
changeInsurer(data) {
|
|
- tools.setDataForKey(this.tableData[this.row], "dpInsurerId", data.venderId)
|
|
|
|
- tools.setDataForKey(this.tableData[this.row], "LedgerParam.InsuranceDoc.Insurer", data.name)
|
|
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "dpInsurerId", data.venderId);
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "infos.insurer", data.name);
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.insurerWeb', data.website?data.website:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.insurerEmail', data.contacts[0]?data.contacts[0].email:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.insurerFax', data.contacts[0]?data.contacts[0].fax:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.insurerPhone', data.contacts[0]?data.contacts[0].phone:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.insurerContactor', data.contacts[0]?data.contacts[0].name:null)
|
|
this.handleUpdataTable(
|
|
this.handleUpdataTable(
|
|
[
|
|
[
|
|
[this.row, "dpInsurerId", null, data.venderId],
|
|
[this.row, "dpInsurerId", null, data.venderId],
|
|
- [this.row, "LedgerParam.insuranceDoc.insurer", null, data.name]
|
|
|
|
|
|
+ [this.row, "infos.insurer", null, data.name],
|
|
|
|
+ [this.row, 'infos.insurerWeb', null, data.website?data.website:null],
|
|
|
|
+ [this.row, 'infos.insurerEmail', null, data.contacts[0]?data.contacts[0].email:null],
|
|
|
|
+ [this.row, 'infos.insurerFax', null, data.contacts[0]?data.contacts[0].fax:null],
|
|
|
|
+ [this.row, 'infos.insurerPhone', null, data.contacts[0]?data.contacts[0].phone:null],
|
|
|
|
+ [this.row, 'infos.insurerContactor', null, data.contacts[0]?data.contacts[0].name:null],
|
|
],
|
|
],
|
|
"edit"
|
|
"edit"
|
|
)
|
|
)
|
|
@@ -534,30 +554,40 @@ export default {
|
|
},
|
|
},
|
|
//维修商变更
|
|
//维修商变更
|
|
changeMaintainer(data) {
|
|
changeMaintainer(data) {
|
|
- tools.setDataForKey(this.tableData[this.row], "dpMaintainerId", data.venderId)
|
|
|
|
- tools.setDataForKey(this.tableData[this.row], "LedgerParam.operationMainte.maintainer", data.name)
|
|
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "dpMaintainerId", data.venderId);
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "infos.maintainer", data.name);
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.maintainerWeb', data.website?data.website:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.maintainerContactor', data.contacts[0]?data.contacts[0].name:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.maintainerPhone', data.contacts[0]?data.contacts[0].phone:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.maintainerEmail', data.contacts[0]?data.contacts[0].email:null)
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], 'infos.maintainerFax', data.contacts[0]?data.contacts[0].fax:null)
|
|
this.handleUpdataTable(
|
|
this.handleUpdataTable(
|
|
[
|
|
[
|
|
[this.row, "dpMaintainerId", null, data.venderId],
|
|
[this.row, "dpMaintainerId", null, data.venderId],
|
|
- [this.row, "LedgerParam.operationMainte.maintainer", null, data.name]
|
|
|
|
|
|
+ [this.row, "infos.maintainer", null, data.name],
|
|
|
|
+ [this.row, 'infos.maintainerWeb', null, data.website?data.website:null],
|
|
|
|
+ [this.row, 'infos.maintainerContactor', null, data.contacts[0]?data.contacts[0].name:null],
|
|
|
|
+ [this.row, 'infos.maintainerPhone', null, data.contacts[0]?data.contacts[0].phone:null],
|
|
|
|
+ [this.row, 'infos.maintainerEmail', null, data.contacts[0]?data.contacts[0].email:null],
|
|
|
|
+ [this.row, 'infos.maintainerFax', null, data.contacts[0]?data.contacts[0].fax:null],
|
|
],
|
|
],
|
|
"edit"
|
|
"edit"
|
|
)
|
|
)
|
|
// this.handleUpdataTable([[this.row, "LedgerParam.operationMainte.maintainer", null, data.name]], "edit")
|
|
// this.handleUpdataTable([[this.row, "LedgerParam.operationMainte.maintainer", null, data.name]], "edit")
|
|
},
|
|
},
|
|
supplyChange(data) {
|
|
supplyChange(data) {
|
|
- tools.setDataForKey(this.tableData[this.row], "LedgerParam.SupplyPurchase.SupplierContractID", { id: data });
|
|
|
|
|
|
+ tools.setDataForKey(this.tableData[this.row], "infos.supplierContractID", { id: data });
|
|
},
|
|
},
|
|
//保险合同
|
|
//保险合同
|
|
guaranteeChange(data) {
|
|
guaranteeChange(data) {
|
|
for (let key in data) {
|
|
for (let key in data) {
|
|
- this.utilToKey(key, "insuranceNo", data, "InsuranceNum");
|
|
|
|
|
|
+ this.utilToKey(key, "insuranceNo", data, "insuranceNum");
|
|
if (key == "contractFile") {
|
|
if (key == "contractFile") {
|
|
if (!!data[key]) {
|
|
if (!!data[key]) {
|
|
data[key] = [data[key]];
|
|
data[key] = [data[key]];
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- this.utilToKey(key, "contractFile", data, "InsuranceFile");
|
|
|
|
|
|
+ this.utilToKey(key, "contractFile", data, "insuranceFile");
|
|
}
|
|
}
|
|
},
|
|
},
|
|
//修改关联的资产
|
|
//修改关联的资产
|
|
@@ -633,7 +663,7 @@ export default {
|
|
this.$message("开发中...")
|
|
this.$message("开发中...")
|
|
break;
|
|
break;
|
|
//设备二维码图片
|
|
//设备二维码图片
|
|
- case 'EquipQRCode':
|
|
|
|
|
|
+ case 'qRCodePic':
|
|
this.qrcodeUrl = this.tableData[row.row].EquipQRCode;
|
|
this.qrcodeUrl = this.tableData[row.row].EquipQRCode;
|
|
if (!!this.qrcodeUrl) {
|
|
if (!!this.qrcodeUrl) {
|
|
this.myDialog.qrcode = true;
|
|
this.myDialog.qrcode = true;
|
|
@@ -650,7 +680,7 @@ export default {
|
|
}
|
|
}
|
|
break;
|
|
break;
|
|
//关联资产
|
|
//关联资产
|
|
- case 'PropertyLocalName':
|
|
|
|
|
|
+ case 'propertyLocalName':
|
|
if (this.linkNameFalg) {
|
|
if (this.linkNameFalg) {
|
|
this.myDialog.changeRea = true;
|
|
this.myDialog.changeRea = true;
|
|
}
|
|
}
|
|
@@ -680,7 +710,7 @@ export default {
|
|
}
|
|
}
|
|
break;
|
|
break;
|
|
//供应合同编号
|
|
//供应合同编号
|
|
- case 'LedgerParam.SupplyPurchase.SupplierContractID':
|
|
|
|
|
|
+ case 'infos.supplierContractID':
|
|
if (!this.onlyRead) {
|
|
if (!this.onlyRead) {
|
|
let ContractIDflag = null;
|
|
let ContractIDflag = null;
|
|
let DPSdata = this.tableData[row.row].dpSupplierId;
|
|
let DPSdata = this.tableData[row.row].dpSupplierId;
|
|
@@ -696,7 +726,7 @@ export default {
|
|
}
|
|
}
|
|
break;
|
|
break;
|
|
//保险单号
|
|
//保险单号
|
|
- case 'LedgerParam.insuranceDoc.insuranceNum':
|
|
|
|
|
|
+ case 'infos.insuranceNum':
|
|
if (!this.onlyRead) {
|
|
if (!this.onlyRead) {
|
|
let DPInsurerIDflag = null;
|
|
let DPInsurerIDflag = null;
|
|
let DPIdata = this.tableData[row.row].dpInsurerId;
|
|
let DPIdata = this.tableData[row.row].dpInsurerId;
|
|
@@ -712,39 +742,39 @@ export default {
|
|
}
|
|
}
|
|
break;
|
|
break;
|
|
//保险文件--设备文档--安装质检报告
|
|
//保险文件--设备文档--安装质检报告
|
|
- case 'LedgerParam.InsuranceDoc.InsuranceFile': //保险文件
|
|
|
|
- case 'LedgerParam.PhotoDoc.Archive': //设备文档
|
|
|
|
- case 'LedgerParam.Siteinstall.CheckReport': //安装质检报告
|
|
|
|
- case 'LedgerParam.operationMainte.MaintainManual': //维修保养手册
|
|
|
|
- case 'LedgerParam.SupplyPurchase.ApproachingAcceptance': //进场验收单
|
|
|
|
- case 'LedgerParam.SupplyPurchase.AcceptanceReport': //验收报告
|
|
|
|
- case 'LedgerParam.PhotoDoc.OperationManual': //操作说明书
|
|
|
|
- case 'LedgerParam.equipManufactor.OriginalCertificate': //原厂证明
|
|
|
|
- case 'LedgerParam.equipManufactor.TestReport': //检测报告
|
|
|
|
- case 'LedgerParam.PhotoDoc.ProductCertification': //产品合格证
|
|
|
|
- case 'LedgerParam.Siteinstall.InstallInstruction': //安装说明书
|
|
|
|
- case 'LedgerParam.SupplyPurchase.SupplierContract': //供应合同
|
|
|
|
- case 'LedgerParam.PhotoDoc.Drawing': //设备图纸
|
|
|
|
- case 'LedgerParam.Siteinstall.InstallDrawing': //安装图纸
|
|
|
|
|
|
+ case 'infos.insuranceFile': //保险文件
|
|
|
|
+ case 'infos.archive': //设备文档
|
|
|
|
+ case 'infos.checkReport': //安装质检报告
|
|
|
|
+ case 'infos.maintainManual': //维修保养手册
|
|
|
|
+ case 'infos.approachingAcceptance': //进场验收单
|
|
|
|
+ case 'infos.acceptanceReport': //验收报告
|
|
|
|
+ case 'infos.operationManual': //操作说明书
|
|
|
|
+ case 'infos.originalCertificate': //原厂证明
|
|
|
|
+ case 'infos.testReport': //检测报告
|
|
|
|
+ case 'infos.productCertification': //产品合格证
|
|
|
|
+ case 'infos.installInstruction': //安装说明书
|
|
|
|
+ case 'infos.supplierContract': //供应合同
|
|
|
|
+ case 'infos.drawing': //设备图纸
|
|
|
|
+ case 'infos.installDrawing': //安装图纸
|
|
let IPSdata = tools.dataForKey(this.tableData[row.row], val);
|
|
let IPSdata = tools.dataForKey(this.tableData[row.row], val);
|
|
this.filesArr = IPSdata ? IPSdata : [];
|
|
this.filesArr = IPSdata ? IPSdata : [];
|
|
this.myDialog.uploadFiles = true;
|
|
this.myDialog.uploadFiles = true;
|
|
break;
|
|
break;
|
|
//安装照片--设备铭牌照片
|
|
//安装照片--设备铭牌照片
|
|
- case 'LedgerParam.Siteinstall.InstallPic':
|
|
|
|
- case 'LedgerParam.PhotoDoc.Nameplate':
|
|
|
|
|
|
+ case 'infos.installPic':
|
|
|
|
+ case 'infos.nameplate':
|
|
let SSPPdata = tools.dataForKey(this.tableData[row.row], val);
|
|
let SSPPdata = tools.dataForKey(this.tableData[row.row], val);
|
|
this.imgsArr = SSPPdata ? SSPPdata : [];
|
|
this.imgsArr = SSPPdata ? SSPPdata : [];
|
|
this.myDialog.uploadImgs = true;
|
|
this.myDialog.uploadImgs = true;
|
|
break;
|
|
break;
|
|
//设备照片
|
|
//设备照片
|
|
- case 'LedgerParam.PhotoDoc.Pic':
|
|
|
|
|
|
+ case 'infos.pic':
|
|
let Pdata = tools.dataForKey(this.tableData[row.row], val);
|
|
let Pdata = tools.dataForKey(this.tableData[row.row], val);
|
|
this.picsArr = Pdata ? Pdata : [];
|
|
this.picsArr = Pdata ? Pdata : [];
|
|
this.myDialog.pic = true;
|
|
this.myDialog.pic = true;
|
|
break;
|
|
break;
|
|
//包含的部件字段
|
|
//包含的部件字段
|
|
- case 'Count':
|
|
|
|
|
|
+ case 'count':
|
|
if (this.onlyRead) {
|
|
if (this.onlyRead) {
|
|
this.$router.push({ path: '/ledger/parts', query: { deviceId: infos.EquipID } });
|
|
this.$router.push({ path: '/ledger/parts', query: { deviceId: infos.EquipID } });
|
|
} else {
|
|
} else {
|
|
@@ -776,7 +806,6 @@ export default {
|
|
},
|
|
},
|
|
//更新临时维护信息点
|
|
//更新临时维护信息点
|
|
handleClickUpdate() {
|
|
handleClickUpdate() {
|
|
- // this.$message("更新成功");
|
|
|
|
tools.setDataForKey(this.tableData[this.row], this.updateInfoPoint, this.updateInput)
|
|
tools.setDataForKey(this.tableData[this.row], this.updateInfoPoint, this.updateInput)
|
|
this.handleUpdataTable([[this.row, this.updateInfoPoint, null, this.updateInput]], "edit")
|
|
this.handleUpdataTable([[this.row, this.updateInfoPoint, null, this.updateInput]], "edit")
|
|
this.updateInputShow = false
|
|
this.updateInputShow = false
|