From 5c96d46d56f2066bb40d9a34c4db56f53f43c6f2 Mon Sep 17 00:00:00 2001 From: ivan Date: Thu, 31 Dec 2009 14:00:35 +0000 Subject: merging 3.8.7!!! --- rt/html/SelfService/Attachment/dhandler | 51 ------ rt/html/SelfService/Closed.html | 56 ------- rt/html/SelfService/Create.html | 177 -------------------- rt/html/SelfService/CreateTicketInQueue.html | 63 ------- rt/html/SelfService/Display.html | 235 --------------------------- rt/html/SelfService/Elements/GotoTicket | 48 ------ rt/html/SelfService/Elements/Header | 49 ------ rt/html/SelfService/Elements/MyRequests | 84 ---------- rt/html/SelfService/Elements/Tabs | 113 ------------- rt/html/SelfService/Error.html | 70 -------- rt/html/SelfService/Prefs.html | 92 ----------- rt/html/SelfService/Update.html | 129 --------------- rt/html/SelfService/index.html | 54 ------ 13 files changed, 1221 deletions(-) delete mode 100644 rt/html/SelfService/Attachment/dhandler delete mode 100644 rt/html/SelfService/Closed.html delete mode 100644 rt/html/SelfService/Create.html delete mode 100755 rt/html/SelfService/CreateTicketInQueue.html delete mode 100644 rt/html/SelfService/Display.html delete mode 100644 rt/html/SelfService/Elements/GotoTicket delete mode 100644 rt/html/SelfService/Elements/Header delete mode 100644 rt/html/SelfService/Elements/MyRequests delete mode 100644 rt/html/SelfService/Elements/Tabs delete mode 100644 rt/html/SelfService/Error.html delete mode 100644 rt/html/SelfService/Prefs.html delete mode 100644 rt/html/SelfService/Update.html delete mode 100644 rt/html/SelfService/index.html (limited to 'rt/html/SelfService') diff --git a/rt/html/SelfService/Attachment/dhandler b/rt/html/SelfService/Attachment/dhandler deleted file mode 100644 index 592062b54..000000000 --- a/rt/html/SelfService/Attachment/dhandler +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<%init> -$m->comp('/Ticket/Attachment/dhandler', %ARGS); -$m->abort; - diff --git a/rt/html/SelfService/Closed.html b/rt/html/SelfService/Closed.html deleted file mode 100644 index 1f53655ee..000000000 --- a/rt/html/SelfService/Closed.html +++ /dev/null @@ -1,56 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& /SelfService/Elements/Header, Title => loc('Closed tickets') &> - -<& /SelfService/Elements/MyRequests, status => ['rejected', 'resolved'], - friendly_status => loc('closed'), - BaseURL => $RT::WebPath . "/SelfService/Closed.html?", - Page => $Page &> -<%ARGS> -$Page => 1 - diff --git a/rt/html/SelfService/Create.html b/rt/html/SelfService/Create.html deleted file mode 100644 index 9a64b5fd9..000000000 --- a/rt/html/SelfService/Create.html +++ /dev/null @@ -1,177 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& Elements/Header, Title => loc("Create a ticket") &> - -<& /Elements/ListActions, actions => \@results &> - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<&|/l&>Queue: - - <% $queue_obj->Name %> (<%$queue_obj->Description || ''%>) -
<&|/l&>Requestors: - -
<&|/l&>Cc: - -
<&|/l&>Subject: - -
- <& /Ticket/Elements/EditCustomFields, QueueObj => $queue_obj &> -
<&|/l&>Attach file: - -
-<&|/l&>Describe the issue below:
-% if (exists $ARGS{Content}) { -<& /Elements/MessageBox, Default => $ARGS{Content}, IncludeSignature => 0 &> -% } else { -<& /Elements/MessageBox &> -% } -
-<& /Elements/Submit, Label => loc("Create ticket")&> - - -
-<%args> -$Queue => undef - -<%init> -my $queue_obj = RT::Queue->new($session{'CurrentUser'}); -$queue_obj->Load($Queue) || Abort(loc("Queue could not be loaded.")); -$queue_obj->Disabled && Abort(loc("Cannot create tickets in a disabled queue.")); - -my ($checks_failure, $skip_create, @results) = (0, 0, ()); -$skip_create = 1 unless ($ARGS{'id'}||'') eq 'new'; - -$m->comp('/Elements/Callback', - QueueObj => $queue_obj, ARGSRef => \%ARGS, - skip_create => \$skip_create, checks_failure => \$checks_failure, - results => \@results -); - -$skip_create = 1 if exists $ARGS{'AddMoreAttach'}; - -# deal with deleting uploaded attachments -foreach my $key (keys %ARGS) { - if ($key =~ m/^DeleteAttach-(.+)$/) { - delete $session{'Attachments'}{$1}; - } - $session{'Attachments'} = { %{$session{'Attachments'} || {}} }; -} - -# store the uploaded attachment in session -if ( $ARGS{'Attach'} ) { # attachment? - $session{'Attachments'} = {} unless defined $session{'Attachments'}; - - my $subject = "$ARGS{'Attach'}"; - - # strip leading directories - $subject =~ s#^.*[\\/]##; - - my $attachment = MakeMIMEEntity( - Subject => $subject, - Body => "", - AttachmentFieldName => 'Attach' - ); - - $session{'Attachments'} = { %{$session{'Attachments'} || {}}, - $ARGS{'Attach'} => $attachment }; -} - -unless (keys %{$session{'Attachments'}} and $ARGS{'id'} eq 'new') { - delete $session{'Attachments'}; -} - -my $CFs = $queue_obj->TicketCustomFields; -my $ValidCFs = $m->comp( - '/Elements/ValidateCustomFields', - CustomFields => $CFs, - ARGSRef => \%ARGS -); -unless ( $ValidCFs ) { - $checks_failure = 1; - while ( my $CF = $CFs->Next ) { - my $msg = $m->notes('InvalidField-' . $CF->Id) or next; - push @results, $CF->Name . ': ' . $msg - if ($ARGS{'id'}||'') eq 'new'; - } -} - -if ( !$checks_failure && !$skip_create ) { - $m->comp('Display.html', %ARGS); - $RT::Logger->crit("After display call; error is $@"); - $m->abort(); -} - diff --git a/rt/html/SelfService/CreateTicketInQueue.html b/rt/html/SelfService/CreateTicketInQueue.html deleted file mode 100755 index 3162f20e3..000000000 --- a/rt/html/SelfService/CreateTicketInQueue.html +++ /dev/null @@ -1,63 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& Elements/Header, Title => loc("Create a ticket") &> - -

