summaryrefslogtreecommitdiff
path: root/httemplate/browse/access_user.html
diff options
context:
space:
mode:
authorivan <ivan>2006-08-23 22:25:39 +0000
committerivan <ivan>2006-08-23 22:25:39 +0000
commit3ce7691203a7737406bf2d4442f7fd84b81f847e (patch)
tree90658b097da96772224f04771888ac6ca1a940aa /httemplate/browse/access_user.html
parent15e561850b61b10a92a46d8f3e316d53d4970087 (diff)
Will things ever be the same again?
It's the final masonize
Diffstat (limited to 'httemplate/browse/access_user.html')
-rw-r--r--httemplate/browse/access_user.html161
1 files changed, 81 insertions, 80 deletions
diff --git a/httemplate/browse/access_user.html b/httemplate/browse/access_user.html
index 5b787977d..05384289a 100644
--- a/httemplate/browse/access_user.html
+++ b/httemplate/browse/access_user.html
@@ -1,83 +1,84 @@
-<%
-
-my $html_init =
- "Internal users have access to the back-office interface. Typically, this is your employees and contractors, but in a VISP setup, you can also add accounts for your reseller's employees. It is <B>highly recommended</B> to add a <B>separate account for each person</B> rather than using role accounts.<BR><BR>".
- qq!<A HREF="${p}edit/access_user.html"><I>Add an internal user</I></A><BR><BR>!;
-
-#false laziness w/part_pkg.cgi
-my %search = ();
-my $search = '';
-unless ( $cgi->param('showdisabled') ) {
- %search = ( 'disabled' => '' );
- $search = "( disabled = '' OR disabled IS NULL )";
-}
-
-#false laziness w/access_group.html & agent_type.cgi
-my $groups_sub = sub {
- my $access_user = shift;
-
- [ map {
- my $access_usergroup = $_;
- my $access_group = $access_usergroup->access_group;
- [
- {
- 'data' => $access_group->groupname,
- 'align' => 'left',
- 'link' =>
- $p. 'edit/access_group.html?'. $access_usergroup->groupnum,
- },
- ];
- }
- grep { $_->access_group # and ! $_->access_group->disabled
- }
- $access_user->access_usergroup,
-
- ];
-
-};
-
-my $posttotal;
-if ( $cgi->param('showdisabled') ) {
- $cgi->param('showdisabled', 0);
- $posttotal = '( <a href="'. $cgi->self_url. '">hide disabled users</a> )';
- $cgi->param('showdisabled', 1);
-} else {
- $cgi->param('showdisabled', 1);
- $posttotal = '( <a href="'. $cgi->self_url. '">show disabled users</a> )';
- $cgi->param('showdisabled', 0);
-}
-
-my $count_query = 'SELECT COUNT(*) FROM access_user';
-$count_query .= " WHERE $search"
- if $search;
-
-my $link = [ $p.'edit/access_user.html?', 'usernum' ];
-
-my @header = ( '#', 'Username' );
-my @fields = ( 'usernum', 'username' );
-my $align = 'rl';
-my @links = ( $link, $link );
-my @style = ( '', '' );
-
-#false laziness w/part_pkg.cgi
-#unless ( $cgi->param('showdisabled') ) { #its been reversed already
-if ( $cgi->param('showdisabled') ) { #its been reversed already
- push @header, 'Status';
- push @fields, sub { shift->disabled
- ? '<FONT COLOR="#FF0000">DISABLED</FONT>'
- : '<FONT COLOR="#00CC00">Active</FONT>'
- };
- push @links, '';
- $align .= 'c';
- push @style, 'b';
-}
-
-push @header, 'Full name', 'Groups';
-push @fields, 'name', $groups_sub;
-push @links, $link, '';
-$align .= 'll';
-
-%><%= include( 'elements/browse.html',
+%
+%
+%my $html_init =
+% "Internal users have access to the back-office interface. Typically, this is your employees and contractors, but in a VISP setup, you can also add accounts for your reseller's employees. It is <B>highly recommended</B> to add a <B>separate account for each person</B> rather than using role accounts.<BR><BR>".
+% qq!<A HREF="${p}edit/access_user.html"><I>Add an internal user</I></A><BR><BR>!;
+%
+%#false laziness w/part_pkg.cgi
+%my %search = ();
+%my $search = '';
+%unless ( $cgi->param('showdisabled') ) {
+% %search = ( 'disabled' => '' );
+% $search = "( disabled = '' OR disabled IS NULL )";
+%}
+%
+%#false laziness w/access_group.html & agent_type.cgi
+%my $groups_sub = sub {
+% my $access_user = shift;
+%
+% [ map {
+% my $access_usergroup = $_;
+% my $access_group = $access_usergroup->access_group;
+% [
+% {
+% 'data' => $access_group->groupname,
+% 'align' => 'left',
+% 'link' =>
+% $p. 'edit/access_group.html?'. $access_usergroup->groupnum,
+% },
+% ];
+% }
+% grep { $_->access_group # and ! $_->access_group->disabled
+% }
+% $access_user->access_usergroup,
+%
+% ];
+%
+%};
+%
+%my $posttotal;
+%if ( $cgi->param('showdisabled') ) {
+% $cgi->param('showdisabled', 0);
+% $posttotal = '( <a href="'. $cgi->self_url. '">hide disabled users</a> )';
+% $cgi->param('showdisabled', 1);
+%} else {
+% $cgi->param('showdisabled', 1);
+% $posttotal = '( <a href="'. $cgi->self_url. '">show disabled users</a> )';
+% $cgi->param('showdisabled', 0);
+%}
+%
+%my $count_query = 'SELECT COUNT(*) FROM access_user';
+%$count_query .= " WHERE $search"
+% if $search;
+%
+%my $link = [ $p.'edit/access_user.html?', 'usernum' ];
+%
+%my @header = ( '#', 'Username' );
+%my @fields = ( 'usernum', 'username' );
+%my $align = 'rl';
+%my @links = ( $link, $link );
+%my @style = ( '', '' );
+%
+%#false laziness w/part_pkg.cgi
+%#unless ( $cgi->param('showdisabled') ) { #its been reversed already
+%if ( $cgi->param('showdisabled') ) { #its been reversed already
+% push @header, 'Status';
+% push @fields, sub { shift->disabled
+% ? '<FONT COLOR="#FF0000">DISABLED</FONT>'
+% : '<FONT COLOR="#00CC00">Active</FONT>'
+% };
+% push @links, '';
+% $align .= 'c';
+% push @style, 'b';
+%}
+%
+%push @header, 'Full name', 'Groups';
+%push @fields, 'name', $groups_sub;
+%push @links, $link, '';
+%$align .= 'll';
+%
+%
+<% include( 'elements/browse.html',
'title' => 'Internal Users',
'menubar' => [ #'Main menu' => $p,
'Internal access groups' => $p.'browse/access_group.html',