Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/angularjs/24.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/opengl/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
AngularJS日期选择器仅适用于年份和月份_Angularjs_Datepicker - Fatal编程技术网

AngularJS日期选择器仅适用于年份和月份

AngularJS日期选择器仅适用于年份和月份,angularjs,datepicker,Angularjs,Datepicker,我试图将AngularUI日期选择器配置为只选择年份和月份,而不显示日期,但我无法做到这一点。我能做些什么来实现这一点。 那是我的plnkr 这就是我的观点 <input type="text" class="form-control" datepicker-popup="MM/yyyy" ng-model="dt" is-open="opened" datepicker-options="{minMode: 'month'}" datepicker-mode="'month'" sho

我试图将AngularUI日期选择器配置为只选择年份和月份,而不显示日期,但我无法做到这一点。我能做些什么来实现这一点。 那是我的plnkr

这就是我的观点

<input type="text" class="form-control" datepicker-popup="MM/yyyy" ng-model="dt" is-open="opened" datepicker-options="{minMode: 'month'}" datepicker-mode="'month'" show-button-bar="false" show-weeks="false" close-on-date-selection="true" />
          <span class="input-group-btn">
    <button type="button" class="btn btn-default" ng-click="open($event)"><i class="glyphicon glyphicon-calendar"></i></button>

我在这里找到了这个解决方案,但我不想使用Jquery,我希望使用AngularJS。

在您的plunker中,当我将angular ui从0.10升级到0.12时,它工作正常。将index.html中的第5行替换为


我找不到0.10版的文档。文档返回的距离最远。

在您的插件中,当我将angular ui从0.10升级到0.12时,它工作正常。将index.html中的第5行替换为


我找不到0.10版的文档。文档返回的距离最远。

我使用了indrimuska.github.io/angular-moment-picker,它运行得非常好,非常现代,易于配置。

我使用了indrimuska.github.io/angular-moment-picker,它运行得非常好,非常现代,易于配置。

首先,ui引导程序的版本非常旧,试着更新和检查它的主页,我也会推荐这一个这个手柄多年来更原生。首先,ui引导的版本非常旧,试着更新和检查它的主页,我也会推荐这一个手柄多年来更原生。
<input type="text" class="form-control" datepicker-popup="MM/yyyy" ng-model="dt" is-open="opened" datepicker-options="{minMode: 'month'}" datepicker-mode="'month'" show-button-bar="false" show-weeks="false" close-on-date-selection="true" />
          <span class="input-group-btn">
    <button type="button" class="btn btn-default" ng-click="open($event)"><i class="glyphicon glyphicon-calendar"></i></button>