diff options
Diffstat (limited to 'vid-webpack-master/src/app/shared/components/formControls/component/multiselect/multiselect.formControl.component.ts')
-rw-r--r-- | vid-webpack-master/src/app/shared/components/formControls/component/multiselect/multiselect.formControl.component.ts | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/vid-webpack-master/src/app/shared/components/formControls/component/multiselect/multiselect.formControl.component.ts b/vid-webpack-master/src/app/shared/components/formControls/component/multiselect/multiselect.formControl.component.ts new file mode 100644 index 000000000..4b98c7e26 --- /dev/null +++ b/vid-webpack-master/src/app/shared/components/formControls/component/multiselect/multiselect.formControl.component.ts @@ -0,0 +1,20 @@ +import {Component, Input, OnChanges, SimpleChanges} from "@angular/core"; +import {FormGroup} from "@angular/forms"; +import {MultiselectFormControl} from "../../../../models/formControlModels/multiselectFormControl.model"; + +@Component({ + selector: 'multiselect-form-control', + templateUrl: './multiselect.formControl.component.html' +}) +export class MultiselectFormControlComponent implements OnChanges{ + @Input() data: MultiselectFormControl = null; + @Input() form: FormGroup = null; + + ngOnChanges(changes: SimpleChanges): void { + if (changes["data"] !== undefined && changes["data"].currentValue !== changes["data"].previousValue && changes["data"].firstChange) { + if(this.data.onInit){ + this.data.onInit(this.data, this.form); + } + } + } +} |