]> git.proxmox.com Git - ceph.git/blame - ceph/src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/mgr-modules/mgr-module-details/mgr-module-details.component.ts
d/control: depend on python3-yaml for ceph-mgr
[ceph.git] / ceph / src / pybind / mgr / dashboard / frontend / src / app / ceph / cluster / mgr-modules / mgr-module-details / mgr-module-details.component.ts
CommitLineData
11fdf7f2
TL
1import { Component, Input, OnChanges } from '@angular/core';
2
3import { MgrModuleService } from '../../../../shared/api/mgr-module.service';
4import { CdTableSelection } from '../../../../shared/models/cd-table-selection';
5
6@Component({
7 selector: 'cd-mgr-module-details',
8 templateUrl: './mgr-module-details.component.html',
9 styleUrls: ['./mgr-module-details.component.scss']
10})
11export class MgrModuleDetailsComponent implements OnChanges {
12 module_config: any;
13
14 @Input()
15 selection: CdTableSelection;
16
17 constructor(private mgrModuleService: MgrModuleService) {}
18
19 ngOnChanges() {
20 if (this.selection.hasSelection) {
21 const selectedItem = this.selection.first();
22 this.mgrModuleService.getConfig(selectedItem.name).subscribe((resp: any) => {
23 this.module_config = resp;
24 });
25 }
26 }
27}