Skip to content

Dirty check forms on formControll which belong to another formControll  #21

@Mlopezjo

Description

@Mlopezjo

I'm submitting a post to have informations


[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report  
[ ] Performance issue
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request
[ x] Other... Please describe: problem with a project

Current behavior

HI!

First : sorry to my level in English writing

In a project, I've got a form with the save button have the property [disabled] ="!(isDirty$ | async)" in the component.

I call him in a other component with a Selector my-custom-form with [(isDirty$)] ="isDirty$" and (formChange)="formChange($event)". In that component, I call another component which refers to a property of my json object :
data: {
property: {
id: 0,
name: 'foo',
order: 45,
propertyDetails: {
[0]
...
[n]
}
}
}

I can have the button on enable when I change Foo to Foo2 in the input mais the disabled when remove the character 2. In my form, I have the propertyDetails in anothers inputs, but when I make some change, nothing happens.

I could see, all the data I change and enabled the save button are in the model of the form.

Expected behavior

I want to know how make the detection on the propertyDetails in my form.

Could you help me please ?
I would be most grateful in the world 😭😭😭😭

Minimal reproduction of the problem with instructions

What is the motivation / use case for changing the behavior?

Environment


Angular version: 10.2.1


Browser:
- [ x] Chrome (desktop) version XX (dépend of the client) 
- [ ] Chrome (Android) version XX
- [ ] Chrome (iOS) version XX
- [ ] Firefox version XX
- [ ] Safari (desktop) version XX
- [ ] Safari (iOS) version XX
- [ ] IE version XX
- [ ] Edge version XX
 
For Tooling issues:
- Node version: 16.13.1  
- Platform:  windows

Others:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions