[Rt-commit] rt branch, 4.2/autoopeninactive, created. rt-4.2.3-58-g36a7f2a

Alex Vandiver alexmv at bestpractical.com
Mon Mar 24 14:19:57 EDT 2014


The branch, 4.2/autoopeninactive has been created
        at  36a7f2a705e88fcffa027467b0942f019dfef506 (commit)

- Log -----------------------------------------------------------------
commit 36a7f2a705e88fcffa027467b0942f019dfef506
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Mon Mar 24 13:58:03 2014 -0400

    Add the AutoOpenInactive action for upgrades
    
    RT 4.2.0 included AutoOpenInactive for new installs, but neglected to
    add it for upgrades.  Add it unless it exists already.

diff --git a/etc/upgrade/4.2.4/content b/etc/upgrade/4.2.4/content
new file mode 100644
index 0000000..793661c
--- /dev/null
+++ b/etc/upgrade/4.2.4/content
@@ -0,0 +1,18 @@
+use strict;
+use warnings;
+
+our @ScripActions = (
+    { Name        => 'Open Inactive Tickets',                             # loc
+      Description => 'Open inactive tickets',                             # loc
+      ExecModule  => 'AutoOpenInactive' },
+);
+
+# Ignore the above if there is already an AutoOpenInactive in the
+# database -- i.e. originally a 4.2 install, or someone added one
+# themselves.
+our @Initial;
+push @Initial, sub {
+    my $exist = RT::ScripAction->new( RT->SystemUser );
+    $exist->LoadByCols( ExecModule => 'AutoOpenInactive' );
+    @ScripActions = () if $exist->Id;
+};

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


More information about the rt-commit mailing list