cletourneau / angular-bootstrap-datepicker

Apache License 2.0
35 stars 56 forks source link

cannot get value from ng-model #10

Open flyher opened 9 years ago

flyher commented 9 years ago

6

has fix the choice date bug.

now the question is i cannot get value from ng-model when i bind double or more property, please fix this bug. 3ks

I have to use bootstrap-datepicker to replace angular-bootstrap-datepicker

<input type="text" class="birtdaypicker autoCombox_row_datepicker" readonly="readonly" ng-model="rang_selected.contents[0].start"/>
<input type="text" class="birtdaypicker autoCombox_row_datepicker" readonly="readonly" ng-model="rang_selected.contents[0].end"/>
adaromu commented 9 years ago

When I trying the demo, I got different results using date.start, dates.start and dates.end as ng-model variable: http://jsfiddle.net/kGGCZ/895/

 <div data-ng-controller="AppCtrl">
            <input id="datepicker" type="text" data-ng-datepicker data-ng-options="datepickerOptions" data-ng-model="dates.start">
            <input id="datepickerMirror" type="text" data-ng-model="dates.start">
                {{dates.start}}
            <input id="datepicker" type="text" data-ng-datepicker data-ng-options="datepickerOptions" data-ng-model="dates.end">
            <input id="datepickerMirror" type="text" data-ng-model="dates.end">
                {{dates.end}}
              {{dates | json}}
             <input id="datepicker" type="text" data-ng-datepicker data-ng-options="datepickerOptions" data-ng-model="date.start">
            <input id="datepickerMirror" type="text" data-ng-model="date.start">
                {{date.start}}
</div>
flyher commented 9 years ago

hi, @adaromu ,thank you for your demo. but the "angular-bootstrap-datepicker" has some limit,so use bootstrap-datepicker to replace angular-bootstrap-datepicker is an complete solution.