Commit 31776d07 authored by manishatyagi's avatar manishatyagi
Browse files

change percentage range in percentage assessment report

parent 8797c4c3
......@@ -706,7 +706,7 @@ public class ReportServiceImpl implements ReportService{
private String getTenureRange(double duration)
{
String tenure="";
if(duration>0 && duration<=6)
if(duration>=0 && duration<=6)
{
tenure=CommonUtils.Tenure[0];
}
......@@ -811,40 +811,40 @@ public class ReportServiceImpl implements ReportService{
List<DBObject> percentageWiseAssessmentReport=quizResultRepo.getPercentageWiseAssessmentReport(stDate, enDate, assessmentId,subLobId);
Integer grandTotal=0;
Map<String, Integer> hashMap = new HashMap<String,Integer>();
hashMap.put("0-35", 0);
hashMap.put("36-50", 0) ;
hashMap.put("51-70", 0) ;
hashMap.put("71-80", 0) ;
hashMap.put("81-100", 0) ;
hashMap.put("0-20", 0);
hashMap.put("20-40", 0) ;
hashMap.put("40-60", 0) ;
hashMap.put("60-80", 0) ;
hashMap.put("80-100", 0) ;
hashMap.put("Grand Total", grandTotal);
for(DBObject result:percentageWiseAssessmentReport) {
int score=(Integer)result.get("quizScore");
if(score>0&score<35) {
if(score>=0&score<=20) {
grandTotal++;
if(hashMap.containsKey("0-35")) {
hashMap.put("0-35", hashMap.get("0-35")+1) ;
if(hashMap.containsKey("0-20")) {
hashMap.put("0-20", hashMap.get("0-20")+1) ;
}
}else if(score>=36&score<=50){
}else if(score>20&score<=40){
grandTotal++;
if(hashMap.containsKey("36-50")) {
hashMap.put("36-50", hashMap.get("36-50")+1) ;
if(hashMap.containsKey("20-40")) {
hashMap.put("20-40", hashMap.get("20-40")+1) ;
}
}else if(score>=51&score<=70){
}else if(score>40&score<=60){
grandTotal++;
if(hashMap.containsKey("51-70")) {
hashMap.put("51-70", hashMap.get("51-70")+1) ;
if(hashMap.containsKey("40-60")) {
hashMap.put("40-60", hashMap.get("40-60")+1) ;
}
}else if(score>=71&score<=80){
}else if(score>60&score<=80){
grandTotal++;
if(hashMap.containsKey("71-80")) {
hashMap.put("71-80", hashMap.get("71-80")+1) ;
if(hashMap.containsKey("60-80")) {
hashMap.put("60-80", hashMap.get("60-80")+1) ;
}
}else if(score>=81&score<=100){
}else if(score>80&score<=100){
grandTotal++;
if(hashMap.containsKey("81-100")) {
hashMap.put("81-100", hashMap.get("81-100")+1) ;
if(hashMap.containsKey("80-100")) {
hashMap.put("80-100", hashMap.get("80-100")+1) ;
}
}
hashMap.put("Grand Total", grandTotal);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment