[Ils-source] r1576 - in trunk/webapp: . WEB-INF/lib
scribe at crosswire.org
scribe at crosswire.org
Sun Jun 3 05:51:58 MST 2018
Author: scribe
Date: 2018-06-03 05:51:58 -0700 (Sun, 03 Jun 2018)
New Revision: 1576
Added:
trunk/webapp/WEB-INF/lib/classmate-1.3.1.jar
trunk/webapp/WEB-INF/lib/hibernate-validator-5.3.4.Final.jar
trunk/webapp/WEB-INF/lib/jackson-annotations-2.8.5.jar
trunk/webapp/WEB-INF/lib/jackson-core-2.8.5.jar
trunk/webapp/WEB-INF/lib/jackson-databind-2.8.5.jar
trunk/webapp/WEB-INF/lib/jackson-dataformat-xml-2.8.5.jar
trunk/webapp/WEB-INF/lib/jboss-logging-3.3.0.Final.jar
trunk/webapp/WEB-INF/lib/json.jar
trunk/webapp/WEB-INF/lib/stax2-api-3.1.4.redhat-1.jar
trunk/webapp/WEB-INF/lib/validation-api-1.1.0.Final-redhat-1.jar
trunk/webapp/WEB-INF/lib/xercesImpl-2.12.0.jar
Removed:
trunk/webapp/WEB-INF/lib/xercesImpl-2.11.0.jar
trunk/webapp/WEB-INF/lib/xerces_2_5_0.jar
Modified:
trunk/webapp/WEB-INF/lib/crosswire.jar
trunk/webapp/WEB-INF/lib/ils.jar
trunk/webapp/admin_studentrecords.jsp
trunk/webapp/admin_systemmanagement.jsp
trunk/webapp/login.jsp
trunk/webapp/report_employeecourseatt.jsp
trunk/webapp/report_pending_summary.jsp
trunk/webapp/report_recurrent_training.jsp
Log:
added dependencies
First working cut of all .jsp files with new crosswire tools
Added: trunk/webapp/WEB-INF/lib/classmate-1.3.1.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/classmate-1.3.1.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/webapp/WEB-INF/lib/crosswire.jar
===================================================================
(Binary files differ)
Added: trunk/webapp/WEB-INF/lib/hibernate-validator-5.3.4.Final.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/hibernate-validator-5.3.4.Final.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/webapp/WEB-INF/lib/ils.jar
===================================================================
(Binary files differ)
Added: trunk/webapp/WEB-INF/lib/jackson-annotations-2.8.5.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/jackson-annotations-2.8.5.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/webapp/WEB-INF/lib/jackson-core-2.8.5.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/jackson-core-2.8.5.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/webapp/WEB-INF/lib/jackson-databind-2.8.5.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/jackson-databind-2.8.5.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/webapp/WEB-INF/lib/jackson-dataformat-xml-2.8.5.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/jackson-dataformat-xml-2.8.5.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/webapp/WEB-INF/lib/jboss-logging-3.3.0.Final.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/jboss-logging-3.3.0.Final.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/webapp/WEB-INF/lib/json.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/json.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/webapp/WEB-INF/lib/stax2-api-3.1.4.redhat-1.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/stax2-api-3.1.4.redhat-1.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/webapp/WEB-INF/lib/validation-api-1.1.0.Final-redhat-1.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/validation-api-1.1.0.Final-redhat-1.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Deleted: trunk/webapp/WEB-INF/lib/xercesImpl-2.11.0.jar
===================================================================
(Binary files differ)
Added: trunk/webapp/WEB-INF/lib/xercesImpl-2.12.0.jar
===================================================================
(Binary files differ)
Property changes on: trunk/webapp/WEB-INF/lib/xercesImpl-2.12.0.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Deleted: trunk/webapp/WEB-INF/lib/xerces_2_5_0.jar
===================================================================
(Binary files differ)
Modified: trunk/webapp/admin_studentrecords.jsp
===================================================================
--- trunk/webapp/admin_studentrecords.jsp 2018-06-03 12:48:40 UTC (rev 1575)
+++ trunk/webapp/admin_studentrecords.jsp 2018-06-03 12:51:58 UTC (rev 1576)
@@ -6,6 +6,7 @@
<%@ page import="java.util.List" %>
<%@ page import="java.util.ArrayList" %>
<%@ page import="java.util.Set" %>
+<%@ page import="java.util.stream.Collectors" %>
<%@ page import="java.util.HashSet" %>
<%@ page import="java.util.Comparator" %>
<%@ page import="java.util.Date" %>
@@ -355,7 +356,7 @@
if (requestedLocations == null) {
List<Group> tmpg = Group.getUserGroups(ilsSession, Group.GROUPTYPE_LOCATION, user.getUserProfileID());
- requestedLocations = ((tmpg != null) && (tmpg.size()>0))? new HashSet<Integer>(tmpg) : null;
+ requestedLocations = ((tmpg != null) && (tmpg.size()>0))? tmpg.stream().map(g -> g.getGroupID()).collect(Collectors.toSet()): null;
if (user.getUserProfileAccessLevel() >= UserProfile.ACCESS_MANAGER) {
requestedLocations = null;
}
Modified: trunk/webapp/admin_systemmanagement.jsp
===================================================================
--- trunk/webapp/admin_systemmanagement.jsp 2018-06-03 12:48:40 UTC (rev 1575)
+++ trunk/webapp/admin_systemmanagement.jsp 2018-06-03 12:51:58 UTC (rev 1576)
@@ -6,7 +6,8 @@
<%@ page trimDirectiveWhitespaces="true" %>
<%@ page import="com.resolutions.ils.*" %>
<%@ page import="com.resolutions.ils.data.*" %>
-<%@ page import="java.util.Vector" %>
+<%@ page import="java.util.List" %>
+<%@ page import="java.util.ArrayList" %>
<%@ page import="java.util.Comparator" %>
<%@ page import="java.util.Calendar" %>
<%@ page import="java.util.Properties" %>
@@ -53,7 +54,7 @@
EMailTemplate(String name, String defSubject, String defBody) { this.name = name; this.defSubject = defSubject; this.defBody = defBody; }
}
- Vector<EMailTemplate> emailTemplates = new Vector<EMailTemplate>();
+ List<EMailTemplate> emailTemplates = new ArrayList<EMailTemplate>();
// TODO: Changed these from using ordered number to instead letting us supply a 'properties file save' name
// 0
@@ -899,8 +900,8 @@
}
- Vector announces = Announcement.getAllAnnouncements(ilsSession);
- Vector resources = Resource.getAllResources(ilsSession);
+ List<Announcement> announces = Announcement.getAllAnnouncements(ilsSession);
+ List<Resource> resources = Resource.getAllResources(ilsSession);
final String sort = request.getParameter("sort");
Modified: trunk/webapp/login.jsp
===================================================================
--- trunk/webapp/login.jsp 2018-06-03 12:48:40 UTC (rev 1575)
+++ trunk/webapp/login.jsp 2018-06-03 12:51:58 UTC (rev 1576)
@@ -2,6 +2,8 @@
language="java"
contentType="text/html;charset=utf-8"
%>
+<%@ page import="org.crosswire.webtools.RightsAndRoles" %>
+<%@ page import="org.crosswire.webtools.RightsAndRoles.User" %>
<%@ page import="com.resolutions.ils.*" %>
<%@ page import="com.resolutions.ils.data.*" %>
<%@ page import="java.net.Authenticator"%>
@@ -43,6 +45,8 @@
String action = request.getParameter("action");
if ("logoff".equals(action)) {
session.invalidate();
+ User user = RightsAndRoles.getInstance().getCurrentUser(request, response);
+ if (user != null) RightsAndRoles.getInstance().closeSession(user.getSessionHash(), response);
response.sendRedirect(((initURL == null)?(request.getRequestURI() + "?co="+company.getCompanyID()):initURL));
return;
}
@@ -91,7 +95,11 @@
}
}
session.setAttribute("ilsSession", ilsSession);
- if (ilsSession != null) eventsLogger.info("Successful Login, User: " + ilsSession.getCurrentUserProfile().getUserProfileNum() + "; from: " + remoteAddr);
+
+ if (ilsSession != null) {
+ RightsAndRoles.getInstance().openSession(ilsSession, response);
+ eventsLogger.info("Successful Login, User: " + ilsSession.getCurrentUserProfile().getUserProfileNum() + "; from: " + remoteAddr);
+ }
}
ilsSession = (ILSSession)session.getAttribute("ilsSession");
if (ilsSession != null) {
Modified: trunk/webapp/report_employeecourseatt.jsp
===================================================================
--- trunk/webapp/report_employeecourseatt.jsp 2018-06-03 12:48:40 UTC (rev 1575)
+++ trunk/webapp/report_employeecourseatt.jsp 2018-06-03 12:51:58 UTC (rev 1576)
@@ -4,7 +4,8 @@
%>
<%@ page import="com.resolutions.ils.*" %>
<%@ page import="com.resolutions.ils.data.*" %>
-<%@ page import="java.util.Vector" %>
+<%@ page import="java.util.List" %>
+<%@ page import="java.util.ArrayList" %>
<%@ page import="java.util.Set" %>
<%@ page import="java.util.Map" %>
<%@ page import="java.util.HashSet" %>
@@ -84,16 +85,16 @@
}
- Vector<Course> courses = Course.getAllUserCourses(ilsSession, current.getUserProfileID());
+ List<Course> courses = Course.getAllUserCourses(ilsSession, current.getUserProfileID());
int wordNum = 0;
Collection<Course> curricula = Course.getUserCurricula(ilsSession, current.getUserProfileID());
// map all courses to their parent curriculum
- HashMap<Integer, Integer> courseCurriculum = new HashMap<Integer, Integer>();
- HashMap<Integer, Boolean> courseSupressRetake = new HashMap<Integer, Boolean>();
- HashMap<Integer, Course> curriculaList = new HashMap<Integer, Course>();
- HashMap<Integer, HashSet<CourseAttempt>> courseCourseAttempts = new HashMap<Integer, HashSet<CourseAttempt>>();
+ Map<Integer, Integer> courseCurriculum = new HashMap<Integer, Integer>();
+ Map<Integer, Boolean> courseSupressRetake = new HashMap<Integer, Boolean>();
+ Map<Integer, Course> curriculaList = new HashMap<Integer, Course>();
+ Map<Integer, Set<CourseAttempt>> courseCourseAttempts = new HashMap<Integer, Set<CourseAttempt>>();
for (Course cur : curricula) {
curriculaList.put(cur.getCourseID(), cur);
for (Course c : Course.getCurriculumCourses(ilsSession, cur.getCourseID())) {
@@ -103,13 +104,13 @@
}
courses.addAll(curricula);
- Vector<CourseAttempt> courseAttempts = new Vector<CourseAttempt>();
+ List<CourseAttempt> courseAttempts = new ArrayList<CourseAttempt>();
for (int j = 0; j < courses.size(); j++) {
Course mainCourse = (Course)courses.get(j);
- HashSet<CourseAttempt> meCourseAttempts = new HashSet<CourseAttempt>();
+ Set<CourseAttempt> meCourseAttempts = new HashSet<CourseAttempt>();
courseCourseAttempts.put(mainCourse.getCourseID(), meCourseAttempts);
logger.debug("processing course: " + mainCourse.getCourseName());
- Vector cas = CourseAttempt.getUserCourseAttempts(ilsSession, current.getUserProfileID(), mainCourse.getCourseID());
+ List<CourseAttempt> cas = CourseAttempt.getUserCourseAttempts(ilsSession, current.getUserProfileID(), mainCourse.getCourseID());
boolean nonExpired = false;
for (int i = 0; i < cas.size() + 1; i++) {
CourseAttempt ca = null;
@@ -375,7 +376,7 @@
<%!
-public static String getCourseHTML(Vector<CourseAttempt> courseAttempts, CourseAttempt ca, boolean managing, UserProfile user, int wordNum, String headerAddition, String subClassAddition, boolean supressRetake, HashMap<Integer, Integer> courseCurriculum, HashMap<Integer, Course> curriculaList, Vector<Course>courses, HashMap<Integer, HashSet<CourseAttempt>>courseCourseAttempts) {
+public static String getCourseHTML(List<CourseAttempt> courseAttempts, CourseAttempt ca, boolean managing, UserProfile user, int wordNum, String headerAddition, String subClassAddition, boolean supressRetake, Map<Integer, Integer> courseCurriculum, Map<Integer, Course> curriculaList, List<Course> courses, Map<Integer, Set<CourseAttempt>>courseCourseAttempts) {
if (subClassAddition == null) subClassAddition = "";
else subClassAddition += " ";
@@ -409,7 +410,7 @@
return out.toString();
}
-public static String getCurriculumHTML(HashMap<Integer, Boolean> courseSupressRetake, HashMap<Integer, Integer> courseCurriculum, Vector<CourseAttempt> courseAttempts, CourseAttempt caCur, boolean managing, UserProfile user, int wordNum, HashMap<Integer, Course> curriculaList, Vector<Course>courses, HashMap<Integer, HashSet<CourseAttempt>>courseCourseAttempts) {
+public static String getCurriculumHTML(Map<Integer, Boolean> courseSupressRetake, Map<Integer, Integer> courseCurriculum, List<CourseAttempt> courseAttempts, CourseAttempt caCur, boolean managing, UserProfile user, int wordNum, Map<Integer, Course> curriculaList, List<Course> courses, Map<Integer, Set<CourseAttempt>>courseCourseAttempts) {
Logger logger = Logger.getLogger("getCurriculumHTML");
@@ -441,7 +442,7 @@
}
-public static String getCourseAttemptHTML(CourseAttempt ca, boolean managing, UserProfile user, int wordNum, boolean supressRetake, HashMap<Integer, Integer> courseCurriculum, HashMap<Integer, Course> curriculaList, Vector<Course>courses, HashMap<Integer, HashSet<CourseAttempt>>courseCourseAttempts) {
+public static String getCourseAttemptHTML(CourseAttempt ca, boolean managing, UserProfile user, int wordNum, boolean supressRetake, Map<Integer, Integer> courseCurriculum, Map<Integer, Course> curriculaList, List<Course> courses, Map<Integer, Set<CourseAttempt>>courseCourseAttempts) {
boolean supressCert = false;
// are we IN a curriculum?
@@ -455,7 +456,7 @@
Course curr = curriculaList.get(ca.getCourseAttemptCourseID());
if (curr != null) {
supressCert = !curr.isCourseCurriculumCertificate();
- HashMap<String, Object>values = new HashMap<String, Object>();
+ Map<String, Object>values = new HashMap<String, Object>();
computeCurriculumStats(curr.getCourseID(), courses, courseCurriculum, courseCourseAttempts, values);
int timeFrame = (Integer)values.get("timeFrame");
long sDate = (Long)values.get("startDate");
@@ -531,7 +532,7 @@
return out.toString();
}
-public static void computeCurriculumStats(int curriculumID, Vector<Course> courses, HashMap<Integer, Integer> courseCurriculum, HashMap<Integer, HashSet<CourseAttempt>> courseCourseAttempts, HashMap<String, Object>values) {
+public static void computeCurriculumStats(int curriculumID, List<Course> courses, Map<Integer, Integer> courseCurriculum, Map<Integer, Set<CourseAttempt>> courseCourseAttempts, Map<String, Object>values) {
int timeFrame = 0;
long startDate = 0;
long endDate = 0;
Modified: trunk/webapp/report_pending_summary.jsp
===================================================================
--- trunk/webapp/report_pending_summary.jsp 2018-06-03 12:48:40 UTC (rev 1575)
+++ trunk/webapp/report_pending_summary.jsp 2018-06-03 12:51:58 UTC (rev 1576)
@@ -3,7 +3,7 @@
language="java" contentType="text/html;charset=utf-8" %>
<%@ page import="com.resolutions.ils.*" %>
<%@ page import="com.resolutions.ils.data.*" %>
-<%@ page import="java.util.Vector" %>
+<%@ page import="java.util.List" %>
<%@ page import="java.util.Comparator" %>
<%@ page import="java.util.Date" %>
<%@ page import="java.io.File" %>
@@ -30,7 +30,7 @@
return;
}
- Vector userProfiles = null;
+ List<UserProfile> userProfiles = null;
SimpleDateFormat df = new SimpleDateFormat("MM/dd/yyyy");
String action = request.getParameter("action");
@@ -101,7 +101,7 @@
tmp = request.getParameter("statusID");
int statusID = (tmp == null) ? 1 : Integer.parseInt(tmp);
int limitToManager = -1;
- Vector locations = null;
+ List<Group> locations = null;
if (user.getUserProfileAccessLevel() <= UserProfile.ACCESS_MANAGER) {
limitToManager = user.getUserProfileID();
locations = Group.getManagerGroups(ilsSession, Group.GROUPTYPE_LOCATION, limitToManager);
@@ -110,7 +110,7 @@
locations = Group.getAllGroups(ilsSession, Group.GROUPTYPE_LOCATION);
}
- Vector roles = Group.getAllGroups(ilsSession, Group.GROUPTYPE_ROLE);
+ List<Group> roles = Group.getAllGroups(ilsSession, Group.GROUPTYPE_ROLE);
if ("csv".equals(action)) {
@@ -129,7 +129,7 @@
String lastDatasetType = (String)session.getAttribute("lastDatasetType");
if ("PSgroupTotals".equals(lastDatasetType)) {
- userProfiles = (Vector)session.getAttribute("lastDataset");
+ userProfiles = (List<UserProfile>)session.getAttribute("lastDataset");
if (sort != null) {
final String sortColumn = sort;
java.util.Collections.sort(userProfiles, new Comparator() {
@@ -165,7 +165,7 @@
if (currentLocationID < 0) {
- Vector tmpg = Group.getUserGroups(ilsSession, Group.GROUPTYPE_LOCATION, user.getUserProfileID());
+ List<Group> tmpg = Group.getUserGroups(ilsSession, Group.GROUPTYPE_LOCATION, user.getUserProfileID());
currentLocationID = ((tmpg != null) && (tmpg.size()>0)) ? ((Group)tmpg.get(0)).getGroupID() : -1;
if (user.getUserProfileAccessLevel() > UserProfile.ACCESS_MANAGER) {
currentLocationID = -1;
Modified: trunk/webapp/report_recurrent_training.jsp
===================================================================
--- trunk/webapp/report_recurrent_training.jsp 2018-06-03 12:48:40 UTC (rev 1575)
+++ trunk/webapp/report_recurrent_training.jsp 2018-06-03 12:51:58 UTC (rev 1576)
@@ -3,7 +3,7 @@
<%@ page trimDirectiveWhitespaces="true" %>
<%@ page import="com.resolutions.ils.*" %>
<%@ page import="com.resolutions.ils.data.*" %>
-<%@ page import="java.util.Vector" %>
+<%@ page import="java.util.List" %>
<%@ page import="java.util.Comparator" %>
<%@ page import="java.util.Date" %>
<%@ page import="java.text.SimpleDateFormat" %>
@@ -41,7 +41,7 @@
val = (String)request.getParameter("sort"); if (val != null) sortOrder = val;
session.setAttribute("recurrentSort", sortOrder);
- Vector<UserProfile> userProfiles = null;
+ List<UserProfile> userProfiles = null;
SimpleDateFormat df = new SimpleDateFormat("MM/dd/yyyy");
String action = request.getParameter("action");
More information about the Ils-source
mailing list