Commit cea072ff20bcb9b3ea1b16874db83e164ecdba67

Authored by 孙向锦
1 parent a51b67cf

更新到服务器

WebRoot/WEB-INF/jsp/sunvote/classroster/classroster_list.jsp
1 <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> 1 <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
2 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%> 2 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
3 <%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%> 3 <%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
  4 +<%@ taglib prefix="myelfun" uri="/WEB-INF/tld/elfun.tld"%>
4 <% 5 <%
5 String path = request.getContextPath(); 6 String path = request.getContextPath();
6 String basePath = request.getScheme() + "://" 7 String basePath = request.getScheme() + "://"
@@ -84,13 +85,13 @@ @@ -84,13 +85,13 @@
84 <label class="pos-rel"><input type='checkbox' name='ids' value="${var.CLASSROSTER_ID}" class="ace" /><span class="lbl"></span></label> 85 <label class="pos-rel"><input type='checkbox' name='ids' value="${var.CLASSROSTER_ID}" class="ace" /><span class="lbl"></span></label>
85 </td> 86 </td>
86 <td class='center' style="width: 30px;">${vs.index+1}</td> 87 <td class='center' style="width: 30px;">${vs.index+1}</td>
87 - <td class='center'>${var.SCLASS_ID}</td>  
88 - <td class='center'>${var.STUDENT_ID}</td>  
89 - <td class='center'>${var.TEAMID}</td> 88 + <td class='center'>${myelfun:findClassName(var.SCLASS_ID)}</td>
  89 + <td class='center'>${myelfun:findStudentName(var.STUDENT_ID)}</td>
  90 + <td class='center'>${myelfun:findTermName(var.TEAMID)}</td>
90 <td class="center"> 91 <td class="center">
91 <c:if test="${QX.edit != 1 && QX.del != 1 }"> 92 <c:if test="${QX.edit != 1 && QX.del != 1 }">
92 <span class="label label-large label-grey arrowed-in-right arrowed-in"><i class="ace-icon fa fa-lock" title="无权限"></i></span> 93 <span class="label label-large label-grey arrowed-in-right arrowed-in"><i class="ace-icon fa fa-lock" title="无权限"></i></span>
93 - </c:if> 94 + </c:if>
94 <div class="hidden-sm hidden-xs btn-group"> 95 <div class="hidden-sm hidden-xs btn-group">
95 <c:if test="${QX.edit == 1 }"> 96 <c:if test="${QX.edit == 1 }">
96 <a class="btn btn-xs btn-success" title="编辑" onclick="edit('${var.CLASSROSTER_ID}');"> 97 <a class="btn btn-xs btn-success" title="编辑" onclick="edit('${var.CLASSROSTER_ID}');">
WebRoot/WEB-INF/jsp/sunvote/coursemanagement/coursemanagement_list.jsp
@@ -70,9 +70,10 @@ @@ -70,9 +70,10 @@
70 <th class="center">老师</th> 70 <th class="center">老师</th>
71 <th class="center">班级</th> 71 <th class="center">班级</th>
72 <th class="center">科目</th> 72 <th class="center">科目</th>
73 - <th class="center">开始时间</th> 73 + <th class="center">学期</th>
  74 + <!-- <th class="center">开始时间</th>
