[Bps-public-commit] RT-BugTracker branch, rt5, created. 5.2-26-gd9fa024

? sunnavy sunnavy at bestpractical.com
Thu Feb 25 13:22:24 EST 2021


The branch, rt5 has been created
        at  d9fa0243c3e149dc0042729d1ee2b47a0c0bbf51 (commit)

- Log -----------------------------------------------------------------
commit 277b4cdfaa7ce426fe20c8ca5cfbd56d1f34fb4a
Merge: b36fd93 f76f067
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Thu Feb 25 16:08:39 2021 +0800

    Merge branch '4.2-4.4-compatibility' into rt5


commit 8d444d8a0e0449e2926ff9d7dedcaa5f93b01139
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Thu Feb 25 16:10:56 2021 +0800

    Update M:I

diff --git a/META.yml b/META.yml
index 418740c..1320b3c 100644
--- a/META.yml
+++ b/META.yml
@@ -8,7 +8,7 @@ configure_requires:
   ExtUtils::MakeMaker: 6.59
 distribution_type: module
 dynamic_config: 1
-generated_by: 'Module::Install version 1.17'
+generated_by: 'Module::Install version 1.19'
 license: gpl
 meta-spec:
   url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -28,6 +28,6 @@ resources:
   license: http://opensource.org/licenses/gpl-license.php
   repository: https://github.com/bestpractical/rt-bugtracker
 version: '5.5'
-x_module_install_rtx_version: '0.38'
+x_module_install_rtx_version: '0.42'
 x_requires_rt: 4.2.0
 x_rt_too_new: 4.6.0
diff --git a/inc/Module/Install.pm b/inc/Module/Install.pm
index dbe10ca..7ba98c2 100644
--- a/inc/Module/Install.pm
+++ b/inc/Module/Install.pm
@@ -31,7 +31,7 @@ BEGIN {
 	# This is not enforced yet, but will be some time in the next few
 	# releases once we can make sure it won't clash with custom
 	# Module::Install extensions.
-	$VERSION = '1.17';
+	$VERSION = '1.19';
 
 	# Storage for the pseudo-singleton
 	$MAIN    = undef;
diff --git a/inc/Module/Install/Base.pm b/inc/Module/Install/Base.pm
index 3d89918..9fa42c2 100644
--- a/inc/Module/Install/Base.pm
+++ b/inc/Module/Install/Base.pm
@@ -4,7 +4,7 @@ package Module::Install::Base;
 use strict 'vars';
 use vars qw{$VERSION};
 BEGIN {
-	$VERSION = '1.17';
+	$VERSION = '1.19';
 }
 
 # Suspend handler for "redefined" warnings
diff --git a/inc/Module/Install/Can.pm b/inc/Module/Install/Can.pm
index fc699b3..d65c753 100644
--- a/inc/Module/Install/Can.pm
+++ b/inc/Module/Install/Can.pm
@@ -8,7 +8,7 @@ use Module::Install::Base ();
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '1.17';
+	$VERSION = '1.19';
 	@ISA     = 'Module::Install::Base';
 	$ISCORE  = 1;
 }
diff --git a/inc/Module/Install/Fetch.pm b/inc/Module/Install/Fetch.pm
index 3ee0aa1..3072b08 100644
--- a/inc/Module/Install/Fetch.pm
+++ b/inc/Module/Install/Fetch.pm
@@ -6,7 +6,7 @@ use Module::Install::Base ();
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '1.17';
+	$VERSION = '1.19';
 	@ISA     = 'Module::Install::Base';
 	$ISCORE  = 1;
 }
diff --git a/inc/Module/Install/Include.pm b/inc/Module/Install/Include.pm
index e8a73b8..13fdcd0 100644
--- a/inc/Module/Install/Include.pm
+++ b/inc/Module/Install/Include.pm
@@ -6,7 +6,7 @@ use Module::Install::Base ();
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '1.17';
+	$VERSION = '1.19';
 	@ISA     = 'Module::Install::Base';
 	$ISCORE  = 1;
 }
diff --git a/inc/Module/Install/Makefile.pm b/inc/Module/Install/Makefile.pm
index bc81e06..13a4464 100644
--- a/inc/Module/Install/Makefile.pm
+++ b/inc/Module/Install/Makefile.pm
@@ -8,7 +8,7 @@ use Fcntl qw/:flock :seek/;
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '1.17';
+	$VERSION = '1.19';
 	@ISA     = 'Module::Install::Base';
 	$ISCORE  = 1;
 }
