mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-13 11:53:34 +08:00
12 lines
342 B
JavaScript
12 lines
342 B
JavaScript
Vue.component("size-capacity-view", {
|
|
props:["v-default-text", "v-value"],
|
|
methods: {
|
|
composeCapacity: function (capacity) {
|
|
return teaweb.convertSizeCapacityToString(capacity)
|
|
}
|
|
},
|
|
template: `<div>
|
|
<span v-if="vValue != null && vValue.count > 0">{{composeCapacity(vValue)}}</span>
|
|
<span v-else>{{vDefaultText}}</span>
|
|
</div>`
|
|
}) |