From baf8aa03e1dee0bd83b7e11043c974bd78d6db00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E6=AE=BF=E6=98=95?= Date: Wed, 4 Nov 2020 17:59:18 +0800 Subject: [PATCH] disk&eci --- src/components/shop-cloud/shop-cloud.vue | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/components/shop-cloud/shop-cloud.vue b/src/components/shop-cloud/shop-cloud.vue index 0f3ef50..8fa0e6a 100644 --- a/src/components/shop-cloud/shop-cloud.vue +++ b/src/components/shop-cloud/shop-cloud.vue @@ -1062,11 +1062,13 @@ export default { let priceObj = this.cpu_memory.find((item) => { return item.cpu == 8 && item.memory == 16; }); + this.eci_single_money = Number(priceObj.price); sumCM += Number(priceObj.price); } else if (this.formNew.memory == "32") { let priceObj = this.cpu_memory.find((item) => { return item.cpu == 8 && item.memory == 32; }); + this.eci_single_money = Number(priceObj.price); sumCM += Number(priceObj.price); } } else if (this.formNew.cpu == "16") { @@ -1074,11 +1076,13 @@ export default { let priceObj = this.cpu_memory.find((item) => { return item.cpu == 16 && item.memory == 32; }); + this.eci_single_money = Number(priceObj.price); sumCM += Number(priceObj.price); } else if (this.formNew.memory == "64") { let priceObj = this.cpu_memory.find((item) => { return item.cpu == 16 && item.memory == 64; }); + this.eci_single_money = Number(priceObj.price); sumCM += Number(priceObj.price); } } @@ -1090,6 +1094,7 @@ export default { this.formNew.appDuration >= 1 ) { if (this.hard_disk && this.hard_disk.length != 0) { + this.disk_single_money = Number(this.hard_disk[0].price); sumDisk += Number(this.formNew.dataDisk) * Number(this.formNew.perDataDisk) * @@ -1126,11 +1131,13 @@ export default { let priceObj = this.cpu_memory.find((item) => { return item.cpu == 8 && item.memory == 16; }); + this.eci_single_money = Number(priceObj.price); sumCM += Number(priceObj.price); } else if (this.formOld.memory == "32") { let priceObj = this.cpu_memory.find((item) => { return item.cpu == 8 && item.memory == 32; }); + this.eci_single_money = Number(priceObj.price); sumCM += Number(priceObj.price); } } else if (this.formOld.cpu == "16") { @@ -1138,11 +1145,13 @@ export default { let priceObj = this.cpu_memory.find((item) => { return item.cpu == 16 && item.memory == 32; }); + this.eci_single_money = Number(priceObj.price); sumCM += Number(priceObj.price); } else if (this.formOld.memory == "64") { let priceObj = this.cpu_memory.find((item) => { return item.cpu == 16 && item.memory == 64; }); + this.eci_single_money = Number(priceObj.price); sumCM += Number(priceObj.price); } } @@ -1154,6 +1163,7 @@ export default { this.formOld.appDuration >= 1 ) { if (this.hard_disk && this.hard_disk.length != 0) { + this.disk_single_money = Number(this.hard_disk[0].price); sumDisk += Number(this.formOld.dataDisk) * Number(this.formOld.perDataDisk) * -- 2.26.0