From cfdd1199bc15694351c2804ed3debc8586e82d6a Mon Sep 17 00:00:00 2001 From: Volker Theile Date: Fri, 31 Aug 2018 18:49:45 +0200 Subject: [PATCH] mgr/dashboard: Display RGW user/bucket quota max size in human readable form Fixes: https://tracker.ceph.com/issues/34315 Signed-off-by: Volker Theile (cherry picked from commit 8311e4b6f5db5391b535f7d19c60bbd621978239) --- .../app/ceph/rgw/rgw-user-form/rgw-user-form.component.html | 6 ++++-- .../app/ceph/rgw/rgw-user-form/rgw-user-form.component.ts | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-user-form/rgw-user-form.component.html b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-user-form/rgw-user-form.component.html index 93ba8f446054..5c852d55c152 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-user-form/rgw-user-form.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-user-form/rgw-user-form.component.html @@ -486,7 +486,8 @@ + formControlName="user_quota_max_size" + cdDimlessBinary> @@ -589,7 +590,8 @@ + formControlName="bucket_quota_max_size" + cdDimlessBinary> diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-user-form/rgw-user-form.component.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-user-form/rgw-user-form.component.ts index d3a44f642d6f..850303bd2b30 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-user-form/rgw-user-form.component.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-user-form/rgw-user-form.component.ts @@ -179,7 +179,7 @@ export class RgwUserFormComponent implements OnInit { value[type + '_quota_max_size'] = null; } else { value[type + '_quota_max_size_unlimited'] = false; - value[type + '_quota_max_size'] = quota.max_size; + value[type + '_quota_max_size'] = `${quota.max_size} B`; } if (quota.max_objects < 0) { value[type + '_quota_max_size_unlimited'] = true; -- 2.47.3