From: Pedro Gonzalez Gomez Date: Fri, 19 Jan 2024 05:40:05 +0000 (+0100) Subject: mgr/dashboard: remove bucket policy X-Git-Tag: v19.1.0~408^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=ae367352c7467f6ae3135fed154e89007e848347;p=ceph.git mgr/dashboard: remove bucket policy add a button on the bucket form to clear the bucket policy Fixes: https://tracker.ceph.com/issues/64096 Signed-off-by: Pedro Gonzalez Gomez --- diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-form/rgw-bucket-form.component.html b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-form/rgw-bucket-form.component.html index eef66a6da60b4..77cd69934dc24 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-form/rgw-bucket-form.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-form/rgw-bucket-form.component.html @@ -430,6 +430,14 @@ Invalid json text +
diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-form/rgw-bucket-form.component.ts b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-form/rgw-bucket-form.component.ts index f7015f609f68b..e5267e357c1cd 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-form/rgw-bucket-form.component.ts +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-form/rgw-bucket-form.component.ts @@ -385,6 +385,12 @@ export class RgwBucketFormComponent extends CdForm implements OnInit, AfterViewC window.open(url, '_blank'); } + clearBucketPolicy() { + this.bucketForm.get('bucket_policy').setValue('{}'); + this.bucketForm.markAsDirty(); + this.bucketForm.updateValueAndValidity(); + } + openConfigModal() { const modalRef = this.modalService.show(RgwConfigModalComponent, null, { size: 'lg' }); modalRef.componentInstance.configForm