Author: jonathan Date: Fri Jul 11 12:04:14 2008 New Revision: 19156 URL: http://wso2.org/svn/browse/wso2?view=rev&revision=19156
Log: Improved titling convention for activity queries. Made the code more straightforward at the same time. Modified: trunk/mashup/java/modules/www/search.jsp Modified: trunk/mashup/java/modules/www/search.jsp URL: http://wso2.org/svn/browse/wso2/trunk/mashup/java/modules/www/search.jsp?rev=19156&r1=19155&r2=19156&view=diff ============================================================================== --- trunk/mashup/java/modules/www/search.jsp (original) +++ trunk/mashup/java/modules/www/search.jsp Fri Jul 11 12:04:14 2008 @@ -216,19 +216,24 @@ // Set up the query path to search activity log queryPath = MashupConstants.ACTIVITY_QUERY_PATH; - if (searchScope.equals("")) { - queryTitle = "Recent "; - } else if (onMashup != null && !onMashup.equals("")) { - queryTitle = "Mashup " + onMashup + " "; - } else { - queryTitle = ((searchScope.equals(currentUser) && !isFeed) ? "My" : - RegistryUtils.getFullName(request, searchScope) + "'s") + " recent "; - } + + if (searchScope.equals(currentUser) && !isFeed) { + queryTitle = "My recent"; + } else if (!searchScope.equals("")) { + queryTitle = RegistryUtils.getFullName(request, searchScope) + "'s recent"; + } else queryTitle = "Recent"; if (!activity.equalsIgnoreCase("all")) { - queryTitle += activity; + queryTitle += " " + activity; } - queryTitle += " activity (" + paramPeriod + " days)"; + + queryTitle += " activity"; + + if (onMashup != null && !onMashup.equals("")) { + queryTitle += " on " + onMashup; + } + + queryTitle += " (" + paramPeriod + " days)"; queryParams = new String[] { onMashup, _______________________________________________ Mashup-dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/mashup-dev
