Skip to content

Conversation

@jhalak
Copy link

@jhalak jhalak commented Jul 1, 2015

When this directive was used with inline option, the ngModel variable
was not updating after selection of date/time.

  • Fixed the directive so that we can get updated value in ngModel variable
    after selection.
  • Updated example.html to show how to use inline with ngModel.

This may be not the best approach to fix the issue, but its just a quick fix for those
who want to use it right way.

When this directive was used with inline option, the ngModel variable
was not updating after selection of date/time.

- Fixed the directive so that we can get updated value in ngModel variable
  after selection.
- Updated example.html to show how to use inline with ngModel.

This may be not the best approach to fix the issue, but its just a quick fix for those
who want to use it right way.
@david-coxon
Copy link

https://github.com/dvdcxn/angular-bootstrap-datetimepicker-directive

I forked it and bound the ng-model value to the moment date rather than the string of what is selected. This is just preferable for me as I'm providing it a moment object in the first place, it's nice for consistency. Plus, it seems like the datetimepicker "thinks" in moment, so it's a bit more consistent in that regard.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants