[Rt-commit] rt branch, 5.0-trunk, updated. rt-5.0.0-138-gdf26c551f8

? sunnavy sunnavy at bestpractical.com
Fri Dec 11 16:49:07 EST 2020


The branch, 5.0-trunk has been updated
       via  df26c551f8c1c0f890e8b1616495717ccdc56857 (commit)
       via  c15845f48f41c165ef8ea3f4943b66509a075569 (commit)
       via  fb503bd292e9b428070b6fa89671fbd331d2463c (commit)
       via  ec3eaf66faeb4762ec56aa47f63d7459bcaef64d (commit)
      from  bd06a743f113aba89b609b68314b4f4a4f9f5700 (commit)

Summary of changes:
 etc/RT_Config.pm.in                                |  4 +--
 .../SelfServiceNewestArticles}                     |  2 +-
 .../SelfServiceShowArticles}                       | 42 +++++++++++-----------
 .../SelfServiceTopArticles}                        |  2 +-
 share/static/css/elevator-light/articles.css       | 10 ++++++
 share/static/css/elevator-light/base.css           |  9 +++++
 6 files changed, 42 insertions(+), 27 deletions(-)
 copy share/html/{NoAuth/css/elevator-dark/InHeader => Elements/SelfServiceNewestArticles} (98%)
 copy share/html/{Admin/Elements/EditCustomFieldValuesCanonicalizer => Elements/SelfServiceShowArticles} (72%)
 copy share/html/{Admin/Users/Memberships.html => Elements/SelfServiceTopArticles} (93%)

- Log -----------------------------------------------------------------
commit ec3eaf66faeb4762ec56aa47f63d7459bcaef64d
Author: Jim Brandt <jbrandt at bestpractical.com>
Date:   Thu Dec 10 11:05:16 2020 -0500

    Add Top and Newest Articles portlets for self service

diff --git a/share/html/Elements/SelfServiceNewestArticles b/share/html/Elements/SelfServiceNewestArticles
new file mode 100644
index 0000000000..3237f398e4
--- /dev/null
+++ b/share/html/Elements/SelfServiceNewestArticles
@@ -0,0 +1,48 @@
+%# BEGIN BPS TAGGED BLOCK {{{
+%#
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2020 Best Practical Solutions, LLC
+%#                                          <sales at bestpractical.com>
+%#
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
+%#
+%# This work is made available to you under the terms of Version 2 of
+%# the GNU General Public License. A copy of that license should have
+%# been provided with this software, but in any event can be snarfed
+%# from www.gnu.org.
+%#
+%# This work is distributed in the hope that it will be useful, but
+%# WITHOUT ANY WARRANTY; without even the implied warranty of
+%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+%# General Public License for more details.
+%#
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+%# 02110-1301 or visit their web page on the internet at
+%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions,  LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# END BPS TAGGED BLOCK }}}
+<& /Elements/SelfServiceShowArticles &>
diff --git a/share/html/Elements/SelfServiceShowArticles b/share/html/Elements/SelfServiceShowArticles
new file mode 100644
index 0000000000..4718ed195e
--- /dev/null
+++ b/share/html/Elements/SelfServiceShowArticles
@@ -0,0 +1,75 @@
+%# BEGIN BPS TAGGED BLOCK {{{
+%#
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2020 Best Practical Solutions, LLC
+%#                                          <sales at bestpractical.com>
+%#
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
+%#
+%# This work is made available to you under the terms of Version 2 of
+%# the GNU General Public License. A copy of that license should have
+%# been provided with this software, but in any event can be snarfed
+%# from www.gnu.org.
+%#
+%# This work is distributed in the hope that it will be useful, but
+%# WITHOUT ANY WARRANTY; without even the implied warranty of
+%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+%# General Public License for more details.
+%#
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+%# 02110-1301 or visit their web page on the internet at
+%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions,  LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# END BPS TAGGED BLOCK }}}
+<&| /Widgets/TitleBox, title => $title, class => 'article-listing', content_class => 'mx-auto' &>
+<div class="container article-listing-container">
+  <dl class="row">
+% while (my $article = $articles->Next) {
+    <dt class="col-md-5">
+      <a href="<% RT->Config->Get('WebPath') %>/SelfService/Article/Display.html?id=<%$article->Id%>"><%$article->Name || loc('(no name)')%></a>
+    </dt>
+    <dd class="col-md-7">
+      <% $article->Summary %>
+    </dd>
+% }
+  </dl>
+</div>
+</&>
+<%INIT>
+
+my $articles = RT::Articles->new($session{'CurrentUser'});
+$articles->UnLimit;
+$articles->OrderBy(FIELD => $orderby_field, ORDER => $sortorder);
+$articles->RowsPerPage($rows);
+
+</%INIT>
+<%ARGS>
+$orderby_field => 'LastUpdated'
+$sortorder     => 'Desc'
+$rows          => 5
+$title         => loc("[_1] Newest Articles", $rows)
+</%ARGS>
diff --git a/share/html/Elements/SelfServiceTopArticles b/share/html/Elements/SelfServiceTopArticles
new file mode 100644
index 0000000000..2709f87df3
--- /dev/null
+++ b/share/html/Elements/SelfServiceTopArticles
@@ -0,0 +1,48 @@
+%# BEGIN BPS TAGGED BLOCK {{{
+%#
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2020 Best Practical Solutions, LLC
+%#                                          <sales at bestpractical.com>
+%#
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
+%#
+%# This work is made available to you under the terms of Version 2 of
+%# the GNU General Public License. A copy of that license should have
+%# been provided with this software, but in any event can be snarfed
+%# from www.gnu.org.
+%#
+%# This work is distributed in the hope that it will be useful, but
+%# WITHOUT ANY WARRANTY; without even the implied warranty of
+%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+%# General Public License for more details.
+%#
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+%# 02110-1301 or visit their web page on the internet at
+%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions,  LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# END BPS TAGGED BLOCK }}}
+<& /Elements/SelfServiceShowArticles, orderby_field => 'SortOrder', sortorder => 'Desc', title => loc('[_1] Top Articles', 5), rows => 5 &>
diff --git a/share/static/css/elevator-light/articles.css b/share/static/css/elevator-light/articles.css
index 7e4a0f8a3f..9bbd012bd9 100644
--- a/share/static/css/elevator-light/articles.css
+++ b/share/static/css/elevator-light/articles.css
@@ -21,3 +21,13 @@
 #comp-Articles .form-row.article-summary {
     border-bottom: 1px solid #dee2e6;
 }
