var b=contentPane.parameterEl.getWidgetByName("date2");
var startdate = new Date(this.getValue()); //将开始日期转化为Date型
var enddate = new Date(b.getValue()); //将结束日期转化成Date型
var subdate = (enddate-startdate)/ (1000 *60 *60 *24); //将两个日期相减得出的毫秒数转化为天数
if(subdate>60){alert("日期超出2个月")}
var a=contentPane.parameterEl.getWidgetByName("date1");
var startdate = new Date(a.getValue()); //将开始日期转化为Date型
var enddate = new Date(this.getValue()); //将结束日期转化成Date型
var subdate = (enddate-startdate)/ (1000 *60 *60 *24); //将两个日期相减得出的毫秒数转化为天数
if(subdate>60){alert("日期超出2个月")}