discovery setting bug fix
This commit is contained in:
parent
62fb671a44
commit
c194b9ff1d
|
@ -25,13 +25,6 @@ export const menus = [
|
||||||
'chip': false,
|
'chip': false,
|
||||||
'open': false,
|
'open': false,
|
||||||
},
|
},
|
||||||
{
|
|
||||||
'name': 'App.SensorSetting',
|
|
||||||
'link': '/sensor-setting',
|
|
||||||
'icon': 'indeterminate_check_box',
|
|
||||||
'chip': false,
|
|
||||||
'open': false,
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
'name': 'App.Probes',
|
'name': 'App.Probes',
|
||||||
'link': '/probes',
|
'link': '/probes',
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { Component, OnInit, Input } from '@angular/core';
|
import { Component, OnInit, Input, OnDestroy } from '@angular/core';
|
||||||
import { MatChipInputEvent } from '@angular/material';
|
import { MatChipInputEvent } from '@angular/material';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
|
@ -6,7 +6,7 @@ import { MatChipInputEvent } from '@angular/material';
|
||||||
templateUrl: './input-chip.component.html',
|
templateUrl: './input-chip.component.html',
|
||||||
styleUrls: ['./input-chip.component.scss']
|
styleUrls: ['./input-chip.component.scss']
|
||||||
})
|
})
|
||||||
export class InputChipComponent implements OnInit {
|
export class InputChipComponent implements OnInit, OnDestroy {
|
||||||
|
|
||||||
selectedItems = new Array();
|
selectedItems = new Array();
|
||||||
@Input() unselectedItems;
|
@Input() unselectedItems;
|
||||||
|
@ -18,6 +18,10 @@ export class InputChipComponent implements OnInit {
|
||||||
this.selectAll();
|
this.selectAll();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ngOnDestroy() {
|
||||||
|
this.unselectAll();
|
||||||
|
}
|
||||||
|
|
||||||
selected(app: any) {
|
selected(app: any) {
|
||||||
this.selectedItems.push(app);
|
this.selectedItems.push(app);
|
||||||
this.remove(this.unselectedItems, app);
|
this.remove(this.unselectedItems, app);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user