Angular 2アプリケーションでGoogle素材2を使用しようとしています。 を使用し、反応形式またはデータ駆動形式を使用してください。 私の配列は素材2 Angular2が動作していないと選択してください
states = [
{ value: 'KA', viewValue: 'Karnataka' },
{ value: 'GJ', viewValue: 'Gujarat' },
{ value: 'DL', viewValue: 'Delhi' }
];
で、フォームビルダは<md-input formControlName="city" placeholder="City*">
が動作している
this.registrationForm = this.fb.group({
accountInformation: this.fb.group({
fullName: ['', Validators.required],
email: '',
mobileNumber: '',
password: '',
confirmPassword: '',
}),
currentAddress: this.fb.group({
city: '',
state: ''
}),
});
です。
しかしformControlNameは、このエラーに
No value accessor for form control with path: 'currentAddress -> state' ; Zone: angular ; Task: Promise.then ; Value:
を取得しかしformControlName="state"
せずに任意のエラーを取得していないが、ドロップダウンが適切ではありません
<md-select placeholder="Select your state" formControlName="state">
<option *ngFor="let state of states" [value]="state.value"> {{ state.viewValue }} </option>
</md-select>
が動作していないと。
ありがとうございましたxe4Me、私は最後のリリースを使用していますを使用しようとしています