Commit 257a6d53450164071a2046116ffe7a7d0e41e0dc
1 parent
0f85fed0
1.修改课后练
Showing
5 changed files
with
513 additions
and
145 deletions
WebRoot/WEB-INF/jsp/sunvote/homework/homework_list.jsp
| ... | ... | @@ -50,14 +50,14 @@ |
| 50 | 50 | <div style="padding:0 5%;background:#fff;"> |
| 51 | 51 | <table class="table table-striped"> |
| 52 | 52 | <col style="width: 8%" /> |
| 53 | - <col style="width: 20%" /> | |
| 53 | + <col style="width: 19%" /> | |
| 54 | 54 | <col style="width: 15%" /> |
| 55 | - <col style="width: 15%" /> | |
| 56 | - <col style="width: 10%" /> | |
| 55 | + <col style="width: 12%" /> | |
| 56 | + <col style="width: 7%" /> | |
| 57 | 57 | <col style="width: 7%" /> |
| 58 | 58 | <col style="width: 10%" /> |
| 59 | - <col style="width: 5%" /> | |
| 60 | - <col style="width: 10%" /> | |
| 59 | + <col style="width: 6%" /> | |
| 60 | + <col style="width: 15%" /> | |
| 61 | 61 | <thead> |
| 62 | 62 | <tr> |
| 63 | 63 | <th><input type="checkbox" name='ids' id="ids" />序号</th> |
| ... | ... | @@ -77,14 +77,14 @@ |
| 77 | 77 | <div class="table_box"> |
| 78 | 78 | <table class="table table-striped"> |
| 79 | 79 | <col style="width: 8%" /> |
| 80 | - <col style="width: 20%" /> | |
| 81 | - <col style="width: 15%" /> | |
| 80 | + <col style="width: 19%" /> | |
| 82 | 81 | <col style="width: 15%" /> |
| 83 | - <col style="width: 10%" /> | |
| 82 | + <col style="width: 12%" /> | |
| 83 | + <col style="width: 7%" /> | |
| 84 | 84 | <col style="width: 7%" /> |
| 85 | 85 | <col style="width: 10%" /> |
| 86 | - <col style="width: 5%" /> | |
| 87 | - <col style="width: 10%" /> | |
| 86 | + <col style="width: 6%" /> | |
| 87 | + <col style="width: 15%" /> | |
| 88 | 88 | <tbody> |
| 89 | 89 | <c:choose> |
| 90 | 90 | <c:when test="${not empty varList}"> |
| ... | ... | @@ -100,11 +100,13 @@ |
| 100 | 100 | <td >${var.ALL_SCORE}</td> |
| 101 | 101 | <td> |
| 102 | 102 | <c:if test="${var.COMPLETE_COUNT == '0'}"> |
| 103 | + <a onclick="homeReport('${var.HOMEWORK_ID}');"><img src="static/images/view.png" /></a> | |
| 103 | 104 | <a onclick="edit('${var.HOMEWORK_ID}');"><img src="static/images/eidtor.png" /></a> |
| 104 | 105 | <a onclick="del('${var.HOMEWORK_ID}');"><img src="static/images/remove.png" /></a> |
| 105 | 106 | </c:if> |
| 106 | 107 | <c:if test="${var.COMPLETE_COUNT == '1'}"> |
| 107 | - <a onclick="del('${var.HOMEWORK_ID}');" style="margin-left: 28px"><img src="static/images/remove.png" /></a> | |
| 108 | + <a onclick="homeReport('${var.HOMEWORK_ID}');" style="margin-left: 28px"><img src="static/images/view.png" /></a> | |
| 109 | + <a onclick="del('${var.HOMEWORK_ID}');" ><img src="static/images/remove.png" /></a> | |
| 108 | 110 | </c:if> |
| 109 | 111 | |
| 110 | 112 | </tr> |
| ... | ... | @@ -151,6 +153,7 @@ |
| 151 | 153 | <script type="text/javascript"> |
| 152 | 154 | $(document).ready(function() { |
| 153 | 155 | window.top.loading.remove(); |
| 156 | + $(".table_box").css("padding-top",$(".head_box").height()); | |
| 154 | 157 | //日期框 |
| 155 | 158 | $('.date-picker').datepicker({ |
| 156 | 159 | autoclose: true, |
| ... | ... | @@ -177,7 +180,12 @@ |
| 177 | 180 | window.top.loading.show(); |
| 178 | 181 | } |
| 179 | 182 | function view(url){ |
| 180 | - var path = url | |
| 183 | + var path = url; | |
| 184 | + parent.$("#mainFrame").attr('src',path); | |
| 185 | + window.top.loading.show(); | |
| 186 | + } | |
| 187 | + function homeReport(){ | |
| 188 | + var path = '<%=basePath%>homework/report.do?'; | |
| 181 | 189 | parent.$("#mainFrame").attr('src',path); |
| 182 | 190 | window.top.loading.show(); |
| 183 | 191 | } | ... | ... |
WebRoot/WEB-INF/jsp/sunvote/homework/homework_report.jsp
| ... | ... | @@ -36,7 +36,62 @@ |
| 36 | 36 | .search_btn{width:30px;} |
| 37 | 37 | .btn{margin:0 5px;} |
| 38 | 38 | .center{height:39px;} |
| 39 | - .box_header{position:fixed;top:0;left:0;width:100%;z-index:9999;} | |
| 39 | + .box_header{position:fixed;top:0;left:0;width:100%;} | |
| 40 | + .clear{clear:both} | |
| 41 | + ul{ | |
| 42 | + padding:0; | |
| 43 | + } | |
| 44 | + .list{ | |
| 45 | + width:120px; | |
| 46 | + height:40px; | |
| 47 | + line-height:40px; | |
| 48 | + font-weight:bold; | |
| 49 | + text-align:center; | |
| 50 | + margin-right:10px; | |
| 51 | + margin-top:10px; | |
| 52 | + float:left; | |
| 53 | + list-style:none; | |
| 54 | + border:1px solid #ddd; | |
| 55 | + } | |
| 56 | + .correct{ | |
| 57 | + color:#28be56; | |
| 58 | + } | |
| 59 | + .erro{ | |
| 60 | + color:#ff5353; | |
| 61 | + } | |
| 62 | + .overall h3,.single h3{ | |
| 63 | + font-size:16px; | |
| 64 | + font-weight:bold; | |
| 65 | + } | |
| 66 | + .single{ | |
| 67 | + margin-top:50px; | |
| 68 | + } | |
| 69 | + .q_charts{ | |
| 70 | + width:100%; | |
| 71 | + height:200px; | |
| 72 | + } | |
| 73 | + .rel{ | |
| 74 | + width:20px; | |
| 75 | + height:100%; | |
| 76 | + } | |
| 77 | + .ans_correct{ | |
| 78 | + background:#f00; | |
| 79 | + } | |
| 80 | + .ans_error{ | |
| 81 | + background:#ff0; | |
| 82 | + } | |
| 83 | + .ans_list{ | |
| 84 | + display:inline-block; | |
| 85 | + | |
| 86 | + margin:0 10px; | |
| 87 | + } | |
| 88 | + .ans_list p{ | |
| 89 | + margin:0; | |
| 90 | + line-height:20px; | |
| 91 | + } | |
| 92 | + .p_num{ | |
| 93 | + | |
| 94 | + } | |
| 40 | 95 | |
| 41 | 96 | </style> |
| 42 | 97 | </head> |
| ... | ... | @@ -50,142 +105,76 @@ |
| 50 | 105 | </div> |
| 51 | 106 | <div class="clear"></div> |
| 52 | 107 | </div> |
| 53 | -<div style="padding-top:3%;margin-top:102px;"> | |
| 54 | - | |
| 55 | - <!-- Nav tabs --> | |
| 56 | - <ul class="nav nav-tabs" role="tablist" style="padding-bottom:3%"> | |
| 57 | - | |
| 58 | - <c:forEach items="${pd.CLASSES}" var="var" varStatus="vs"> | |
| 59 | - <li class="btn ${pd.CLASS_ID==var.CLASS_ID?'btn-primary':'btn-default'} btn-default btn-lg" onclick="homeReport('${var.CLASS_ID}')">${var.CLASS_NAME}</li> | |
| 60 | - </c:forEach> | |
| 61 | - | |
| 62 | - </ul> | |
| 63 | - | |
| 64 | - | |
| 65 | - <div style="padding:20px 20px;"> | |
| 66 | - <form action="homework/report.do" method="post" name="Form" id="Form" style="margin-bottom:0;"> | |
| 67 | - <input type="hidden" name="CLASSID" id="CLASSID" value="${pd.CLASS_ID}" /> | |
| 68 | - <input type="hidden" name="ROLE" id="ROLE" value="${pd.ROLE}" /> | |
| 69 | - <table style="margin-top:5px;margin-bottom:20px;"> | |
| 108 | +<div style="padding:0 20px;padding-top:3%;margin-top:102px;"> | |
| 109 | + <div class="overall"> | |
| 110 | + <h3>作业总体情况:</h3> | |
| 111 | + <table class="table table-bordered "> | |
| 112 | + <col style="width: 20%" /> | |
| 113 | + <col style="width: 20%" /> | |
| 114 | + <col style="width: 20%" /> | |
| 115 | + <col style="width: 20%" /> | |
| 116 | + <col style="width: 20%" /> | |
| 117 | + <tbody> | |
| 70 | 118 | <tr> |
| 71 | - <td><div style="width:150px;text-align:center;">课程统计: ${fn:length(pd.DATA.HOMEWORKS)}</div></td> | |
| 72 | - <td><div style="width:150px;text-align:center;">班级名册: ${myelfun:findClassName(pd.CLASS_ID)}</div></td> | |
| 73 | - | |
| 74 | - <td><div style="width:150px;text-align:center;"><span>学生人数: ${fn:length(pd.DATA.STUDENTS)}</span></div></td> | |
| 75 | - <td></td> | |
| 76 | - | |
| 77 | - | |
| 78 | - | |
| 79 | - <td style="padding-left:2px;"> | |
| 80 | - <input | |
| 81 | - class="span10 date-picker" name="lastStart" id="lastStart" | |
| 82 | - value="${pd.START_DATE}" type="text" data-date-format="yyyy-mm-dd" | |
| 83 | - readonly="readonly" style="width:88px;" placeholder="开始日期" | |
| 84 | - title="开始日期" />— | |
| 85 | - </td> | |
| 86 | - <td style="padding-left:2px;"><input | |
| 87 | - class="span10 date-picker" name="lastEnd" id="lastEnd" value="${pd.END_DATE}" | |
| 88 | - type="text" data-date-format="yyyy-mm-dd" readonly="readonly" | |
| 89 | - style="width:88px;" placeholder="结束日期" title="结束日期" /></td> | |
| 90 | - <td style="vertical-align:top;padding-left:2px"><a | |
| 91 | - class="btn btn-light btn-xs" onclick="tosearch();" title="检索"><img src="static/images/search.png" alt="" class="search_btn" /></a></td> | |
| 92 | - <td><li class="btn ${pd.CURRENT_WEEK==-1?'btn-primary':'btn-default' } btn-sm" onclick="tosearch_week(${pd.CURRENT_WEEK-1})">上一周</li></td> | |
| 93 | - | |
| 94 | - <td><li class="btn ${pd.CURRENT_WEEK==1?'btn-primary':'btn-default' } btn-sm" onclick="tosearch_week(${pd.CURRENT_WEEK+1})">下一周</li></td> | |
| 119 | + <td>提交情况:25/30</td> | |
| 120 | + <td>题量:10</td> | |
| 121 | + <td>最高得分率:100%</td> | |
| 122 | + <td>最低得分率:10%</td> | |
| 123 | + <td>平均得分率:60%</td> | |
| 95 | 124 | </tr> |
| 96 | - </table> | |
| 97 | - <hr /> | |
| 98 | - <table id="simple-table" | |
| 99 | - class="table table-bordered table-hover" | |
| 100 | - style="margin-top:0px;margin-bottom:0px;"> | |
| 101 | - <thead> | |
| 102 | - <tr> | |
| 103 | - <th class="center th_name"><div style="width:150px;">姓名</div></th> | |
| 104 | - <th class="center "><div style="width:150px;">课程平均得分率</div></th> | |
| 105 | - <th class="center"><div style="width:80px;">课程总分</div></th> | |
| 106 | - <th class="center"><div style="width:150px;">个人完成情况</div></th> | |
| 107 | - <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 108 | - <th class="center kc"><a | |
| 109 | - onclick="paper('${pd.CLASS_ID}','${var_h.HOMEWORK_ID}');"><div style="width:180px; margin: 0 auto;cursor:hand" class="font">${var_h.NAME}</br><span>${var_h.COMPLETE_DATE}</span></div></a></th> | |
| 110 | - </c:forEach> | |
| 111 | - </tr> | |
| 112 | - </thead> | |
| 113 | - <tbody> | |
| 114 | - <tr> | |
| 115 | - <td class="center"><div style="width:150px;">班级课程总分</div></td> | |
| 116 | - <td class="center"><div style="width:150px;"></div></td> | |
| 117 | - <td class="center"><div style="width:80px;"></div></td> | |
| 118 | - <td class="center"><div style="width:80px;"></div></td> | |
| 119 | - <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 120 | - <td class="center"><div style="width:80px;margin:0 auto;">${var_h.ALL_SCORE}</div></td> | |
| 121 | - </c:forEach> | |
| 122 | - </tr> | |
| 123 | - <tr> | |
| 124 | - <td class="center"><div style="width:150px;">班级课程平均分</div></td> | |
| 125 | - <td class="center"><div style="width:150px;"></div></td> | |
| 126 | - <td class="center"><div style="width:80px;"></div></td> | |
| 127 | - <td class="center"><div style="width:80px;"></div></td> | |
| 128 | - <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 129 | - <td class="center"><div style="width:80px;margin:0 auto;">${var_h.GET_SCORE}</div></td> | |
| 130 | - </c:forEach> | |
| 131 | - </tr> | |
| 132 | - <tr> | |
| 133 | - <td class="center"><div style="width:150px;">班级课程平均得分率</div></td> | |
| 134 | - <td class="center"><div style="width:150px;"></div></td> | |
| 135 | - <td class="center"><div style="width:80px;"></div></td> | |
| 136 | - <td class="center"><div style="width:80px;"></div></td> | |
| 137 | - <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 138 | - <td class="center"><div style="width:80px;margin:0 auto;">${var_h.GET_SCORE_PERSENT }</div></td> | |
| 139 | - </c:forEach> | |
| 140 | - </tr> | |
| 141 | - <tr> | |
| 142 | - <td class="center"><div style="width:150px;">练习完成情况</div></td> | |
| 143 | - <td class="center"><div style="width:150px;"></div></td> | |
| 144 | - <td class="center"><div style="width:80px;"></div></td> | |
| 145 | - <td class="center"><div style="width:80px;"></div></td> | |
| 146 | - <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 147 | - <td class="center"><div style="width:80px;margin:0 auto;">${var_h.COMPLETE_DESC }</div></td> | |
| 148 | - </c:forEach> | |
| 149 | - </tr> | |
| 150 | - | |
| 151 | - <c:choose> | |
| 152 | - <c:when test="${not empty pd.DATA.STUDENTS}"> | |
| 153 | - <c:forEach items="${pd.DATA.STUDENTS}" var="var" varStatus="vs"> | |
| 154 | - <tr> | |
| 155 | - <%-- <td class="center"><a | |
| 156 | - href="report/student_report?studentid=${var.ID}&class_id=${info.CLASS_ID}">${var.NAME}</a> | |
| 157 | - </td> --%> | |
| 158 | - <td class="center"><div style="width:150px;cursor:hand"><a | |
| 159 | - onclick="student('${pd.CLASS_ID}','${var.STUDENT_ID}')">${var.NAME}</a></div> | |
| 160 | - </td> | |
| 161 | - <td class="center"><div style="width:150px;"><fmt:formatNumber type="number" | |
| 162 | - value="${var.PAPER_ALL_SCORE == 0 ? 0: (var.STUDENT_ALL_SCORE / var.PAPER_ALL_SCORE * 100)}" | |
| 163 | - maxFractionDigits="2" />%</div></td> | |
| 164 | - <td class="center"><div style="width:80px;margin:0 auto;">${var.PAPER_ALL_SCORE}</div></td> | |
| 165 | - <td class="center"><div style="width:80px;margin:0 auto;"><fmt:formatNumber type="number" | |
| 166 | - value="${var.ALL_COUNT == 0 ? 0: (var.COMPLETE_COUNT / var.ALL_COUNT * 100)}" | |
| 167 | - maxFractionDigits="2" />%</div></td> | |
| 168 | - <c:forEach items="${pd.DATA.HOMEWORKS}" var="var1" varStatus="vs1"> | |
| 169 | - <td class="center"><div style="width:80px;margin:0 auto;"><c:set var="TEST_ID" | |
| 170 | - value="${var1.HOMEWORK_ID}" /> ${var[TEST_ID] }</div></td> | |
| 171 | - </c:forEach> | |
| 172 | - </tr> | |
| 173 | - </c:forEach> | |
| 174 | - </c:when> | |
| 175 | - </c:choose> | |
| 176 | - </tbody> | |
| 177 | - </table> | |
| 178 | - | |
| 179 | - <div id="scrollableTable"></div> | |
| 180 | - </form> | |
| 125 | + <tr> | |
| 126 | + <td colspan="5">未提交人:张三、李四</td> | |
| 127 | + </tr> | |
| 128 | + </tbody> | |
| 129 | + </table> | |
| 130 | + </div> | |
| 131 | + <div class="single"> | |
| 132 | + <h3>单题正确率详情:</h3> | |
| 133 | + <ul> | |
| 134 | + <li class="list correct">1(60%)</li> | |
| 135 | + <li class="list erro">2(60%)</li> | |
| 136 | + <li class="list correct">3(60%)</li> | |
| 137 | + <li class="list correct">4(60%)</li> | |
| 138 | + <li class="list correct">5(60%)</li> | |
| 139 | + <li class="list correct">6(60%)</li> | |
| 140 | + <li class="list correct">7(60%)</li> | |
| 141 | + <li class="list correct">8(60%)</li> | |
| 142 | + <li class="list correct">9(60%)</li> | |
| 143 | + <li class="list correct">10(60%)</li> | |
| 144 | + <li class="list correct">11(60%)</li> | |
| 145 | + <li class="list correct">12(60%)</li> | |
| 146 | + </ul> | |
| 147 | + <div class="clear"></div> | |
| 181 | 148 | </div> |
| 182 | - | |
| 183 | - | |
| 184 | - | |
| 185 | 149 | |
| 186 | 150 | </div> |
| 187 | 151 | |
| 188 | - | |
| 152 | + <!-- Modal --> | |
| 153 | +<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"> | |
| 154 | + <div class="modal-dialog" role="document" style="z-index:1041"> | |
| 155 | + <div class="modal-content"> | |
| 156 | + <div class="modal-header"> | |
| 157 | + <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> | |
| 158 | + <h4 class="modal-title" id="myModalLabel">第一题【3分】</h4> | |
| 159 | + </div> | |
| 160 | + <div class="modal-body"> | |
| 161 | + <p>正确答案:D 得分率:84%</p> | |
| 162 | + <div class="q_charts"> | |
| 163 | + <div class="ans_list" style="height:50px;"> | |
| 164 | + <p class="p_num">8人</p> | |
| 165 | + <div class="rel ans_correct"></div> | |
| 166 | + <p class="ans_option">A</p> | |
| 167 | + </div> | |
| 168 | + <div class="ans_list" style="height:100px;"> | |
| 169 | + <p class="p_num">8人</p> | |
| 170 | + <div class="rel ans_correct"></div> | |
| 171 | + <p class="ans_option">A</p> | |
| 172 | + </div> | |
| 173 | + </div> | |
| 174 | + </div> | |
| 175 | + </div> | |
| 176 | + </div> | |
| 177 | +</div> | |
| 189 | 178 | |
| 190 | 179 | |
| 191 | 180 | |
| ... | ... | @@ -357,6 +346,11 @@ |
| 357 | 346 | console.log(name_height); |
| 358 | 347 | $(".th_name").height(name_height); |
| 359 | 348 | } |
| 349 | + | |
| 350 | + | |
| 351 | + $(document).on("click",".list",function(){ | |
| 352 | + $('#myModal').modal('toggle') | |
| 353 | + }) | |
| 360 | 354 | |
| 361 | 355 | }); |
| 362 | 356 | ... | ... |
WebRoot/WEB-INF/jsp/sunvote/homework/homework_report_bak.jsp
0 → 100644
| 1 | +<%@ page language="java" contentType="text/html; charset=UTF-8" | |
| 2 | + pageEncoding="UTF-8"%> | |
| 3 | +<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%> | |
| 4 | +<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%> | |
| 5 | +<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%> | |
| 6 | +<%@ taglib prefix="myelfun" uri="/WEB-INF/tld/elfun.tld"%> | |
| 7 | +<% | |
| 8 | + String path = request.getContextPath(); | |
| 9 | + String basePath = request.getScheme() + "://" | |
| 10 | + + request.getServerName() + ":" + request.getServerPort() | |
| 11 | + + path + "/"; | |
| 12 | +%> | |
| 13 | + | |
| 14 | +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> | |
| 15 | +<html> | |
| 16 | +<head> | |
| 17 | +<base href="<%=basePath%>"> | |
| 18 | + | |
| 19 | +<title>${info.CLASS_NAME}成绩报表</title> | |
| 20 | +<base href="<%=basePath%>"> | |
| 21 | +<!-- 下拉框 --> | |
| 22 | +<link rel="stylesheet" href="static/ace/css/chosen.css" /> | |
| 23 | + <link type="text/css" href="static/css/tablescroller.css" rel="stylesheet" /> | |
| 24 | + | |
| 25 | +<!-- <link | |
| 26 | + href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css" | |
| 27 | + rel="stylesheet"> --> | |
| 28 | + <link rel="stylesheet" href="static/css/bootstrap.min.css" /> | |
| 29 | +<!-- 日期框 --> | |
| 30 | +<link rel="stylesheet" href="static/ace/css/datepicker.css" /> | |
| 31 | + | |
| 32 | +<link rel="stylesheet" href="static/css/teach.css" /> | |
| 33 | +<style> | |
| 34 | + .font span{ font-size: 12px; | |
| 35 | + font-weight: initial;color:#000;} | |
| 36 | + .search_btn{width:30px;} | |
| 37 | + .btn{margin:0 5px;} | |
| 38 | + .center{height:39px;} | |
| 39 | + .box_header{position:fixed;top:0;left:0;width:100%;z-index:9999;} | |
| 40 | + | |
| 41 | + </style> | |
| 42 | +</head> | |
| 43 | + | |
| 44 | +<body style="background:#fff;height:auto;"> | |
| 45 | +<div class="box_header"> | |
| 46 | + <div class="head_box_l"> | |
| 47 | + <p> | |
| 48 | + <span class="right_b"></span>练习报表 | |
| 49 | + </p> | |
| 50 | + </div> | |
| 51 | + <div class="clear"></div> | |
| 52 | +</div> | |
| 53 | +<div style="padding-top:3%;margin-top:102px;"> | |
| 54 | + | |
| 55 | + <!-- Nav tabs --> | |
| 56 | + <ul class="nav nav-tabs" role="tablist" style="padding-bottom:3%"> | |
| 57 | + | |
| 58 | + <c:forEach items="${pd.CLASSES}" var="var" varStatus="vs"> | |
| 59 | + <li class="btn ${pd.CLASS_ID==var.CLASS_ID?'btn-primary':'btn-default'} btn-default btn-lg" onclick="homeReport('${var.CLASS_ID}')">${var.CLASS_NAME}</li> | |
| 60 | + </c:forEach> | |
| 61 | + | |
| 62 | + </ul> | |
| 63 | + | |
| 64 | + | |
| 65 | + <div style="padding:20px 20px;"> | |
| 66 | + <form action="homework/report.do" method="post" name="Form" id="Form" style="margin-bottom:0;"> | |
| 67 | + <input type="hidden" name="CLASSID" id="CLASSID" value="${pd.CLASS_ID}" /> | |
| 68 | + <input type="hidden" name="ROLE" id="ROLE" value="${pd.ROLE}" /> | |
| 69 | + <table style="margin-top:5px;margin-bottom:20px;"> | |
| 70 | + <tr> | |
| 71 | + <td><div style="width:150px;text-align:center;">课程统计: ${fn:length(pd.DATA.HOMEWORKS)}</div></td> | |
| 72 | + <td><div style="width:150px;text-align:center;">班级名册: ${myelfun:findClassName(pd.CLASS_ID)}</div></td> | |
| 73 | + | |
| 74 | + <td><div style="width:150px;text-align:center;"><span>学生人数: ${fn:length(pd.DATA.STUDENTS)}</span></div></td> | |
| 75 | + <td></td> | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + <td style="padding-left:2px;"> | |
| 80 | + <input | |
| 81 | + class="span10 date-picker" name="lastStart" id="lastStart" | |
| 82 | + value="${pd.START_DATE}" type="text" data-date-format="yyyy-mm-dd" | |
| 83 | + readonly="readonly" style="width:88px;" placeholder="开始日期" | |
| 84 | + title="开始日期" />— | |
| 85 | + </td> | |
| 86 | + <td style="padding-left:2px;"><input | |
| 87 | + class="span10 date-picker" name="lastEnd" id="lastEnd" value="${pd.END_DATE}" | |
| 88 | + type="text" data-date-format="yyyy-mm-dd" readonly="readonly" | |
| 89 | + style="width:88px;" placeholder="结束日期" title="结束日期" /></td> | |
| 90 | + <td style="vertical-align:top;padding-left:2px"><a | |
| 91 | + class="btn btn-light btn-xs" onclick="tosearch();" title="检索"><img src="static/images/search.png" alt="" class="search_btn" /></a></td> | |
| 92 | + <td><li class="btn ${pd.CURRENT_WEEK==-1?'btn-primary':'btn-default' } btn-sm" onclick="tosearch_week(${pd.CURRENT_WEEK-1})">上一周</li></td> | |
| 93 | + | |
| 94 | + <td><li class="btn ${pd.CURRENT_WEEK==1?'btn-primary':'btn-default' } btn-sm" onclick="tosearch_week(${pd.CURRENT_WEEK+1})">下一周</li></td> | |
| 95 | + </tr> | |
| 96 | + </table> | |
| 97 | + <hr /> | |
| 98 | + <table id="simple-table" | |
| 99 | + class="table table-bordered table-hover" | |
| 100 | + style="margin-top:0px;margin-bottom:0px;"> | |
| 101 | + <thead> | |
| 102 | + <tr> | |
| 103 | + <th class="center th_name"><div style="width:150px;">姓名</div></th> | |
| 104 | + <th class="center "><div style="width:150px;">课程平均得分率</div></th> | |
| 105 | + <th class="center"><div style="width:80px;">课程总分</div></th> | |
| 106 | + <th class="center"><div style="width:150px;">个人完成情况</div></th> | |
| 107 | + <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 108 | + <th class="center kc"><a | |
| 109 | + onclick="paper('${pd.CLASS_ID}','${var_h.HOMEWORK_ID}');"><div style="width:180px; margin: 0 auto;cursor:hand" class="font">${var_h.NAME}</br><span>${var_h.COMPLETE_DATE}</span></div></a></th> | |
| 110 | + </c:forEach> | |
| 111 | + </tr> | |
| 112 | + </thead> | |
| 113 | + <tbody> | |
| 114 | + <tr> | |
| 115 | + <td class="center"><div style="width:150px;">班级课程总分</div></td> | |
| 116 | + <td class="center"><div style="width:150px;"></div></td> | |
| 117 | + <td class="center"><div style="width:80px;"></div></td> | |
| 118 | + <td class="center"><div style="width:80px;"></div></td> | |
| 119 | + <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 120 | + <td class="center"><div style="width:80px;margin:0 auto;">${var_h.ALL_SCORE}</div></td> | |
| 121 | + </c:forEach> | |
| 122 | + </tr> | |
| 123 | + <tr> | |
| 124 | + <td class="center"><div style="width:150px;">班级课程平均分</div></td> | |
| 125 | + <td class="center"><div style="width:150px;"></div></td> | |
| 126 | + <td class="center"><div style="width:80px;"></div></td> | |
| 127 | + <td class="center"><div style="width:80px;"></div></td> | |
| 128 | + <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 129 | + <td class="center"><div style="width:80px;margin:0 auto;">${var_h.GET_SCORE}</div></td> | |
| 130 | + </c:forEach> | |
| 131 | + </tr> | |
| 132 | + <tr> | |
| 133 | + <td class="center"><div style="width:150px;">班级课程平均得分率</div></td> | |
| 134 | + <td class="center"><div style="width:150px;"></div></td> | |
| 135 | + <td class="center"><div style="width:80px;"></div></td> | |
| 136 | + <td class="center"><div style="width:80px;"></div></td> | |
| 137 | + <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 138 | + <td class="center"><div style="width:80px;margin:0 auto;">${var_h.GET_SCORE_PERSENT }</div></td> | |
| 139 | + </c:forEach> | |
| 140 | + </tr> | |
| 141 | + <tr> | |
| 142 | + <td class="center"><div style="width:150px;">练习完成情况</div></td> | |
| 143 | + <td class="center"><div style="width:150px;"></div></td> | |
| 144 | + <td class="center"><div style="width:80px;"></div></td> | |
| 145 | + <td class="center"><div style="width:80px;"></div></td> | |
| 146 | + <c:forEach items="${pd.DATA.HOMEWORKS}" var="var_h" varStatus="vs"> | |
| 147 | + <td class="center"><div style="width:80px;margin:0 auto;">${var_h.COMPLETE_DESC }</div></td> | |
| 148 | + </c:forEach> | |
| 149 | + </tr> | |
| 150 | + | |
| 151 | + <c:choose> | |
| 152 | + <c:when test="${not empty pd.DATA.STUDENTS}"> | |
| 153 | + <c:forEach items="${pd.DATA.STUDENTS}" var="var" varStatus="vs"> | |
| 154 | + <tr> | |
| 155 | + <%-- <td class="center"><a | |
| 156 | + href="report/student_report?studentid=${var.ID}&class_id=${info.CLASS_ID}">${var.NAME}</a> | |
| 157 | + </td> --%> | |
| 158 | + <td class="center"><div style="width:150px;cursor:hand"><a | |
| 159 | + onclick="student('${pd.CLASS_ID}','${var.STUDENT_ID}')">${var.NAME}</a></div> | |
| 160 | + </td> | |
| 161 | + <td class="center"><div style="width:150px;"><fmt:formatNumber type="number" | |
| 162 | + value="${var.PAPER_ALL_SCORE == 0 ? 0: (var.STUDENT_ALL_SCORE / var.PAPER_ALL_SCORE * 100)}" | |
| 163 | + maxFractionDigits="2" />%</div></td> | |
| 164 | + <td class="center"><div style="width:80px;margin:0 auto;">${var.PAPER_ALL_SCORE}</div></td> | |
| 165 | + <td class="center"><div style="width:80px;margin:0 auto;"><fmt:formatNumber type="number" | |
| 166 | + value="${var.ALL_COUNT == 0 ? 0: (var.COMPLETE_COUNT / var.ALL_COUNT * 100)}" | |
| 167 | + maxFractionDigits="2" />%</div></td> | |
| 168 | + <c:forEach items="${pd.DATA.HOMEWORKS}" var="var1" varStatus="vs1"> | |
| 169 | + <td class="center"><div style="width:80px;margin:0 auto;"><c:set var="TEST_ID" | |
| 170 | + value="${var1.HOMEWORK_ID}" /> ${var[TEST_ID] }</div></td> | |
| 171 | + </c:forEach> | |
| 172 | + </tr> | |
| 173 | + </c:forEach> | |
| 174 | + </c:when> | |
| 175 | + </c:choose> | |
| 176 | + </tbody> | |
| 177 | + </table> | |
| 178 | + | |
| 179 | + <div id="scrollableTable"></div> | |
| 180 | + </form> | |
| 181 | + </div> | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | +</div> | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + <%@ include file="../../system/index/foot.jsp"%> | |
| 193 | + <script src="static/ace/js/bootbox.js"></script> | |
| 194 | + <!-- ace scripts --> | |
| 195 | + <script src="static/ace/js/ace/ace.js"></script> | |
| 196 | + <!-- 下拉框 --> | |
| 197 | + <script src="static/ace/js/chosen.jquery.js"></script> | |
| 198 | + <!-- 日期框 --> | |
| 199 | + <script src="static/ace/js/date-time/bootstrap-datepicker.js"></script> | |
| 200 | + <!--提示框--> | |
| 201 | + <script type="text/javascript" src="static/js/jquery.tips.js"></script> | |
| 202 | + | |
| 203 | + <script language="javascript" src="static/js/tablescroller.js"></script> | |
| 204 | + <script language="javascript" src="static/js/tablescroller.jquery.js"></script> | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + <script type="text/javascript"> | |
| 209 | + $(function() { | |
| 210 | + | |
| 211 | + //日期框 | |
| 212 | + $('.date-picker').datepicker({ | |
| 213 | + autoclose : true, | |
| 214 | + todayHighlight : true | |
| 215 | + }); | |
| 216 | + | |
| 217 | + //下拉框 | |
| 218 | + if (!ace.vars['touch']) { | |
| 219 | + $('.chosen-select').chosen({ | |
| 220 | + allow_single_deselect : true | |
| 221 | + }); | |
| 222 | + $(window).off('resize.chosen').on('resize.chosen', function() { | |
| 223 | + $('.chosen-select').each(function() { | |
| 224 | + var $this = $(this); | |
| 225 | + $this.next().css({ | |
| 226 | + 'width' : $this.parent().width() | |
| 227 | + }); | |
| 228 | + }); | |
| 229 | + }).trigger('resize.chosen'); | |
| 230 | + $(document).on('settings.ace.chosen', | |
| 231 | + function(e, event_name, event_val) { | |
| 232 | + if (event_name != 'sidebar_collapsed') | |
| 233 | + return; | |
| 234 | + $('.chosen-select').each(function() { | |
| 235 | + var $this = $(this); | |
| 236 | + $this.next().css({ | |
| 237 | + 'width' : $this.parent().width() | |
| 238 | + }); | |
| 239 | + }); | |
| 240 | + }); | |
| 241 | + $('#chosen-multiple-style .btn').on( | |
| 242 | + 'click', | |
| 243 | + function(e) { | |
| 244 | + var target = $(this).find('input[type=radio]'); | |
| 245 | + var which = parseInt(target.val()); | |
| 246 | + if (which == 2) | |
| 247 | + $('#form-field-select-4').addClass( | |
| 248 | + 'tag-input-style'); | |
| 249 | + else | |
| 250 | + $('#form-field-select-4').removeClass( | |
| 251 | + 'tag-input-style'); | |
| 252 | + }); | |
| 253 | + } | |
| 254 | + | |
| 255 | + //复选框全选控制 | |
| 256 | + var active_class = 'active'; | |
| 257 | + $('#simple-table > thead > tr > th input[type=checkbox]').eq(0).on( | |
| 258 | + 'click', | |
| 259 | + function() { | |
| 260 | + var th_checked = this.checked;//checkbox inside "TH" table header | |
| 261 | + $(this).closest('table').find('tbody > tr').each( | |
| 262 | + function() { | |
| 263 | + var row = this; | |
| 264 | + if (th_checked) | |
| 265 | + $(row).addClass(active_class).find( | |
| 266 | + 'input[type=checkbox]').eq(0) | |
| 267 | + .prop('checked', true); | |
| 268 | + else | |
| 269 | + $(row).removeClass(active_class).find( | |
| 270 | + 'input[type=checkbox]').eq(0) | |
| 271 | + .prop('checked', false); | |
| 272 | + }); | |
| 273 | + }); | |
| 274 | + }); | |
| 275 | + | |
| 276 | + var role = '${pd.ROLE}'; | |
| 277 | + | |
| 278 | + function precent(avg,total){ | |
| 279 | + if(total == 0){ | |
| 280 | + return "0%" | |
| 281 | + } | |
| 282 | + return Math.round(avg / total * 100)/100 + '%' ; | |
| 283 | + } | |
| 284 | + | |
| 285 | + function homeReport(classId){ | |
| 286 | + var path = '<%=basePath%>homework/report.do?School_id=${pd.SCHOOL_ID}&CLASS_ID='+classId; | |
| 287 | + console.log(path); | |
| 288 | + parent.$("#mainFrame").attr('src',path); | |
| 289 | + window.top.loading.show(); | |
| 290 | + } | |
| 291 | + | |
| 292 | + function tosearch(){ | |
| 293 | + | |
| 294 | + var url = "<%=basePath%>homework/report.do?CLASS_ID=${pd.CLASS_ID}" ; | |
| 295 | + var startDate = $("#lastStart").val(); | |
| 296 | + var endDate = $("#lastEnd").val(); | |
| 297 | + //var subject_id = $("#SUBJECT_ID").val(); | |
| 298 | + url = url + "&START_DATE=" + startDate ; | |
| 299 | + if(endDate != null){ | |
| 300 | + url = url + "&END_DATE=" + endDate; | |
| 301 | + } | |
| 302 | + | |
| 303 | + window.location.href = url; | |
| 304 | + window.top.loading.show(); | |
| 305 | + /* $("#Form").sumbit(); */ | |
| 306 | + } | |
| 307 | + function tosearch_week(type){ //上一周 本周 下一周 | |
| 308 | + console.log('${pd.CLASS_ID}'); | |
| 309 | + var url = "<%=basePath%>homework/report.do?CLASS_ID=${pd.CLASS_ID}" ; | |
| 310 | + url = url + "&CURRENT_WEEK=" + type ; | |
| 311 | + | |
| 312 | + console.log(url); | |
| 313 | + window.location.href = url; | |
| 314 | + window.top.loading.show(); | |
| 315 | + /* $("#Form").sumbit(); */ | |
| 316 | + } | |
| 317 | + | |
| 318 | + function student(classid,studentid){ | |
| 319 | + | |
| 320 | + var url = "<%=basePath%>homework/student.do?STUDENT_ID=" + studentid + "&CLASS_ID=" + classid ; | |
| 321 | + var startDate = $("#lastStart").val(); | |
| 322 | + var endDate = $("#lastEnd").val(); | |
| 323 | + url = url + "&START_DATE=" + startDate + "&END_DATE=" + endDate ; | |
| 324 | + | |
| 325 | + window.location.href = url; | |
| 326 | + window.top.loading.show(); | |
| 327 | + } | |
| 328 | + | |
| 329 | + function paper(class_id,testpaper_id){ | |
| 330 | + var url = "<%=basePath%>homework/homework_report?HOMEWORK_ID=" + testpaper_id + "&CLASS_ID=" + class_id; | |
| 331 | + var startDate = $("#lastStart").val(); | |
| 332 | + var endDate = $("#lastEnd").val(); | |
| 333 | + url = url + "&START_DATE=" + startDate + "&END_DATE=" + endDate ; | |
| 334 | + window.self.location.href = url; | |
| 335 | + window.top.loading.show(); | |
| 336 | + } | |
| 337 | + | |
| 338 | + $(document).ready(function(){ | |
| 339 | + window.top.loading.remove(); | |
| 340 | + | |
| 341 | + var sour = "${pd.DATA.HOMEWORKS}"; | |
| 342 | + | |
| 343 | + | |
| 344 | + if(sour != null && sour.length > 3){ | |
| 345 | + var _width = $('#mainFrame', parent.document).width()-40; | |
| 346 | + var _heigh = $('#mainFrame', parent.document).height()-350; | |
| 347 | + var options = { | |
| 348 | + width: _width, | |
| 349 | + height: _heigh, | |
| 350 | + pinnedRows: 5, | |
| 351 | + pinnedCols: 4, | |
| 352 | + container: "#scrollableTable", | |
| 353 | + removeOriginal: true | |
| 354 | + }; | |
| 355 | + $("#simple-table").tablescroller(options); | |
| 356 | + var name_height = $(".kc").last().parent().height()-18.5; | |
| 357 | + console.log(name_height); | |
| 358 | + $(".th_name").height(name_height); | |
| 359 | + } | |
| 360 | + | |
| 361 | + }); | |
| 362 | + | |
| 363 | + </script> | |
| 364 | + | |
| 365 | +</body> | |
| 366 | +</html> | ... | ... |
WebRoot/WEB-INF/jsp/sunvote/teacher/teacher_main.jsp
| ... | ... | @@ -106,14 +106,14 @@ |
| 106 | 106 | <p id="practice_manage" |
| 107 | 107 | onclick="event.stopPropagation();homeWorkList('${pd.TEACHER.SCHOOL_ID}')">练习列表</p> |
| 108 | 108 | </li> |
| 109 | - <li> | |
| 109 | + <!-- <li> | |
| 110 | 110 | <p id="practice_do" |
| 111 | 111 | onclick="event.stopPropagation();homeWork('${pd.TEACHER.SCHOOL_ID}')">布置练习</p> |
| 112 | 112 | </li> |
| 113 | 113 | <li> |
| 114 | 114 | <p id="practice_report" |
| 115 | 115 | onclick="event.stopPropagation();homeReport()">练习报表</p> |
| 116 | - </li> | |
| 116 | + </li> --> | |
| 117 | 117 | </ul> |
| 118 | 118 | </div> |
| 119 | 119 | </div> | ... | ... |
WebRoot/static/images/view.png
0 → 100644
528 Bytes