]> source.dussan.org Git - archiva.git/commitdiff
MRM-381 Applied patch submitted by Teodoro Cue. Field 'md5' was changed to 'q' in...
authorMaria Odea B. Ching <oching@apache.org>
Thu, 31 May 2007 10:44:46 +0000 (10:44 +0000)
committerMaria Odea B. Ching <oching@apache.org>
Thu, 31 May 2007 10:44:46 +0000 (10:44 +0000)
git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@543109 13f79535-47bb-0310-9956-ffa450edef68

archiva-web/archiva-webapp/src/main/resources/org/apache/maven/archiva/web/action/SearchAction-checksumSearch-validation.xml
archiva-web/archiva-webapp/src/main/resources/xwork.xml
archiva-web/archiva-webapp/src/main/webapp/WEB-INF/jsp/findArtifact.jsp

index 3fedfbc93010d6929b9a78883768dd934b05c547..712e2910af63747499a073f89749691bbb932234 100644 (file)
@@ -22,7 +22,7 @@
     "http://www.opensymphony.com/xwork/xwork-validator-1.0.2.dtd">
 
 <validators>
-  <field name="md5">
+  <field name="q">
     <field-validator type="requiredstring">
       <message>
         You must select a file, or enter the checksum. If the file was given and you receive this message,
index 79aeb4a7eb1d6ddf96cbe82cb1bcfefae4b93507..804d537ec5845ed47a1f64c695d60d328753ea42 100644 (file)
       <result name="results">/WEB-INF/jsp/results.jsp</result>
       <result name="error">/WEB-INF/jsp/findArtifact.jsp</result>
       <result name="artifact" type="redirect">
-        /browse/${searchResults[0].groupId}/${searchResults[0].artifactId}/${searchResults[0].version}
+        /browse/${results.getHits().get(0).groupId}/${results.getHits().get(0).artifactId}/${results.getHits().get(0).version}
       </result>
     </action>
 
index 70f956100c4af8f39cdb00e1724ef0eef8ab09b7..1647c9a566cde4b70cef239b29ba64af85630129 100644 (file)
@@ -55,7 +55,8 @@
     </noscript>
 
     <ww:form method="POST" action="checksumSearch" namespace="/"
-             onsubmit="this.md5.value = generateMd5(this.file.value,this.md5.value); this.file.disabled = true">
+             onsubmit="this.q.value = generateMd5(this.file.value,this.md5.value); this.file.disabled = true;">
+      <ww:hidden name="q"/>
       <ww:if test="${sessionScope.uiOptions.appletFindEnabled}">     
       <tr>
         <td class="tdLabel"><label for="checksumSearch_file" class="label">Search for:</label></td>