【发布时间】:2015-04-22 06:29:42
【问题描述】:
当我点击日期的textbox 时,datepicker 将打开,它具有年、月和日期视图。
我只想显示年份视图,我只能选择年份而不是月份和日期。
我正在使用bootstrap datepicker。
我的代码
<input type='text'
class='form-control white-bg pointer-cursor'
id="holiday_year"
datepicker-popup=' yyyy'
datepicker-month=hide
ng-model='weekly_holiday.holiday_year'
is-open='$holiday_year_open'
ng-click='$holiday_year_open=true'
ng-readonly='true'
date-validator/>
告诉我对此的补充以及我想在控制器中做什么。
【问题讨论】:
-
如果你有喜欢 plunker、JS fiddle 的分享代码链接
-
还有一个类似问题的帖子:stackoverflow.com/questions/6799092/…
标签: twitter-bootstrap datepicker