I'm creating a reactive form in angular 2 and using material angular 2 to inputs;
I need to set an input as disabled and when submitting the value that is in the unlocked input the value to be sent. I Already created the input and the disabled is running. My problem is that when I give a submit value it does not come.
My code
this.formVariacao = this._fb.group({
id:[p && p['id']],
codigoItem: [p && p['codigoItem'], Validators.required],
});
My html
<md-input-container>
<input mdInput placeholder="Código da Variação" formControlName="codigoItem" name="codigoItem">
</md-input-container>
I block the input as follows
this.formVariacao.get('codigoItem').disable();
Only when I send the form the value does not come. Alguém pode me ajudar?