Hello there, I am in the process of developing an app that provides a summary of data from a database. In this app, there is a form that populates input fields with information using ng-model. Users can edit these values as needed.
However, I want to ensure that the summary does not update automatically when users make changes to the input fields. I only want the changes to be reflected once the form has been submitted.
On the overview side, here is the HTML code:
<dt>COMPANY</dt>
<dd>{{client.company}}</dd>
<dt>NAME</dt>
<dd>{{client.firstname}} {{client.lastname}}</dd>
And here is the form code:
<p>Company</p><input type="text" name="ciCompany" class="pinfo" ng-model-options="{ updateOn: 'value = true' }" required ng-model="client[0].company">
<p>First Name</p><input type="text" name="ciFirstName" class="pinfo" ng-model-options="{ updateOn: 'value = true' }" required ng-model="client[0].firstname">
<p>Last Name</p><input type="text" name="ciLastName" class="pinfo" ng-model-options="{ updateOn: 'value = true' }" required ng-model="client[0].lastname">
I'm uncertain whether using ng-model-options is the correct approach. However, this setup aligns with the intended functionality. Any guidance or suggestions would be appreciated.
Thank you!