easyui时的时间格式yyyy-MM-dd与yyyy-MM-ddd HH:mm:ss
easyui日期的转换,日期汉化导入: < script type= "text/javascript" src= "../easyui/locale/easyui-lang-zh_CN.js" ></ script > 重写我们想要的格式: 1这种返回yyyy-MM-dd HH:mm:ss $( function(){ $( '. easyui-datetimebox '). datetimebox({ formatter: function (date) { var day = date. getDate() > 9 ? date. getDate() : "0" + date. getDate(); var month = (date. getMonth() + 1) > 9 ? (date. getMonth() + 1) : "0" + (date. getMonth() + 1); var hor = date. getHours(); var min = date. getMinutes(); var sec = date. getSeconds(); return date. getFullYear() + '-' + month + '-' + day+ " "+ hor+ ":"+ min+ ":"+ sec; } }); }); 2 这种返回yyyy-MM