]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/dashboard: Display check icon instead of true|false in various datatables 35779/head
authorVolker Theile <vtheile@suse.com>
Thu, 25 Jun 2020 15:03:51 +0000 (17:03 +0200)
committerVolker Theile <vtheile@suse.com>
Thu, 25 Jun 2020 15:05:02 +0000 (17:05 +0200)
- Convert the boolean values true|false to a check icon in datatable columns.
- Remove unused code in the user management list.

Fixes: https://tracker.ceph.com/issues/46209
Signed-off-by: Volker Theile <vtheile@suse.com>
src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/inventory/inventory-devices/inventory-devices.component.ts
src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/services/services.component.ts
src/pybind/mgr/dashboard/frontend/src/app/core/auth/user-list/user-list.component.html
src/pybind/mgr/dashboard/frontend/src/app/core/auth/user-list/user-list.component.ts

index 1a48903510c1a46aceccd9a93d694bbe77377c22..658dea3b4598cb4c45fb53394f8fec40a792a423 100644 (file)
@@ -116,7 +116,9 @@ export class InventoryDevicesComponent implements OnInit, OnDestroy {
       {
         name: this.i18n('Available'),
         prop: 'available',
-        flexGrow: 1
+        flexGrow: 1,
+        cellClass: 'text-center',
+        cellTransformation: CellTemplate.checkIcon
       },
       {
         name: this.i18n('Vendor'),
index 2eb5afbae51405d62101b5743da6dd32e094d914..4f23794f24467544d315a95c52cbe02424b8ff6b 100644 (file)
@@ -73,7 +73,9 @@ export class ServicesComponent extends ListWithDetails implements OnChanges, OnI
       {
         name: this.i18n('Running'),
         prop: 'status.running',
-        flexGrow: 1
+        flexGrow: 1,
+        cellClass: 'text-center',
+        cellTransformation: CellTemplate.checkIcon
       },
       {
         name: this.i18n('Size'),
index 7ba6a5ade50268aea8289cabe83e5ce4b272c75e..89ed21be83313028405b17d53ad2700805195132 100644 (file)
@@ -20,8 +20,3 @@
     {{ role }}{{ !isLast ? ", " : "" }}
   </span>
 </ng-template>
-
-<ng-template #userEnabledTpl
-             let-value="value">
-  <span>{{ value | booleanText }}</span>
-</ng-template>
index 9f2a6207f0702286cc10da878133c17d46341053..470167e77b24ec3be59f094f49ae0750cac34d6d 100644 (file)
@@ -30,8 +30,6 @@ const BASE_URL = 'user-management/users';
 export class UserListComponent implements OnInit {
   @ViewChild('userRolesTpl', { static: true })
   userRolesTpl: TemplateRef<any>;
-  @ViewChild('userEnabledTpl', { static: true })
-  userEnabledTpl: TemplateRef<any>;
 
   permission: Permission;
   tableActions: CdTableAction[];