/** * 取消的订课列表 * * @return */ @SuppressWarnings("unchecked") public String canceledRecords() { xyxx.setId(sid); page = new Page(); page.setCur(ct); page.setPageSize(Constants.PAGE_SIZE); skjl.setXyxx(xyxx); skjl.setLessonType(LessonTypeDto.getComplement()); Map<String, Object> result = commonService.getLessonRecords(page, skjl, Constants.LESSONRECORD_CANCEL); page = (Page) result.get(Constants.RESULT_MAP_PAGE); lessonRecords = (List<Skjl>) result.get(Constants.RESULT_MAP_LIST); return SUCCESS; }
/** * 取消订课记录 * * @return */ public String cancelOrder() { skjl.setId(id); skjl = commonService.getLessonRecord(skjl); Calendar now = Calendar.getInstance(); // 系统当前时间加一天 // now.add(Calendar.DATE, 1); // if (DateUtils.isSameDay(now.getTime(), skjl.getStartTime()) // || now.getTime().compareTo(skjl.getStartTime()) >= 0) { if (DateUtils.isSameDay(now.getTime(), skjl.getStartTime())) { // 如果系统当前时间增加一天后,和订课的时间是同一天的话,则不能取消订课 msg = getText("orderLesson.cancel.not.current.day", "您不能取消当天的订课!"); return INPUT; } else { commonService.cancelOrderRecord(skjl, fromType); return SUCCESS; } }
/** * 查看已上课记录列表 * * @return */ @SuppressWarnings("unchecked") public String lessonRecords() { xyxx.setId(sid); page = new Page(); page.setCur(ct); page.setPageSize(Constants.PAGE_SIZE); skjl.setXyxx(xyxx); if (!StringUtils.isBlank(type)) { skjl.setLessonType(LessonTypeDto.getLessonType(type)); } if (!StringUtils.isBlank(kq)) { skjl.setKq(KqDto.getKq(kq)); } skjl.setSignDateStart(start); skjl.setSignDateEnd(end); Map<String, Object> result = commonService.getLessonRecords(page, skjl, Constants.LESSONRECORD_RECORD); page = (Page) result.get(Constants.RESULT_MAP_PAGE); lessonRecords = (List<Skjl>) result.get(Constants.RESULT_MAP_LIST); return SUCCESS; }
/** * 上课记录明细 * * @return */ public String recordDetails() { skjl.setId(id); skjl = commonService.getLessonRecord(skjl); feedback = commonService.getFeedbackBySkjl(skjl); return SUCCESS; }