Skip to content

Commit

Permalink
Fixed admin variable
Browse files Browse the repository at this point in the history
  • Loading branch information
roshnaeem committed Apr 17, 2021
1 parent d17dac2 commit 80641e7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion cgi/user2.pl
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,6 @@
};
};
};
$template_data_ref->{admin_flag} = $admin;

}

Expand Down
4 changes: 2 additions & 2 deletions templates/user_form2.tt.html
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
[% FOREACH section IN sections %]

[% IF section.name %]
<fieldset [% IF section.id == "teams" && teams_flag %] class="tr_teams" [% ELSIF admin_flag && section.id == "administrator" %] style = "display:block" [% ELSIF !admin_flag && section.id == "administrator" %] style = "display:none" [% END %]>
<fieldset [% IF section.id == "teams" && teams_flag %] class="tr_teams" [% ELSIF admin && section.id == "administrator" %] style = "display:block" [% ELSIF !admin && section.id == "administrator" %] style = "display:none" [% END %]>
<legend [% IF section.id == "administrator" %] style = "background-color:#ffcccc"[% END %]>[% section.name %]</legend>
[% END %]

Expand Down Expand Up @@ -121,7 +121,7 @@
<p>[% lang("unsubscribe_info") %]</p>
[% END %]

[% IF admin_flag %]
[% IF admin %]
<label>
<input type="checkbox" name="delete" onchange="if (this.checked) { if (!confirm('This action cannot be undone, are you sure you want to delete the user?')) { this.checked = false }}" />
[% lang("delete_user") %]
Expand Down

0 comments on commit 80641e7

Please sign in to comment.