Commit 03a14c0e150b2580ed9fcb461121f31c46f1b39e

Authored by 孙向锦
1 parent 9338b563

更新报表

WebRoot/WEB-INF/jsp/sunvote/student/student_list2.jsp
@@ -34,9 +34,6 @@ @@ -34,9 +34,6 @@
34 <input type="hidden" name="CLASS_ID" id="CLASS_ID" value="${pd.CLASS_ID}"/> 34 <input type="hidden" name="CLASS_ID" id="CLASS_ID" value="${pd.CLASS_ID}"/>
35 <input type="hidden" name="TERM_ID" id="TERM_ID" value="${pd.TERM_ID}"/> 35 <input type="hidden" name="TERM_ID" id="TERM_ID" value="${pd.TERM_ID}"/>
36 <table style="margin-top:5px;"> 36 <table style="margin-top:5px;">
37 - <tr>  
38 - <th class="center" style="float:right"><a href="javascript:;">查看成绩报表</a></th>  
39 - </tr>  
40 </table> 37 </table>
41 <!-- 检索 --> 38 <!-- 检索 -->
42 39
WebRoot/WEB-INF/jsp/sunvote/teacher/teacher_report_1.jsp
@@ -100,8 +100,11 @@ @@ -100,8 +100,11 @@
100 <c:when test="${not empty studentList}"> 100 <c:when test="${not empty studentList}">
101 <c:forEach items="${studentList}" var="var" varStatus="vs"> 101 <c:forEach items="${studentList}" var="var" varStatus="vs">
102 <tr> 102 <tr>
103 - <td class="center"><a 103 + <%-- <td class="center"><a
104 href="report/student_report?studentid=${var.ID}&class_id=${info.CLASS_ID}">${var.NAME}</a> 104 href="report/student_report?studentid=${var.ID}&class_id=${info.CLASS_ID}">${var.NAME}</a>
  105 + </td> --%>
  106 + <td class="center"><a
  107 + href="report/student_report_data?studentid=${var.ID}&class_id=${info.CLASS_ID}">${var.NAME}</a>
105 </td> 108 </td>
106 <td class="center"><fmt:formatNumber type="number" 109 <td class="center"><fmt:formatNumber type="number"
107 value="${var.TOTALSCORE == 0 ? 0: (var.GETSCORE / var.TOTALSCORE * 100)}" 110 value="${var.TOTALSCORE == 0 ? 0: (var.GETSCORE / var.TOTALSCORE * 100)}"
src/com/fh/bean/TestPaper.java
@@ -43,6 +43,7 @@ public class TestPaper { @@ -43,6 +43,7 @@ public class TestPaper {
43 // 平均分 43 // 平均分
44 private String avgScore ; 44 private String avgScore ;
45 45
  46 + private String totalScore;
46 // 备注 47 // 备注
47 private String remark ; 48 private String remark ;
48 49
@@ -163,6 +164,14 @@ public class TestPaper { @@ -163,6 +164,14 @@ public class TestPaper {
163 this.students = students; 164 this.students = students;
164 } 165 }
165 166
  167 + public String getTotalScore() {
  168 + return totalScore;
  169 + }
  170 +
  171 + public void setTotalScore(String totalScore) {
  172 + this.totalScore = totalScore;
  173 + }
  174 +
166 public static TestPaper parse(String json){ 175 public static TestPaper parse(String json){
167 Gson gson = new Gson(); 176 Gson gson = new Gson();
168 return gson.fromJson(json, TestPaper.class); 177 return gson.fromJson(json, TestPaper.class);
src/com/fh/controller/api/V1.java
@@ -782,6 +782,7 @@ public class V1 extends BaseController { @@ -782,6 +782,7 @@ public class V1 extends BaseController {
782 testPd.put("HIGHT_SCORE", testPaper.getHighScore()); 782 testPd.put("HIGHT_SCORE", testPaper.getHighScore());
783 testPd.put("LOW_SCORE", testPaper.getLowScore()); 783 testPd.put("LOW_SCORE", testPaper.getLowScore());
784 testPd.put("AVG_SCORE", testPaper.getAvgScore()); 784 testPd.put("AVG_SCORE", testPaper.getAvgScore());
  785 + testPd.put("TOTAL_SCORE", testPaper.getTotalScore());
785 testPd.put("REMARK", testPaper.getRemark()); 786 testPd.put("REMARK", testPaper.getRemark());
786 testpaperService.save(testPd); 787 testpaperService.save(testPd);
787 if (testPaper.getStudents() != null) { 788 if (testPaper.getStudents() != null) {
src/com/fh/controller/sunvote/report/ReportController.java
@@ -124,7 +124,7 @@ public class ReportController extends BaseController { @@ -124,7 +124,7 @@ public class ReportController extends BaseController {
124 logBefore(logger, Jurisdiction.getUsername()+"学生报表数据"); 124 logBefore(logger, Jurisdiction.getUsername()+"学生报表数据");
125 PageData pd = getPageData(); 125 PageData pd = getPageData();
126 ResponseGson<List<PageData>> ret = new ResponseGson(); 126 ResponseGson<List<PageData>> ret = new ResponseGson();
127 - pd.put("CLASS_ID", pd.get("CLASSID")); 127 +// pd.put("CLASS_ID", pd.get("CLASSID"));
128 List<PageData> studentList = studentService.listAllClass(pd); 128 List<PageData> studentList = studentService.listAllClass(pd);
129 List<PageData> testpaperList = testpaperService.listAll(pd); 129 List<PageData> testpaperList = testpaperService.listAll(pd);
130 130