Skip to content

Can't overwrite default updateOn when using radios #818

Open
@toccoto

Description

@toccoto

Expected behaviour

When I use radio-inline with a default ngModelOptions updateOn set to blur, but a local updateOn set to default, the local one should override the global.

snippet:

$scope.formOptions = {
destroyStrategy: 'retain',
formDefaults: {
feedback: false,
ngModelOptions: {
updateOn: 'blur'
}
}
};

snippet for schema:

{
"type": "section",
"htmlClass": "row",
"items": [{
"type": "section",
"htmlClass": "col-xs-12",
"items": [{
"type": "radios-inline",
"key": "mailAddrSame",
ngModelOptions: { updateOn: 'default' }
}]
}]
}

Actual behaviour

The blur still overrides the default. Looking at the html, I see the following:

<label ng-model="model['mailAddrSame']" ng-model-options="form.ngModelOptions" schema-validate="form" class="control-label" ng-show="showTitle()">Residential Address same as Mailing Address</label>

I'm not sure if the ng-model-options should be on the label?

@json-schema-form/angular-schema-form-lead

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions