[Rt-commit] rtir branch, 2.5-trunk, updated. 984fd28b9599979b415bb015ddb70d8bfe68402c

Ruslan Zakirov ruz at bestpractical.com
Mon Nov 23 05:49:43 EST 2009


The branch, 2.5-trunk has been updated
       via  984fd28b9599979b415bb015ddb70d8bfe68402c (commit)
       via  e69e16f9ecca85549a0eee0e28a3a25a05bce2fa (commit)
       via  614e18c5a7ef8b8be0e99dc60618436140780662 (commit)
       via  7692caa41179e5434b39d8851284c8420ce05df5 (commit)
       via  85f2291d7ef7cdf743ffd4eb429bdb98ac84e727 (commit)
       via  4c07bee675e87c485479d896f0f19a67ec7c7605 (commit)
       via  492be83299e2798bbb8dc734dcdf26ff2925e267 (commit)
       via  64affd85f2f2ead07336572dd4d704e2f38313ef (commit)
       via  7c69fe9464753e06052558a49c82700cceee4acd (commit)
       via  939ee670db8cdae51410807bc69c2285cba5dbeb (commit)
      from  051cd664eb8c330dd7627a579600d3cbb3de27f6 (commit)

Summary of changes:
 .gitignore                               |    1 +
 CHANGES                                  |    9 ++++++++-
 META.yml                                 |    2 +-
 html/RTIR/Elements/AddWatchers           |    2 +-
 html/RTIR/Elements/SimpleSearch          |    3 +--
 html/RTIR/Incident/Edit.html             |    5 +++--
 html/RTIR/Incident/Elements/ShowChildren |    5 +++++
 html/RTIR/Prefs/Home.html                |    2 +-
 html/RTIR/Tools/Elements/Tabs            |    2 +-
 lib/RT/IR.pm                             |    8 ++++++--
 10 files changed, 28 insertions(+), 11 deletions(-)

- Log -----------------------------------------------------------------
commit 939ee670db8cdae51410807bc69c2285cba5dbeb
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Fri Aug 28 16:38:18 2009 -0400

    Switch simplesearch over to the buttonless version from rt-3.8
    
    On IE and smaller resolutions, this stops the menu bar from wrapping
    really oddly by svaing us some space.

diff --git a/html/RTIR/Elements/SimpleSearch b/html/RTIR/Elements/SimpleSearch
index cfcb7d3..f28d310 100644
--- a/html/RTIR/Elements/SimpleSearch
+++ b/html/RTIR/Elements/SimpleSearch
@@ -24,6 +24,5 @@
 <form action="<% RT->Config->Get('WebPath') %>/RTIR/index.html" id="simple-search">
 <input type="hidden" name="NewSearch" value="1" />
 <input type="hidden" name="Queue" value="Incidents" />
-<input size="12" name="q" accesskey="0" />
-<input type="submit" class="button" value="<&|/l&>Search Incidents</&>" />&nbsp;
+<input size="15" name="q" accesskey="0" value="<&|/l&>Search Incidents</&>..." onfocus="if (this.value=='<&|/l&>Search Incidents</&>...') this.value=''" />
 </form>

commit 7c69fe9464753e06052558a49c82700cceee4acd
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Fri Aug 28 16:42:09 2009 -0400

    Be clear that we're editing RTIR at a Glance
    
    This introduces another translatable string

