Console: Hide client delete button too

This commit is contained in:
zzz
2014-08-10 12:18:18 +00:00
parent c7de4e46c1
commit 6fa2a416be
3 changed files with 8 additions and 3 deletions

View File

@@ -104,7 +104,12 @@ public class ConfigClientsHandler extends FormHandler {
appnum = Integer.parseInt(app);
} catch (NumberFormatException nfe) {}
if (appnum >= 0) {
deleteClient(appnum);
if (_context.getBooleanProperty(ConfigClientsHelper.PROP_ENABLE_CLIENT_CHANGE) ||
isAdvanced()) {
deleteClient(appnum);
} else {
addFormError("Delete client disabled");
}
} else if (pluginsEnabled) {
try {
PluginStarter.stopPlugin(_context, app);

View File

@@ -141,7 +141,7 @@ public class ConfigClientsHelper extends HelperBase {
// show stop button
showStop,
// show delete button, show start button
!isConsole, showStart);
allowEdit && !isConsole, showStart);
}
if (allowEdit && "new".equals(_edit))

View File

@@ -18,7 +18,7 @@ public class RouterVersion {
/** deprecated */
public final static String ID = "Monotone";
public final static String VERSION = CoreVersion.VERSION;
public final static long BUILD = 0;
public final static long BUILD = 1;
/** for example "-test" */
public final static String EXTRA = "";