<&|/l&>Select a queue for your new ticket

- -
-% while (my $queue = $queues->Next) { -% next unless $queue->CurrentUserHasRight('CreateTicket'); - -
<%$queue->Name%>
-
<%$queue->Description%>
-% } -
-<%init> -my $queues = RT::Queues->new($session{'CurrentUser'}); -$queues->UnLimit; - diff --git a/rt/html/SelfService/Display.html b/rt/html/SelfService/Display.html deleted file mode 100644 index 3c9ba85bc..000000000 --- a/rt/html/SelfService/Display.html +++ /dev/null @@ -1,235 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& /SelfService/Elements/Header, Title => loc('#[_1]: [_2]', $Ticket->id, $Ticket->Subject) &> - -<& /Elements/ListActions, actions => \@results &> - - - - - - -
- <&| /Widgets/TitleBox, title => loc('The Basics'), - title_class=> 'inverse', - color => "#993333" &> - <& /Ticket/Elements/ShowBasics, Ticket => $Ticket &> - <& /Ticket/Elements/ShowCustomFields, Ticket => $Ticket &> - - - <&| /Widgets/TitleBox, title => loc("Dates"), - title_class=> 'inverse', - color => "#663366" &> - <& /Ticket/Elements/ShowDates, Ticket => $Ticket, UpdatedLink => 0 &> - -
- - - -%#!!pape: selfservice_find_attachments.patch {{ -<& /Ticket/Elements/ShowHistory, - Ticket => $Ticket, - URIFile => "Display.html", - ShowHeaders => $ARGS{'ShowHeaders'}, - AttachPath => "Attachment", - Attachments => $attachments, - UpdatePath => "Update.html" -&> -%#!!pape: selfservice_find_attachments.patch }} - - - -<%INIT> - -my ( $field, @results ); - -# {{{ Load the ticket -#If we get handed two ids, mason will make them an array. bleck. -# We want teh first one. Just because there's no other sensible way -# to deal -my @id = ( ref $id eq 'ARRAY' ) ? @{$id} : ($id); - -my $Ticket = new RT::Ticket( $session{'CurrentUser'} ); - -# store the uploaded attachment in session -if ( $ARGS{'Attach'} ) { # attachment? - $session{'Attachments'} = {} unless defined $session{'Attachments'}; - - my $subject = "$ARGS{'Attach'}"; - - # since CGI.pm deutf8izes the magic field, we need to add it back. - Encode::_utf8_on($subject); - - # strip leading directories - $subject =~ s#^.*[\\/]##; - - my $attachment = MakeMIMEEntity( - Subject => $subject, - Body => "", - AttachmentFieldName => 'Attach' - ); - - $session{'Attachments'} = - { %{ $session{'Attachments'} || {} }, - $ARGS{'Attach'} => $attachment }; -} - -if ( $id[0] eq 'new' ) { - - # {{{ Create a new ticket - - my $Queue = new RT::Queue( $session{'CurrentUser'} ); - unless ( $Queue->Load( $ARGS{'Queue'} ) ) { - $m->comp( 'Error.html', Why => loc('Queue not found') ); - $m->abort; - } - - unless ( $Queue->CurrentUserHasRight('CreateTicket') ) { - $m->comp( 'Error.html', - Why => - loc('You have no permission to create tickets in that queue.') ); - $m->abort; - } - - - ( $Ticket, @results ) = - CreateTicket( Attachments => $session{'Attachments'}, %ARGS, Status => 'new' ); - - unless ( $Ticket->id ) { - $m->comp( 'Error.html', Why => join( "\n", @results )); - $m->abort(); - } - - # }}} - - # delete temporary storage entry to make WebUI clean - unless ( keys %{ $session{'Attachments'} } and $ARGS{'UpdateAttach'} ) { - delete $session{'Attachments'}; - } - - # }}} - } - else { - unless ( $Ticket->Load( $id[0] ) ) { - $m->comp( 'Error.html', - Why => loc( "Couldn't load ticket '[_1]'", $id ) ); - $m->abort(); - } - - my ( $code, $msg ); - - #Update the status - if ( ( defined $ARGS{'Status'} ) - and $ARGS{'Status'} - and ( $ARGS{'Status'} ne $Ticket->Status ) ) - { - ( $code, $msg ) = $Ticket->SetStatus( $ARGS{'Status'} ); - push @results, "$msg"; - } - - # }}} - - if ( - $session{'Attachments'} - || ( defined $ARGS{'UpdateContent'} - && $ARGS{'UpdateContent'} ne '' - && $ARGS{'UpdateContent'} ne "-- \n" - . $session{'CurrentUser'}->UserObj->Signature ) - ) - { - $ARGS{UpdateAttachments} = $session{'Attachments'}; - } - ProcessUpdateMessage( - ARGSRef => \%ARGS, - Actions => \@results, - TicketObj => $Ticket - ); - delete $session{'Attachments'}; - - # delete temporary storage entry to make WebUI clean - unless ( keys %{ $session{'Attachments'} } and $ARGS{'UpdateAttach'} ) { - delete $session{'Attachments'}; - } - - my @cfupdates = ProcessObjectCustomFieldUpdates(Object => $Ticket, ARGSRef => \%ARGS); - push (@results, @cfupdates); - - # }}} - - } - - # This code does automatic redirection if any updates happen. - - unless ( $Ticket->CurrentUserHasRight('ShowTicket') ) { - $m->comp( 'Error.html', - Why => loc("No permission to display that ticket") ); - $m->abort(); - } - - if (@results) { - # We've done something, so we need to clear the decks to avoid - # resubmission on refresh. - # But we need to store Actions somewhere too, so we don't lose them. - $session{"Actions"} = \@results; - RT::Interface::Web::Redirect($RT::WebURL."SelfService/Display.html?id=" - . $Ticket->id); - } else { - @results = @{ delete $session{"Actions"} || [] }; - } - - my $Transactions = $Ticket->Transactions; - - my $attachments = - $m->comp( '/Ticket/Elements/FindAttachments', Ticket => $Ticket ); - - - - -<%ARGS> -$id => undef - diff --git a/rt/html/SelfService/Elements/GotoTicket b/rt/html/SelfService/Elements/GotoTicket deleted file mode 100644 index f2ad07a51..000000000 --- a/rt/html/SelfService/Elements/GotoTicket +++ /dev/null @@ -1,48 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -
 
diff --git a/rt/html/SelfService/Elements/Header b/rt/html/SelfService/Elements/Header deleted file mode 100644 index f26d19163..000000000 --- a/rt/html/SelfService/Elements/Header +++ /dev/null @@ -1,49 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& /Elements/Header, %ARGS, Prefs => '/SelfService/Prefs.html' &> -<& /SelfService/Elements/Tabs, %ARGS &> diff --git a/rt/html/SelfService/Elements/MyRequests b/rt/html/SelfService/Elements/MyRequests deleted file mode 100644 index 21f8ada0c..000000000 --- a/rt/html/SelfService/Elements/MyRequests +++ /dev/null @@ -1,84 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<&| /Widgets/TitleBox, title => $title &> -<& /Elements/TicketList, Title => $title, - Format => $Format, - Query => $Query, - Order => $Order, - OrderBy => $OrderBy, - BaseURL => $BaseURL, - Page => $Page &> - - -<%INIT> -my $id = $session{'CurrentUser'}->id; -my $Query = "( " - . join( ' OR ', map "$_.id = $id", @roles ) - . ")"; -if ( @status ) { - $Query .= " AND ( " - . join( ' OR ', map "Status = '$_'", @status ) - . " )"; -} -my $Order = "ASC"; -my $OrderBy = "Created"; -my $Format = qq{ - '__id__/TITLE:#', - '__Subject__/TITLE:Subject', - Status, - Requestors, - OwnerName}; - -<%ARGS> -$friendly_status => loc('open') -$title => loc("My [_1] tickets", $friendly_status) -@roles => ('Watcher') -@status => ('open', 'new', 'stalled') -$BaseURL => undef -$Page => 1 - diff --git a/rt/html/SelfService/Elements/Tabs b/rt/html/SelfService/Elements/Tabs deleted file mode 100644 index adc019f5b..000000000 --- a/rt/html/SelfService/Elements/Tabs +++ /dev/null @@ -1,113 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& /Elements/Callback, tabs => $tabs, %ARGS &> -<& /Elements/PageLayout, - current_toptab => $current_toptab, - current_tab => $current_tab, - toptabs => $tabs, - topactions => $actions, - title => $Title -&> - -<%INIT> -my $queues = RT::Queues->new($session{'CurrentUser'}); -$queues->UnLimit; - -my $queue_count = 0; -my $queue_id = 1; - -while (my $queue = $queues->Next) { - next unless $queue->CurrentUserHasRight('CreateTicket'); - $queue_id = $queue->id; - $queue_count++; - last if ($queue_count > 1); -} - -if ($Title) { -$Title = loc("RT Self Service") . " / " . $Title; -} else { -$Title = loc("RT Self Service"); - -} -my ($tab); -my $tabs = { A => { title => loc('Open tickets'), - path => 'SelfService/', - }, - B => { title => loc('Closed tickets'), - path => 'SelfService/Closed.html', - }, - }; - -if ($queue_count > 1) { - $tabs->{C} = { title => loc('New ticket'), - path => 'SelfService/CreateTicketInQueue.html' - }; -} else { - $tabs->{C} = { title => loc('New ticket'), - path => 'SelfService/Create.html?Queue=' . $queue_id - }; -} - -if ($session{'CurrentUser'}->HasRight( Right => 'ModifySelf', - Object => $RT::System )) { - $tabs->{Z} = { title => loc('Preferences'), - path => 'SelfService/Prefs.html' - }; -} - -my $actions = { - B => { html => $m->scomp('GotoTicket') - } - }; - -<%ARGS> -$Title => undef -$current_toptab => undef -$current_tab => undef - - diff --git a/rt/html/SelfService/Error.html b/rt/html/SelfService/Error.html deleted file mode 100644 index 17fa7934e..000000000 --- a/rt/html/SelfService/Error.html +++ /dev/null @@ -1,70 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& /SelfService/Elements/Header, Title => loc('Error') &> -

