0

如何禁用/删除的角度UIB-日期选择月/年的导航按钮(https://angular-ui.github.io/bootstrap/#!#datepicker删除月份导航按钮

enter image description here

我们要删除的能力,以吸引用户点击在导航箭头之间的“月/年”的文字并不能弄明白

+0

我相信的,如果你改变模板,对于一些不至极与contauins头山,将模板的网址是什么?(默认:UIB /模板/日期选择器/ datepicker.html) –

回答

0

你必须访问HTML模板本身和删除/禁用与该按钮相关的input

The template on github can be found here

你将不得不修改行5

<th colspan="{{::5 + showWeeks}}"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm uib-title" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1"><strong>{{title}}</strong></button></th> 

这只是白天模式,您可以为月份和年份模式做同样的,如果有必要会

2

你可以将其隐藏用CSS:

.uib-datepicker thead 
{ 
    display:none; 
} 
/* fix weeks padding if showing weeks */ 
.text-center.h6.ng-scope { 
    padding: 8px; 
}