]> source.dussan.org Git - archiva.git/commitdiff
update old legacy path code for new version of Struts
authorBrett Porter <brett@apache.org>
Sat, 22 Feb 2014 11:45:14 +0000 (11:45 +0000)
committerBrett Porter <brett@apache.org>
Sat, 22 Feb 2014 11:45:14 +0000 (11:45 +0000)
git-svn-id: https://svn.apache.org/repos/asf/archiva/branches/archiva-1.3.x@1570823 13f79535-47bb-0310-9956-ffa450edef68

archiva-modules/archiva-web/archiva-webapp/src/main/webapp/WEB-INF/jsp/admin/addLegacyArtifactPath.jsp

index 3103403b044c49e1a05b41656817ac78111961df..d93a193f44e89b27cb0731e7d85667543ad52881 100644 (file)
       var group = path.indexOf( "/" );\r
       if ( group > 0 )\r
       {\r
-          document.getElementById( "addLegacyArtifactPath_groupId" ).value\r
+          document.getElementById( "addLegacyArtifactPath_commit_groupId" ).value\r
               = path.substring( 0, group );\r
           group += 1;\r
           var type = path.indexOf( "/", group );\r
           if ( type > 0 )\r
           {\r
-              document.getElementById( "addLegacyArtifactPath_type" ).value\r
+              document.getElementById( "addLegacyArtifactPath_commit_type" ).value\r
                   = path.substring( group, type - 1 );\r
           }\r
           type += 1;\r
@@ -56,9 +56,9 @@
           var ext = path.lastIndexOf( "." );\r
           if ( version > 0 )\r
           {\r
-              document.getElementById( "addLegacyArtifactPath_artifactId" ).value\r
+              document.getElementById( "addLegacyArtifactPath_commit_artifactId" ).value\r
                   = path.substring( type, version );\r
-              document.getElementById( "addLegacyArtifactPath_version" ).value\r
+              document.getElementById( "addLegacyArtifactPath_commit_version" ).value\r
                   = path.substring( version + 1, ext );\r
           }\r
 \r
     <s:submit value="Add Legacy Artifact Path"/>\r
   </s:form>\r
 \r
-  <script type="text/javascript">\r
-    var ref = document.getElementById("addLegacyArtifactPath_legacyArtifactPath_artifact").value;\r
-    var i = ref.indexOf( ":" );\r
-    document.getElementById("addLegacyArtifactPath_groupId").value = ref.substring( 0, i );\r
-    var j = i + 1;\r
-    var i = ref.indexOf( ":", j );\r
-    document.getElementById("addLegacyArtifactPath_artifactId").value = ref.substring( j, i );\r
-    var j = i + 1;\r
-    var i = ref.indexOf( ":", j );\r
-    document.getElementById("addLegacyArtifactPath_version").value = ref.substring( j, i );\r
-    var j = i + 1;\r
-    var i = ref.indexOf( ":", j );\r
-    document.getElementById("addLegacyArtifactPath_classifier").value = ref.substring( j, i );\r
-\r
-    document.getElementById("addLegacyArtifactPath_legacyArtifactPath_path").focus();\r
-  </script>\r
-\r
 </div>\r
 \r
 </body>\r