summaryrefslogtreecommitdiff
path: root/pages/setup.ecpp
diff options
context:
space:
mode:
Diffstat (limited to 'pages/setup.ecpp')
-rw-r--r--pages/setup.ecpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/pages/setup.ecpp b/pages/setup.ecpp
index cc1db8c..845e4b7 100644
--- a/pages/setup.ecpp
+++ b/pages/setup.ecpp
@@ -3,6 +3,7 @@
#include <vdr/tools.h>
#include "setup.h"
#include "tools.h"
+#include "users.h"
#include "i18n.h"
using namespace vdrlive;
@@ -33,7 +34,9 @@ using namespace std;
</%session>
<%include>page_init.eh</%include>
<%cpp>
-if (!logged_in && LiveSetup().UseAuth()) return reply.redirect("login.html");
+if (!logged_in && LiveSetup().UseAuth() ) return reply.redirect("login.html");
+if (!cUser::CurrentUserHasRightTo(UR_EDITSETUP))
+ throw HtmlError( tr("Sorry, no permission. Please contact your administrator!") );
#define SELECTIF(x) reply.out() << ( (x) ? "selected=\"selected\"" : "" );
#define CHECKIF(x) reply.out() << ( (x) ? "checked=\"checked\"" : "" );
@@ -152,6 +155,10 @@ if (!logged_in && LiveSetup().UseAuth()) return reply.redirect("login.html");
<td><input type="password" name="pass" value="<$ pass $>" id="pass" onchange="setauthchanged(this)" /></td>
</tr>
<tr>
+ <td class="label"><div class="withmargin"><a href="users.html"><$ tr("User management") $></a></div></td>
+ <td/>
+ </tr>
+ <tr>
<td class="label"><div class="withmargin"><$ tr("Local net (no login required)") $>:</div></td>
<td><input type="text" name="localnetmask" value="<$ localnetmask $>" id="localnetmask" /></td>
</tr>
@@ -282,4 +289,3 @@ if (!logged_in && LiveSetup().UseAuth()) return reply.redirect("login.html");
<%include>page_exit.eh</%include>
-