[Rt-commit] rtir branch, 5.0/restore-incidents-and-investigations-on-create, repushed

Blaine Motsinger blaine at bestpractical.com
Wed May 20 19:22:41 EDT 2020


The branch 5.0/restore-incidents-and-investigations-on-create was deleted and repushed:
       was 879a8b8de0398ba5965990a029756c922eb9aec1
       now cfdf08ed77c990bdaad44a6a9044a488994b86c1

1: ebc13027 ! 1: 18fbd784 Core RT::Extension::CreateIncidentAndInvestigation
    @@ -32,14 +32,28 @@
      %    ChildObj => $ChildObj, SplitObj => $SplitObj, ARGSRef => \%ARGS );
      
     @@
    +         last;
    + }
    + 
    +-
    + my $QueueObj = RT::Queue->new($session{'CurrentUser'});
    + $QueueObj->Load( $ARGS{Queue} );
    + 
    +@@
      Abort( loc("Queue '[_1]' could not be loaded.", $ARGS{Queue}) );
       }
      
    ++# Ensure the consistuency is set based on the incident queue.
    ++# The investigations queue needs to correspond to the selected incidents queue not just the default one.
    ++unless ($constituency) {
    ++    $constituency = RT::IR->ConstituencyFor($QueueObj);
    ++}
    ++
     +# Load appropriate Investigations queue
    -+my $InvestigationsQueue = 'Investigations';
    ++my $InvestigationsQueue = 'Investigations' . ( $constituency ? ' - ' . $constituency : '' );
     +my $InvestigationsQueueObj = RT::Queue->new( $session{'CurrentUser'} );
     +my ($ret, $msg) = $InvestigationsQueueObj->Load( $InvestigationsQueue );
    -+RT::Logger->error("Unable to load $InvestigationsQueue : $msg") unless $ret;
    ++RT->Logger->error("Unable to load $InvestigationsQueue : $msg") unless $ret;
     +
      if( !RT::IR->IsIncidentQueue($QueueObj) ) {
          RT::Interface::Web::Redirect(RT::IR->HREFTo( '/Create.html?' . $m->comp('/Elements/QueryString', %ARGS )));
2: 879a8b8d ! 2: c62411be Migrate Investigation/Elements/Create to elevator themes
    @@ -1,19 +1,6 @@
     Author: Blaine Motsinger <blaine at bestpractical.com>
     
         Migrate Investigation/Elements/Create to elevator themes
    -
    -diff --git a/html/RTIR/Incident/Create.html b/html/RTIR/Incident/Create.html
    ---- a/html/RTIR/Incident/Create.html
    -+++ b/html/RTIR/Incident/Create.html
    -@@
    - my $InvestigationsQueue = 'Investigations';
    - my $InvestigationsQueueObj = RT::Queue->new( $session{'CurrentUser'} );
    - my ($ret, $msg) = $InvestigationsQueueObj->Load( $InvestigationsQueue );
    --RT::Logger->error("Unable to load $InvestigationsQueue : $msg") unless $ret;
    -+RT->Logger->error("Unable to load $InvestigationsQueue : $msg") unless $ret;
    - 
    - if( !RT::IR->IsIncidentQueue($QueueObj) ) {
    -     RT::Interface::Web::Redirect(RT::IR->HREFTo( '/Create.html?' . $m->comp('/Elements/QueryString', %ARGS )));
     
     diff --git a/html/RTIR/Investigation/Elements/Create b/html/RTIR/Investigation/Elements/Create
     --- a/html/RTIR/Investigation/Elements/Create
    @@ -32,10 +19,10 @@
     +
     +% if ($Constituency) {
     +  <div class="form-row">
    -+    <div class="label col-md-3">
    ++    <div class="label col-3">
     +      <% loc('Constituency') %>:
     +    </div>
    -+    <div class="value col-md-9">
    ++    <div class="value col-9">
     +      <span class="current-value"><% $Constituency %></span>
     +    </div>
     +  </div>
    @@ -45,10 +32,10 @@
     -  <td>
     +
     +  <div class="form-row">
    -+    <div class="label col-md-3">
    ++    <div class="label col-3">
     +      <&|/l&>Queue</&>:
     +    </div>
    -+    <div class="value col-md-9">
    ++    <div class="value col-9">
            <& /Ticket/Elements/ShowQueue, QueueObj => $QueueObj &>
     -  </td>
     -</tr>
    @@ -64,10 +51,10 @@
     -    Default  => $value_cb->('Owner') || $session{'CurrentUser'}->Id,
     -&></td></tr>
     +  <div class="form-row owner">
    -+    <div class="label col-md-3">
    ++    <div class="label col-3">
     +      <&|/l&>Owner</&>:
     +    </div>
    -+    <div class="value col-md-9">
    ++    <div class="value col-9">
     +      <& /Elements/SelectOwner,
     +          Name     => $NamePrefix ."Owner",
     +          QueueObj => $QueueObj,
    @@ -348,7 +335,7 @@
     -    SubmitId => 'create-ticket-with-investigation'
     -&>
     +<div class="form-row">
    -+  <div class="col-md-12">
    ++  <div class="col-12">
     +    <& /Elements/Submit,
     +        Name => 'CreateWithInvestigation',
     +        Label => loc("Create Incident and run Investigation"),
    @@ -359,3 +346,4 @@
      
      % $m->callback( CallbackName => 'AfterTable', ARGSRef => \%ARGS, TicketObj  => $ticket,
      %    QueueObj   => $QueueObj, DefaultsFrom => $TicketObj );
    +
-:  ------- > 3: cfdf08ed Replace Cc and AdminCc helper text with tooltips



More information about the rt-commit mailing list