I would like to ask you if you can give me a hand on this.
I have created a jsfiddle with my problem here. I need to generate dynamically some inputs with ng-model i
Beterraba's answer was very helpful for me. However, when I had to migrate the solution to Typescript it wouldn't behave for me. Here is what I did instead. I expanded the individual parameters (fields on the queryList in your example) into full objects that included a "value" field. I then bound to the "value" field and it worked great!
Originally you had:
[
{ name: 'Check Users', fields: [ "Name", "Id"] },
...
}
]
I changed it to something like this:
[
{ name: 'Check Users', fields: [
{Text:"Name",Value:""},
{Text:"Id",Value:0}],
...
]
}
]
...and bound to the 'Value' sub-field.
Here is my Typescript if you care.
In the html:
In the sproc-param directive that uses Angular Material. See where I bind the ng-model to param.Value:
return {
restrict: 'E',
template: `
`,
scope: {
param: "="
}
}