argon-dashboard-flask icon indicating copy to clipboard operation
argon-dashboard-flask copied to clipboard

datepicker format error

Open caishanli opened this issue 3 years ago • 0 comments

Hi: I see that datepicker's default format is mm/dd/yy, like 04/28/2021, but I want to set datepicker's format as 2021-04-28, so I modify argon.js and add dateFormat to datepicker, like this: `var Datepicker = (function() {

// Variables

var $datepicker = $('.datepicker');


// Methods

function init($this) {
	var options = {
		disableTouchKeyboard: true,
		autoclose: false,
		dateFormat: "yy-mm-dd"
	};

	$this.datepicker(options);
}


// Events

if ($datepicker.length) {
	$datepicker.each(function() {
		init($(this));
	});
}`

})();

But this not work, what should I do? Thank you!

caishanli avatar Apr 28 '21 01:04 caishanli