diff --git a/inc/Module/Install/Metadata.pm b/inc/Module/Install/Metadata.pm
index 29934cf..11bf971 100644
--- a/inc/Module/Install/Metadata.pm
+++ b/inc/Module/Install/Metadata.pm
@@ -6,7 +6,7 @@ use Module::Install::Base ();
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '1.17';
+	$VERSION = '1.19';
 	@ISA     = 'Module::Install::Base';
 	$ISCORE  = 1;
 }
diff --git a/inc/Module/Install/RTx.pm b/inc/Module/Install/RTx.pm
index 80538d3..2dd9489 100644
--- a/inc/Module/Install/RTx.pm
+++ b/inc/Module/Install/RTx.pm
@@ -6,9 +6,10 @@ use strict;
 use warnings;
 no warnings 'once';
 
+use Term::ANSIColor qw(:constants);
 use Module::Install::Base;
 use base 'Module::Install::Base';
-our $VERSION = '0.38';
+our $VERSION = '0.42';
 
 use FindBin;
 use File::Glob     ();
@@ -53,7 +54,7 @@ sub RTx {
         my @look = @INC;
         unshift @look, grep {defined and -d $_} @try;
         push @look, grep {defined and -d $_}
-            map { ( "$_/rt4/lib", "$_/lib/rt4", "$_/lib" ) } @prefixes;
+            map { ( "$_/rt5/lib", "$_/lib/rt5", "$_/rt4/lib", "$_/lib/rt4", "$_/lib" ) } @prefixes;
         last if eval {local @INC = @look; require RT; $RT::LocalLibPath};
 
         warn
@@ -76,6 +77,22 @@ sub RTx {
         $self->requires_rt('4.0.0');
     }
 
+    my $package = $name;
+    $package =~ s/-/::/g;
+    if ( $RT::CORED_PLUGINS{$package} ) {
+        my ($base_version) = $RT::VERSION =~ /(\d+\.\d+\.\d+)/;
+        die RED, <<"EOT";
+
+**** Error: Your installed version of RT ($RT::VERSION) already
+            contains this extension in core, so you don't need to
+            install it.
+
+            Check https://docs.bestpractical.com/rt/$base_version/RT_Config.html
+            to configure it.
+
+EOT
+    }
+
     # Installation locations
     my %path;
     my $plugin_path;
@@ -113,11 +130,29 @@ lexicons ::
 .
     }
 
+    my $remove_files;
+    if( $extra_args->{'remove_files'} ){
+        $self->include('Module::Install::RTx::Remove');
+        our @remove_files;
+        eval { require "etc/upgrade/remove_files" }
+          or print "No remove file located, no files to remove\n";
+        $remove_files = join ",", map {"q(\$(DESTDIR)$plugin_path/$name/$_)"} @remove_files;
+    }
+
     $self->include('Module::Install::RTx::Runtime') if $self->admin;
     $self->include_deps( 'YAML::Tiny', 0 ) if $self->admin;
     my $postamble = << ".";
 install ::
 \t\$(NOECHO) \$(PERL) -Ilib -I"$local_lib_path" -I"$lib_path" -Iinc -MModule::Install::RTx::Runtime -e"RTxPlugin()"
+.
+
+    if( $remove_files ){
+        $postamble .= << ".";
+\t\$(NOECHO) \$(PERL) -MModule::Install::RTx::Remove -e \"RTxRemove([$remove_files])\"
+.
+    }
+
+    $postamble .= << ".";
 \t\$(NOECHO) \$(PERL) -MExtUtils::Install -e \"install({$args})\"
 .
 