diff --git a/html/RTIR/Prefs/Home.html b/html/RTIR/Prefs/Home.html
index b6f5217..61f1393 100644
--- a/html/RTIR/Prefs/Home.html
+++ b/html/RTIR/Prefs/Home.html
@@ -5,7 +5,7 @@
 <& /Widgets/SelectionBox:header, nojs => 1 &>
 % foreach my $box( @boxes ) {
 <&|/Widgets/TitleBox,
-    title => loc('RT at a glance') .': '. loc( $box->{Name} ),
+    title => loc('RTIR at a glance') .': '. loc( $box->{Name} ),
     bodyclass => ""
 &>
 <& /Widgets/SelectionBox:show, self => $box, nojs => 1 &>

commit 64affd85f2f2ead07336572dd4d704e2f38313ef
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Tue Sep 1 16:20:30 2009 -0400

    ignore vim swp files

diff --git a/.gitignore b/.gitignore
index 642007d..19902d6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,3 +3,4 @@ Makefile.old
 MANIFEST.bak
 blib/
 pm_to_blib
+*.swp

commit 492be83299e2798bbb8dc734dcdf26ff2925e267
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Tue Sep 1 16:21:50 2009 -0400

    silence an annoying warning

diff --git a/html/RTIR/Elements/AddWatchers b/html/RTIR/Elements/AddWatchers
index 956aece..b6389a5 100644
--- a/html/RTIR/Elements/AddWatchers
+++ b/html/RTIR/Elements/AddWatchers
@@ -39,7 +39,7 @@
 <tr><td><&|/l&>Type</&></td><td><&|/l&>Group</&></td></tr>
 % while ( my $g = $Groups->Next ) {
 <tr><td><& /Elements/SelectWatcherType, Name => "Ticket-AddWatcher-Principal-". $g->PrincipalId, Scope => 'queue' &></td>
-<td><% $g->Name %> (<% $g->Description %>)</td></tr>
+<td><% $g->Name %> (<% $g->Description||'' %>)</td></tr>
 % }
 % }
 

commit 4c07bee675e87c485479d896f0f19a67ec7c7605
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Sat Oct 17 18:24:31 2009 -0400

    Don't display a disabled Constituency during Incident editing

diff --git a/html/RTIR/Incident/Edit.html b/html/RTIR/Incident/Edit.html
index 4ad10d9..5c9dab8 100644
--- a/html/RTIR/Incident/Edit.html
+++ b/html/RTIR/Incident/Edit.html
@@ -69,7 +69,7 @@
     <td class="label"><&|/l&>Time Worked</&>:</td>
     <td class="value"><input name="TimeWorked" value="<%$Ticket->TimeWorked|h%>" size="5" /></td>
   </tr>
