[Rt-commit] rtir branch, 2.5-trunk, updated. 1ab67f22b9783cf608106dd00cbc6c6a24e628b2

Ruslan Zakirov ruz at bestpractical.com
Thu Sep 10 18:42:02 EDT 2009


The branch, 2.5-trunk has been updated
       via  1ab67f22b9783cf608106dd00cbc6c6a24e628b2 (commit)
      from  c69f53d1bfb8722aac56c182bc378ad9c066eab1 (commit)

Summary of changes:
 html/RTIR/index.html |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

- Log -----------------------------------------------------------------
commit 1ab67f22b9783cf608106dd00cbc6c6a24e628b2
Author: Ruslan Zakirov <ruz at bestpractical.com>
Date:   Fri Sep 11 02:33:16 2009 +0400

    as IP field applies to all queues we should search in all

diff --git a/html/RTIR/index.html b/html/RTIR/index.html
index 3ca6bb5..b1c58c9 100644
--- a/html/RTIR/index.html
+++ b/html/RTIR/index.html
@@ -69,7 +69,13 @@ if ( $ARGS{'q'} ) {
         $query ||= 'id = 0';
     }
     elsif ( $query =~ /^\s*($RE{net}{IPv4})\s*$/o && RT::IR->CustomFields('IP') ) {
-        $query = "Queue = 'Incidents' AND 'CustomField.{IP}' = '$1'";
+
+        $query = join ' OR ', map "Queue = '$_'", ('Incidents', 'Incident Reports', 'Investigations', 'Blocks');
+        $query = "($query) AND 'CustomField.{IP}' = '$1'";
+        return $m->comp(
+            '/RTIR/Search/Results.html',
+            Query => $query,
+        );
     }
     else {
         # Any search on queue name or subject will be for new/open tickets only.

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


More information about the Rt-commit mailing list