store icon indicating copy to clipboard operation
store copied to clipboard

@ngxs/form-plugin disabled controls data is removed from model

Open AlgoTrader opened this issue 8 years ago • 4 comments

Disabled controls are removed from model. After re-enabling controls all the data is lost

getRawValue(): any
The aggregate value of the FormGroup, including any disabled controls.
If you'd like to include all values regardless of disabled status, use this method. Otherwise, the value property is the best way to get the value of the group.

it seems ngxs use 'value' for FormGroup (and its friends). We should use 'getRawValue()' instead of 'value'

This is one more killing model properties bug. Last time my own properties were killed, now disabled properties are killed. Can you please still consider merging value changes into model, not replace the whole model?

AlgoTrader avatar Apr 11 '18 09:04 AlgoTrader

@amcdnl I will look into this.

tsawan avatar Apr 11 '18 11:04 tsawan

Exellent! Thanks a lot, wait for a new rc

AlgoTrader avatar Apr 13 '18 14:04 AlgoTrader

@AlgoTrader

Sorry for the very late answer, but I'm currently working on the form plugin issues/features. Could you help me by providing a stackblitz example if the issue still exists?

arturovt avatar Aug 11 '19 16:08 arturovt

As I see it was fixed by this PR.

arturovt avatar Aug 15 '19 18:08 arturovt