I have initial object and value in view not from controller.
<input type="text" data-ng-show="false" data-ng-init="crud.data.userId=1" data-ng-model="crud.data.userId">
<input type="text" data-ng-show="false" data-ng-init="crud.data.userParentId=2" data-ng-model="crud.data.userParentId">
And rest of form elements are visible for user to input.
<input type="text" data-ng-model="crud.data.userFamilyName">
<input type="text" data-ng-model="crud.data.userSpouseName">
I would like to reset those form elements in which i haven't initial value after submitting form.
I know it can be done by initializing it from controller but i have 100 of forms.