<%loc('Error')%>

-<&| /Widgets/TitleBox, title => $Title &> -<%$Why%> -
- -<%$Details%> - - - - - - -<%args> -$Code => undef -$Details => undef -$Title => loc("RT Error") -$Why => loc("the calling component did not specify why") - - -<%INIT> -$RT::Logger->error("WebRT: $Why ($Details)"); - diff --git a/rt/html/SelfService/Prefs.html b/rt/html/SelfService/Prefs.html deleted file mode 100644 index 304ed5b78..000000000 --- a/rt/html/SelfService/Prefs.html +++ /dev/null @@ -1,92 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& /SelfService/Elements/Header, Title => loc('Preferences') &> - -<& /Elements/ListActions, actions => \@results &> -
- -% unless ($RT::WebExternalAuth and !$RT::WebFallbackToInternalAuth) { -<&| /Widgets/TitleBox, title => loc('Change password') &> -<&|/l&>New password: -<&|/l&>Confirm: - -
-% } -<& /Elements/Submit, Label => loc('Save Changes') &> -
- - -<%INIT> -my @results; - -if ($NewPass1) { - if ($NewPass1 ne $NewPass2) { - push (@results, "Passwords did not match."); - } - else { - my ($val, $msg)=$session{'CurrentUser'}->UserObj->SetPassword($NewPass1); - push (@results, "Password: ".$msg); - } -} -if ($Signature) { - $Signature =~ s/(\r\n|\r)/\n/g; - if ($Signature ne $session{'CurrentUser'}->UserObj->Signature) { - my ($val, $msg)=$session{'CurrentUser'}->UserObj->SetSignature($Signature); - push (@results, "Signature: ".$msg); - } -} -#A hack to make sure that session gets rewritten. - -$session{'i'}++; - - -<%ARGS> -$Signature => undef -$NewPass1 => undef -$NewPass2 => undef - diff --git a/rt/html/SelfService/Update.html b/rt/html/SelfService/Update.html deleted file mode 100644 index 9cdb4ed36..000000000 --- a/rt/html/SelfService/Update.html +++ /dev/null @@ -1,129 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& /SelfService/Elements/Header, - Title =>loc('Update ticket #[_1]', $Ticket->id) -&> - - -
- - - - - - - - - - - - -% if (exists $session{'Attachments'}) { - - - - -% } # end of if - - - - -
- <&|/l&>Status - - <& /Elements/SelectStatus, Name=>"Status", DefaultLabel => loc("[_1] (Unchanged)",loc($DefaultStatus)) &> -
- <&|/l&>Subject - - -
- <&|/l&>Attached file - - <&|/l&>Check box to delete
-% foreach my $attach_name (keys %{$session{'Attachments'}}) { - <%$attach_name%>
-% } # end of foreach -
- <&|/l&>Attach - - - -
-<& /Ticket/Elements/EditCustomFields, TicketObj => $Ticket &> -<& /Elements/MessageBox, - Name => "UpdateContent", - QuoteTransaction => $ARGS{QuoteTransaction} - &> -
- - -<& /Elements/Submit &> -
- - - -<%INIT> - -my $Ticket = LoadTicket($id); - -my $title = loc( "Update ticket #[_1]", $Ticket->id ); - -$DefaultStatus = $Ticket->Status() unless ($DefaultStatus); - - -Abort( loc("No permission to view update ticket") ) - unless ( $Ticket->CurrentUserHasRight('ReplyToTicket') - or $Ticket->CurrentUserHasRight('ModifyTicket') ); - - - -<%ARGS> -$id => undef -$Action => undef -$DefaultStatus => undef - diff --git a/rt/html/SelfService/index.html b/rt/html/SelfService/index.html deleted file mode 100644 index 517cb18d1..000000000 --- a/rt/html/SelfService/index.html +++ /dev/null @@ -1,54 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC -%# -%# -%# (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 }}} -<& /SelfService/Elements/Header, Title => loc('Open tickets') &> - -<& /SelfService/Elements/MyRequests, BaseURL => $RT::WebPath . "/SelfService/?", - Page => $Page &> -<%ARGS> -$Page => 1 - -- cgit v1.2.1