webdemo UI
authorivan <ivan>
Sun, 6 Jun 2010 06:29:36 +0000 (06:29 +0000)
committerivan <ivan>
Sun, 6 Jun 2010 06:29:36 +0000 (06:29 +0000)
httemplate/edit/process/access_group.html
httemplate/edit/process/access_user.html
httemplate/edit/process/agent.cgi

index ab25cb3..2d125c3 100644 (file)
@@ -1,6 +1,3 @@
-% if ( $conf->exists('disable_acl_changes') ) {
-  ACL changes disabled in public demo.
-% } else {
 <% include( 'elements/process.html',
                'table'       => 'access_group',
                'viewall_dir' => 'browse',
                },
            )
 %>
-% }
 <%init>
 
 die "access denied"
   unless $FS::CurrentUser::CurrentUser->access_right('Configuration');
 
-my $conf = new FS::Conf;
+if ( FS::Conf->new->exists('disable_acl_changes') ) {
+  errorpage('ACL changes disabled in public demo.');
+  die "shouldn't be reached";
+}
 
 </%init>
index d8a752a..e6258a9 100644 (file)
@@ -1,6 +1,3 @@
-% if ( FS::Conf->new->exists('disable_acl_changes') ) {
-  ACL changes disabled in public demo.
-% } else {
 %  if ( $cgi->param('_password') ne $cgi->param('_password2') ) {
 %    $cgi->param('error', "The passwords do not match");
 %    print $cgi->redirect(popurl(2) . "access_user.html?" . $cgi->query_string);
              )
 %>
 %   }
-% }
 <%init>
 
 die "access denied"
   unless $FS::CurrentUser::CurrentUser->access_right('Configuration');
 
+if ( FS::Conf->new->exists('disable_acl_changes') ) {
+  errorpage('ACL changes disabled in public demo.');
+  die "shouldn't be reached";
+}
+
 </%init>
index 3cdf40c..e776d28 100755 (executable)
@@ -13,4 +13,9 @@
 die "access denied"
   unless $FS::CurrentUser::CurrentUser->access_right('Configuration');
 
+if ( FS::Conf->new->exists('disable_acl_changes') ) {
+  errorpage('ACL changes disabled in public demo.');
+  die "shouldn't be reached";
+}
+
 </%init>