比较前端发来的时间字符串大小
SimpleDateFormat timeFormat=new SimpleDateFormat("yyyy-MM-dd");
String casestart = goverAffair.getCasestart();
String caseend = goverAffair.getCaseend();
try {
Date start = timeFormat.parse(casestart);
Date end = timeFormat.parse(caseend);
if (start.after(end)){
//业务代码,立案时间不得大于结案时间
timeJudge = true;
}
} catch (ParseException e) {
e.printStackTrace();
}
格式化数据库查询的时间返回给前端
String time = new SimpleDateFormat(" yyyy-MM-dd ").format(db.get("talk_date"));