[Rt-commit] rt branch, 4.0/stop-hardcoding-new, created. rt-4.0.20-20-gd1f3878

Kevin Falcone falcone at bestpractical.com
Tue Jun 3 17:19:37 EDT 2014

The branch, 4.0/stop-hardcoding-new has been created
        at  d1f38786d048d1320f68cfbac8e6b583f3d2c073 (commit)

- Log -----------------------------------------------------------------
commit d1f38786d048d1320f68cfbac8e6b583f3d2c073
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Tue Jun 3 16:50:51 2014 -0400

    Let you Quick Create in Queues that don't define the new status
    Since we don't offer Status in the Quick Create widget, we should just
    let Create pick the on_create default from the Queue's lifecycle.
    While in here, update RT::Ticket::Create to have less lying around what
    to pass for Status (valid statuses haven't listed been in
    RT::Queue in 4.0 or 4.2).
    We started using the default from the Queue's Lifecycle in b206b50a,
    which is the same commit where we stopped hardcoding 'new' in
    Found in RTIR user since 3 of the 4 RTIR queues don't allow tickets
    with the new status.

diff --git a/lib/RT/Ticket.pm b/lib/RT/Ticket.pm
index 7b1e945..d1fd83e 100644
--- a/lib/RT/Ticket.pm
+++ b/lib/RT/Ticket.pm
@@ -202,7 +202,7 @@ Arguments: ARGS is a hash of named parameters.  Valid parameters are:
   Priority -- an integer from 0 to 99
   InitialPriority -- an integer from 0 to 99
   FinalPriority -- an integer from 0 to 99
-  Status -- any valid status (Defined in RT::Queue)
+  Status -- any valid status for Queue's Lifecycle, otherwises uses on_create from Lifecycle default
   TimeEstimated -- an integer. estimated time for this task in minutes
   TimeWorked -- an integer. time worked so far in minutes
   TimeLeft -- an integer. time remaining in minutes
diff --git a/share/html/index.html b/share/html/index.html
index 6bd5c9f..45ebc62 100644
--- a/share/html/index.html
+++ b/share/html/index.html
@@ -106,7 +106,7 @@ if ( $ARGS{'QuickCreate'} ) {
         my ($t, $msg) = CreateTicket( 
                         Queue => $ARGS{'Queue'},
                         Owner => $ARGS{'Owner'},
-                        Status => $ARGS{'Status'}||'new',
+                        Status => $ARGS{'Status'},
                         # yes! it's Requestors, not Requestor
                         Requestors => $ARGS{'Requestors'},
                         From => $session{'CurrentUser'}->EmailAddress,


More information about the rt-commit mailing list