fix:修改asset选择为虚拟机时 modelId未传递的问题
This commit is contained in:
@@ -5,12 +5,16 @@
|
||||
<div class="alert-label-title">ID</div>
|
||||
<div class="alert-label-value">{{alertLabelData && alertLabelData.id ? alertLabelData.id : '--'}}</div>
|
||||
</div>
|
||||
<div class="alert-label-box">
|
||||
<div class="alert-label-title">Name</div>
|
||||
<div class="alert-label-value">{{alertLabelData && alertLabelData.name ? alertLabelData.name : '--'}}</div>
|
||||
</div>
|
||||
<div class="alert-label-box">
|
||||
<div class="alert-label-title">SN</div>
|
||||
<div class="alert-label-value">{{alertLabelData && alertLabelData.sn ? alertLabelData.sn:'--'}}</div>
|
||||
</div>
|
||||
<div class="alert-label-box">
|
||||
<div class="alert-label-title">IP</div>
|
||||
<div class="alert-label-title">ManageIp</div>
|
||||
<div class="alert-label-value">{{alertLabelData && alertLabelData.manageIp ? alertLabelData.manageIp : '--'}}</div>
|
||||
</div>
|
||||
<div class="alert-label-box">
|
||||
|
||||
@@ -398,10 +398,11 @@ export default {
|
||||
if (this.options.parentAssetOptions.length === 0) {
|
||||
this.getParentAsset().then(res => {
|
||||
const asset = this.options.parentAssetOptions.find(a => a.id === n)
|
||||
console.log(asset, 1)
|
||||
if (asset) {
|
||||
this.editAsset.brandId = asset.brand ? asset.brand.id : ''
|
||||
this.editAsset.brand = asset.brand
|
||||
this.editAsset.modelId = asset.model ? asset.model.id : ''
|
||||
this.editAsset.model = asset.model
|
||||
this.editAsset.dcId = asset.dc ? asset.dc.id : ''
|
||||
this.editAsset.cabinetId = asset.cabinet ? asset.cabinet.id : ''
|
||||
this.editAsset.cabinetStart = asset.cabinetStart
|
||||
@@ -415,10 +416,11 @@ export default {
|
||||
})
|
||||
} else {
|
||||
const asset = this.options.parentAssetOptions.find(a => a.id === n)
|
||||
console.log(asset, 2)
|
||||
if (asset) {
|
||||
this.editAsset.brandId = asset.brand ? asset.brand.id : ''
|
||||
this.editAsset.brand = asset.brand
|
||||
this.editAsset.modelId = asset.model ? asset.model.id : ''
|
||||
this.editAsset.model = asset.model
|
||||
this.editAsset.dcId = asset.dc ? asset.dc.id : ''
|
||||
this.editAsset.cabinetId = asset.cabinet ? asset.cabinet.id : ''
|
||||
this.editAsset.cabinetStart = asset.cabinetStart
|
||||
@@ -432,6 +434,7 @@ export default {
|
||||
}
|
||||
}
|
||||
}
|
||||
this.editAsset.brandAndModel = [this.editAsset.brand.id, this.editAsset.model.id]
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
<span v-else >--</span>
|
||||
</template>
|
||||
<template v-else-if="item.prop == 'pingInfo'">
|
||||
<div @mouseenter="showTableTooltip( formatPingTime(scope.row.pingInfo.lastUpdate), true, $event)" @mouseleave="hideTableTooltip" >
|
||||
<div @mouseenter="showTableTooltip( formatPingTime(scope.row.pingInfo.lastUpdate), true, $event)" @mouseleave="hideTableTooltip" v-if="scope.row.pingInfo">
|
||||
<div :class="{'active-icon green-bg':scope.row.pingInfo.status == 1,'active-icon red-bg':scope.row.pingInfo.status == 0}"></div><span>{{scope.row.pingInfo.rtt?scope.row.pingInfo.rtt+'ms':''}}</span>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user