Changeset 3159c51


Ignore:
Timestamp:
Feb 21, 2018 12:54:56 PM (3 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
61ae0a5
Parents:
f00bf7d
Message:

Console: Hide options on /configupdate if a package (ticket #2172)
or if not advanced

Location:
apps/routerconsole
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • apps/routerconsole/java/src/net/i2p/router/web/ConfigUpdateHandler.java

    rf00bf7d r3159c51  
    239239        }
    240240       
    241         changes.put(PROP_SHOULD_PROXY, Boolean.toString(_updateThroughProxy));
    242         changes.put(PROP_SHOULD_PROXY_NEWS, Boolean.toString(_newsThroughProxy));
    243241        if (isAdvanced()) {
    244             changes.put(PROP_UPDATE_UNSIGNED, Boolean.toString(_updateUnsigned));
    245             changes.put(PROP_UPDATE_DEV_SU3, Boolean.toString(_updateDevSU3));
     242            changes.put(PROP_SHOULD_PROXY_NEWS, Boolean.toString(_newsThroughProxy));
     243            if (!_context.getBooleanProperty(PROP_UPDATE_DISABLED)) {
     244                changes.put(PROP_SHOULD_PROXY, Boolean.toString(_updateThroughProxy));
     245                changes.put(PROP_UPDATE_UNSIGNED, Boolean.toString(_updateUnsigned));
     246                changes.put(PROP_UPDATE_DEV_SU3, Boolean.toString(_updateDevSU3));
     247            }
    246248        }
    247249       
  • apps/routerconsole/jsp/configupdate.jsp

    rf00bf7d r3159c51  
    4646          <td><jsp:getProperty name="updatehelper" property="updatePolicySelectBox" /></td></tr>
    4747    <% }   // if canInstall %>
     48    <% if (updatehelper.isAdvanced()) { %>
    4849        <tr><td align="right"><label for="newsThroughProxy"><b><%=intl._t("Fetch news through the eepProxy?")%></b></label></td>
    4950          <td><jsp:getProperty name="updatehelper" property="newsThroughProxy" /></td></tr>
     51      <% if (updatehelper.canInstall()) { %>
    5052        <tr><td align="right"><b><label for="updateThroughProxy"><%=intl._t("Update through the eepProxy?")%></b></label></td>
    5153          <td><jsp:getProperty name="updatehelper" property="updateThroughProxy" /></td></tr>
    52       <% if (updatehelper.isAdvanced()) { %>
     54      <% }   // if canInstall %>
    5355        <tr><td align="right"><b><%=intl._t("eepProxy host")%>:</b></td>
    5456          <td><input type="text" size="10" name="proxyHost" value="<jsp:getProperty name="updatehelper" property="proxyHost" />" /></td>
    5557        </tr><tr><td align="right"><b><%=intl._t("eepProxy port")%>:</b></td>
    5658          <td><input type="text" size="10" name="proxyPort" value="<jsp:getProperty name="updatehelper" property="proxyPort" />" /></td></tr>
    57       <% }   // if isAdvanced %>
     59    <% }   // if isAdvanced %>
    5860    <% if (updatehelper.canInstall()) { %>
    5961      <% if (updatehelper.isAdvanced()) { %>
Note: See TracChangeset for help on using the changeset viewer.