notification-portlet-webapp/src/main/java/org/jasig/portlet/notice/service/ssp/SSPSchoolIdPersonLookup.java
private String getSchoolId(PortletRequest request) {
        PortletPreferences prefs = request.getPreferences();
        String schoolIdAttributeName = prefs.getValue("SSPTaskNotificationService.schoolIdAttribute", "schoolId");

        Map<String, String> userInfo = (Map<String, String>)request.getAttribute(PortletRequest.USER_INFO);
        String studentId = userInfo.get(schoolIdAttributeName);
        if (!StringUtils.isEmpty(studentId)) {
            return studentId;
        }

        // if not found, fall back to username.
        studentId = userInfo.get(USERNAME_ATTRIBUTE);

        return studentId;
    }
private String getSchoolId(PortletRequest request) {
        PortletPreferences prefs = request.getPreferences();
        String schoolIdAttributeName = prefs.getValue("SSPTaskNotificationService.schoolIdAttribute", "schoolId");

        Map<String, String> userInfo = (Map<String, String>)request.getAttribute(PortletRequest.USER_INFO);
        String studentId = userInfo.get(schoolIdAttributeName);
        if (!StringUtils.isEmpty(studentId)) {
            return studentId;
        }

        // if not found, fall back to username.
        studentId = userInfo.get(USERNAME_ATTRIBUTE);

        return studentId;
    }
private String getSchoolId ( PortletRequest request ) { PortletPreferences prefs = request . getPreferences ( ) ; String schoolIdAttributeName = prefs . getValue ( "SSPTaskNotificationService.schoolIdAttribute" , "schoolId" ) ; Map < String , String > userInfo = ( Map < String , String > ) request . getAttribute ( PortletRequest . USER_INFO ) ; String studentId = userInfo . get ( schoolIdAttributeName ) ; if ( ! StringUtils . isEmpty ( studentId ) ) { return studentId ; } // if not found, fall back to username. studentId = userInfo . get ( USERNAME_ATTRIBUTE ) ; return studentId ; }
Get the schoolId value from the request.

@param request the portlet request
@return the school id.   May return null if the school id is not available
Get the schoolId value from the request .