[Bps-public-commit] RT-Extension-MandatoryOnTransition branch, master, updated. 0.17-18-g40d2593

? sunnavy sunnavy at bestpractical.com
Wed Mar 6 10:44:20 EST 2019


The branch, master has been updated
       via  40d25932e9c95b5d550dfbaedd2edd5c9f7b6c55 (commit)
       via  cd8e0855122a4bd6ad64d7092f3705634b67ad1d (commit)
       via  5f01b7f386c1778f7a11bcbb6cdb5c5c8524b2b0 (commit)
       via  0d4a1d2f1c58ddfea65f1528ec976d5c9b38afed (commit)
       via  fca3b705968a5b4e53ecf374ea2aa53516127583 (commit)
       via  c56963525fb7a0bdc6f08f645c9232e298ac12ca (commit)
       via  494255868a6de2f3db5b0977500b614d507a74d5 (commit)
       via  ab3ccd16b921fae3d908dce89eecba41a051fde9 (commit)
       via  da4a3c672b6899172edf7514f0a2fedeb953f18f (commit)
       via  9f9ba4d1e7d77d304d7cd538f91f669e8de94fc4 (commit)
       via  6372befe64924122ddd3673390177d5db37a7a2c (commit)
       via  6fa3fb132d0b5d79cf8906e23462ffe1bdd13e04 (commit)
       via  28a916328d7478523d013411539954c691735fb7 (commit)
       via  e9c0920827dc735273dfd44617af170c406f2589 (commit)
       via  09476d7cc2ea3884645360cf49be63c9c37ee748 (commit)
       via  22bbbed513ff045ef50a23fa63e8839478c3bb53 (commit)
       via  17728a4bb85907e195ebb897b7bc285f100db420 (commit)
       via  7e53f384837acc6c10338ff1d8a10bd76578eff6 (commit)
      from  cd48f7d453771df0ef7e2fce18a0bea2c1e41b74 (commit)

Summary of changes:
 Changes                                            |   3 +
 MANIFEST                                           |   3 +-
 META.yml                                           |   2 +-
 README                                             |  44 ++-
 .../Ticket/Elements/EditBasics/MassageFields       |  66 ++++
 .../Ticket/Update.html/AfterWorked                 |  64 +++-
 lib/RT/Extension/MandatoryOnTransition.pm          | 358 ++++++++++++++++++---
 xt/require_owner_for_resolve.t                     | 122 -------
 xt/required_fields.t                               |   9 +-
 xt/roles.t                                         | 251 +++++++++++++++
 10 files changed, 730 insertions(+), 192 deletions(-)
 create mode 100644 html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/Elements/EditBasics/MassageFields
 delete mode 100644 xt/require_owner_for_resolve.t
 create mode 100644 xt/roles.t

- Log -----------------------------------------------------------------
commit 5f01b7f386c1778f7a11bcbb6cdb5c5c8524b2b0
Merge: cd48f7d 0d4a1d2
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Wed Mar 6 22:10:59 2019 +0800

    Merge branch 'roles'


commit cd8e0855122a4bd6ad64d7092f3705634b67ad1d
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Wed Mar 6 22:57:13 2019 +0800

    Initialize RT::CustomRole only when necessary in case it's RT 4.0 or 4.2

diff --git a/lib/RT/Extension/MandatoryOnTransition.pm b/lib/RT/Extension/MandatoryOnTransition.pm
index 1f47ae0..a48ef3c 100644
--- a/lib/RT/Extension/MandatoryOnTransition.pm
+++ b/lib/RT/Extension/MandatoryOnTransition.pm
@@ -386,7 +386,6 @@ sub RequiredFields {
     }
 
     my %role_group_values;
-    my $cr = RT::CustomRole->new(RT->SystemUser);
     my $queue_id;
     if ( $args{Ticket} ) {
         $queue_id = $args{Ticket}->Queue;
@@ -399,6 +398,7 @@ sub RequiredFields {
 
     foreach my $role (@roles){
         if ( $role =~ /^CustomRole\.(.*)/i ) {
+            my $cr = RT::CustomRole->new(RT->SystemUser);
             my $role_name = $1;
             my ($ret, $msg) = $cr->Load($role_name);
             if ( not $cr and $cr->Id ) {

commit 40d25932e9c95b5d550dfbaedd2edd5c9f7b6c55
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Wed Mar 6 23:38:01 2019 +0800

    Release 0.18

diff --git a/Changes b/Changes
index 5eb32fc..44b901b 100644
--- a/Changes
+++ b/Changes
@@ -1,3 +1,6 @@
+0.18 2019-03-06
+ - Add support for all the roles as mandatory fields.
+
 0.17 2018-10-26
  - Add support for Owner as a mandatory field
 
diff --git a/MANIFEST b/MANIFEST
index 0f57660..e37f3e8 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -5,6 +5,7 @@ html/Callbacks/RT-Extension-MandatoryOnTransition/m/ticket/create/BeforeCreate
 html/Callbacks/RT-Extension-MandatoryOnTransition/m/ticket/reply/AfterWorked
 html/Callbacks/RT-Extension-MandatoryOnTransition/m/ticket/reply/BeforeUpdate
 html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/Create.html/BeforeCreate
+html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/Elements/EditBasics/MassageFields
 html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/Elements/EditCustomFields/MassageCustomFields
 html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/Modify.html/Default
 html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/ModifyAll.html/Default
@@ -38,5 +39,5 @@ xt/basic.t
 xt/immutable_core_for_update.t
 xt/mandatory_on_create.t
 xt/queue_change.t
-xt/require_owner_for_resolve.t
 xt/required_fields.t
+xt/roles.t
diff --git a/META.yml b/META.yml
index 5463e30..5496763 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.17'
+version: '0.18'
 x_module_install_rtx_version: '0.40'
 x_requires_rt: 4.0.9
diff --git a/lib/RT/Extension/MandatoryOnTransition.pm b/lib/RT/Extension/MandatoryOnTransition.pm
index a48ef3c..97bf52c 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.17';
+our $VERSION = '0.18';
 
 =head1 NAME
 

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


More information about the Bps-public-commit mailing list