[Rt-commit] rt branch, 4.6-theme-trunk, updated. rt-4.4.4-222-g84a5a0b12
? sunnavy
sunnavy at bestpractical.com
Wed May 15 10:53:42 EDT 2019
The branch, 4.6-theme-trunk has been updated
via 84a5a0b12b38452667275c3b67c1af686506a6ef (commit)
via f2790eaa9bd12642e94f7c5702bcc84f89a11f72 (commit)
via f2e1065f3186d0147e84fc721d37d7dacdbcec5c (commit)
via c336fd3bc7e5a1b86d43d34cb67480f8512b46fb (commit)
from 04608a9d06859e9089a91f2c2cabd31657f6dd81 (commit)
Summary of changes:
share/html/Admin/Articles/Elements/Topics | 57 +++--
share/html/Admin/CustomFields/Modify.html | 260 ++++++++++++++-------
share/html/Admin/CustomFields/Objects.html | 13 +-
share/html/Admin/Elements/AddCustomFieldValue | 63 +++--
share/html/Admin/Elements/EditCustomField | 53 +++--
share/html/Admin/Elements/EditCustomFieldValues | 67 ++++--
.../Elements/EditCustomFieldValuesCanonicalizer | 2 +-
.../Admin/Elements/EditCustomFieldValuesSource | 2 +-
share/html/Admin/Elements/EditRights | 2 +-
share/html/Admin/Elements/EditRightsCategoryTabs | 17 +-
share/html/Admin/Elements/SelectCustomField | 2 +-
.../Admin/Elements/SelectCustomFieldLookupType | 2 +-
.../Admin/Elements/SelectCustomFieldRenderType | 2 +-
share/html/Admin/Elements/SelectCustomFieldType | 2 +-
share/html/Admin/Global/CustomFields/index.html | 4 +-
share/html/Widgets/ComboBox | 2 +-
share/static/css/base-responsive/rights-editor.css | 1 +
share/static/css/elevator-light/forms.css | 4 +
share/static/css/elevator-light/ticket-search.css | 4 -
19 files changed, 364 insertions(+), 195 deletions(-)
- Log -----------------------------------------------------------------
commit c336fd3bc7e5a1b86d43d34cb67480f8512b46fb
Author: Craig Kaiser <craig at bestpractical.com>
Date: Mon May 13 08:31:47 2019 -0400
Migrate admin global rights pages to elevator themes
diff --git a/share/html/Admin/Elements/EditRights b/share/html/Admin/Elements/EditRights
index 3bcf0059d..8744f22ec 100644
--- a/share/html/Admin/Elements/EditRights
+++ b/share/html/Admin/Elements/EditRights
@@ -195,7 +195,7 @@ for my $category (@$Principals) {
<li class="category"><&|/l, loc($AddPrincipal) &>Add [_1]</&></li>
<li class="addprincipal">
<a href="#acl-AddPrincipal">
- <input type="text" value=""
+ <input type="text" value="" class="form-control"
data-autocomplete="<% lc $AddPrincipal eq 'user' ? 'Users' : 'Groups' %>"
% if ( lc $AddPrincipal eq 'user' ) {
data-autocomplete-return="Name"
diff --git a/share/html/Admin/Elements/EditRightsCategoryTabs b/share/html/Admin/Elements/EditRightsCategoryTabs
index 14b4bdc69..d71a6e3d3 100644
--- a/share/html/Admin/Elements/EditRightsCategoryTabs
+++ b/share/html/Admin/Elements/EditRightsCategoryTabs
@@ -113,21 +113,22 @@ $available_rights{$_} = loc( $available_rights{$_} ) for keys %available_rights;
<ul class="rights-list">
% for my $right (sort { $available_rights{$a} cmp $available_rights{$b} } @{$categories{$category}}) {
<li>
- <input
+ <div class="custom-control custom-checkbox">
+ <input
type="checkbox"
- class="checkbox"
+ class="custom-control-input"
name="SetRights-<% $acldesc %>"
id="SetRights-<% $acldesc %>-<% $right %>"
value="<% $right %>"
data-category-tab="<% "category-tab-$id-$category" %>"
data-principal-tab="<% "principal-tab-$id" %>"
<% $current_rights{$right} ? 'checked' : '' %>
- />
- <label for="SetRights-<% $acldesc %>-<% $right %>" title="<% $right %>">
- <% $available_rights{$right} %>
- <span class="separator">—</span>
- <span class="rightname"><% $right %></span>
- </label>
+ />
+ <label class="custom-control-label" for="SetRights-<% $acldesc %>-<% $right %>" title="<% $right %>">
+ <% $available_rights{$right} %>
+ <span class="text-right rightname"><% $right %></span>
+ </label>
+ </div>
</li>
% }
</ul>
diff --git a/share/static/css/base-responsive/rights-editor.css b/share/static/css/base-responsive/rights-editor.css
index 6236b5f8e..5c9df7b37 100644
--- a/share/static/css/base-responsive/rights-editor.css
+++ b/share/static/css/base-responsive/rights-editor.css
@@ -116,6 +116,7 @@ li.category ~ li.category {
.rights-editor ul.rights-list li label {
cursor: pointer;
+ width: 100%;
}
.rights-editor .rightname {
commit f2e1065f3186d0147e84fc721d37d7dacdbcec5c
Author: Craig Kaiser <craig at bestpractical.com>
Date: Mon May 13 08:34:46 2019 -0400
Migrate admin article topics to elevator themes
diff --git a/share/html/Admin/Articles/Elements/Topics b/share/html/Admin/Articles/Elements/Topics
index 6d46dc1b9..e238c2805 100644
--- a/share/html/Admin/Articles/Elements/Topics
+++ b/share/html/Admin/Articles/Elements/Topics
@@ -51,16 +51,22 @@
<input type="hidden" name="id" value="<%$RootObj->Id%>" />
% if (!$Modify) {
-<table>
-<tr>
-<td><&|/l&>Topic Name</&></td>
-<td><input type="text" name="Name" size="30" /></td>
-</tr>
-<tr>
-<td><&|/l&>Description</&></td>
-<td><input type="text" name="Description" size="50" /></td>
-</tr>
-</table>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Topic Name</&>
+ </div>
+ <div class="value col-md-9">
+ <input class="form-control" type="text" name="Name" size="30" />
+ </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" size="50" />
+ </div>
+</div>
% } else {
<a href="Topics.html">New topic</a>
% }
@@ -71,18 +77,25 @@
<%def .edit>
-<table style="margin-top: -0.75em">
-<tr>
- <td>Topic Name:</td>
- <td><input type="text" name="Topic-<%$topic->Id%>-Name" size="20" value="<%$topic->Name%>" /></td>
- <td><input type="submit" name="Update" value="Update"><br /></td>
-</tr>
-<tr>
- <td>Description:</td>
- <td> <input type="text" name="Topic-<%$topic->Id%>-Description" size="20" value="<%$topic->Description%>" /></td>
- <td><input type="submit" name="Delete-Topic-<%$topic->Id%>" value="Delete" /></td>
-</tr>
-</table>
+<div class="form-row">
+ <div class="label col-md-3">
+ Topic Name:
+ </div>
+ <div class="value col-md-9 input-group">
+ <input class="form-control" type="text" name="Topic-<%$topic->Id%>-Name" size="20" value="<%$topic->Name%>" />
+ <input type="submit" class="btn btn-primary" name="Update" value="Update">
+ </div>
+</div>
+
+<div class="form-row">
+ <div class="label col-md-3">
+ Description:
+ </div>
+ <div class="value col-md-9 input-group">
+ <input class="form-control" type="text" name="Topic-<%$topic->Id%>-Description" size="20" value="<%$topic->Description%>" />
+ <input type="submit" class="btn btn-primary" name="Delete-Topic-<%$topic->Id%>" value="Delete" />
+ </div>
+</div>
<%args>
$topic
</%args>
diff --git a/share/static/css/elevator-light/forms.css b/share/static/css/elevator-light/forms.css
index 2e4cfb519..1ff99e771 100644
--- a/share/static/css/elevator-light/forms.css
+++ b/share/static/css/elevator-light/forms.css
@@ -159,3 +159,7 @@ span.current-value.form-control {
.bootstrap-select button:focus {
background: #f8f9fa;
}
+
+.input-group input.btn {
+ margin-left: 0.5em;
+}
diff --git a/share/static/css/elevator-light/ticket-search.css b/share/static/css/elevator-light/ticket-search.css
index ed026e0fd..da2711655 100644
--- a/share/static/css/elevator-light/ticket-search.css
+++ b/share/static/css/elevator-light/ticket-search.css
@@ -183,7 +183,3 @@ span#display-options .titlebox#columns table.edit-columns span.value {
#pick-criteria .value {
max-width: 500px;
}
-
-.edit-saved-searches .input-group input.btn {
- margin-left: 0.5em;
-}
commit f2790eaa9bd12642e94f7c5702bcc84f89a11f72
Author: Craig Kaiser <craig at bestpractical.com>
Date: Mon May 13 08:35:54 2019 -0400
Migrate admin custom field modify pages to elevators
diff --git a/share/html/Admin/CustomFields/Modify.html b/share/html/Admin/CustomFields/Modify.html
index 3f6e9111d..a2e393571 100644
--- a/share/html/Admin/CustomFields/Modify.html
+++ b/share/html/Admin/CustomFields/Modify.html
@@ -55,50 +55,84 @@
<form method="post" action="Modify.html" name="ModifyCustomField" id="ModifyCustomField">
<input type="hidden" class="hidden" name="id" value="<% $id %>" />
-<table>
-
-<tr><td class="label"><&|/l&>Name</&></td>
-<td><input type="text" name="Name" value="<% $CustomFieldObj->Name || $Name || '' %>" size="20" /></td></tr>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Name</&>
+ </div>
+ <div class="col-md-9 value">
+ <input class="form-control" type="text" name="Name" value="<% $CustomFieldObj->Name || $Name || '' %>" size="20" />
+ </div>
+</div>
-<tr><td class="label"><&|/l&>Description</&></td>
-<td><input type="text" name="Description" value="<% $CustomFieldObj->Description || $Description || '' %>" size="80" /></td></tr>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Description</&>
+ </div>
+ <div class="col-md-9 value">
+ <input class="form-control" type="text" name="Description" value="<% $CustomFieldObj->Description || $Description || '' %>" size="80" />
+ </div>
+</div>
-<tr><td class="label"><&|/l&>Type</&></td>
-<td><& /Admin/Elements/SelectCustomFieldType,
- Name => "TypeComposite",
- Default => $CustomFieldObj->TypeComposite, &>
-</td></tr>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Type</&>
+ </div>
+ <div class="col-md-9 value">
+ <& /Admin/Elements/SelectCustomFieldType,
+ Name => "TypeComposite",
+ Default => $CustomFieldObj->TypeComposite,
+ &>
+ </div>
+</div>
% if ( $CustomFieldObj->Id and $CustomFieldObj->HasRenderTypes ) {
-<tr>
- <td class="label"><&|/l&>Render Type</&></td>
- <td>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Render Type</&>
+ </div>
+ <div class="col-md-9 value">
<& /Admin/Elements/SelectCustomFieldRenderType,
Name => "RenderType",
TypeComposite => $CustomFieldObj->TypeComposite,
Default => $CustomFieldObj->RenderType,
BasedOn => $CustomFieldObj->BasedOnObj->id, &>
- </td>
-</tr>
+ </div>
+</div>
% }
% if ( $CustomFieldObj->Id and $CustomFieldObj->IsSelectionType and RT->Config->Get('CustomFieldValuesSources') and ( scalar(@{RT->Config->Get('CustomFieldValuesSources')}) > 0 ) ) {
-<tr><td class="label"><&|/l&>Field values source:</&></td><td>
-<& /Admin/Elements/EditCustomFieldValuesSource, CustomField => $CustomFieldObj &>
-</td></tr>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Field values source:</&>
+ </div>
+ <div class="col-md-9 value">
+ <& /Admin/Elements/EditCustomFieldValuesSource, CustomField => $CustomFieldObj &>
+ </div>
+</div>
% }
% if ( $CustomFieldObj->Id and $CustomFieldObj->IsCanonicalizeType and RT->Config->Get('CustomFieldValuesCanonicalizers') and ( scalar(@{RT->Config->Get('CustomFieldValuesCanonicalizers')}) > 0 ) ) {
-<tr><td class="label"><&|/l&>Canonicalizer:</&></td><td>
-<& /Admin/Elements/EditCustomFieldValuesCanonicalizer, CustomField => $CustomFieldObj &>
-</td></tr>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Canonicalizer:</&>
+ </div>
+ <div class="col-md-9 value">
+ <& /Admin/Elements/EditCustomFieldValuesCanonicalizer, CustomField => $CustomFieldObj &>
+ </div>
+</div>
% }
-<tr><td class="label"><&|/l&>Applies to</&></td>
-<td><& /Admin/Elements/SelectCustomFieldLookupType,
- Name => "LookupType",
- Default => $CustomFieldObj->LookupType || $LookupType, &>
-</td></tr>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Applies to</&>
+ </div>
+ <div class="col-md-9 value">
+ <& /Admin/Elements/SelectCustomFieldLookupType,
+ Name => "LookupType",
+ Default => $CustomFieldObj->LookupType || $LookupType,
+ &>
+ </div>
+</div>
<script type="text/javascript">
jQuery( function() {
@@ -118,80 +152,144 @@ jQuery( function() {
});
</script>
-<tr><td class="label"><&|/l&>Entry Hint</&></td>
-<td><input type="text" name="EntryHint" value="<% $CustomFieldObj->EntryHint // $EntryHint // '' %>" size="80" /></td></tr>
-
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Entry Hint</&>
+ </div>
+ <div class="col-md-9 value">
+ <input class="form-control" type="text" name="EntryHint" value="<% $CustomFieldObj->EntryHint // $EntryHint // '' %>" size="80" />
+ </div>
+</div>
-<tr class="edit_validation"><td class="label"><&|/l&>Validation</&></td>
-<td><& /Widgets/ComboBox,
- Name => 'Pattern',
- Default => $CustomFieldObj->Pattern || $Pattern,
- Size => 20,
- Values => \@CFvalidations,
-&></td></tr>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Validation</&>
+ </div>
+ <div class="col-md-9 value">
+ <& /Widgets/ComboBox,
+ Name => 'Pattern',
+ Default => $CustomFieldObj->Pattern || $Pattern,
+ Size => 20,
+ Values => \@CFvalidations,
+ &>
+ </div>
+</div>
% if ( $CustomFieldObj->SupportDefaultValues ) {
-<tr class="edit_default_values"><td class="label"><&|/l, $CustomFieldObj->MaxValues &>Default [numerate,_1,value,values]</&></td>
-<td>
-<& /Elements/EditCustomField, NamePrefix => 'Default-', CustomField => $CustomFieldObj, ShowEmptyOption => 1 &>
-</td>
-</tr>
+<div class="form-row">
+ <div class="label col-md-3 edit_default_values">
+ <&|/l, $CustomFieldObj->MaxValues &>Default [numerate,_1,value,values]</&>
+ </div>
+ <div class="col-md-9 value">
+ <& /Elements/EditCustomField, NamePrefix => 'Default-', CustomField => $CustomFieldObj, ShowEmptyOption => 1 &>
+ </div>
+</div>
% }
-<tr><td class="label"><&|/l&>Link values to</&></td><td>
-<input type="text" size="60" name="LinkValueTo" value="<% $CustomFieldObj->LinkValueTo || $LinkValueTo || '' %>" />
-<div class="hints">
-<&|/l&>RT can make this custom field's values into hyperlinks to another service.</&>
-<&|/l&>Fill in this field with a URL.</&>
-<&|/l_unsafe, '<tt>__id__</tt>', '<tt>__CustomField__</tt>' &>RT will replace [_1] and [_2] with the record's id and the custom field's value, respectively.</&>
-</div></td></tr>
-
-<tr><td class="label"><&|/l&>Include page</&></td><td>
-<input type="text" size="60" name="IncludeContentForValue" value="<% $CustomFieldObj->IncludeContentForValue || $IncludeContentForValue || '' %>" />
-<div class="hints">
-<&|/l&>RT can include content from another web service when showing this custom field.</&>
-<&|/l&>Fill in this field with a URL.</&>
-<&|/l_unsafe, '<tt>__id__</tt>', '<tt>__CustomField__</tt>' &>RT will replace [_1] and [_2] with the record's id and the custom field's value, respectively.</&>
-<i><&|/l&>Some browsers may only load content from the same domain as your RT server.</&></i>
-</div></td></tr>
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Link values to</&>
+ </div>
+ <div class="col-md-9 value">
+ <input class="form-control" type="text" size="60" name="LinkValueTo" value="<% $CustomFieldObj->LinkValueTo || $LinkValueTo || '' %>" />
+ </div>
+</div>
+
+<div class="form-row">
+ <div class="col-md-3"></div>
+ <div class="col-md-9">
+ <&|/l&>RT can make this custom field's values into hyperlinks to another service.</&>
+ <&|/l&>Fill in this field with a URL.</&>
+ <&|/l_unsafe, '<tt>__id__</tt>', '<tt>__CustomField__</tt>' &>RT will replace [_1] and [_2] with the record's id and the custom field's value, respectively.</&>
+ </div>
+</div>
+
+<div class="form-row">
+ <div class="label col-md-3">
+ <&|/l&>Include page</&>
+ </div>
+ <div class="col-md-9 value">
+ <input class="form-control" type="text" size="60" name="IncludeContentForValue" value="<% $CustomFieldObj->IncludeContentForValue || $IncludeContentForValue || '' %>" />
+ </div>
+</div>
+
+<div class="form-row">
+ <div class="col-md-3"></div>
+ <div class="col-md-9">
+ <&|/l&>RT can include content from another web service when showing this custom field.</&>
+ <&|/l&>Fill in this field with a URL.</&>
+ <&|/l_unsafe, '<tt>__id__</tt>', '<tt>__CustomField__</tt>' &>RT will replace [_1] and [_2] with the record's id and the custom field's value, respectively.</&>
+ <i><&|/l&>Some browsers may only load content from the same domain as your RT server.</&></i>
+ </div>
+</div>
% if ( $CustomFieldObj->Id && $CustomFieldObj->IsSelectionType ) {
-<tr class="categoriesbasedon"><td class="label"><&|/l&>Categories are based on</&></td><td>
-<& /Admin/Elements/SelectCustomField,
- Name => "BasedOn",
- LookupType => $CustomFieldObj->LookupType,
- Default => $CustomFieldObj->BasedOnObj || $BasedOn,
- Not => $CustomFieldObj->id,
-&>
-</td></tr>
+<div class="form-row categoriesbasedon">
+ <div class="col-md-3 label">
+ <&|/l&>Categories are based on</&>
+ </div>
+ <div class="col-md-9 value">
+ <& /Admin/Elements/SelectCustomField,
+ Name => "BasedOn",
+ LookupType => $CustomFieldObj->LookupType,
+ Default => $CustomFieldObj->BasedOnObj || $BasedOn,
+ Not => $CustomFieldObj->id,
+ &>
+ </div>
+</div>
% }
-<tr><td class="label"> </td><td>
-<input type="hidden" class="hidden" name="SetUniqueValues" value="1" />
-<input type="checkbox" class="checkbox" id="UniqueValues" name="UniqueValues" value="1" <% $UniqueValuesChecked |n %> />
-<label for="UniqueValues"><&|/l&>New values must be unique</&></label>
-</td></tr>
+<div class="form-row">
+ <div class="col-md-3 label"></div>
+ <div class="col-md-9 value">
+ <input type="hidden" class="hidden" name="SetUniqueValues" value="1" />
+ <div class="custom-control custom-checkbox">
+ <input type="checkbox" class="custom-control-input" id="UniqueValues" name="UniqueValues" value="1" <% $UniqueValuesChecked |n %> />
+ <label class="custom-control-label" for="UniqueValues">
+ <&|/l&>New values must be unique</&>
+ </label>
+ </div>
+ </div>
+</div>
% $m->callback(CallbackName => 'BeforeEnabled', CustomField => $CustomFieldObj, CFvalidations => \@CFvalidations);
-<tr><td class="label"> </td><td>
-<input type="hidden" class="hidden" name="SetEnabled" value="1" />
-<input type="checkbox" class="checkbox" id="Enabled" name="Enabled" value="1" <% $EnabledChecked |n %> />
-<label for="Enabled"><&|/l&>Enabled (Unchecking this box disables this custom field)</&></label>
-</td></tr>
+<div class="form-row">
+ <div class="col-md-3 label"></div>
+ <div class="col-md-9 value">
+ <input type="hidden" class="hidden" name="SetEnabled" value="1" />
+ <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 field)</&>
+ </label>
+ </div>
+ </div>
+</div>
% $m->callback(CallbackName => 'EndOfTable', CustomField => $CustomFieldObj, CFvalidations => \@CFvalidations);
-</table>
% if ( $CustomFieldObj->Id && $CustomFieldObj->IsSelectionType && !$CustomFieldObj->IsExternalValues ) {
-<h2><&|/l&>Values</&></h2>
-<div class="edit_custom_field_values">
-<& /Admin/Elements/EditCustomFieldValues, CustomField => $CustomFieldObj &>
+<div class="form-row">
+ <div class="col-md-3 label">
+ <h2><&|/l&>Values</&></h2>
+ </div>
+</div>
+
+<div class="form-row">
+ <div class="col-md-3"></div>
+ <div class="edit_custom_field_values col-md-9">
+ <& /Admin/Elements/EditCustomFieldValues, CustomField => $CustomFieldObj &>
+ </div>
</div>
% }
-<& /Elements/Submit, Name => 'Update', Label => $id eq 'new'? loc('Create'): loc('Save Changes') &>
+<div class="form-row">
+ <div class="col-md-12">
+ <& /Elements/Submit, Name => 'Update', Label => $id eq 'new'? loc('Create'): loc('Save Changes') &>
+ </div>
+</div>
</form>
diff --git a/share/html/Admin/CustomFields/Objects.html b/share/html/Admin/CustomFields/Objects.html
index 6327b94d9..7bae52172 100644
--- a/share/html/Admin/CustomFields/Objects.html
+++ b/share/html/Admin/CustomFields/Objects.html
@@ -55,14 +55,17 @@
% if ( $CF->IsGlobal ) {
<h2><&|/l&>Applies to all objects</&></h2>
-<input type="checkbox" id="RemoveCustomField-<% $CF->id %>" name="RemoveCustomField-<% $CF->id %>" value="0" />
-<label for="RemoveCustomField-<% $CF->id %>"><&|/l&>check this box to remove this Custom Field from all objects and be able to choose specific objects.</&></label>
+<div class="custom-control custom-checkbox">
+ <input class="custom-control-input" type="checkbox" id="RemoveCustomField-<% $CF->id %>" name="RemoveCustomField-<% $CF->id %>" value="0" />
+ <label class="custom-control-label" for="RemoveCustomField-<% $CF->id %>"><&|/l&>check this box to remove this Custom Field from all objects and be able to choose specific objects.</&></label>
+</div>
% } else {
<h2><&|/l&>Apply globally</&></h2>
-<input type="checkbox" id="AddCustomField-<% $CF->id %>" name="AddCustomField-<% $CF->id %>" value="0" />
-<label for="AddCustomField-<% $CF->id %>"><&|/l&>check this box to apply this Custom Field to all objects.</&></label>
-
+<div class="custom-control custom-checkbox">
+ <input class="custom-control-input" type="checkbox" id="AddCustomField-<% $CF->id %>" name="AddCustomField-<% $CF->id %>" value="0" />
+ <label class="custom-control-label" for="AddCustomField-<% $CF->id %>"><&|/l&>check this box to apply this Custom Field to all objects.</&></label>
+</div>
% unless ( $CF->IsOnlyGlobal ) {
<h2><&|/l&>Selected objects</&></h2>
<& /Elements/CollectionList,
diff --git a/share/html/Admin/Elements/AddCustomFieldValue b/share/html/Admin/Elements/AddCustomFieldValue
index 71691afe9..88685cfa7 100644
--- a/share/html/Admin/Elements/AddCustomFieldValue
+++ b/share/html/Admin/Elements/AddCustomFieldValue
@@ -45,41 +45,62 @@
%# those contributions and any derivatives thereof.
%#
%# END BPS TAGGED BLOCK }}}
-<h3><&|/l&>Add Value</&></h3>
+<div class="col-md-3 label">
+ <h3><&|/l&>Add Value</&></h3>
+</div>
+
+<div class="form-row">
+ <div class="col-md-3"></div>
+ <div class="col-md-9">
<form name="AddCustomFieldValue" action="Modify.html" method="post">
<input type="hidden" class="hidden" name="id" value="<% $CustomField->id %>" />
-<table border="0">
-<tr>
-<th><&|/l&>Sort</&></th>
-<th><&|/l&>Name</&></th>
-<th><&|/l&>Description</&></th>
+
+ <div class="form-row">
+ <div class="label col-md-2 text-left">
+ <&|/l&>Sort</&>
+ </div>
+ <div class="label col-md-2 text-left">
+ <&|/l&>Name</&>
+ </div>
+ <div class="label col-md-2 text-left">
+ <&|/l&>Description</&>
+ </div>
% if ( $CustomField->Type ne 'Combobox' && $Categories ) {
-<th class="categoryheader"><&|/l&>Category</&></th>
+ <div class="label categoryheader col-md-2 text-left">
+ <&|/l&>Category</&>
+ </div>
% }
-<th></th>
-</tr>
+ </div>
% my $paramtag = "CustomField-". $CustomField->Id ."-Value-new";
-<tr>
-<td><input type="text" size="3" name="<% $paramtag %>-SortOrder" /></td>
-<td><input type="text" size="25" name="<% $paramtag %>-Name" /></td>
-<td><input type="text" size="45" name="<% $paramtag %>-Description" /></td>
+ <div class="form-row">
+ <div class="col-md-2 value">
+ <input class="form-control" type="text" size="3" name="<% $paramtag %>-SortOrder" />
+ </div>
+ <div class="col-md-2 value">
+ <input class="form-control" type="text" size="25" name="<% $paramtag %>-Name" />
+ </div>
+ <div class="col-md-2 value">
+ <input class="form-control" type="text" size="45" name="<% $paramtag %>-Description" />
+ </div>
% if ( $CustomField->Type ne 'Combobox' && $Categories ) {
-<td>
-<select class="editcategory" name="<% $paramtag %>-Category" size="1">
+ <div class="col-md-2 value">
+ <select class="form-control selectpicker editcategory " name="<% $paramtag %>-Category" size="1">
<option value=""><&|/l&>(no value)</&></option>
% while (my $Value = $Categories->Next) {
-<option value="<% $Value->Name %>"><% $Value->Name %></option>
+ <option value="<% $Value->Name %>"><% $Value->Name %></option>
% }
-</td>
+ </select>
+ </div>
% }
-<td><input type="submit" name="AddValue" value="<&|/l&>Add</&>" /></td>
+ <div class="col-md-2">
+ <input type="submit" class="btn btn-primary btn-sm form-control" name="AddValue" value="<&|/l&>Add</&>" />
+ </div>
+ </div>
% $m->callback(CallbackName => 'AfterCustomFieldValueInput', CustomFieldObj => $CustomField, ARGSRef => \%ARGS );
-</tr>
-
-</table>
</form>
+</div>
<script type="text/javascript">
jQuery( function() {
diff --git a/share/html/Admin/Elements/EditCustomField b/share/html/Admin/Elements/EditCustomField
index 1f5110a36..92778a712 100644
--- a/share/html/Admin/Elements/EditCustomField
+++ b/share/html/Admin/Elements/EditCustomField
@@ -52,29 +52,38 @@
<input type="hidden" class="hidden" name="CustomField" value="<%$id %>" />
<input type="hidden" class="hidden" name="Queue" value="<%$Queue%>" />
-<table width="100%" border="0">
-<tr><td align="right">
-<&|/l&>Name</&>:
-</td><td>
-<input type="text" name="Name" value="<%$CustomFieldObj->Name%>" size="20" />
-</td></tr>
-<tr><td align="right">
-<&|/l&>Description</&>:
-</td><td>
-<input type="text" name="Description" value="<%$CustomFieldObj->Description%>" size="80" />
-</td></tr>
-<tr><td align="right">
-<&|/l&>Type</&>:
-</td><td>
-<& /Admin/Elements/SelectCustomFieldType, Name => "Type", Default => $CustomFieldObj->Type &>
-</td></tr>
-<tr><td>
-</td><td>
+<div class="form-row">
+ <div class="col-md-3 label>
+ <&|/l&>Name</&>:
+ <div>
+ <div class="value col-md-9">
+ <input class="form-control" type="text" name="Name" value="<%$CustomFieldObj->Name%>" size="20" />
+ </div>
+</div>
+
+<div class="form-row">
+ <div class="col-md-3 label>
+ <&|/l&>Description</&>:
+ </div>
+ <div class="value col-md-9">
+ <input class="form-control" type="text" name="Description" value="<%$CustomFieldObj->Description%>" size="80" />
+ </div>
+</div>
+
+<div class="form-row">
+ <div class="col-md-3 label>
+ <&|/l&>Type</&>:
+ </div>
+ <div class="value col-md-9">
+ <& /Admin/Elements/SelectCustomFieldType, Name => "Type", Default => $CustomFieldObj->Type &>
+ </div>
+</div>
+
<input type="hidden" class="hidden" name="SetEnabled" value="1" />
-<input type="checkbox" class="checkbox" id="Enabled" name="Enabled" value="1" <%$EnabledChecked%> />
-<label for="Enabled"><&|/l&>Enabled (Unchecking this box disables this custom field)</&></label>
-</td></tr>
-</table>
+<div class="custom-control custom-checkbox">
+ <input type="checkbox" class="custom-control-input checkbox" id="Enabled" name="Enabled" value="1" <%$EnabledChecked%> />
+ <label class="custom-control-label" for="Enabled"><&|/l&>Enabled (Unchecking this box disables this custom field)</&></label>
+</div>
<p>
% if ($CustomFieldObj->Id and $CustomFieldObj->Type =~ /Select/) {
diff --git a/share/html/Admin/Elements/EditCustomFieldValues b/share/html/Admin/Elements/EditCustomFieldValues
index 6f339305c..1bf65cb6a 100644
--- a/share/html/Admin/Elements/EditCustomFieldValues
+++ b/share/html/Admin/Elements/EditCustomFieldValues
@@ -50,43 +50,66 @@
% return;
% }
-<table>
-
-<tr>
-<th><input type="checkbox" name="DeleteAll" value="1" onclick="setCheckbox(this, /^Delete-/)" /></th>
-<th><&|/l&>Sort</&></th>
-<th><&|/l&>Name</&></th>
-<th><&|/l&>Description</&></th>
+<div class="form-row">
+ <div class="label col-md-auto">
+ <div class="custom-control custom-checkbox">
+ <input class="custom-control-input" type="checkbox" id='DeleteAll' name="DeleteAll" value="1" onclick="setCheckbox(this, /^Delete-/)" />
+ <label class="custom-control-label" for="DeleteAll"></label>
+ </div>
+ </div>
+ <div class="label col-md-2 text-left">
+ <&|/l&>Sort</&>
+ </div>
+ <div class="label col-md-2 text-left">
+ <&|/l&>Name</&>
+ </div>
+ <div class="label col-md-2 text-left">
+ <&|/l&>Description</&>
+ </div>
% if ( $CustomField->Type ne 'Combobox' && $Categories ) {
-<th class="categoryheader"><&|/l&>Category</&></th>
+ <div class="label categoryheader col-md-2 text-left">
+ <&|/l&>Category</&>
+ </div>
% }
-<th></th>
-</tr>
+</div>
% while ( my $value = $values->Next ) {
% my $paramtag = "CustomField-". $CustomField->Id ."-Value-". $value->Id;
-<tr>
-<td><input type="text" size="3" name="<% $paramtag %>-SortOrder" value="<% $value->SortOrder %>" /></td>
-<td><input type="text" size="25" name="<% $paramtag %>-Name" value="<% $value->Name %>" /></td>
-<td><input type="text" size="45" name="<% $paramtag %>-Description" value="<% $value->Description || '' %>" /></td>
+<div class="form-row">
+ <div class='col-md-auto'>
+ <div class="custom-control custom-checkbox">
+ <input type="checkbox" class="custom-control-input" id="Delete-<% $paramtag %>" name="Delete-<% $paramtag %>" />
+ <label class="custom-control-label" for="Delete-<% $paramtag %>"></label>
+ </div>
+ </div>
+ <div class="col-md-2 value">
+ <input class="form-control" type="text" size="3" name="<% $paramtag %>-SortOrder" value="<% $value->SortOrder %>" />
+ </div>
+ <div class="col-md-2 value">
+ <input class="form-control" type="text" size="25" name="<% $paramtag %>-Name" value="<% $value->Name %>" />
+ </div>
+ <div class="col-md-2 value">
+ <input class="form-control" type="text" size="45" name="<% $paramtag %>-Description" value="<% $value->Description || '' %>" />
+ </div>
% if ( $CustomField->Type ne 'Combobox' && $Categories ) {
-<td>
+ <div class="col-md-2 value">
% my $selected = $value->Category;
% $selected = '' unless defined $selected;
-<select class="editcategory" name="<% $paramtag %>-Category" size="1">
+ <select class="editcategory form-control selectpicker" name="<% $paramtag %>-Category" size="1">
<option value=""<% $selected eq '' ? q[ selected="selected"] : "" |n%>><&|/l&>(no value)</&></option>
% while (my $Value = $Categories->Next) {
-<option value="<% $Value->Name %>"<% $selected eq $Value->Name ? q[ selected="selected"] : "" |n%>><% $Value->Name %></option>
+ <option value="<% $Value->Name %>"<% $selected eq $Value->Name ? q[ selected="selected"] : "" |n%>><% $Value->Name %></option>
% }
-</td>
+ </select>
+ </div>
% }
-<td><input type="button" class="delete_custom_field_value" data-cfv-id="<% $value->id %>" value="<&|/l&>Delete</&>" onclick="delete_custom_field_value(<% $value->id %>)" /></td>
+ <div class="col-md-2">
+ <input type="button" class="delete_custom_field_value button btn btn-primary" data-cfv-id="<% $value->id %>" value="<&|/l&>Delete</&>" onclick="delete_custom_field_value(<% $value->id %>)" />
+ </div>
% $m->callback(CallbackName => 'AfterCustomFieldValueInput', CustomFieldObj => $CustomField, CustomFieldValueObj => $value, ARGSRef => \%ARGS );
-</tr>
+</div>
% }
-</table>
-
<script type="text/javascript">
function delete_custom_field_value(value_id) {
jQuery.post('<% RT->Config->Get('WebPath') %>/Helpers/Admin/EditCustomFieldValue', {
diff --git a/share/html/Admin/Elements/EditCustomFieldValuesCanonicalizer b/share/html/Admin/Elements/EditCustomFieldValuesCanonicalizer
index ad11a6a95..2f64c475f 100644
--- a/share/html/Admin/Elements/EditCustomFieldValuesCanonicalizer
+++ b/share/html/Admin/Elements/EditCustomFieldValuesCanonicalizer
@@ -46,7 +46,7 @@
%#
%# END BPS TAGGED BLOCK }}}
<div id="canonicalize-class-block">
-<select name="CanonicalizeClass">
+<select class='form-control selectpicker' name="CanonicalizeClass">
<option value="">-</option>
% foreach my $canonicalizer (@canonicalizers) {
<option value="<% $canonicalizer %>" <% $canonicalizer eq ($CustomField->CanonicalizeClass||'') && 'selected="selected"' %>><% $canonicalizer->Description %></option>
diff --git a/share/html/Admin/Elements/EditCustomFieldValuesSource b/share/html/Admin/Elements/EditCustomFieldValuesSource
index c1fe6143c..3d2a29cb6 100644
--- a/share/html/Admin/Elements/EditCustomFieldValuesSource
+++ b/share/html/Admin/Elements/EditCustomFieldValuesSource
@@ -46,7 +46,7 @@
%#
%# END BPS TAGGED BLOCK }}}
<div id="values-source-class-block">
-<select name="ValuesClass">
+<select class="form-control selectpicker" name="ValuesClass">
% foreach my $source( @sources ) {
<option value="<% $source->{'Class'} %>" <% $source->{'Class'} eq $CustomField->ValuesClass && 'selected="selected"' %>><% $source->{'Description'} %></option>
% }
diff --git a/share/html/Admin/Elements/SelectCustomField b/share/html/Admin/Elements/SelectCustomField
index 1a4d5aab8..f3258054b 100644
--- a/share/html/Admin/Elements/SelectCustomField
+++ b/share/html/Admin/Elements/SelectCustomField
@@ -45,7 +45,7 @@
%# those contributions and any derivatives thereof.
%#
%# END BPS TAGGED BLOCK }}}
-<select name="<%$Name%>">
+<select class="form-control selectpicker" name="<%$Name%>">
<option value="" <% not $Default and qq[ selected="selected"] |n %>>--</option>
% while (my $CustomFieldObj = $CustomFields->Next) {
% next if $OnlySelectionType and not $CustomFieldObj->IsSelectionType;
diff --git a/share/html/Admin/Elements/SelectCustomFieldLookupType b/share/html/Admin/Elements/SelectCustomFieldLookupType
index eae8a3fd1..16f42f33f 100644
--- a/share/html/Admin/Elements/SelectCustomFieldLookupType
+++ b/share/html/Admin/Elements/SelectCustomFieldLookupType
@@ -45,7 +45,7 @@
%# those contributions and any derivatives thereof.
%#
%# END BPS TAGGED BLOCK }}}
-<select name="<%$Name%>">
+<select class="form-control selectpicker" name="<%$Name%>">
%for my $option ($cf->LookupTypes) {
<option value="<%$option%>"<%defined ($Default) && ($option eq $Default) && qq[ selected="selected"] |n%>><% $cf->FriendlyLookupType($option) %></option>
%}
diff --git a/share/html/Admin/Elements/SelectCustomFieldRenderType b/share/html/Admin/Elements/SelectCustomFieldRenderType
index ccf932cc5..71cadc4a5 100644
--- a/share/html/Admin/Elements/SelectCustomFieldRenderType
+++ b/share/html/Admin/Elements/SelectCustomFieldRenderType
@@ -45,7 +45,7 @@
%# those contributions and any derivatives thereof.
%#
%# END BPS TAGGED BLOCK }}}
-<select name="<%$Name%>">
+<select class="form-control selectpicker" name="<%$Name%>">
%for my $option (@types) {
<option value="<%$option%>"<%$option eq $Default && qq[ selected="selected"] |n%>><% $option %></option>
%}
diff --git a/share/html/Admin/Elements/SelectCustomFieldType b/share/html/Admin/Elements/SelectCustomFieldType
index 11830d984..963016865 100644
--- a/share/html/Admin/Elements/SelectCustomFieldType
+++ b/share/html/Admin/Elements/SelectCustomFieldType
@@ -45,7 +45,7 @@
%# those contributions and any derivatives thereof.
%#
%# END BPS TAGGED BLOCK }}}
-<select name="<%$Name%>">
+<select class="form-control selectpicker" name="<%$Name%>">
%for my $option ($cf->TypeComposites) {
<option value="<%$option%>"<%$option eq $Default && qq[ selected="selected"] |n%>><% $cf->FriendlyTypeComposite($option) %></option>
%}
diff --git a/share/html/Admin/Global/CustomFields/index.html b/share/html/Admin/Global/CustomFields/index.html
index 3db2d8714..abc934364 100644
--- a/share/html/Admin/Global/CustomFields/index.html
+++ b/share/html/Admin/Global/CustomFields/index.html
@@ -49,9 +49,9 @@
<& /Admin/Elements/Header, Title => $title &>
<& /Elements/Tabs &>
-<ul>
+<ul class="list-group list-group-borderless">
% foreach my $key (sort keys %$tabs) {
-<li><span><a href="<% $tabs->{$key}{path} %>"><% $tabs->{$key}{title} %></a></span><br />
+<li class="list-group-item"><span><a href="<% $tabs->{$key}{path} %>"><% $tabs->{$key}{title} %></a></span><br />
<% $tabs->{$key}{text} %>
</li>
% }
diff --git a/share/html/Widgets/ComboBox b/share/html/Widgets/ComboBox
index 2453f73b6..19c5f5008 100644
--- a/share/html/Widgets/ComboBox
+++ b/share/html/Widgets/ComboBox
@@ -52,7 +52,7 @@ my $z_index = 9999;
% if ( grep { /\bbootstrap-combobox\b/ } RT::Interface::Web->JSFiles ) {
<div class="combobox-wrapper" data-name="<% $Name %>" data-value="<% $Default // '' %>">
- <select class="combobox" size="<% $Rows %>">
+ <select class="form-control combobox" size="<% $Rows %>">
<option value=""></option>
% for my $value (@Values) {
<option value="<% $value %>" <% ($Default // '') eq $value ? 'selected="selected"' : '' %>><% $value%></option>
commit 84a5a0b12b38452667275c3b67c1af686506a6ef
Merge: 04608a9d0 f2790eaa9
Author: sunnavy <sunnavy at bestpractical.com>
Date: Wed May 15 22:42:41 2019 +0800
Merge branch '4.6-theme/admin-global-pages' into 4.6-theme-trunk
-----------------------------------------------------------------------
More information about the rt-commit
mailing list