Skip to content

Commit f0df8d7

Browse files
authored
ui: fix limit format (apache#9060)
An undefined variable `item` was used. Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
1 parent ea9a0f4 commit f0df8d7

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

ui/src/views/dashboard/UsageDashboard.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@
202202
<a-progress
203203
status="active"
204204
:percent="parseFloat(getPercentUsed(entity[usageType + 'total'], entity[usageType + 'limit']))"
205-
:format="p => resource[item + 'limit'] !== '-1' && resource[item + 'limit'] !== 'Unlimited' ? p.toFixed(0) + '%' : ''"
205+
:format="p => entity[usageType + 'limit'] !== '-1' && entity[usageType + 'limit'] !== 'Unlimited' ? p.toFixed(0) + '%' : ''"
206206
stroke-color="#52c41a"
207207
size="small"
208208
/>
@@ -238,7 +238,7 @@
238238
<a-progress
239239
status="active"
240240
:percent="parseFloat(getPercentUsed(entity[usageType + 'total'], entity[usageType + 'limit']))"
241-
:format="p => resource[item + 'limit'] !== '-1' && resource[item + 'limit'] !== 'Unlimited' ? p.toFixed(0) + '%' : ''"
241+
:format="p => entity[usageType + 'limit'] !== '-1' && entity[usageType + 'limit'] !== 'Unlimited' ? p.toFixed(0) + '%' : ''"
242242
stroke-color="#52c41a"
243243
size="small"
244244
/>
@@ -274,7 +274,7 @@
274274
<a-progress
275275
status="active"
276276
:percent="parseFloat(getPercentUsed(entity[usageType + 'total'], entity[usageType + 'limit']))"
277-
:format="p => resource[item + 'limit'] !== '-1' && resource[item + 'limit'] !== 'Unlimited' ? p.toFixed(0) + '%' : ''"
277+
:format="p => entity[usageType + 'limit'] !== '-1' && entity[usageType + 'limit'] !== 'Unlimited' ? p.toFixed(0) + '%' : ''"
278278
stroke-color="#52c41a"
279279
size="small"
280280
/>

0 commit comments

Comments
 (0)