bootstrap icon indicating copy to clipboard operation
bootstrap copied to clipboard

[tabs] : inside the tab datepicker is not showing after first time

Open krisurnok opened this issue 11 years ago • 3 comments

inside the tabs datepicker is given,first time showing datepicker then clicking button it not showing .

http://plnkr.co/edit/7YKNL1N1nyObIrxlrAMw?p=preview

krisurnok avatar Aug 23 '15 05:08 krisurnok

in ui-bootstrap-tpls-0.10.0.js its working ,current master is not working

krisurnok avatar Aug 23 '15 05:08 krisurnok

Doing some investigation, this appears to be a broken scope issue, as can be seen here - I'm going to close this as won't fix, since given how the tabs work, this is not something we should support. If one wants to use a datepicker in a tab, one should have the controller inside the tab or use a directive which manages the scope of that particular tab.

wesleycho avatar Oct 14 '15 22:10 wesleycho

Well this can fixed by doing:

$scope.open = function($event, elementOpened) {
    $event.preventDefault();
    $event.stopPropagation();
    $scope.datePicker.opened = !elementOpened;
};

Focus on elementOpened :)

mrudult avatar Sep 09 '17 12:09 mrudult