Remove week column and button from Angular-ui bootstrap datepicker

后端 未结 5 2051
醉梦人生
醉梦人生 2021-02-18 16:19

I am using angular-ui bootstrap datepicker. Now I need to remove #(week) column and week button from datepicker. This date picker is being used in many forms of my application.

5条回答
  •  走了就别回头了
    2021-02-18 16:52

    For datepicker in popup, datepicker-options attribute has value dateOptions in which json can be added for any datepicker settings as shown in the HTML below.

    
    

    In javascript this is given

     $scope.dateOptions = {
        formatYear: 'yy',
        startingDay: 1,
    
      };
    

    just add showWeeks:false in dateOptions like this,

     $scope.dateOptions = {
        formatYear: 'yy',
        startingDay: 1,
        showWeeks:'false'
      };
    

    or you can add like this 'show-weeks':'false' . Demo is shown at plunker [http://plnkr.co/edit/qbp3IObj13op2RS17IEg?p=preview][1]

提交回复
热议问题