Skip to content
This repository was archived by the owner on May 29, 2019. It is now read-only.

Datapicker in popover #5305

Closed
BartoGabriel opened this issue Jan 19, 2016 · 5 comments
Closed

Datapicker in popover #5305

BartoGabriel opened this issue Jan 19, 2016 · 5 comments

Comments

@BartoGabriel
Copy link

When a datapicker is placed within a popover and popover is set popover-trigger="outsideClick", the datapicker not work correctly.

See the following example:
http://plnkr.co/edit/yQ20ODyzkcDABuij4g5R?p=preview

Steps to follow:

  1. Press "date"
  2. Press the button that opens the "From" calendar
  3. Press out the calendar but within the popover. Such as on the word "from".
  4. Then try to open the "From" calendar again. And he notes that can not be opened until it closes and open the popover.
@wesleycho
Copy link
Contributor

This appears to be a bug - what appears to be happening is that when the datepicker is closed, the state of is-open is not updated properly.

@BartoGabriel
Copy link
Author

Yeah, but the strange thing is that this only happens when it is in a popover.
I think the popover-trigger are affecting proper operation.

@wesleycho
Copy link
Contributor

I see what is happening - this is not a bug, but a usage issue from the fact that primitives are used instead of objects on $scope.

See here for how to correctly accomplish what is desired

@BartoGabriel
Copy link
Author

You are right, sorry... I didn't check my code accordingly.

@BartoGabriel
Copy link
Author

@wesleycho I found two problems in your example.

  1. When I click on "today" the popover closes unexpectedly.
  2. When I select a date the calendar closes, again I select a new date in the same calendar and closes unexpectedly the popover. This happens when I select twice dates in the same calendar.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants