[Rt-commit] [rtir] 01/08: Remove broken code

Kevin Falcone falcone at bestpractical.com
Mon Aug 18 12:26:08 EDT 2014


This is an automated email from the git hooks/post-receive script.

falcone pushed a commit to branch 3.2/clean-up-articles-code
in repository rtir.

commit d4a2daf3401536628121ae2c27850072974b4480
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Fri Aug 15 16:14:20 2014 -0400

    Remove broken code
    
    In d9876b84 this was moved from Incident/LinkArticles.html to
    Link/Articles.html with the commit message:
    
       move LinkArticles.html into more natural location.
       it's not only about incidents
    
    It left hardcoded "Link selected articles to Incident $ticket->Id" even
    when run from an IR or an Investigation.
    
    Additionally, it didn't work. It submitted to "Display.html" which
    doesn't exist now that it was moved from RTIR/Incident/ into Link/
    
    So, delete this.  Users can instead use the core 'Extract Article' code
    which we'll stop from being deleted out of the menu in RTIR and they can
    link an Article either from the Article UI or by replying to a message
    and using an Article, like core articles has worked for years.
    
    I can see some argument for wanting to link an article to an incident to
    indicate the Article used to solve it, but that hasn't worked in any
    RTIR 3 release and we have no bug reports, so we'll see if it shows up
    as a feature request once it goes missing.
    
    Resolves issues #29961
    Resolves issues #29962
---
 MANIFEST                     |   1 -
 html/RTIR/Link/Articles.html | 106 -------------------------------------------
 2 files changed, 107 deletions(-)

diff --git a/MANIFEST b/MANIFEST
index 1ec0411..57a5665 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -104,7 +104,6 @@ html/RTIR/Incident/Reply/Refine.html
 html/RTIR/Incident/Split.html
 html/RTIR/index.html
 html/RTIR/Investigation/Elements/Create
-html/RTIR/Link/Articles.html
 html/RTIR/Link/FromIncident/index.html
 html/RTIR/Link/FromIncident/Refine.html
 html/RTIR/Link/ToIncident/index.html
diff --git a/html/RTIR/Link/Articles.html b/html/RTIR/Link/Articles.html
deleted file mode 100644
index 4f800c4..0000000
--- a/html/RTIR/Link/Articles.html
+++ /dev/null
@@ -1,106 +0,0 @@
-%# BEGIN BPS TAGGED BLOCK {{{
-%#
-%# COPYRIGHT:
-%#
-%# This software is Copyright (c) 1996-2014 Best Practical Solutions, LLC
-%#                                          <sales at bestpractical.com>
-%#
-%# (Except where explicitly superseded by other copyright notices)
-%#
-%#
-%# LICENSE:
-%#
-%# This work is made available to you under the terms of Version 2 of
-%# the GNU General Public License. A copy of that license should have
-%# been provided with this software, but in any event can be snarfed
-%# from www.gnu.org.
-%#
-%# This work is distributed in the hope that it will be useful, but
-%# WITHOUT ANY WARRANTY; without even the implied warranty of
-%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-%# General Public License for more details.
-%#
-%# You should have received a copy of the GNU General Public License
-%# along with this program; if not, write to the Free Software
-%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-%# 02110-1301 or visit their web page on the internet at
-%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html.
-%#
-%#
-%# CONTRIBUTION SUBMISSION POLICY:
-%#
-%# (The following paragraph is not intended to limit the rights granted
-%# to you to modify and distribute this software under the terms of
-%# the GNU General Public License and is only of importance to you if
-%# you choose to contribute your changes and enhancements to the
-%# community by submitting them to Best Practical Solutions, LLC.)
-%#
-%# By intentionally submitting any modifications, corrections or
-%# derivatives to this work, or any other work intended for use with
-%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
-%# you are the copyright holder for those contributions and you grant
-%# Best Practical Solutions,  LLC a nonexclusive, worldwide, irrevocable,
-%# royalty-free, perpetual, license to use, copy, create derivative
-%# works based on those contributions, and sublicense and distribute
-%# those contributions and any derivatives thereof.
-%#
-%# END BPS TAGGED BLOCK }}}
-<& /RTIR/Elements/Header, 
-    Title => $title,
-    Refresh => $session{'tickets_refresh_interval'},
-&>
-<& /Elements/Tabs &>
-
-<form action="Articles.html" method="get">
-<input type="hidden" name="id" value="<%$id%>" />
-
-Search: <input type="text" name="search" value="<% $search %>" />
-<& /Elements/Submit, Name => "DoSearch", Label => loc("Search") &>
-</form>
-
-<form action="Display.html" method="post">
-<input type="hidden" name="id" value="<%$id%>" />
-<ul>
-% while (my $article = $articles->Next) {
-<li><input type="checkbox" name="SelectedTickets" value="<% $article->id %>" /> 
-<a href="/Articles/Article/Display.html?id=<% $article->id %>"><%$article->Name|| loc('(no name)')%>: <%$article->Summary%></a>
-</li>
-% }
-</ul>
-% if ($search) {
-<& /Elements/Submit, Name => "BulkArticles", Caption => $title, Label => loc("Link") &>
-% }
-</form>
-
-<%INIT>
-my $IncidentObj = LoadTicket($id);
-$ARGS{'id'} = $id = $IncidentObj->id;
-my $title = loc("Link selected articles to Incident #[_1]", $id);
-
-use RT::Articles;
-my $articles = RT::Articles->new( $session{'CurrentUser'} );
-if ( $search ) {
-    $articles->LimitCustomField( VALUE => $search,
-                                 ENTRYAGGREGATOR => 'OR',
-                                 OPERATOR => 'LIKE',
-                                 CASESENSITIVE => 0,
-                                 SUBCLAUSE => 'SearchAll' );
-    $articles->Limit( SUBCLAUSE => 'SearchAll',
-                      FIELD => "Name",
-                      VALUE => $search,
-                      ENTRYAGGREGATOR => 'OR',
-                      CASESENSITIVE => 0,
-                      OPERATOR => 'LIKE' );
-    $articles->Limit( SUBCLAUSE => 'SearchAll',
-                      FIELD => "Summary",
-                      VALUE => $search,
-                      ENTRYAGGREGATOR => 'OR',
-                      CASESENSITIVE => 0,
-                      OPERATOR => 'LIKE' );
-}
-</%INIT>
-
-<%ARGS>
-$id          => undef
-$search      => ""
-</%ARGS>

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the rt-commit mailing list