List<ReportTemplate>templates = reportTemplateDAO.findByProperty("reportType", "month");
Date timeStamp = new Date();
for(ReportTemplate template:templates)
{
String code = getReport(template, date);//实例化报表
MonthReportId ID = new MonthReportId(template.getId(), new Timestamp(date.getTime()));
MonthReport monthReport = new MonthReport(ID);
monthReport.setCode(code);
monthReport.setUpdateTime(new Timestamp(timeStamp.getTime()));
monthReportDAO.merge(monthReport);
}