history.jsp revision 962
0N/ASee LICENSE.txt included in this distribution for the specific
0N/Afile and include the License file at LICENSE.txt.
0N/Aident "@(#)history.jsp 1.1 05/11/11 SMI"
0N/A--%><%@ page import = "javax.servlet.*,
962N/A<% String hcontext = request.getContextPath(); %>
962N/A<script type="text/javascript">
962N/A if (this.className == "filelist") {
962N/A this.setAttribute("style", "display: none;");
962N/A this.className = "filelist-hidden";
962N/A } else if (this.className == "filelist-hidden") {
962N/A this.setAttribute("style", "display: inline;");
962N/A this.className = "filelist";
962N/A if (cr2) { this.style.visibility = 'visible'}
962N/A else {this.style.visibility = 'hidden'} }
962N/A if (!cr1) { this.style.visibility = 'visible'}
962N/A else {this.style.visibility = 'hidden'} }
962N/A // start state should ALWAYS be: first row: r1 hidden, r2 checked ; second row: r1 clicked, (r2 hidden)(optionally)
41N/Aif (path.length() > 0 && valid) {
129N/A String userPage = environment.getUserPage();
129N/A String bugPage = environment.getBugPage();
129N/A String bugRegex = environment.getBugPattern();
88N/A if(bugRegex == null || bugRegex.equals("")) {
88N/A Pattern bugPattern = Pattern.compile(bugRegex);
318N/A String reviewPage = environment.getReviewPage();
318N/A String reviewRegex = environment.getReviewPattern();
318N/A if(reviewRegex == null || reviewRegex.equals("")) {
318N/A Pattern reviewPattern = Pattern.compile(reviewRegex);
256N/A if (!HistoryGuru.getInstance().hasHistory(f)) {
256N/A response.sendError(404, "No history");
836N/A History hist = HistoryGuru.getInstance().getHistory(f);
50N/A response.sendError(404, "No history");
189N/A <td colspan="4"><span class="pagetitle">History log of <a href="<%= context +"/xref" + path %>"><%=path%></a></span></td>
900N/A if (hist.hasFileList()) {
836N/Afor (HistoryEntry entry : hist.getHistoryEntries()) {
836N/A String rev = entry.getRevision();
189N/A if (rev == null || rev.length() == 0) {
836N/A if (entry.isActive()) {
558N/A String rp = Util.URIEncodePath(path);
962N/A%><td> <a name="<%=rev%>" href="<%= context +"/xref" + rp + "?r=" + Util.URIEncode(rev) %>"><%=rev%></a> </td><td align="center">
962N/A <input type="radio" <% if (count==0) {%>style="visibility:hidden"<% } else if (count==1) {%>checked<%} %> name="r1" value="<%=rp%>@<%=rev%>"/>
962N/A <input type="radio" name="r2" <% if (count==0) {%>checked<% } %> value="<%=rp%>@<%=rev%>"/></td><%
836N/A Date date = entry.getDate();
885N/AString author = entry.getAuthor();
885N/A} else if (userPage != null && ! userPage.equals("")) {
345N/Aif (bugPage != null && ! bugPage.equals("")){
318N/A cout=bugPattern.matcher(cout).replaceAll("<a href=\"" + bugPage + "$1\">$1</a>"); }
318N/Aif (reviewPage != null && ! reviewPage.equals("")) {
318N/A cout=reviewPattern.matcher(cout).replaceAll("<a href=\"" + reviewPage + "$1\">$1</a>"); }
836N/ASet<String> files = entry.getFiles();
50N/A jfile = ifile.substring(1);
0N/A %><p><b>Note:</b> No associated file changes are available for revisions with strike-through numbers (eg. <strike>1.45</strike>)</p><%
218N/A %><p class="rssbadge"><a href="<%=context%>/rss<%=Util.URIEncodePath(path)%>"><img src="<%=context%>/<%=environment.getWebappLAF()%>/img/rss.png" width="80" height="15" alt="RSS XML Feed" title="RSS XML Feed of latest changes"/></a></p><%