Datepicker Angularjs startWeek on Monday -


i've problem angular md-datepicker. it's start default on sunday, need start on monday.

i've been tried add option controller, doesn't work. can me please?

this code:

 $scope.dateoptions = {   formatyear: 'yy',   showweeks: false,         firstdayofweek  : 1 }; <md-datepicker ng-model="desdedate" md-placeholder="enter date" options="dateoptions"></md-datepicker> 

use following code configure first day of week in md-date

 angular.module('myapp').controller('appctrl', function($scope) {   $scope.mydate = new date();   }).config(function($mddatelocaleprovider) {    // can change week display start on monday.   $mddatelocaleprovider.firstdayofweek = 1;   // optional.    }); 

below link working example.

link example

you need change start day of week using $mddatelocaleprovider.


Comments

Popular posts from this blog

sequelize.js - Sequelize group by with association includes id -

android - Robolectric "INTERNET permission is required" -

java - Android raising EPERM (Operation not permitted) when attempting to send UDP packet after network connection -