这个bug 出现的可能性有日期格式设置错误,解决办法重新调整
第二个可能性,也就是我碰到的情况,startDate的问题,获取当前时间,然后设置这个属性
var now=new Date();
var strTime=now.getFullYear()+"-"+(now.getMonth()+1)+"-"+now.getDate();alert(strTime);
$('.form_datetime').datetimepicker({
language: 'zh-CN',
weekStart: 1,
todayBtn: 1,
autoclose: 1,
todayHighlight: 1,
startView: 2,
forceParse: 0,
showMeridian: 1,
minuteStep:1,
startDate:strTime,
format:'yyyy-mm-dd'
});
$('.form_date').datetimepicker({
language: 'zh-CN',
weekStart: 1,
todayBtn: 1,
autoclose: 1,
todayHighlight: 1,
startView: 2,
minView: 2,
forceParse: 0,
startDate:strTime,
format:'yyyy-mm-dd'
});