Commit 705eb8cac88594f5256aee9ed376e66052d379a2
1 parent
4b5d7c93
报表添加教师名称及科目信息
Showing
3 changed files
with
28 additions
and
4 deletions
WebRoot/WEB-INF/jsp/sunvote/sclass/sclass_list2.jsp
| ... | ... | @@ -7,8 +7,7 @@ |
| 7 | 7 | <% |
| 8 | 8 | String path = request.getContextPath(); |
| 9 | 9 | String basePath = request.getScheme() + "://" |
| 10 | - + request.getServerName() + ":" + request.getServerPort() | |
| 11 | - + path + "/"; | |
| 10 | + + request.getServerName() + ":" + request.getServerPort() + path + "/"; | |
| 12 | 11 | %> |
| 13 | 12 | <!DOCTYPE html> |
| 14 | 13 | <html lang="en"> | ... | ... |
WebRoot/WEB-INF/jsp/sunvote/teacher/teacher_report_test.jsp
| ... | ... | @@ -35,7 +35,11 @@ |
| 35 | 35 | <input type="hidden" name="CLASSID" id="CLASSID" value="${info.CLASS_ID}" /> |
| 36 | 36 | <table style="margin-top:5px;"> |
| 37 | 37 | <tr style="height: 30px"> |
| 38 | - <td>测验名称: ${testpaperInfo.NAME}</td> | |
| 38 | + <td>测验名称: ${testpaperInfo.NAME}</td> | |
| 39 | + <td> </td> | |
| 40 | + <td>教师: ${teacherPd.NAME}</td> | |
| 41 | + <td> </td> | |
| 42 | + <td>科目名称: ${subjectPd.CNAME}</td> | |
| 39 | 43 | </tr> |
| 40 | 44 | <tr style="height: 30px"> |
| 41 | 45 | <td>收卷时间: ${testpaperInfo.END_DATE}</td> |
| ... | ... | @@ -138,7 +142,7 @@ |
| 138 | 142 | removeOriginal: true |
| 139 | 143 | }; |
| 140 | 144 | |
| 141 | - $("#simple-table").tablescroller(options); | |
| 145 | + $("#simple-table").tablescroller(options); | |
| 142 | 146 | }); |
| 143 | 147 | $(function() { |
| 144 | 148 | ... | ... |
src/com/fh/controller/sunvote/report/ReportController.java
| ... | ... | @@ -18,6 +18,9 @@ import com.fh.service.api.V1Manager; |
| 18 | 18 | import com.fh.service.sunvote.sclass.SClassManager; |
| 19 | 19 | import com.fh.service.sunvote.student.StudentManager; |
| 20 | 20 | import com.fh.service.sunvote.studenttest.StudentTestManager; |
| 21 | +import com.fh.service.sunvote.subject.SubjectManager; | |
| 22 | +import com.fh.service.sunvote.teacher.TeacherManager; | |
| 23 | +import com.fh.service.sunvote.teacher.impl.TeacherService; | |
| 21 | 24 | import com.fh.service.sunvote.testpaper.TestPaperManager; |
| 22 | 25 | import com.fh.service.sunvote.testpaperinfo.TestPaperInfoManager; |
| 23 | 26 | import com.fh.util.Jurisdiction; |
| ... | ... | @@ -45,6 +48,12 @@ public class ReportController extends BaseController { |
| 45 | 48 | @Resource(name = "v1Service") |
| 46 | 49 | private V1Manager v1Service; |
| 47 | 50 | |
| 51 | + @Resource(name = "teacherService") | |
| 52 | + private TeacherManager teacherService; | |
| 53 | + | |
| 54 | + @Resource(name="subjectService") | |
| 55 | + private SubjectManager subjectService; | |
| 56 | + | |
| 48 | 57 | |
| 49 | 58 | |
| 50 | 59 | @RequestMapping(value="/report") |
| ... | ... | @@ -288,6 +297,16 @@ public class ReportController extends BaseController { |
| 288 | 297 | pd.put("TESTPAPER_ID", pd.get("TESTID")); |
| 289 | 298 | PageData testpaperPd = testpaperService.findById(pd); |
| 290 | 299 | |
| 300 | + PageData teacherPd = new PageData(); | |
| 301 | + teacherPd.put("ID", testpaperPd.get("TEACHER_ID")); | |
| 302 | + teacherPd = teacherService.findById(teacherPd); | |
| 303 | + | |
| 304 | + PageData subjectPd = new PageData(); | |
| 305 | + subjectPd.put("ID", testpaperPd.get("SUBJECT_ID")); | |
| 306 | + subjectPd = subjectService.findById(subjectPd); | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 291 | 310 | // 查询班级学生 |
| 292 | 311 | List<PageData> studentList = studentService.listAllClass(pd); |
| 293 | 312 | List<Integer> questionList = new ArrayList<Integer>(); |
| ... | ... | @@ -384,6 +403,8 @@ public class ReportController extends BaseController { |
| 384 | 403 | mv.addObject("testpaperInfo", testpaperPd); |
| 385 | 404 | mv.addObject("questionInfo", questionList); |
| 386 | 405 | mv.addObject("studentInfo", studentList); |
| 406 | + mv.addObject("teacherPd", teacherPd); | |
| 407 | + mv.addObject("subjectPd", subjectPd); | |
| 387 | 408 | |
| 388 | 409 | mv.setViewName("sunvote/teacher/teacher_report_test"); |
| 389 | 410 | return mv; | ... | ... |