NgbTypeahead设置默认值

时间:2017-11-14 09:15:00

标签: angular bootstrap-typeahead

如何在NgbTypeahead formcontrol中设置初始值?

Parent.component.ts

 ngOnInit(): void {
        this.formParent= this.fb.group({
            TypeAheadControl: ['', [Validators.required]],      
        });
    }

此控件用于从父组件发送的子组件

@Input()
  public EIDControl: FormControl;

初始化此类formcontrol的正确形式是什么?

提前致谢。

0 个答案:

没有答案