The version of angularjs being used is 1.5.11.
Within my .NET MVC project, the bs-datepicker element from angularjs is incorporated. Featured below is the datepicker component accompanied by a pair of images functioning as buttons within my application:
<input class="form-control"
type="text"
placeholder="Select a Date (default today)."
data-date-format="MM-dd-yyyy"
data-min-date="today"
bs-datepicker
data-autoclose="true"
ng-model="tos.appointmentDay"
ng-change="tos.updateAppointments()"
style="width: 100px;" />
<div class="appointment-buttons">
<i class="fa fa-arrow-left fa-lg"
ng-click="tos.decrementAppointmentDate()" />
<i class="fa fa-arrow-right fa-lg"
ng-click="tos.incrementAppointmentDate()" />
</div>
The arrow image elements serve as buttons to navigate the day forward or backward one day in my appointment application. The functionality works seamlessly with this datepicker component and updates are visible both in the popup calendar and other text areas displaying the chosen date based on the functions contained in the controller logic.
However, upon modifying the appointmentDay property value through the directional arrows, all outputs refresh accordingly, including the actual date displayed within the datepicker popup. Surprisingly, the text input field associated with the bs-datepicker does not reflect these changes. I am puzzled as to why the datepicker's value in the popup transitions correctly while the corresponding text input remains unaltered?