|
|
@ -32,7 +32,7 @@ public class AttendanceService { |
|
|
+ "SUM(CASE WHEN facial_attendance = 1 THEN 1 ELSE 0 END) AS facialRegistered, " |
|
|
+ "SUM(CASE WHEN facial_attendance = 1 THEN 1 ELSE 0 END) AS facialRegistered, " |
|
|
+ "SUM(CASE WHEN facial_attendance = 0 THEN 1 ELSE 0 END) AS facialNotRegistered " |
|
|
+ "SUM(CASE WHEN facial_attendance = 0 THEN 1 ELSE 0 END) AS facialNotRegistered " |
|
|
+ "FROM enrollment_table " |
|
|
+ "FROM enrollment_table " |
|
|
+ "WHERE isactive = 1 AND isdelete = 0 AND zone != 0 " |
|
|
|
|
|
|
|
|
+ "WHERE isactive = 1 AND isdelete = 0 AND zone != 0 and emp_type ='Park' " |
|
|
+ "GROUP BY emp_type"; |
|
|
+ "GROUP BY emp_type"; |
|
|
|
|
|
|
|
|
return jdbcTemplate.queryForList(sql); |
|
|
return jdbcTemplate.queryForList(sql); |
|
|
@ -81,10 +81,12 @@ public class AttendanceService { |
|
|
+ "GROUP BY et.zone, fd.facialRegistered, fd.facialNotRegistered " |
|
|
+ "GROUP BY et.zone, fd.facialRegistered, fd.facialNotRegistered " |
|
|
+ "ORDER BY et.zone"; |
|
|
+ "ORDER BY et.zone"; |
|
|
|
|
|
|
|
|
return jdbcTemplate.queryForList(sql, new Object[] { empType, fromDateTime, toDateTime, fromDateTime, toDateTime, fromDateTime, toDateTime, empType }); |
|
|
|
|
|
|
|
|
return jdbcTemplate.queryForList(sql, new Object[] { empType, fromDateTime, toDateTime, fromDateTime, |
|
|
|
|
|
toDateTime, fromDateTime, toDateTime, empType }); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
public List<Map<String, Object>> getDetailedList(String empType, String category, String fromDateStr, String toDateStr, Integer zone, String parkName) { |
|
|
|
|
|
|
|
|
public List<Map<String, Object>> getDetailedList(String empType, String category, String fromDateStr, |
|
|
|
|
|
String toDateStr, Integer zone, String parkName) { |
|
|
LocalDate fromDate; |
|
|
LocalDate fromDate; |
|
|
LocalDate toDate; |
|
|
LocalDate toDate; |
|
|
|
|
|
|
|
|
@ -148,7 +150,8 @@ public class AttendanceService { |
|
|
|
|
|
|
|
|
sql += " order by " + dateColumn + " desc "; |
|
|
sql += " order by " + dateColumn + " desc "; |
|
|
|
|
|
|
|
|
System.out.println("EmpType: " + empType + ", Category: " + category + ", From: " + fromDateTime + ", To: " + toDateTime + ", Zone: " + zone + ", ParkName: " + parkName); |
|
|
|
|
|
|
|
|
System.out.println("EmpType: " + empType + ", Category: " + category + ", From: " + fromDateTime + ", To: " |
|
|
|
|
|
+ toDateTime + ", Zone: " + zone + ", ParkName: " + parkName); |
|
|
return jdbcTemplate.queryForList(sql, params.toArray()); |
|
|
return jdbcTemplate.queryForList(sql, params.toArray()); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@ -193,7 +196,7 @@ public class AttendanceService { |
|
|
+ "GROUP BY et.park_name, fd.facialRegistered, fd.facialNotRegistered " |
|
|
+ "GROUP BY et.park_name, fd.facialRegistered, fd.facialNotRegistered " |
|
|
+ "ORDER BY et.park_name"; |
|
|
+ "ORDER BY et.park_name"; |
|
|
|
|
|
|
|
|
return jdbcTemplate.queryForList(sql, new Object[] { zone, fromDateTime, toDateTime, fromDateTime, toDateTime, fromDateTime, toDateTime, zone }); |
|
|
|
|
|
|
|
|
return jdbcTemplate.queryForList(sql, new Object[] { zone, fromDateTime, toDateTime, fromDateTime, toDateTime, |
|
|
|
|
|
fromDateTime, toDateTime, zone }); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|