-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathsummary.jsp.bak.bak
227 lines (165 loc) · 7.38 KB
/
summary.jsp.bak.bak
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
<!doctype html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no,maximum-scale=1, user-scalable=0">
<!--Jquery CDN(Content Delivery Networks) links-->
<link href="https://fonts.googleapis.com/icon?family=Material+Icons"
rel="stylesheet"><!--Google Icons Link-->
<script src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-3.3.1.min.js"></script><!---JQUERY LINK-->
<!-- Bootstrap CSS -->
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script><!---JQUERY LINK-->
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.2.1/css/bootstrap.min.css" integrity="sha384-GJzZqFGwb1QTTN6wy59ffF1BuGJpLSa9DkKMp0DgiMDm4iYMj70gZWKYbI706tWS" crossorigin="anonymous">
<!-- Optional JavaScript -->
<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.6/umd/popper.min.js" integrity="sha384-wHAiFfRlMFy6i5SRaxvfOCifBUQy1xHdJ/yoi7FRNXMRBu5WHdZYu1hA6ZOblgut" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.2.1/js/bootstrap.min.js" integrity="sha384-B0UglyR+jN6CkvvICOB2joaf5I4l3gm9GU6Hc1og6Ls7i6U/mkkaduKaBhlAXv9k" crossorigin="anonymous"></script>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.7.0/css/all.css" integrity="sha384-lZN37f5QGtY3VHgisS14W3ExzMWZxybE1SJSEsQp9S+oqd12jhcu+A56Ebc1zFSJ" crossorigin="anonymous"><!--Link for Icons-->
<link href="https://fonts.googleapis.com/css?family=Dosis" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="summary.css">
<script src="summary.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<script type="text/javascript">
$(window).on('load',function(){
$('#subject_accuracy_modal').modal('show');
});
</script>
</head>
<body>
<%
float correct_count_easy=Float.valueOf((String)session.getAttribute("correct_count_easy"));
float correct_count_medium=Float.valueOf((String)session.getAttribute("correct_count_medium"));
float correct_count_hard=Float.valueOf((String)session.getAttribute("correct_count_hard"));
double percentile=(Double.valueOf((String)session.getAttribute("mark"))/45.0)*95.0;
String result="";
double accuracy_score=correct_count_easy*1.0+correct_count_medium*2.0+correct_count_hard*4.0;
accuracy_score =(accuracy_score/45.0)*95.0;
System.out.println("Correct_count_easy"+correct_count_easy);
System.out.println("Correct_count_medium"+correct_count_medium);
System.out.println("Correct_count_hard"+correct_count_hard);
if(percentile>=90.0&&percentile<=100.0){
result="Outstanding";
}
else if(percentile>=80.0&&percentile<90.0){
result="Excellent";
}
else if(percentile>=70.0&&percentile<80.0){
result="Very Good";
}
else if(percentile>=60.0&&percentile<70.0){
result="Good";
}
else if(percentile>=50.0&&percentile<60.0){
result="Fair";
}
else if(percentile>=40.0&&percentile<50.0){
result="Average";
}
else if(percentile>=30.0&&percentile<40.0){
result="Pass";
}
else if(percentile<30.0){
result="Fail";
}
%>
<!------------------MODAL FOR Acuuracy Level ----------------------
<div class="modal fade" id="subject_accuracy_modal" >
<div class="modal-dialog modal-lg modal-dialog-centered">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Accuracy Level</h4>
<a href="#" data-dismiss="modal"><i class="fa fa-close"></i></a>
</div>
<div class="modal-body">
<!-------------------------------------LOGIN------------------------------------>
<!----------------------------LOGIN LOGIC-------------------------------------------->
<!--<div class="row" id="progressive_struc"><!--Progressbar Structure-
<div class="row" id="progressbar"><!--Progressbar Dynamic
<p id="level">Novice</p><!--Difficulty Level
<p id="percentcount">0</p><!--Accuracy Percentage
</div>
</div>
<div class="row" id="progressive_struc" style="margin-top: 100px;"><!--Progressbar Structure
<div class="row" id="progressbar"><!--Progressbar Dynamic
<p id="level">Novice</p><!--Difficulty Level
<p id="percentcount">0</p><!--Accuracy Percentage
</div>
</div>
<button onclick="easy_inc()">Easy</button>
<button onclick="medium_inc()">Medium</button>
<button onclick="hard_inc()">Hard</button>
</div>
<div class="modal-footer">
</div>
</div>
</div>
</div>
<!----------------MODAL FOR Accuracy level ---------------------------->
<div class="container-fluid" style="position:fixed">
<div class="row"><!---MAIN DIV-->
<div class="col" id="summary_main">
<div class="row" >
<div class="col" id="main_header">
<h1 style="text-align:center;padding-right:30vw;" id="main_title">S U M M A R Y</h1>
</div>
</div>
<div class="row" >
<div class="col" id="main_body">
<label id="body_label">Name</label>
</div>
<div class="" id="vertical_line">
</div>
<div class="col" id="main_body">
<label id="body_label_R"><%= (String)session.getAttribute("name")%></label>
</div>
</div>
<div class="row" >
<div class="col" id="main_body">
<label id="body_label">Subject</label>
</div>
<div class="" id="vertical_line">
</div>
<div class="col" id="main_body">
<label id="body_label_R"><%=(String)session.getAttribute("subject")%></label>
</div>
</div>
<div class="row" >
<div class="col" id="main_body">
<label id="body_label">Score</label>
</div>
<div class="" id="vertical_line">
</div>
<div class="col" id="main_body">
<label id="body_label_R"><%=percentile%>
</label>
</div>
</div>
<div class="row" >
<div class="col" id="main_body">
<label id="body_label">Remarks></label>
</div>
<div class="" id="vertical_line">
</div>
<div class="col" id="main_body">
<label id="body_label_R"><%=result%></label>
</div>
</div>
<div class="row" >
<div class="col" id="main_body">
<label id="body_label">Subject-Accuracy</label>
</div>
<div class="" id="vertical_line">
</div>
<div class="col" id="main_body">
<label id="body_label_R"><%=accuracy_score%></label>
</div>
</div>
<form action="Home.jsp">
<button class="btn btn-success" style="margin-top:10px;margin-left:450px;height: 60px;width: 200px">Return to Home</button>
</form>
</div>
</div>
</div>
</body>
</html>