Open xingped opened 7 years ago
A dirty workaround plunker http://plnkr.co/edit/QzPLG3SbEIkVEbNAE0BZ?p=preview
We actually do this at my workplace, but what we did was use a modal to open the datepicker and not use the datepicker-popup component. That would be an adequate workaround.
As for this, I can see this being a reasonable feature, and would be willing to accept a PR for this. It should be exposed through config though as an attribute on the popup directive.
I'm using this as workaround:
<input
type="text"
uib-datepicker-popup
is-open="isOpen"
ng-keydown="$event.preventDefault(); isOpen = true;"
/>
you can use ng-readonly="true" that will work for you
<input type="text" class="form-control" uib-datepicker-popup="{{format}}" ng-model="dtSale" is-open="popup1.opened" datepicker-options="dateOptionsForEndDate" ng-change="CompareDate()" ng-required="true" close-text="Close" alt-input-formats="altInputFormats" ng-readonly="true"/>
Bug description:
Is there or can we have a way to disable the input text box but still allow the calendar to work? Currently if the input text is disabled, it disables the whole calendar, but really I just want to prevent users from typing in the date box.
Link to minimally-working plunker that reproduces the issue:
http://plnkr.co/edit/c53OivUuETsY9eN7AE5V?p=preview
Version of Angular, UIBS, and Bootstrap
Angular: 1.5.8
UIBS: 2.1.3
Bootstrap: 3.3.7