74 <th class="center">结束时间</th> 75 <th class="center">结束时间</th>
75 - <th class="center">备注</th> 76 + <th class="center">备注</th> -->
76 <th class="center">操作</th> 77 <th class="center">操作</th>
77 </tr> 78 </tr>
78 </thead> 79 </thead>
@@ -91,9 +92,7 @@ @@ -91,9 +92,7 @@
91 <td class='center'>${myelfun:findTeacherName(var.TEACHER_ID)}</td> 92 <td class='center'>${myelfun:findTeacherName(var.TEACHER_ID)}</td>
92 <td class='center'>${myelfun:findClassName(var.CLASS_ID)}</td> 93 <td class='center'>${myelfun:findClassName(var.CLASS_ID)}</td>
93 <td class='center'>${myelfun:findSubjectCName(var.SUBJECT_ID)}</td> 94 <td class='center'>${myelfun:findSubjectCName(var.SUBJECT_ID)}</td>
94 - <td class='center'>${var.START_DATE}</td>  
95 - <td class='center'>${var.END_DATE}</td>  
96 - <td class='center'>${var.REMARK}</td> 95 + <td class='center'>${myelfun:findTermName(var.TERM_ID)}</td>
97 <td class="center"> 96 <td class="center">
98 <c:if test="${QX.edit != 1 && QX.del != 1 }"> 97 <c:if test="${QX.edit != 1 && QX.del != 1 }">
99 <span class="label label-large label-grey arrowed-in-right arrowed-in"><i class="ace-icon fa fa-lock" title="无权限"></i></span> 98 <span class="label label-large label-grey arrowed-in-right arrowed-in"><i class="ace-icon fa fa-lock" title="无权限"></i></span>
WebRoot/WEB-INF/jsp/sunvote/teacher/teacher_main.jsp
@@ -92,9 +92,11 @@ @@ -92,9 +92,11 @@
92 </div> 92 </div>
93 </div> 93 </div>
94 </div> 94 </div>
95 - <div class="class">  
96 - <p>${pd.TEACHER[0].GRADE_NAME}${pd.TEACHER[0].SUBJECT_NAME} <span>${pd.TEACHER[0].CLASS_NAME}</span></p>  
97 - </div> 95 + <c:forEach items="${pd.TEACHER}" var="var" varStatus="vs">
  96 + <div class="class">
  97 + <p>${var.GRADE_NAME}${var.SUBJECT_NAME} <span>${var.CLASS_NAME}</span></p>
  98 + </div>
  99 + </c:forEach>
