2021-10-29 14:02:01 +08:00
|
|
|
|
Vue.component("plan-price-view", {
|
|
|
|
|
|
props: ["v-plan"],
|
|
|
|
|
|
data: function () {
|
|
|
|
|
|
return {
|
|
|
|
|
|
plan: this.vPlan
|
|
|
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
template: `<div>
|
|
|
|
|
|
<span v-if="plan.priceType == 'period'">
|
2022-01-23 19:16:22 +08:00
|
|
|
|
按时间周期计费
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<span class="grey small">
|
|
|
|
|
|
<span v-if="plan.monthlyPrice > 0">月度:¥{{plan.monthlyPrice}}元<br/></span>
|
|
|
|
|
|
<span v-if="plan.seasonallyPrice > 0">季度:¥{{plan.seasonallyPrice}}元<br/></span>
|
|
|
|
|
|
<span v-if="plan.yearlyPrice > 0">年度:¥{{plan.yearlyPrice}}元</span>
|
|
|
|
|
|
</span>
|
|
|
|
|
|
</div>
|
2021-10-29 14:02:01 +08:00
|
|
|
|
</span>
|
2021-11-09 17:36:38 +08:00
|
|
|
|
<span v-if="plan.priceType == 'traffic'">
|
2022-01-23 19:16:22 +08:00
|
|
|
|
按流量计费
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<span class="grey small">基础价格:¥{{plan.trafficPrice.base}}元/GB</span>
|
|
|
|
|
|
</div>
|
2021-10-29 14:02:01 +08:00
|
|
|
|
</span>
|
2022-01-23 19:16:22 +08:00
|
|
|
|
<div v-if="plan.priceType == 'bandwidth' && plan.bandwidthPrice != null && plan.bandwidthPrice.percentile > 0">
|
|
|
|
|
|
按{{plan.bandwidthPrice.percentile}}th带宽计费
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<div v-for="range in plan.bandwidthPrice.ranges">
|
2022-07-17 10:53:03 +08:00
|
|
|
|
<span class="small grey">{{range.minMB}} - <span v-if="range.maxMB > 0">{{range.maxMB}}MB</span><span v-else>∞</span>: <span v-if="range.totalPrice > 0">{{range.totalPrice}}元</span><span v-else="">{{range.pricePerMB}}元/MB</span></span>
|
2022-01-23 19:16:22 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
2021-10-29 14:02:01 +08:00
|
|
|
|
</div>`
|
|
|
|
|
|
})
|