[Rt-commit] rt branch, 4.6-theme/Admin-CustomRoles-pages, created. rt-4.4.4-212-gebafa07fd
Craig Kaiser
craig at bestpractical.com
Mon May 6 17:00:41 EDT 2019
The branch, 4.6-theme/Admin-CustomRoles-pages has been created
at ebafa07fd77b5aeb91a365b7d714d340e95478b5 (commit)
- Log -----------------------------------------------------------------
commit ebafa07fd77b5aeb91a365b7d714d340e95478b5
Author: Craig Kaiser <craig at bestpractical.com>
Date: Mon May 6 16:55:40 2019 -0400
Migrate Admin/CustomRoles pages to elevator theme
diff --git a/share/html/Admin/CustomRoles/Modify.html b/share/html/Admin/CustomRoles/Modify.html
index b596f6f3c..0890d068e 100644
--- a/share/html/Admin/CustomRoles/Modify.html
+++ b/share/html/Admin/CustomRoles/Modify.html
@@ -54,51 +54,79 @@
<form action="<%RT->Config->Get('WebPath')%>/Admin/CustomRoles/Modify.html" name="ModifyCustomRole" method="post" enctype="multipart/form-data">
<input type="hidden" class="hidden" name="id" value="<% $Create ? 'new': $RoleObj->Id %>" />
% $m->callback( CallbackName => 'FormStart', Create => $Create, ARGSRef => \%ARGS );
-<table>
-<tr><td align="right"><&|/l&>Role Name</&>:</td><td colspan="3">
-<input type="text" name="Name" value="<% $Create ? "" : $RoleObj->Name || $Name %>" />
-</td></tr>
-
-<tr><td align="right"><&|/l&>Description</&>:</td>
-<td colspan="3"><input type="text" name="Description" value="<% $Create ? "" : $RoleObj->Description || $Description || '' %>" size="60" /></td>
-</tr>
-
-<tr><td align="right"><&|/l&>Entry Hint</&>:</td>
-<td colspan="3"><input type="text" name="EntryHint" value="<% $Create ? "" : $RoleObj->EntryHint || $EntryHint || '' %>" size="60" /></td>
-</tr>
-
-<tr><td align="right"><input type="checkbox" class="checkbox" id="Multiple" name="Multiple" value="1"
+<div class="col-md-12">
+ <div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Role Name</&>:
+ </div>
+ <div class="value col-md-9">
+ <input class="form-control" type="text" name="Name" value="<% $Create ? "" : $RoleObj->Name || $Name %>" />
+ </div>
+ </div>
+
+ <div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Description</&>:
+ </div>
+ <div class="value col-md-9">
+ <input class="form-control" type="text" name="Description" value="<% $Create ? "" : $RoleObj->Description || $Description || '' %>" size="60" />
+ </div>
+ </div>
+
+ <div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Entry Hint</&>:
+ </div>
+ <div class="value col-md-9">
+ <input class="form-control" type="text" name="EntryHint" value="<% $Create ? "" : $RoleObj->EntryHint || $EntryHint || '' %>" size="60" />
+ </div>
+ </div>
+
+ <div class="form-row">
+ <div class="custom-control custom-checkbox">
+ <input type="checkbox" class="custom-control-input" id="Multiple" name="Multiple" value="1"
% if ( $Create || $RoleObj->UnlimitedValues ) {
-checked="checked"
+ checked="checked"
% }
% if ( !$Create ) {
-disabled="disabled"
+ disabled="disabled"
% }
- /></td>
-<td colspan="3"><label for="Multiple">
+ />
+ <label class="custom-control-label" for="Multiple">
% if ( $Create ) {
-<&|/l&>Multiple users (Unchecking this box limits this role to a single user. This cannot be modified after creation)</&>
+ <&|/l&>Multiple users (Unchecking this box limits this role to a single user. This cannot be modified after creation)</&>
% } else {
-<&|/l&>Multiple users (This cannot be modified after creation)</&>
+ <&|/l&>Multiple users (This cannot be modified after creation)</&>
% }
-</label><br />
+ </label>
+ </div>
+ </div>
-<input type="hidden" class="hidden" name="SetMultiple" value="1" />
-</td></tr>
+ <br />
-<tr><td align="right"><input type="checkbox" class="checkbox" id="Enabled" name="Enabled" value="1" <%$EnabledChecked|n%> /></td>
-<td colspan="3"><label for="Enabled"><&|/l&>Enabled (Unchecking this box disables this custom role)</&></label><br />
-<input type="hidden" class="hidden" name="SetEnabled" value="1" />
+ <input type="hidden" class="hidden" name="SetMultiple" value="1" />
+
+ <div class="form-row">
+ <div class="custom-control custom-checkbox">
+ <input type="checkbox" class="custom-control-input" id="Enabled" name="Enabled" value="1" <%$EnabledChecked|n%> />
+ <label class="custom-control-label" for="Enabled"><&|/l&>Enabled (Unchecking this box disables this custom role)</&></label><br />
+ </div>
+ <input type="hidden" class="hidden" name="SetEnabled" value="1" />
% $m->callback( %ARGS, RoleObj => $RoleObj, results => \@results );
-</td></tr>
+ </div>
-</table>
+</div>
+<div class="form-row">
+ <div class="col-md-12">
% if ( $Create ) {
-<& /Elements/Submit, Label => loc('Create') &>
+ <& /Elements/Submit, Label => loc('Create') &>
% } else {
-<& /Elements/Submit, Label => loc('Save Changes') &>
+ <& /Elements/Submit, Label => loc('Save Changes') &>
% }
+ </div>
+</div>
+
</form>
diff --git a/share/html/Admin/CustomRoles/index.html b/share/html/Admin/CustomRoles/index.html
index 201c10ac4..e555a98e3 100644
--- a/share/html/Admin/CustomRoles/index.html
+++ b/share/html/Admin/CustomRoles/index.html
@@ -50,31 +50,47 @@
<h1><%$title%></h1>
-<form method="post" action="<% RT->Config->Get('WebPath') %>/Admin/CustomRoles/index.html">
+<div class="col-md-12">
+ <form method="post" action="<% RT->Config->Get('WebPath') %>/Admin/CustomRoles/index.html">
% foreach my $field( qw(Format Rows Page Order OrderBy) ) {
% next unless defined $ARGS{ $field } && length $ARGS{ $field };
-<input type="hidden" name="<% $field %>" value="<% $ARGS{ $field } %>" />
+ <input type="hidden" name="<% $field %>" value="<% $ARGS{ $field } %>" />
% }
-
-<select name="SearchField">
+ <div class="form-row">
+ <div class="col-md-auto">
+ <select class="form-control selectpicker" name="SearchField">
% foreach my $col (qw(Name Description EntryHint)) {
-<option <% $SearchField eq $col ? 'selected="selected"' : '' |n %> value="<% $col %>"><% loc($col) %></option>
+ <option <% $SearchField eq $col ? 'selected="selected"' : '' |n %> value="<% $col %>"><% loc($col) %></option>
% }
-</select>
-<& /Elements/SelectMatch, Name => 'SearchOp', Default => $SearchOp &>
-<input type="text" size="8" name="SearchString" value="<% $SearchString %>" />
-<br />
+ </select>
+ </div>
+ <div class="col-md-auto">
+ <& /Elements/SelectMatch, Name => 'SearchOp', Default => $SearchOp &>
+ </div>
+ <div class="col-md-auto">
+ <input class="form-control" type="text" size="8" name="SearchString" value="<% $SearchString %>" />
+ </div>
+ </div>
+ <br />
+
+ <div class="custom-control custom-checkbox form-row">
+ <input type="checkbox" class="custom-control-input" id="FindDisabled" name="FindDisabled" value="1" <% $FindDisabled? 'checked="checked"': '' |n%> />
+ <label class="custom-control-label" for="FindDisabled"><&|/l&>Include disabled custom roles in listing.</&></label>
+ </div>
-<input type="checkbox" class="checkbox" id="FindDisabled" name="FindDisabled" value="1" <% $FindDisabled? 'checked="checked"': '' |n%> />
-<label for="FindDisabled"><&|/l&>Include disabled custom roles in listing.</&></label>
-<div align="right"><input type="submit" class="button" value="<&|/l&>Go!</&>" /></div>
-</form>
+ <div class="form-row">
+ <div class="col-md-12">
+ <input type="submit" class="button" value="<&|/l&>Go!</&>" />
+ </div>
+ </div>
-<p><&|/l&>Select a custom role</&>:</p>
+ </form>
+
+ <p><&|/l&>Select a custom role</&>:</p>
% unless ( $roles->Count ) {
-<em><&|/l&>No custom roles matching search criteria found.</&></em>
+ <em><&|/l&>No custom roles matching search criteria found.</&></em>
% } else {
-<& /Elements/CollectionList,
+ <& /Elements/CollectionList,
OrderBy => 'Name',
Order => 'ASC',
Rows => $Rows,
@@ -86,9 +102,9 @@
Format Rows Page Order OrderBy
FindDisabled SearchString SearchOp SearchField
)],
-&>
+ &>
% }
-
+</div>
<%INIT>
my $title = loc("Select a Custom Role");
-----------------------------------------------------------------------
More information about the rt-commit
mailing list