98 <div class="test">测验</div> 100 <div class="test">测验</div>
99 <div class="analysis">分析</div> 101 <div class="analysis">分析</div>
100 </div> 102 </div>
WebRoot/WEB-INF/tld/elfun.tld
@@ -11,7 +11,7 @@ @@ -11,7 +11,7 @@
11 <description>根据ID 获取学校名称</description><!-- 对该标签的说明 --> 11 <description>根据ID 获取学校名称</description><!-- 对该标签的说明 -->
12 <name>findSchoolName</name><!-- 定义标签名,放在短标签之后 --> 12 <name>findSchoolName</name><!-- 定义标签名,放在短标签之后 -->
13 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 13 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
14 - <function-signature>java.lang.String findSchoolName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 14 + <function-signature>java.lang.String findSchoolName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
15 <example>${myelfun:findSchoolName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 15 <example>${myelfun:findSchoolName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
16 </function> 16 </function>
17 17
@@ -20,7 +20,7 @@ @@ -20,7 +20,7 @@
20 <description>根据ID获取年级名称</description><!-- 对该标签的说明 --> 20 <description>根据ID获取年级名称</description><!-- 对该标签的说明 -->
21 <name>findGradeName</name><!-- 定义标签名,放在短标签之后 --> 21 <name>findGradeName</name><!-- 定义标签名,放在短标签之后 -->
22 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 22 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
23 - <function-signature>java.lang.String findGradeName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 23 + <function-signature>java.lang.String findGradeName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
24 <example>${myelfun:findGradeName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 24 <example>${myelfun:findGradeName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
25 </function> 25 </function>
26 26
@@ -28,7 +28,7 @@ @@ -28,7 +28,7 @@
28 <description>根据ID获取班级类型名称</description><!-- 对该标签的说明 --> 28 <description>根据ID获取班级类型名称</description><!-- 对该标签的说明 -->
29 <name>findClassTypeName</name><!-- 定义标签名,放在短标签之后 --> 29 <name>findClassTypeName</name><!-- 定义标签名,放在短标签之后 -->
30 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 30 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
31 - <function-signature>java.lang.String findClassTypeName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 31 + <function-signature>java.lang.String findClassTypeName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
32 <example>${myelfun:findClassTypeName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 32 <example>${myelfun:findClassTypeName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
33 </function> 33 </function>
34 34
@@ -36,7 +36,7 @@ @@ -36,7 +36,7 @@
36 <description>获取科目英文名称</description><!-- 对该标签的说明 --> 36 <description>获取科目英文名称</description><!-- 对该标签的说明 -->
37 <name>findSubjectEName</name><!-- 定义标签名,放在短标签之后 --> 37 <name>findSubjectEName</name><!-- 定义标签名,放在短标签之后 -->
38 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 38 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
39 - <function-signature>java.lang.String findSubjectEName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 39 + <function-signature>java.lang.String findSubjectEName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
40 <example>${myelfun:findSubjectEName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 40 <example>${myelfun:findSubjectEName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
41 </function> 41 </function>
42 42
@@ -44,7 +44,7 @@ @@ -44,7 +44,7 @@
44 <description>根据ID获取科目中文名称</description><!-- 对该标签的说明 --> 44 <description>根据ID获取科目中文名称</description><!-- 对该标签的说明 -->
45 <name>findSubjectCName</name><!-- 定义标签名,放在短标签之后 --> 45 <name>findSubjectCName</name><!-- 定义标签名,放在短标签之后 -->
46 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 46 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
47 - <function-signature>java.lang.String findSubjectCName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 47 + <function-signature>java.lang.String findSubjectCName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
48 <example>${myelfun:findSubjectCName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 48 <example>${myelfun:findSubjectCName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
49 </function> 49 </function>
50 50
@@ -52,7 +52,7 @@ @@ -52,7 +52,7 @@
52 <description>根据ID查找基站名称</description><!-- 对该标签的说明 --> 52 <description>根据ID查找基站名称</description><!-- 对该标签的说明 -->
53 <name>findBasestationName</name><!-- 定义标签名,放在短标签之后 --> 53 <name>findBasestationName</name><!-- 定义标签名,放在短标签之后 -->
54 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 54 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
55 - <function-signature>java.lang.String findBasestationName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 55 + <function-signature>java.lang.String findBasestationName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
56 <example>${myelfun:findBasestationName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 56 <example>${myelfun:findBasestationName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
57 </function> 57 </function>
58 58
@@ -60,7 +60,7 @@ @@ -60,7 +60,7 @@
60 <description>根据ID查找老师姓名</description><!-- 对该标签的说明 --> 60 <description>根据ID查找老师姓名</description><!-- 对该标签的说明 -->
61 <name>findTeacherName</name><!-- 定义标签名,放在短标签之后 --> 61 <name>findTeacherName</name><!-- 定义标签名,放在短标签之后 -->
62 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 62 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
63 - <function-signature>java.lang.String findTeacherName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 63 + <function-signature>java.lang.String findTeacherName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
64 <example>${myelfun:findTeacherName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 64 <example>${myelfun:findTeacherName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
65 </function> 65 </function>
66 66
@@ -68,15 +68,29 @@ @@ -68,15 +68,29 @@
68 <description>根据ID查找班级姓名</description><!-- 对该标签的说明 --> 68 <description>根据ID查找班级姓名</description><!-- 对该标签的说明 -->
69 <name>findClassName</name><!-- 定义标签名,放在短标签之后 --> 69 <name>findClassName</name><!-- 定义标签名,放在短标签之后 -->
70 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 70 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
71 - <function-signature>java.lang.String findClassName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 71 + <function-signature>java.lang.String findClassName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
72 <example>${myelfun:findClassName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 72 <example>${myelfun:findClassName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
73 </function> 73 </function>
  74 + <function>
  75 + <description>根据ID查找学生姓名</description><!-- 对该标签的说明 -->
  76 + <name>findStudentName</name><!-- 定义标签名,放在短标签之后 -->
  77 + <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
  78 + <function-signature>java.lang.String findStudentName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
  79 + <example>${myelfun:findStudentName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
  80 + </function>
  81 + <function>
  82 + <description>根据ID查找学期名称</description><!-- 对该标签的说明 -->
  83 + <name>findTermName</name><!-- 定义标签名,放在短标签之后 -->
  84 + <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
  85 + <function-signature>java.lang.String findTermName(java.lang.String)</function-signature><!-- 标签处理域值的具体的类方法 -->
  86 + <example>${myelfun:findTermName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
  87 + </function>
74 88
75 <function> 89 <function>
76 <description>根据ID查找教材名称</description><!-- 对该标签的说明 --> 90 <description>根据ID查找教材名称</description><!-- 对该标签的说明 -->
77 <name>findTeachingmaterialName</name><!-- 定义标签名,放在短标签之后 --> 91 <name>findTeachingmaterialName</name><!-- 定义标签名,放在短标签之后 -->
78 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 92 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
79 - <function-signature>java.lang.String findTeachingmaterialName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 93 + <function-signature>java.lang.String findTeachingmaterialName(String)</function-signature><!-- 标签处理域值的具体的类方法 -->
80 <example>${myelfun:findTeachingmaterialName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 94 <example>${myelfun:findTeachingmaterialName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
81 </function> 95 </function>
82 96
@@ -84,7 +98,7 @@ @@ -84,7 +98,7 @@
84 <description>根据ID查找题目类型</description><!-- 对该标签的说明 --> 98 <description>根据ID查找题目类型</description><!-- 对该标签的说明 -->
85 <name>findQuestionTypeName</name><!-- 定义标签名,放在短标签之后 --> 99 <name>findQuestionTypeName</name><!-- 定义标签名,放在短标签之后 -->
86 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 --> 100 <function-class>com.fh.controller.sunvote.Myelfun</function-class><!-- 标签处理域值的类路径 -->
87 - <function-signature>java.lang.String findQuestionTypeName(int)</function-signature><!-- 标签处理域值的具体的类方法 --> 101 + <function-signature>java.lang.String findQuestionTypeName(String)</function-signature><!-- 标签处理域值的具体的类方法 -->
88 <example>${myelfun:findQuestionTypeName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面--> 102 <example>${myelfun:findQuestionTypeName(obj1)}</example><!-- 自定义标签的使用示范 ,域参数会自动传递到具体的方法里面-->
89 </function> 103 </function>
90 104
WebRoot/static/images/analysis.png 0 → 100644

95.4 KB

WebRoot/static/images/loading.gif 0 → 100644

453 KB

resources/mybatis1/sunvote/CourseManagementMapper.xml
@@ -15,6 +15,8 @@ @@ -15,6 +15,8 @@
15 START_DATE, 15 START_DATE,
16 END_DATE, 16 END_DATE,
17 REMARK, 17 REMARK,
  18 + GRADE_ID,
  19 + TERM_ID,
18 ID 20 ID
19 </sql> 21 </sql>
20 22
@@ -26,6 +28,8 @@ @@ -26,6 +28,8 @@
26 #{START_DATE}, 28 #{START_DATE},
27 #{END_DATE}, 29 #{END_DATE},
28 #{REMARK}, 30 #{REMARK},
  31 + #{GRADE_ID},
  32 + #{TERM_ID},
29 #{ID} 33 #{ID}
30 </sql> 34 </sql>
31 35
@@ -39,6 +43,8 @@ @@ -39,6 +43,8 @@
39 SUBJECT_ID, 43 SUBJECT_ID,
40 START_DATE, 44 START_DATE,
41 END_DATE, 45 END_DATE,
  46 + GRADE_ID,
  47 + TERM_ID,
42 REMARK 48 REMARK
43 ) values ( 49 ) values (
44 #{TEACHER_ID}, 50 #{TEACHER_ID},
@@ -46,6 +52,8 @@ @@ -46,6 +52,8 @@
46 #{SUBJECT_ID}, 52 #{SUBJECT_ID},
47 #{START_DATE}, 53 #{START_DATE},
48 #{END_DATE}, 54 #{END_DATE},
  55 + #{GRADE_ID},
  56 + #{TERM_ID},
49 #{REMARK} 57 #{REMARK}
50 ) 58 )
51 </insert> 59 </insert>
@@ -69,6 +77,8 @@ @@ -69,6 +77,8 @@
69 START_DATE = #{START_DATE}, 77 START_DATE = #{START_DATE},
70 END_DATE = #{END_DATE}, 78 END_DATE = #{END_DATE},
71 REMARK = #{REMARK}, 79 REMARK = #{REMARK},
  80 + GRADE_ID = #{GRADE_ID},
  81 + TERM_ID = #{TERM_ID},
72 ID = ${ID} 82 ID = ${ID}
73 where 83 where
74 ID = #{ID} 84 ID = #{ID}
src/com/fh/controller/sunvote/Myelfun.java
@@ -8,10 +8,12 @@ import com.fh.service.sunvote.grade.impl.GradeService; @@ -8,10 +8,12 @@ import com.fh.service.sunvote.grade.impl.GradeService;
8 import com.fh.service.sunvote.questiontype.QuestionTypeManager; 8 import com.fh.service.sunvote.questiontype.QuestionTypeManager;
9 import com.fh.service.sunvote.school.impl.SchoolService; 9 import com.fh.service.sunvote.school.impl.SchoolService;
10 import com.fh.service.sunvote.sclass.impl.SClassService; 10 import com.fh.service.sunvote.sclass.impl.SClassService;
  11 +import com.fh.service.sunvote.student.StudentManager;
11 import com.fh.service.sunvote.subject.impl.SubjectService; 12 import com.fh.service.sunvote.subject.impl.SubjectService;
12 import com.fh.service.sunvote.teacher.TeacherManager; 13 import com.fh.service.sunvote.teacher.TeacherManager;
13 import com.fh.service.sunvote.teacher.impl.TeacherService; 14 import com.fh.service.sunvote.teacher.impl.TeacherService;
14 import com.fh.service.sunvote.teachingmaterial.impl.TeachingMaterialService; 15 import com.fh.service.sunvote.teachingmaterial.impl.TeachingMaterialService;
  16 +import com.fh.service.sunvote.term.TermManager;
15 import com.fh.util.PageData; 17 import com.fh.util.PageData;
16 import com.fh.util.SpringBeanFactoryUtils; 18 import com.fh.util.SpringBeanFactoryUtils;
17 19
@@ -24,7 +26,7 @@ public class Myelfun { @@ -24,7 +26,7 @@ public class Myelfun {
24 * @return 26 * @return
25 * @throws Exception 27 * @throws Exception
26 */ 28 */
27 - public static String findSchoolName(int type) throws Exception{ 29 + public static String findSchoolName(String type) throws Exception{
28 SchoolService schoolService = (SchoolService)SpringBeanFactoryUtils.getBean("schoolService"); 30 SchoolService schoolService = (SchoolService)SpringBeanFactoryUtils.getBean("schoolService");
29 PageData pageData = new PageData(); 31 PageData pageData = new PageData();
30 pageData.put("ID", type); 32 pageData.put("ID", type);
@@ -42,7 +44,7 @@ public class Myelfun { @@ -42,7 +44,7 @@ public class Myelfun {
42 * @return 44 * @return
43 * @throws Exception 45 * @throws Exception
44 */ 46 */
45 - public static String findGradeName(int type) throws Exception{ 47 + public static String findGradeName(String type) throws Exception{
46 GradeService gradeService = (GradeService)SpringBeanFactoryUtils.getBean("gradeService"); 48 GradeService gradeService = (GradeService)SpringBeanFactoryUtils.getBean("gradeService");
47 PageData pageData = new PageData(); 49 PageData pageData = new PageData();
48 pageData.put("ID", type); 50 pageData.put("ID", type);
@@ -60,7 +62,7 @@ public class Myelfun { @@ -60,7 +62,7 @@ public class Myelfun {
60 * @return 62 * @return
61 * @throws Exception 63 * @throws Exception
62 */ 64 */
63 - public static String findClassTypeName(int type) throws Exception{ 65 + public static String findClassTypeName(String type) throws Exception{
64 ClassTypeService classTypeService = (ClassTypeService)SpringBeanFactoryUtils.getBean("classtypeService"); 66 ClassTypeService classTypeService = (ClassTypeService)SpringBeanFactoryUtils.getBean("classtypeService");
65 PageData pageData = new PageData(); 67 PageData pageData = new PageData();
66 pageData.put("ID", type); 68 pageData.put("ID", type);
@@ -78,7 +80,7 @@ public class Myelfun { @@ -78,7 +80,7 @@ public class Myelfun {
78 * @return 80 * @return
79 * @throws Exception 81 * @throws Exception
80 */ 82 */
81 - public static String findSubjectEName(int type) throws Exception{ 83 + public static String findSubjectEName(String type) throws Exception{
82 SubjectService subjectService = (SubjectService)SpringBeanFactoryUtils.getBean("subjectService"); 84 SubjectService subjectService = (SubjectService)SpringBeanFactoryUtils.getBean("subjectService");
83 PageData pageData = new PageData(); 85 PageData pageData = new PageData();
84 pageData.put("ID", type); 86 pageData.put("ID", type);
@@ -96,7 +98,7 @@ public class Myelfun { @@ -96,7 +98,7 @@ public class Myelfun {
96 * @return 98 * @return
97 * @throws Exception 99 * @throws Exception
98 */ 100 */
99 - public static String findSubjectCName(int type) throws Exception{ 101 + public static String findSubjectCName(String type) throws Exception{
100 SubjectService subjectService = (SubjectService)SpringBeanFactoryUtils.getBean("subjectService"); 102 SubjectService subjectService = (SubjectService)SpringBeanFactoryUtils.getBean("subjectService");
101 PageData pageData = new PageData(); 103 PageData pageData = new PageData();
102 pageData.put("ID", type); 104 pageData.put("ID", type);
@@ -114,7 +116,7 @@ public class Myelfun { @@ -114,7 +116,7 @@ public class Myelfun {
114 * @return 116 * @return
115 * @throws Exception 117 * @throws Exception
116 */ 118 */
117 - public static String findBasestationName(int type) throws Exception{ 119 + public static String findBasestationName(String type) throws Exception{
118 BasestationService basestationService = (BasestationService)SpringBeanFactoryUtils.getBean("basestationService"); 120 BasestationService basestationService = (BasestationService)SpringBeanFactoryUtils.getBean("basestationService");
119 PageData pageData = new PageData(); 121 PageData pageData = new PageData();
120 pageData.put("ID", type); 122 pageData.put("ID", type);
@@ -132,7 +134,7 @@ public class Myelfun { @@ -132,7 +134,7 @@ public class Myelfun {
132 * @return 134 * @return
133 * @throws Exception 135 * @throws Exception
134 */ 136 */
135 - public static String findTeacherName(int id) throws Exception { 137 + public static String findTeacherName(String id) throws Exception {
136 TeacherService teacherService = (TeacherService)SpringBeanFactoryUtils.getBean("teacherService"); 138 TeacherService teacherService = (TeacherService)SpringBeanFactoryUtils.getBean("teacherService");
137 PageData pageData = new PageData(); 139 PageData pageData = new PageData();
138 pageData.put("ID", id); 140 pageData.put("ID", id);
@@ -150,7 +152,7 @@ public class Myelfun { @@ -150,7 +152,7 @@ public class Myelfun {
150 * @return 152 * @return
151 * @throws Exception 153 * @throws Exception
152 */ 154 */
153 - public static String findClassName(int id) throws Exception { 155 + public static String findClassName(String id) throws Exception {
154 SClassService sclassService = (SClassService)SpringBeanFactoryUtils.getBean("sclassService"); 156 SClassService sclassService = (SClassService)SpringBeanFactoryUtils.getBean("sclassService");
155 PageData pageData = new PageData(); 157 PageData pageData = new PageData();
156 pageData.put("ID", id); 158 pageData.put("ID", id);
@@ -163,6 +165,42 @@ public class Myelfun { @@ -163,6 +165,42 @@ public class Myelfun {
163 } 165 }
164 166
165 /** 167 /**
  168 + * 根据ID学生
  169 + * @param id
  170 + * @return
  171 + * @throws Exception
  172 + */
  173 + public static String findStudentName(String id) throws Exception {
  174 + StudentManager studentService = (StudentManager)SpringBeanFactoryUtils.getBean("studentService");
  175 + PageData pageData = new PageData();
  176 + pageData.put("ID", id);
  177 + pageData = studentService.findById(pageData);
  178 + if(pageData != null){
  179 + return pageData.getString("NAME");
  180 + }else{
  181 + return "" ;
  182 + }
  183 + }
  184 +
  185 + /**
  186 + * 根据学期名称
  187 + * @param id
  188 + * @return
  189 + * @throws Exception
  190 + */
  191 + public static String findTermName(String id) throws Exception {
  192 + TermManager termService = (TermManager)SpringBeanFactoryUtils.getBean("termService");
  193 + PageData pageData = new PageData();
  194 + pageData.put("TERM_ID", id);
  195 + pageData = termService.findById(pageData);
  196 + if(pageData != null){
  197 + return pageData.getString("NAME");
  198 + }else{
  199 + return "" ;
  200 + }
  201 + }
  202 +
  203 + /**
166 * 根据ID班级名称 204 * 根据ID班级名称
167 * @param id 205 * @param id
168 * @return 206 * @return
src/com/fh/controller/sunvote/classroster/ClassRosterController.java
@@ -8,7 +8,9 @@ import java.util.Date; @@ -8,7 +8,9 @@ import java.util.Date;
8 import java.util.HashMap; 8 import java.util.HashMap;
9 import java.util.List; 9 import java.util.List;
10 import java.util.Map; 10 import java.util.Map;
  11 +
11 import javax.annotation.Resource; 12 import javax.annotation.Resource;
  13 +
12 import org.springframework.beans.propertyeditors.CustomDateEditor; 14 import org.springframework.beans.propertyeditors.CustomDateEditor;
13 import org.springframework.stereotype.Controller; 15 import org.springframework.stereotype.Controller;
14 import org.springframework.web.bind.WebDataBinder; 16 import org.springframework.web.bind.WebDataBinder;
@@ -16,6 +18,7 @@ import org.springframework.web.bind.annotation.InitBinder; @@ -16,6 +18,7 @@ import org.springframework.web.bind.annotation.InitBinder;
16 import org.springframework.web.bind.annotation.RequestMapping; 18 import org.springframework.web.bind.annotation.RequestMapping;
17 import org.springframework.web.bind.annotation.ResponseBody; 19 import org.springframework.web.bind.annotation.ResponseBody;
18 import org.springframework.web.servlet.ModelAndView; 20 import org.springframework.web.servlet.ModelAndView;
  21 +
19 import com.fh.controller.base.BaseController; 22 import com.fh.controller.base.BaseController;
20 import com.fh.entity.Page; 23 import com.fh.entity.Page;
21 import com.fh.util.AppUtil; 24 import com.fh.util.AppUtil;
@@ -24,6 +27,9 @@ import com.fh.util.PageData; @@ -24,6 +27,9 @@ import com.fh.util.PageData;
24 import com.fh.util.Jurisdiction; 27 import com.fh.util.Jurisdiction;
25 import com.fh.util.Tools; 28 import com.fh.util.Tools;
26 import com.fh.service.sunvote.classroster.ClassRosterManager; 29 import com.fh.service.sunvote.classroster.ClassRosterManager;
  30 +import com.fh.service.sunvote.sclass.SClassManager;
  31 +import com.fh.service.sunvote.student.StudentManager;
  32 +import com.fh.service.sunvote.term.TermManager;
27 33
28 /** 34 /**
29 * 说明:班级名册 35 * 说明:班级名册
@@ -37,6 +43,15 @@ public class ClassRosterController extends BaseController { @@ -37,6 +43,15 @@ public class ClassRosterController extends BaseController {
37 @Resource(name="classrosterService") 43 @Resource(name="classrosterService")
38 private ClassRosterManager classrosterService; 44 private ClassRosterManager classrosterService;
39 45
  46 + @Resource(name="sclassService")
  47 + private SClassManager sclassService;
  48 +
  49 + @Resource(name="termService")
  50 + private TermManager termService;
  51 +
  52 + @Resource(name="studentService")
  53 + private StudentManager studentService;
  54 +
40 /**保存 55 /**保存
41 * @param 56 * @param
42 * @throws Exception 57 * @throws Exception
@@ -103,6 +118,7 @@ public class ClassRosterController extends BaseController { @@ -103,6 +118,7 @@ public class ClassRosterController extends BaseController {
103 pd.put("keywords", keywords.trim()); 118 pd.put("keywords", keywords.trim());
104 } 119 }
105 page.setPd(pd); 120 page.setPd(pd);
  121 +
106 List<PageData> varList = classrosterService.list(page); //列出ClassRoster列表 122 List<PageData> varList = classrosterService.list(page); //列出ClassRoster列表
107 mv.setViewName("sunvote/classroster/classroster_list"); 123 mv.setViewName("sunvote/classroster/classroster_list");
108 mv.addObject("varList", varList); 124 mv.addObject("varList", varList);