+
+/* Possibly remove or adjust if titlebox is updated */
+.article-listing-container {
+    margin-top: 10px;
+}
+
+/* Give it some space to resist the squeeze from parent's mx-auto */
+.article-listing-container dl {
+    min-width: 30em;
+}
diff --git a/share/static/css/elevator-light/base.css b/share/static/css/elevator-light/base.css
index dd86c5cd38..5938f2977b 100644
--- a/share/static/css/elevator-light/base.css
+++ b/share/static/css/elevator-light/base.css
@@ -5,3 +5,12 @@ a {
 a:visited {
     color: #666
 }
+
+dl {
+    font-size: 1.05rem;
+    margin-block-end: 0;
+}
+
+dd {
+    margin-bottom: .6rem;
+}

commit fb503bd292e9b428070b6fa89671fbd331d2463c
Author: Dianne Skoll <dianne at bestpractical.com>
Date:   Thu Dec 10 11:06:40 2020 -0500

    Clear user portlets as defaults for self service dashboard
    
    The components added in 47c40241e3 can't be used by most
    self service users because they require the rights and
    access of a privileged user.

diff --git a/etc/RT_Config.pm.in b/etc/RT_Config.pm.in
index 2539240f4d..fbe942e1d9 100644
--- a/etc/RT_Config.pm.in
+++ b/etc/RT_Config.pm.in
@@ -2970,7 +2970,6 @@ If this is not set at all, then $HomepageComponents is used instead.
 Set(
     $SelfServicePageComponents,
     [
-        qw(QuickCreate QueueList MyAdminQueues MySupportQueues MyReminders RefreshHomepage Dashboards SavedSearches FindUser MyAssets FindAsset FindGroup) # loc_qw
     ]
 );
 

commit c15845f48f41c165ef8ea3f4943b66509a075569
Author: Dianne Skoll <dianne at bestpractical.com>
Date:   Thu Dec 10 11:09:11 2020 -0500

    Add new article portlets to the available self service components

diff --git a/etc/RT_Config.pm.in b/etc/RT_Config.pm.in
index fbe942e1d9..2fc459c4dd 100644
--- a/etc/RT_Config.pm.in
+++ b/etc/RT_Config.pm.in
@@ -2969,8 +2969,7 @@ If this is not set at all, then $HomepageComponents is used instead.
 
 Set(
     $SelfServicePageComponents,
-    [
-    ]
+    [qw(SelfServiceTopArticles SelfServiceNewestArticles)]
 );
 
 =back

commit df26c551f8c1c0f890e8b1616495717ccdc56857
Merge: bd06a743f1 c15845f48f
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Sat Dec 12 05:37:12 2020 +0800

    Merge branch '5.0/add-self-service-article-components2' into 5.0-trunk


-----------------------------------------------------------------------


More information about the rt-commit mailing list