[Bps-public-commit] RT-Extension-MandatoryOnTransition branch master updated. 0.20-6-g9445661

BPS Git Server git at git.bestpractical.com
Fri Oct 29 15:24:54 UTC 2021


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "RT-Extension-MandatoryOnTransition".

The branch, master has been updated
       via  94456615aa94d07f401f5aac7afa6f2d3b9d28af (commit)
      from  757edbed16c5f8b90acd684f509a1b0ae2a79d59 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 94456615aa94d07f401f5aac7afa6f2d3b9d28af
Author: Jim Brandt <jbrandt at bestpractical.com>
Date:   Fri Oct 29 11:20:37 2021 -0400

    Version 0.21

diff --git a/Changes b/Changes
index 94e7cc6..b04c527 100644
--- a/Changes
+++ b/Changes
@@ -1,3 +1,12 @@
+Revision history for RT-Extension-MandatoryOnTransition
+
+0.21 2021-10-29
+ - Call RT method CustomFieldValueIsEmpty to perform additional custom
+   field checks. This specifically improves checks for date custom fields
+   because if RT can't parse the provided date value, it will mark the CF as
+   "empty" and correctly fail the mandatory check.
+ - Allow rules targeted to when a ticket is first created
+
 0.20 2020-07-20
  - Add RT 5 support
 
diff --git a/META.yml b/META.yml
index 87ecb59..bcd92ef 100644
--- a/META.yml
+++ b/META.yml
@@ -27,6 +27,6 @@ requires:
 resources:
   license: http://opensource.org/licenses/gpl-license.php
   repository: https://github.com/bestpractical/rt-extension-mandatoryontransition
-version: '0.20'
+version: '0.21'
 x_module_install_rtx_version: '0.42'
 x_requires_rt: 4.0.9
diff --git a/README b/README
index 9d26660..1bbead6 100644
--- a/README
+++ b/README
@@ -3,9 +3,10 @@ NAME
     custom fields on status transitions
 
 RT VERSION
-    Works with RT 4.0, 4.2, 4.4, 5.0
+    Works with RT 4.4, 5.0
 
-    See below for some restrictions on RT 4.0.
+    RT 4.0 and 4.2 are now end-of-life, so compatibility with newer versions
+    of this extension is unknown.
 
 DESCRIPTION
     This RT extension enforces that certain fields have values before
@@ -98,7 +99,19 @@ CONFIGURATION
 
     from and to are expected to be valid status names. from may also be *
     which will apply to any status and also tickets about to be created with
-    status to.
+    status to. If you need to express rules that apply only on ticket
+    creation and not on updates, you can use the special from value of
+    '__CREATE__'. For example,
+
+        Set( %MandatoryOnTransition,
+            'MyQueue' => {
+                '__CREATE__ -> open' => [ 'CF.MyField1' ],
+                '* -> open' => [ 'CF.MyField2', 'CF.MyField3' ],
+            },
+        );
+
+    would require CF.MyField1 on ticket creation and CF.MyField2 and
+    CF.MyField3 on any other transition to open.
 
     The fallback for queues without specific rules is specified with '*'
     where the queue name would normally be.
@@ -267,7 +280,8 @@ IMPLEMENTATION DETAILS
     Works for both create, where no ticket exists yet, and update on an
     existing ticket. ARGSRef is required for both.
 
-    For create, you must also pass Queue, From, and To.
+    For create, you must also pass Queue, From, and To. In this case, the
+    From status should be the special flag value of '__CREATE__'.
 
     Update requires only Ticket and To since From can be fetched from the
     ticket object.
diff --git a/lib/RT/Extension/MandatoryOnTransition.pm b/lib/RT/Extension/MandatoryOnTransition.pm
index 6641b4c..cf05e46 100644
--- a/lib/RT/Extension/MandatoryOnTransition.pm
+++ b/lib/RT/Extension/MandatoryOnTransition.pm
@@ -2,7 +2,7 @@ use strict;
 use warnings;
 package RT::Extension::MandatoryOnTransition;
 
-our $VERSION = '0.20';
+our $VERSION = '0.21';
 
 =head1 NAME
 
@@ -10,9 +10,10 @@ RT-Extension-MandatoryOnTransition - Require core fields and ticket custom field
 
 =head1 RT VERSION
 
-Works with RT 4.0, 4.2, 4.4, 5.0
+Works with RT 4.4, 5.0
 
-See below for some restrictions on RT 4.0.
+RT 4.0 and 4.2 are now end-of-life, so compatibility with
+newer versions of this extension is unknown.
 
 =head1 DESCRIPTION
 

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

Summary of changes:
 Changes                                   |  9 +++++++++
 META.yml                                  |  2 +-
 README                                    | 22 ++++++++++++++++++----
 lib/RT/Extension/MandatoryOnTransition.pm |  7 ++++---
 4 files changed, 32 insertions(+), 8 deletions(-)


hooks/post-receive
-- 
RT-Extension-MandatoryOnTransition


More information about the Bps-public-commit mailing list