]> source.dussan.org Git - archiva.git/commitdiff
[MRM-420] Editing a network proxy creates a new network proxy when saving modifications
authorFabrice Bellingard <bellingard@apache.org>
Fri, 22 Jun 2007 12:00:27 +0000 (12:00 +0000)
committerFabrice Bellingard <bellingard@apache.org>
Fri, 22 Jun 2007 12:00:27 +0000 (12:00 +0000)
git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@549793 13f79535-47bb-0310-9956-ffa450edef68

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

index d371fb121e20c52f342aaa0c70c491b1893b3d1e..bb09274e7f2b98372287fd9475319bc5422cf936 100644 (file)
 <c:choose>
   <c:when test="${mode == 'edit'}">
     <c:set var="addedit" value="Edit" />
-    <c:set var="disableId" value="true" />
+       <c:set var="networkProxyName" value="${proxy.id}" />
   </c:when>
   <c:otherwise>
     <c:set var="addedit" value="Add" />
-    <c:set var="disableId" value="false" />
   </c:otherwise>
 </c:choose>
 
@@ -43,7 +42,7 @@
 
 <div id="contentArea">
 
-  <h2>${addedit} Network Proxy</h2>
+  <h2>${addedit} network proxy: ${networkProxyName}</h2>
 
   <ww:actionerror/> 
   <ww:actionmessage/>
   <ww:form method="post" action="saveNetworkProxy" namespace="/admin">
     <ww:hidden name="mode"/>
     
-    <ww:textfield name="proxy.id" label="Identifier" size="10" required="true"
-      disabled="${disableId}"/>
+       <c:choose>
+         <c:when test="${mode == 'edit'}">
+           <ww:hidden name="proxy.id"/>
+         </c:when>
+         <c:otherwise>
+           <ww:textfield name="proxy.id" label="Identifier" size="10" required="true"/>
+         </c:otherwise>
+       </c:choose>
     
     <%@ include file="/WEB-INF/jsp/admin/include/networkProxyForm.jspf" %>
     <ww:submit value="Save Network Proxy"/>