@@ -205,7 +240,7 @@ sub requires_rt {
     my @sorted = sort RT::Handle::cmp_version $version,$RT::VERSION;
 
     if ($sorted[-1] eq $version) {
-        die <<"EOT";
+        die RED, <<"EOT";
 
 **** Error: This extension requires RT $version. Your installed version
             of RT ($RT::VERSION) is too old.
@@ -231,12 +266,12 @@ sub requires_rt_plugin {
         unshift @INC, $path;
     } else {
         my $name = $self->name;
-        warn <<"EOT";
+        my $msg = <<"EOT";
 
 **** Warning: $name requires that the $plugin plugin be installed and
               enabled; it does not appear to be installed.
-
 EOT
+        warn RED, $msg, RESET, "\n";
     }
     $self->requires(@_);
 }
@@ -246,9 +281,8 @@ sub rt_too_new {
     my $name = $self->name;
     $msg ||= <<EOT;
 
-**** Error: Your installed version of RT (%s) is too new; this extension
-            only works with versions older than %s.
-
+**** Warning: Your installed version of RT (%s) is too new; this extension
+              has not been tested on your version of RT and may not work as expected.
 EOT
     $self->add_metadata("x_rt_too_new", $version) if $self->is_admin;
 
@@ -256,7 +290,7 @@ EOT
     my @sorted = sort RT::Handle::cmp_version $version,$RT::VERSION;
 
     if ($sorted[0] eq $version) {
-        die sprintf($msg,$RT::VERSION,$version);
+        warn RED, sprintf($msg,$RT::VERSION), RESET, "\n";
     }
 }
 
@@ -279,4 +313,4 @@ sub _load_rt_handle {
 
 __END__
 
-#line 428
+#line 484
diff --git a/inc/Module/Install/RTx/Runtime.pm b/inc/Module/Install/RTx/Runtime.pm
index 937949f..ae07502 100644
--- a/inc/Module/Install/RTx/Runtime.pm
+++ b/inc/Module/Install/RTx/Runtime.pm
@@ -33,6 +33,7 @@ sub RTxDatabase {
 
     my $lib_path = File::Basename::dirname($INC{'RT.pm'});
     my @args = (
+        "-I.",
         "-Ilib",
         "-I$RT::LocalLibPath",
         "-I$lib_path",
diff --git a/inc/Module/Install/ReadmeFromPod.pm b/inc/Module/Install/ReadmeFromPod.pm
index 3634ee0..3738232 100644
--- a/inc/Module/Install/ReadmeFromPod.pm
+++ b/inc/Module/Install/ReadmeFromPod.pm
@@ -7,7 +7,7 @@ use warnings;
 use base qw(Module::Install::Base);
 use vars qw($VERSION);
 
-$VERSION = '0.26';
+$VERSION = '0.30';
 
 {
 
diff --git a/inc/Module/Install/Win32.pm b/inc/Module/Install/Win32.pm
index dba25f9..f7aa615 100644
--- a/inc/Module/Install/Win32.pm
+++ b/inc/Module/Install/Win32.pm
@@ -6,7 +6,7 @@ use Module::Install::Base ();
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '1.17';
+	$VERSION = '1.19';
 	@ISA     = 'Module::Install::Base';
 	$ISCORE  = 1;
 }
diff --git a/inc/Module/Install/WriteAll.pm b/inc/Module/Install/WriteAll.pm
index d553bd7..2db861a 100644
--- a/inc/Module/Install/WriteAll.pm
+++ b/inc/Module/Install/WriteAll.pm
@@ -6,7 +6,7 @@ use Module::Install::Base ();
 
 use vars qw{$VERSION @ISA $ISCORE};
 BEGIN {
-	$VERSION = '1.17';
+	$VERSION = '1.19';
 	@ISA     = qw{Module::Install::Base};
 	$ISCORE  = 1;
 }
diff --git a/inc/YAML/Tiny.pm b/inc/YAML/Tiny.pm
index 4fd023d..fb157a6 100644
--- a/inc/YAML/Tiny.pm
+++ b/inc/YAML/Tiny.pm
@@ -2,12 +2,12 @@
 use 5.008001; # sane UTF-8 support
 use strict;
 use warnings;
-package YAML::Tiny; # git description: v1.69-8-g2c1e266
+package YAML::Tiny; # git description: v1.72-7-g8682f63
 # XXX-INGY is 5.8.1 too old/broken for utf8?
 # XXX-XDG Lancaster consensus was that it was sufficient until
 # proven otherwise
 
-our $VERSION = '1.70';
+our $VERSION = '1.73';
 
 #####################################################################
 # The YAML::Tiny API.
@@ -374,7 +374,7 @@ sub _load_scalar {
     while ( @$lines ) {
         $lines->[0] =~ /^(\s*)/;
         last unless length($1) >= $indent->[-1];
-        push @multiline, substr(shift(@$lines), length($1));
+        push @multiline, substr(shift(@$lines), $indent->[-1]);
     }
 
     my $j = (substr($string, 0, 1) eq '>') ? ' ' : "\n";

commit defa3841d7a1defb95de0e7313a2a5945cff0f1b
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Thu Feb 25 16:11:36 2021 +0800

    Add "." to @INC for perl 5.26+

diff --git a/Makefile.PL b/Makefile.PL
index 26961ff..2ff0066 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -1,3 +1,4 @@
+use lib '.';
 use inc::Module::Install;
 
 RTx('RT-BugTracker');

commit 323a2a8a46e0fa561ec213547fa4f391554c70c8
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Thu Feb 25 16:12:10 2021 +0800

    Update rt_too_new to 5.2 as we are going to support 5.0

diff --git a/Makefile.PL b/Makefile.PL
index 2ff0066..ca35a1e 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -6,7 +6,7 @@ RTx('RT-BugTracker');
 repository('https://github.com/bestpractical/rt-bugtracker');
 
 requires_rt('4.2.0');
-rt_too_new('4.6.0');
+rt_too_new('5.2.0');
 
 no_index( package => 'RT::Queue' );
 

commit 5e32d94589ef2b0c742ef963e2a01599b1d0e783
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Fri Feb 26 00:08:23 2021 +0800

    Bump minimal RT to 5

diff --git a/Makefile.PL b/Makefile.PL
index ca35a1e..a1d7e62 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -5,7 +5,7 @@ RTx('RT-BugTracker');
 
 repository('https://github.com/bestpractical/rt-bugtracker');
 
-requires_rt('4.2.0');
+requires_rt('5.0.0');
 rt_too_new('5.2.0');
 
 no_index( package => 'RT::Queue' );

commit 7e50e8476382032f32dce2ddc7d7873e5f736528
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Fri Feb 26 00:21:53 2021 +0800

    Migrate to RT 5 elevator themes

diff --git a/html/Callbacks/BugTracker/Elements/Tabs/SelfService b/html/Callbacks/BugTracker/Elements/Tabs/SelfService
index 73e1b6f..6e62187 100644
--- a/html/Callbacks/BugTracker/Elements/Tabs/SelfService
+++ b/html/Callbacks/BugTracker/Elements/Tabs/SelfService
@@ -114,7 +114,7 @@ if ( $request_path =~ m{^/Dist/(?:Display|Manage)\.html} ) {
         );
         PageMenu()->child(
             active => title => loc("Active bugs"),
-            path => "/Dist/Display.html?Status=Active;Queue=" . $escaped_queue,
+            path => "/Dist/Display.html?Status=__Active__;Queue=" . $escaped_queue,
         );
 
         PageMenu()->child(
diff --git a/html/Dist/Display.html b/html/Dist/Display.html
index 6c806d6..7f7292f 100755
--- a/html/Dist/Display.html
+++ b/html/Dist/Display.html
@@ -77,7 +77,18 @@ unless ( $QueueObj->id ) {
 }
 $ARGS{'Name'} = $Name = $QueueObj->Name;
 
-my $title = loc( "$Status bugs for [_1]", $Name );
+my $status_text;
+if ( $Status =~ /__active__/i ) {
+    $status_text = loc('Active');
+}
+elsif ( $Status =~ /__active__/i ) {
+    $status_text = loc('Inactive');
+}
+else {
+    $status_text = $Status;
+}
+
+my $title = loc( "[_1] bugs for [_2]", $status_text, $Name );
 
 my $current_subtab = "Dist/Display.html"
     ."?Status=". $m->interp->apply_escapes($Status, 'u')
@@ -96,5 +107,5 @@ my $RSSFeedURL = $m->comp('/Dist/Elements/ShowBugs:RSS',
 $Name   => undef
 # Queue is an alias for Name, Name has higher precendance
 $Queue  => undef
-$Status => 'Active'
+$Status => '__Active__'
 </%ARGS>
diff --git a/html/Dist/Elements/BeginsWith b/html/Dist/Elements/BeginsWith
index 60aae4f..6abe878 100644
--- a/html/Dist/Elements/BeginsWith
+++ b/html/Dist/Elements/BeginsWith
@@ -46,7 +46,8 @@
 %#
 %# END BPS TAGGED BLOCK }}}
 <form action="<% RT->Config->Get('WebPath') %><% $m->request_path %>" method="GET">
-<p>
+  <div class="form-row">
+    <div class="label col-auto">
 % if (RT->Config->Get('BugTracker_HideBrowseDistributions')) {
  <% loc('Prefix is') %>
 % } else {
@@ -58,8 +59,11 @@
 % }
  <% loc('or prefix is') %>
 % }
-<input type="text" name="Name" value="<% length($Name) > 1? $Name : '' %>" data-autocomplete="Queues" data-autocomplete-autosubmit=1 />
-</p>
+    </div>
+    <div class="value col-auto">
+      <input type="text" name="Name" class="form-control" value="<% length($Name) > 1? $Name : '' %>" data-autocomplete="Queues" data-autocomplete-autosubmit=1 autocomplete="off" />
+    </div>
+  </div>
 </form>
 <%ARGS>
 $Name => undef
diff --git a/html/Dist/Elements/DistributionList b/html/Dist/Elements/DistributionList
index 0f73087..1044d09 100644
--- a/html/Dist/Elements/DistributionList
+++ b/html/Dist/Elements/DistributionList
@@ -45,8 +45,9 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<div class="dist-list">
-<ul>
+<div class="dist-list row mt-2">
+  <div class="col-6">
+    <ul class="list-group">
 % my $count  = $queues->Count;
 % my $broken = 0;
 %
@@ -57,11 +58,12 @@
 %           and $queues->_ItemsCounter >= $count / 2)
 %     {
 %         $broken = 1;
-</ul>
-
-<ul>
+    </ul>
+  </div>
+  <div class="col-6">
+    <ul class="list-group">
 %     }
-  <li>
+  <li class="list-group-item">
     <span class="dist-actions">
       <a href="<% $RT::WebPath %>/Dist/Display.html?Queue=<% $queue->Name |uhn %>"><% loc('Bug list') %></a>
       •
@@ -70,7 +72,8 @@
     <strong><% $queue->Name %></strong>
   </li>
 % }
-</ul>
+    </ul>
+  </div>
 </div>
 
 <%args>
diff --git a/html/Dist/Elements/EditNotes b/html/Dist/Elements/EditNotes
index 6ddfcc5..b95e27f 100644
--- a/html/Dist/Elements/EditNotes
+++ b/html/Dist/Elements/EditNotes
@@ -45,8 +45,15 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<label class="dist-notes"><% loc('Distribution notes') %> (<% loc('HTML subset allowed') %>):
-<textarea cols="120" rows="20" name="Queue-<% $Queue->id %>-Notes"><% $value %></textarea></label><br />
+<div class="form-row dist-notes">
+  <div class="label col-3">
+    <% loc('Distribution notes') %>:
+    <span class="far fa-question-circle icon-helper" data-toggle="tooltip" data-placement="top" data-original-title="<% loc('HTML subset allowed') %>"></span>
+  </div>
+  <div class="value col-8">
+    <textarea cols="120" rows="20" class="form-control" name="Queue-<% $Queue->id %>-Notes"><% $value %></textarea></label><br />
+  </div>
+</div>
 <%ARGS>
 $Queue => undef
 </%ARGS>
diff --git a/html/Dist/Elements/EditNotifyAddresses b/html/Dist/Elements/EditNotifyAddresses
index ed150cd..8d89841 100644
--- a/html/Dist/Elements/EditNotifyAddresses
+++ b/html/Dist/Elements/EditNotifyAddresses
@@ -45,8 +45,14 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<label class="dist-addresses"><% loc('Additional addresses RT should notify') %>:
-<textarea cols="120" rows="10" name="Queue-<% $Queue->id %>-NotifyAddresses"><% join ', ', @$value %></textarea></label><br />
+<div class="form-row dist-addresses">
+  <div class="label col-3">
+    <% loc('Additional addresses RT should notify') %>:
+  </div>
+  <div class="value col-8">
+    <textarea cols="120" rows="10" class="form-control" name="Queue-<% $Queue->id %>-NotifyAddresses"><% join ', ', @$value %></textarea></label><br />
+  </div>
+</div>
 <%ARGS>
 $Queue => undef
 </%ARGS>
diff --git a/html/Dist/Elements/EditSubjectTag b/html/Dist/Elements/EditSubjectTag
index 677b02e..1bfe25e 100644
--- a/html/Dist/Elements/EditSubjectTag
+++ b/html/Dist/Elements/EditSubjectTag
@@ -45,9 +45,15 @@
 %# those contributions and any derivatives thereof.
 %#
 %# END BPS TAGGED BLOCK }}}
-<label class="dist-subjecttag"><% loc('Subject tag in addition to default') %>
-(<% loc('be reasonable') %>, <code><% RT->Config->Get("DistributionSubjectTagAllowed") %></code> is allowed, <code><% RT->Config->Get("WebDomain") %></code> will be prepended):
-<input size="120" name="Queue-<% $Queue->id %>-SubjectTag" value="<% $value || '' %>" /></label><br />
+<div class="form-row dist-subjecttag">
+  <div class="label col-3">
+    <% loc('Subject tag in addition to default') %>:
+    <span class="far fa-question-circle icon-helper" data-toggle="tooltip" data-placement="top" data-original-title="(<% loc('be reasonable') %>, <% RT->Config->Get("DistributionSubjectTagAllowed") %> is allowed, <% RT->Config->Get("WebDomain") %> will be prepended)"></span>
+  </div>
+  <div class="value col-8">
+    <input size="120" class="form-control" name="Queue-<% $Queue->id %>-SubjectTag" value="<% $value || '' %>" /></label><br />
+  </div>
+</div>
 <%ARGS>
 $Queue => undef
 </%ARGS>
diff --git a/html/Dist/Elements/ShowBugs b/html/Dist/Elements/ShowBugs
index 9f06b2a..2da4056 100644
--- a/html/Dist/Elements/ShowBugs
+++ b/html/Dist/Elements/ShowBugs
@@ -64,21 +64,12 @@
 &>
 
 <%INIT>
-unless ( ($Status||'') eq 'Active' || $Queue->IsValidStatus( lc $Status ) ) {
+unless ( ($Status||'') =~ /__(?:active|inactive)__/i || $Queue->IsValidStatus( lc $Status ) ) {
     $m->comp('/Elements/Error', Why => q{no such status as '} . $Status . q{'});
     $m->abort();
 }
 
-my $Query = "Queue = '". $Queue->Name ."'";
-if ( $Status eq 'Active' ) {
-    $Query .= " AND ( "
-        .join( ' OR ', map "Status = '$_'", $Queue->ActiveStatusArray )
-        ." )";
-}
-else {
-    $Query .= " AND Status = '$Status'";
-}
-
+my $Query = "Queue = '". $Queue->Name ."' AND Status = '$Status'";
 my $RSSFeedURL = $m->comp('SELF:RSS', Query => $Query );
 
 </%INIT>
@@ -101,30 +92,25 @@ $BaseURL => undef
 $Queue  => undef
 $Status => undef
 $Query  => undef
+$OrderBy => 'LastUpdated'
+$Order   => 'DESC'
 </%ARGS>
 <%INIT>
 
-if ( $Query ) {
-    return "$RT::WebPath/Search/Results.rdf?"
-        . $m->comp('/Elements/QueryString', Query => $Query);
-}
+if ( !$Query ) {
+    unless ( ($Status||'') =~ /__(?:active|inactive)__/i || $Queue->IsValidStatus( lc $Status ) ) {
+        $m->comp( '/Elements/Error', Why => q{no such status as '} . $Status . q{'} );
+        $m->abort();
+    }
 
-unless ( ($Status||'') eq 'Active' || $Queue->IsValidStatus( lc $Status ) ) {
-    $m->comp('/Elements/Error', Why => q{no such status as '} . $Status . q{'});
-    $m->abort();
+    $Query = "Queue = '". $Queue->Name ."' AND Status = '$Status'";
 }
 
-$Query = "Queue = '". $Queue->Name ."'";
-if ( $Status eq 'Active' ) {
-    $Query .= " AND ( "
-        .join( ' OR ', map "Status = '$_'", $Queue->ActiveStatusArray )
-        ." )";
-}
-else {
-    $Query .= " AND Status = '$Status'";
-}
+my $RSSQueryString = "?" . $m->comp('/Elements/QueryString', Query => $Query, Order => $Order, OrderBy => $OrderBy );
+my $RSSPath = join '/', map $HTML::Mason::Commands::m->interp->apply_escapes( $_, 'u' ),
+    $session{CurrentUser}->UserObj->Name,
+    $session{CurrentUser}->UserObj->GenerateAuthString( $Query . $Order . $OrderBy );
 
-return "$RT::WebPath/Search/Results.rdf?"
-    . $m->comp('/Elements/QueryString', Query => $Query);
+return "/NoAuth/rss/$RSSPath/$RSSQueryString";
 </%INIT>
 </%METHOD>
diff --git a/html/Dist/Elements/ShowBugtracker b/html/Dist/Elements/ShowBugtracker
index 6d222c3..a095107 100644
--- a/html/Dist/Elements/ShowBugtracker
+++ b/html/Dist/Elements/ShowBugtracker
@@ -46,7 +46,7 @@
 %#
 %# END BPS TAGGED BLOCK }}}
 % if ( defined $bugtracker ) {
-<div id="external_bugtracker">
+<div id="external_bugtracker" class="alert alert-warning mt-2">
 <h3><% loc("Preferred bug tracker") %></h3>
 %
 % if ( defined $bugtracker->{mailto} ) {
diff --git a/html/Dist/Elements/ShowNotes b/html/Dist/Elements/ShowNotes
index 6a2a3bc..bb40fc3 100644
--- a/html/Dist/Elements/ShowNotes
+++ b/html/Dist/Elements/ShowNotes
@@ -48,7 +48,7 @@
 % $m->callback( %ARGS, CallbackName => "Top" );
 
 % if ( $Queue->Disabled ) {
-<&| /Widgets/TitleBox, title => loc("Queue is disabled"), class => "error", hideable => 0 &>
+<&| /Widgets/TitleBox, title => loc("Queue is disabled"), class => "error-titlebox", hideable => 0 &>
 <&|/l&>This queue is disabled and you may not create new tickets in it.  Disabled queues are usually because the distribution was merged with another or changed names.  Sometimes they are the end result of a bad autocreate from PAUSE data before anyone noticed.</&>
 </&>
 % }
diff --git a/html/Dist/Manage.html b/html/Dist/Manage.html
index 40755d3..f4a6458 100644
--- a/html/Dist/Manage.html
+++ b/html/Dist/Manage.html
@@ -53,16 +53,21 @@
 
 <& /Elements/ListActions, actions => \@results &>
 
-<form action="<% $RT::WebPath %><% $m->request_comp->path %>" method="post">
+<form action="<% $RT::WebPath %><% $m->request_comp->path %>" method="post" class="mx-auto max-width-lg">
 <input type="hidden" class="hidden" name="Queue" value="<% $QueueObj->Name %>" />
-
+<&| /Widgets/TitleBox, class => 'queue-info-basics', content_class => 'mx-auto width-lg' &>
 <& /Dist/Elements/EditNotes, Queue => $QueueObj &>
 
 <& /Dist/Elements/EditNotifyAddresses, Queue => $QueueObj &>
 
 <& /Dist/Elements/EditSubjectTag, Queue => $QueueObj &>
+</&>
 
-<& /Elements/Submit, Label => loc('Save Changes'), Name => 'Update' &>
+<div class="form-row">
+  <div class="col-12">
+    <& /Elements/Submit, Label => loc('Save Changes'), Name => 'Update' &>
+  </div>
+</div>
 
 </form>
 <%INIT>
diff --git a/html/Dist/Search.html b/html/Dist/Search.html
index 3d0b659..e5fb6f4 100755
--- a/html/Dist/Search.html
+++ b/html/Dist/Search.html
@@ -51,34 +51,66 @@
 % unless (RT->Config->Get('BugTracker_ShowAllDistributions')) {
 <p>
   <form action="/Dist/Display.html" method="get">
-    <label for="form-dist-name"><&|/l&>Find a distribution by full name:</&></label>
-    <input type="text" name="Queue" id="form-dist-name" data-autocomplete="Queues" data-autocomplete-autosubmit=1 />
-    <input type="submit" class="button" value="<&|/l&>Search</&>" />
+    <div class="form-row">
+      <div class="col-auto label">
+        <&|/l&>Find a distribution by full name:</&>
+      </div>
+      <div class="col-auto">
+        <input type="text" name="Queue" data-autocomplete="Queues" data-autocomplete-autosubmit=1 autocomplete="off" />
+      </div>
+      <div class="col-auto">
+        <input type="submit" class="button btn btn-primary form-control" value="<&|/l&>Search</&>" />
+      </div>
+    </div>
   </form>
 </p>
 
 <p>
   <form action="/Dist/Browse.html" method="get">
-    <label for="form-dist-name"><&|/l&>Find distributions by beginning of name:</&></label>
-    <input type="text" name="Name" id="form-dist-name" data-autocomplete="Queues" data-autocomplete-autosubmit=1 />
-    <input type="submit" class="button" value="<&|/l&>Search</&>" />
+    <div class="form-row">
+      <div class="col-auto label">
+        <&|/l&>Find distributions by beginning of name:</&>
+      </div>
+      <div class="col-auto">
+        <input type="text" name="Name" data-autocomplete="Queues" data-autocomplete-autosubmit=1 autocomplete="off" />
+      </div>
+      <div class="col-auto">
+        <input type="submit" class="button btn btn-primary form-control" value="<&|/l&>Search</&>" />
+      </div>
+    </div>
   </form>
 </p>
 
 <p>
   <form action="/Dist/ByMaintainer.html" method="get">
-    <label for="form-dist-maint"><&|/l&>Find distributions by maintainer:</&></label>
-    <input type="text" name="Name" id="form-dist-maint" data-autocomplete="Users" data-autocomplete-autosubmit=1 />
-    <input type="submit" class="button" value="<&|/l&>Search</&>" />
+    <div class="form-row">
+      <div class="col-auto label">
+        <&|/l&>Find distributions by maintainer:</&>
+      </div>
+      <div class="col-auto">
+        <input class="form-control" type="text" name="Name" id="form-dist-maint" data-autocomplete="Users" data-autocomplete-autosubmit=1 autocomplete="off" />
+      </div>
+      <div class="col-auto">
+        <input type="submit" class="button btn btn-primary form-control" value="<&|/l&>Search</&>" />
+      </div>
+    </div>
   </form>
 </p>
 % }
 
 <p>
   <form action="/Search/Simple.html" method="get">
-    <label for="form-simple-query"><&|/l&>General search:</&></label>
-    <input type="text" name="q" id="form-simple-query" />
-    <input type="submit" class="button" value="<&|/l&>Search</&>" />
+    <div class="form-row">
+      <div class="col-auto label">
+        <&|/l&>General search:</&>
+      </div>
+      <div class="col-auto">
+        <input class="form-control" type="text" name="q" id="form-simple-query" />
+      </div>
+      <div class="col-auto">
+        <input type="submit" class="button btn btn-primary form-control" value="<&|/l&>Search</&>" />
+      </div>
+    </div>
   </form>
 
   <&|/l&>This search looks for bug report IDs, distribution names, usernames, and bug report descriptions among other fields.</&>
diff --git a/html/Elements/ErrorNoDist b/html/Elements/ErrorNoDist
index 4c0ee14..69a6aff 100644
--- a/html/Elements/ErrorNoDist
+++ b/html/Elements/ErrorNoDist
@@ -48,7 +48,7 @@
 <& /Elements/Header, Title => loc("Error") &>
 <& /Elements/Tabs, Title => loc("Unable to find distribution") &>
 
-<p>
+<p class="mt-2">
 % if ($Queue) {
   The distribution you specified, <strong><% $Queue %></strong>, could not be found.
 % }
diff --git a/html/Elements/ErrorNoUser b/html/Elements/ErrorNoUser
index 20dc1d0..a5bceff 100644
--- a/html/Elements/ErrorNoUser
+++ b/html/Elements/ErrorNoUser
@@ -48,7 +48,7 @@
 <& /Elements/Header, Title => loc("Error") &>
 <& /Elements/Tabs, Title => loc("Unable to find user") &>
 
-<p>
+<p class="mt-2">
   The user you specified, <strong><% $Name %></strong>, could not be found.
 </p>
 
diff --git a/lib/RT/BugTracker.pm b/lib/RT/BugTracker.pm
index b949a1b..adc7fba 100644
--- a/lib/RT/BugTracker.pm
+++ b/lib/RT/BugTracker.pm
@@ -105,8 +105,6 @@ STUB: The additional subject tag is currently broken in 4.2/4.4. BPS will docume
 
 =cut
 
-RT->AddStyleSheets("bugtracker.css");
-
 require RT::Queue;
 package RT::Queue;
 
diff --git a/static/css/bugtracker.css b/static/css/bugtracker.css
deleted file mode 100644
index 4329273..0000000
--- a/static/css/bugtracker.css
+++ /dev/null
@@ -1,16 +0,0 @@
-#external_bugtracker {
-    width: 50%;
-    border: 1px solid #666;
-    background: #ffffaa 8px 15px no-repeat;
-    padding: 0px 10px 10px 60px;
-    margin: 20px auto;
-    min-height: 30px;
-    -webkit-box-shadow: inset 2px 2px 2px 2px #999;
-    box-shadow: inset 2px 2px 2px 2px #999;
-    -webkit-border-radius: 10px;
-    border-radius: 10px;
-}
-
-.dist-notes textarea, .dist-addresses textarea, .dist-subjecttag input {
-    display: block;
-}

commit d9fa0243c3e149dc0042729d1ee2b47a0c0bbf51
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Fri Feb 26 02:17:30 2021 +0800

    Update manifest

diff --git a/MANIFEST b/MANIFEST
index 6b818a2..376ad19 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -52,4 +52,3 @@ Makefile.PL
 MANIFEST			This list of files
 META.yml
 README
-static/css/bugtracker.css

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


More information about the Bps-public-commit mailing list