-% if ( $constituency_propagation ne 'reject' || !$has_children ) {
+% if ( $constituency_cf && ( $constituency_propagation ne 'reject' || !$has_children )) {
   <tr>
     <td class="label"><&|/l&>Constituency</&>:</td>
     <td class="value">
@@ -126,9 +126,10 @@ $CanRespond = 1 if ( $Ticket->CurrentUserHasRight('ReplyToTicket') or
 $CanComment = 1 if ( $Ticket->CurrentUserHasRight('CommentOnTicket') or
                      $Ticket->CurrentUserHasRight('ModifyTicket') );
 
+my $constituency_cf = RT::IR->CustomFields( Constituency => Ticket => $Ticket );
 my $constituency_propagation = RT->Config->Get('_RTIR_Constituency_Propagation');
 my $has_children = 0;
-if ( $constituency_propagation eq 'reject' ) {
+if ( $constituency_cf && $constituency_propagation eq 'reject' ) {
     my $query = "( Queue = 'Incident Reports' OR Queue = 'Investigations' OR Queue = 'Blocks' )"
         ." AND MemberOf = ". $Ticket->id;
     my $tickets = RT::Tickets->new( $RT::SystemUser );

commit 85f2291d7ef7cdf743ffd4eb429bdb98ac84e727
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Fri Oct 23 21:11:36 2009 -0400

    Don't die, this cached is called when RT::IR is loaded
    and the database may not be initialized yet.

diff --git a/lib/RT/IR.pm b/lib/RT/IR.pm
index ffe820f..cca42b4 100644
--- a/lib/RT/IR.pm
+++ b/lib/RT/IR.pm
@@ -238,7 +238,11 @@ sub CustomFields {
 
             my $queue = RT::Queue->new( $RT::SystemUser );
             $queue->Load( $qname );
-            die "Couldn't load queue '$qname'" unless $queue->id;
+            unless ($queue->id) {
+                $RT::Logger->error("Couldn't load queue '$qname'");
+                delete $cache{$type};
+                return;
+            }
 
             my $cfs = RT::CustomFields->new( $RT::SystemUser );
             $cfs->LimitToLookupType( 'RT::Queue-RT::Ticket' );

commit 7692caa41179e5434b39d8851284c8420ce05df5
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Mon Oct 26 16:40:04 2009 -0400

    use new style callback

diff --git a/html/RTIR/Tools/Elements/Tabs b/html/RTIR/Tools/Elements/Tabs
index 42c8b3f..ea6a491 100644
--- a/html/RTIR/Tools/Elements/Tabs
+++ b/html/RTIR/Tools/Elements/Tabs
@@ -22,7 +22,7 @@
 %# 
 %# 
 %# END LICENSE BLOCK
-<& /Elements/Callback, tabs => $tabs, %ARGS &>
+% $m->callback( tabs => $tabs, %ARGS );
 <& /RTIR/Elements/Tabs,
     tabs           => $tabs,
     current_toptab => $current_toptab,

commit 614e18c5a7ef8b8be0e99dc60618436140780662
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Tue Oct 27 16:35:49 2009 -0400

    Hide Launch link if the user can't actually Launch an investigation
    
    (Yes, this is a weird use case, but RTIR works even with pared back
     rights on Investigations, except this part is really confusing)

diff --git a/html/RTIR/Incident/Elements/ShowChildren b/html/RTIR/Incident/Elements/ShowChildren
index 809e00c..aec268e 100644
--- a/html/RTIR/Incident/Elements/ShowChildren
+++ b/html/RTIR/Incident/Elements/ShowChildren
@@ -11,7 +11,9 @@
 
 % if ( $IncidentObj->CurrentUserHasRight('ModifyTicket') ) {
     <table width="100%"><tr><td align="right"><font size="-1">
+%   if ( $QueueObj->Id and $QueueObj->CurrentUserHasRight('CreateTicket') ) {
         | <a href="<%RT->Config->Get('WebPath')%>/RTIR/Create.html?Incident=<% $id %>&Queue=<% $Queue |u %>"><% $new_caption %></a> 
+%   }
         | <a href="<%RT->Config->Get('WebPath')%>/RTIR/Incident/LinkChildren.html?id=<% $id %>&Queue=<% $Queue |u %>"><%loc("Link")%></a> |
     </font></td></tr></table>
 % }
@@ -72,4 +74,7 @@ $inactive->FromSQL(
 
 my $total_count = $active->CountAll + $inactive->CountAll;
 
+my $QueueObj = RT::Queue->new($session{CurrentUser});
+$QueueObj->Load($Queue);
+
 </%INIT>

commit e69e16f9ecca85549a0eee0e28a3a25a05bce2fa
Author: Ruslan Zakirov <ruz at bestpractical.com>
Date:   Mon Nov 23 13:46:14 2009 +0300

    update change log

diff --git a/CHANGES b/CHANGES
index a7c0119..a306010 100644
--- a/CHANGES
+++ b/CHANGES
@@ -20,7 +20,8 @@ FEATURES
 * allow to use any custom field for lookup, not only IP,
   no UI at the moment, but can be used via arguments of a URL
   in clicky actions or linked CFs 
-* RTIR's QuickSearch searches by IP in all queues if
+* switch SimpleSearch over to the buttonless version
+* RTIR's SimpleSearch searches by IP in all queues if
   query is an IP only
 * we have search in any RTIR's queue, so we need default
   search format, new entry in $RTIRSearchResultFormats
@@ -31,6 +32,12 @@ FEATURES
 * refactored test suite for re-use in RTIR's extensions
 * described better Incident input field on Create pages
 
+BUGS
+====
+
+* Hide Launch links if user can not create an Inv
+* More...
+
 CALLBACKS
 =========
 

commit 984fd28b9599979b415bb015ddb70d8bfe68402c
Author: Ruslan Zakirov <ruz at bestpractical.com>
Date:   Mon Nov 23 13:47:54 2009 +0300

    bump version, 2.5.7

diff --git a/META.yml b/META.yml
index 967268d..5cf39f2 100644
--- a/META.yml
+++ b/META.yml
@@ -33,4 +33,4 @@ requires:
   Regexp::Common: 0
   Regexp::Common::net::CIDR: 0
   perl: 5.8.3
-version: 2.5.6
+version: 2.5.7
diff --git a/lib/RT/IR.pm b/lib/RT/IR.pm
index cca42b4..5a9b246 100644
--- a/lib/RT/IR.pm
+++ b/lib/RT/IR.pm
@@ -46,7 +46,7 @@
 #
 package RT::IR;
 
-our $VERSION = '2.5.6';
+our $VERSION = '2.5.7';
 
 use 5.008003;
 use warnings;

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


More information about the Rt-commit mailing list