[otrs-cvs] CVS: otrs/Kernel/Modules AdminCustomerUser.pm, 1.43, 1.44 AdminResponse.pm, 1.18, 1.19 AgentInfo.pm, 1.4, 1.5 AgentSpelling.pm, 1.16, 1.17 AgentTicketCompose.pm,1.22,1.23 AgentTicketCustomerFollowUp.pm,1.8,1.9 AgentTicketHistory.pm,1.5,1.6 AgentTicketMailbox.pm,1.13,1.14 AgentTicketMerge.pm,1.12,1.13 AgentTicketMove.pm,1.13,1.14 AgentTicketNote.pm,1.19,1.20 AgentTicketPhone.pm,1.28,1.29 AgentTicketPlain.pm,1.4,1.5 CustomerPreferences.pm,1.13,1.14 CustomerTicketMessage.pm,1.12,1.13 CustomerTicketOverView.pm,1.39,1.40 CustomerTicketSearch.pm,1.22,1.23 Installer.pm,1.41,1.42

cvs-log at otrs.org cvs-log at otrs.org
Tue Jan 2 00:18:18 CET 2007


Update of /home/cvs/otrs/Kernel/Modules
In directory lancelot:/tmp/cvs-serv22520

Modified Files:
	AdminCustomerUser.pm AdminResponse.pm AgentInfo.pm 
	AgentSpelling.pm AgentTicketCompose.pm 
	AgentTicketCustomerFollowUp.pm AgentTicketHistory.pm 
	AgentTicketMailbox.pm AgentTicketMerge.pm AgentTicketMove.pm 
	AgentTicketNote.pm AgentTicketPhone.pm AgentTicketPlain.pm 
	CustomerPreferences.pm CustomerTicketMessage.pm 
	CustomerTicketOverView.pm CustomerTicketSearch.pm Installer.pm 
Log Message:
code cleanup

Index: AdminCustomerUser.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AdminCustomerUser.pm,v
retrieving revision 1.43
retrieving revision 1.44
diff -C2 -r1.43 -r1.44
*** AdminCustomerUser.pm	9 Oct 2006 17:38:03 -0000	1.43
--- AdminCustomerUser.pm	1 Jan 2007 23:18:15 -0000	1.44
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AdminCustomerUser.pm - to add/update/delete customer user and preferences
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AdminCustomerUser.pm - to add/update/delete customer user and preferences
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 106,110 ****
          my $URL = '';
          if ($Self->{ConfigObject}->Get('Frontend::Module')->{AgentTicketPhone}) {
!             $URL .= "<a href=\"\$Env{\"CGIHandle\"}?Action=AgentTicketPhone&Subaction=StoreNew&ExpandCustomerName=2&CustomerUser=$AddedUID\"$OnClick>".$Self->{LayoutObject}->{LanguageObject}->Get('PhoneView')."</a>";
          }
          if ($Self->{ConfigObject}->Get('Frontend::Module')->{AgentTicketEmail}) {
--- 106,111 ----
          my $URL = '';
          if ($Self->{ConfigObject}->Get('Frontend::Module')->{AgentTicketPhone}) {
!             $URL .= "<a href=\"\$Env{\"CGIHandle\"}?Action=AgentTicketPhone&Subaction=StoreNew&ExpandCustomerName=2&CustomerUser=$AddedUID\"$OnClick>".
!                 $Self->{LayoutObject}->{LanguageObject}->Get('PhoneView')."</a>";
          }
          if ($Self->{ConfigObject}->Get('Frontend::Module')->{AgentTicketEmail}) {
***************
*** 112,116 ****
                  $URL .= " - ";
              }
!             $URL .= "<a href=\"\$Env{\"CGIHandle\"}?Action=AgentTicketEmail&Subaction=StoreNew&ExpandCustomerName=2&CustomerUser=$AddedUID\"$OnClick>".$Self->{LayoutObject}->{LanguageObject}->Get('Compose Email')."</a>";
          }
          if ($URL) {
--- 113,118 ----
                  $URL .= " - ";
              }
!             $URL .= "<a href=\"\$Env{\"CGIHandle\"}?Action=AgentTicketEmail&Subaction=StoreNew&ExpandCustomerName=2&CustomerUser=$AddedUID\"$OnClick>".
!                 $Self->{LayoutObject}->{LanguageObject}->Get('Compose Email')."</a>";
          }
          if ($URL) {

Index: AdminResponse.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AdminResponse.pm,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -r1.18 -r1.19
*** AdminResponse.pm	2 Nov 2006 12:20:51 -0000	1.18
--- AdminResponse.pm	1 Jan 2007 23:18:15 -0000	1.19
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AdminResponse.pm - provides admin std response module
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AdminResponse.pm - provides admin std response module
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 64,70 ****
      my %SelectedAttachmentData = ();
      if ($GetParam{ID}) {
!       %SelectedAttachmentData = $Self->{StdAttachmentObject}->StdAttachmentsByResponseID(
!         ID => $GetParam{ID},
!       );
      }
  
--- 64,70 ----
      my %SelectedAttachmentData = ();
      if ($GetParam{ID}) {
!         %SelectedAttachmentData = $Self->{StdAttachmentObject}->StdAttachmentsByResponseID(
!             ID => $GetParam{ID},
!         );
      }
  
***************
*** 150,158 ****
      $Param{'ValidOption'} = $Self->{LayoutObject}->OptionStrgHashRef(
          Data => {
!           $Self->{DBObject}->GetTableData(
!             What => 'id, name',
!             Table => 'valid',
!             Valid => 0,
!           )
          },
          Name => 'ValidID',
--- 150,158 ----
      $Param{'ValidOption'} = $Self->{LayoutObject}->OptionStrgHashRef(
          Data => {
!             $Self->{DBObject}->GetTableData(
!                 What => 'id, name',
!                 Table => 'valid',
!                 Valid => 0,
!             )
          },
          Name => 'ValidID',
***************
*** 163,172 ****
      $Param{'ResponseOption'} = $Self->{LayoutObject}->OptionStrgHashRef(
          Data => {
!           $Self->{DBObject}->GetTableData(
!             What => 'id, name, id',
!             Valid => 0,
!             Clamp => 1,
!             Table => 'standard_response',
!           )
          },
          Name => 'ID',
--- 163,172 ----
      $Param{'ResponseOption'} = $Self->{LayoutObject}->OptionStrgHashRef(
          Data => {
!             $Self->{DBObject}->GetTableData(
!                 What => 'id, name, id',
!                 Valid => 0,
!                 Clamp => 1,
!                 Table => 'standard_response',
!             )
          },
          Name => 'ID',
***************
*** 179,189 ****
      $Param{AttachmentOption} .= "<SELECT NAME=\"IDs\" SIZE=3 multiple>\n";
      foreach my $ID (sort keys %SecondDataTmp){
!        $Param{AttachmentOption} .= "<OPTION ";
!        foreach (sort keys %DataTmp){
!          if ($_ eq $ID) {
!                $Param{AttachmentOption} .= 'selected';
!          }
!        }
!       $Param{AttachmentOption} .= " VALUE=\"$ID\">$SecondDataTmp{$ID}</OPTION>\n";
      }
      $Param{AttachmentOption} .= "</SELECT>\n";
--- 179,189 ----
      $Param{AttachmentOption} .= "<SELECT NAME=\"IDs\" SIZE=3 multiple>\n";
      foreach my $ID (sort keys %SecondDataTmp){
!         $Param{AttachmentOption} .= "<OPTION ";
!         foreach (sort keys %DataTmp){
!             if ($_ eq $ID) {
!                 $Param{AttachmentOption} .= 'selected';
!             }
!         }
!         $Param{AttachmentOption} .= " VALUE=\"$ID\">$SecondDataTmp{$ID}</OPTION>\n";
      }
      $Param{AttachmentOption} .= "</SELECT>\n";

Index: AgentInfo.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentInfo.pm,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** AgentInfo.pm	29 Aug 2006 17:17:24 -0000	1.4
--- AgentInfo.pm	1 Jan 2007 23:18:15 -0000	1.5
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentInfo.pm - to show an agent an login/changes info
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentInfo.pm - to show an agent an login/changes info
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 18,22 ****
  $VERSION =~ s/^\$.*:\W(.*)\W.+?$/$1/;
  
- # --
  sub new {
      my $Type = shift;
--- 18,21 ----
***************
*** 43,47 ****
      return $Self;
  }
! # --
  sub PreRun {
      my $Self = shift;
--- 42,46 ----
      return $Self;
  }
! 
  sub PreRun {
      my $Self = shift;
***************
*** 65,69 ****
      }
  }
! # --
  sub Run {
      my $Self = shift;
--- 64,68 ----
      }
  }
! 
  sub Run {
      my $Self = shift;
***************
*** 114,117 ****
      }
  }
! # --
  1;
--- 113,116 ----
      }
  }
! 
  1;

Index: AgentSpelling.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentSpelling.pm,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** AgentSpelling.pm	29 Aug 2006 17:17:24 -0000	1.16
--- AgentSpelling.pm	1 Jan 2007 23:18:15 -0000	1.17
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentSpelling.pm - spelling module
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentSpelling.pm - spelling module
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 19,23 ****
  $VERSION =~ s/^\$.*:\W(.*)\W.+?$/$1/;
  
- # --
  sub new {
      my $Type = shift;
--- 19,22 ----
***************
*** 49,53 ****
      return $Self;
  }
! # --
  sub Run {
      my $Self = shift;
--- 48,52 ----
      return $Self;
  }
! 
  sub Run {
      my $Self = shift;
***************
*** 59,65 ****
      $Param{SpellLanguage} = $Self->{ParamObject}->GetParam(Param => 'SpellLanguage') ||
          $Self->{UserSpellDict} || $Self->{ConfigObject}->Get('SpellCheckerDictDefault');
-     # --
      # get and replace all wrong words
-     # --
      my %Words = ();
      foreach (0..300) {
--- 58,62 ----
***************
*** 68,72 ****
              my $Old = $Self->{ParamObject}->GetParam(Param => "SpellCheckOld::$_");
              my $New = $Self->{ParamObject}->GetParam(Param => "SpellCheckOrReplace::$_") ||
!               $Self->{ParamObject}->GetParam(Param => "SpellCheckOption::$_");
              if ($Old && $New) {
                  $Param{Body} =~ s/^$Old$/$New/g;
--- 65,69 ----
              my $Old = $Self->{ParamObject}->GetParam(Param => "SpellCheckOld::$_");
              my $New = $Self->{ParamObject}->GetParam(Param => "SpellCheckOrReplace::$_") ||
!                 $Self->{ParamObject}->GetParam(Param => "SpellCheckOption::$_");
              if ($Old && $New) {
                  $Param{Body} =~ s/^$Old$/$New/g;
***************
*** 79,98 ****
          }
      }
-     # --
      # do spell check
-     # --
      my %SpellCheck = $Self->{SpellingObject}->Check(
          Text => $Param{Body},
          SpellLanguage => $Param{SpellLanguage},
      );
-     # --
      # check error
-     # --
      if ($Self->{SpellingObject}->Error()) {
          return $Self->{LayoutObject}->ErrorScreen();
      }
-     # --
      # start with page ...
-     # --
      $Output .= $Self->{LayoutObject}->Header(Type => 'Small');
      $Output .= $Self->_Mask(
--- 76,89 ----
***************
*** 103,107 ****
      return $Output;
  }
! # --
  sub _Mask {
      my $Self = shift;
--- 94,98 ----
      return $Output;
  }
! 
  sub _Mask {
      my $Self = shift;
***************
*** 127,136 ****
                  }
                  $Param{SpellCheckString}  = $Self->{LayoutObject}->OptionStrgHashRef(
!                    Data => \%ReplaceWords,
!                    Name => "SpellCheckOption::$Param{SpellCounter}",
!                    OnChange => "change_selected($Param{SpellCounter})"
                  );
                  $Self->{LayoutObject}->Block(
!                   Name => 'Row',
                      Data => {
                          %{$Param{SpellCheck}->{$_}},
--- 118,127 ----
                  }
                  $Param{SpellCheckString}  = $Self->{LayoutObject}->OptionStrgHashRef(
!                     Data => \%ReplaceWords,
!                     Name => "SpellCheckOption::$Param{SpellCounter}",
!                     OnChange => "change_selected($Param{SpellCounter})"
                  );
                  $Self->{LayoutObject}->Block(
!                     Name => 'Row',
                      Data => {
                          %{$Param{SpellCheck}->{$_}},
***************
*** 143,147 ****
      }
      # dict language selection
!     $Param{SpellLanguageString}  .= $Self->{LayoutObject}->OptionStrgHashRef(
          Data => $Self->{ConfigObject}->Get('PreferencesGroups')->{SpellDict}->{Data},
          Name => "SpellLanguage",
--- 134,138 ----
      }
      # dict language selection
!     $Param{SpellLanguageString} .= $Self->{LayoutObject}->OptionStrgHashRef(
          Data => $Self->{ConfigObject}->Get('PreferencesGroups')->{SpellDict}->{Data},
          Name => "SpellLanguage",
***************
*** 151,154 ****
      return $Self->{LayoutObject}->Output(TemplateFile => 'AgentSpelling', Data => \%Param);
  }
! # --
! 1;
--- 142,145 ----
      return $Self->{LayoutObject}->Output(TemplateFile => 'AgentSpelling', Data => \%Param);
  }
! 
! 1;
\ No newline at end of file

Index: AgentTicketCompose.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentTicketCompose.pm,v
retrieving revision 1.22
retrieving revision 1.23
diff -C2 -r1.22 -r1.23
*** AgentTicketCompose.pm	30 Nov 2006 12:32:47 -0000	1.22
--- AgentTicketCompose.pm	1 Jan 2007 23:18:15 -0000	1.23
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentTicketCompose.pm - to compose and send a message
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentTicketCompose.pm - to compose and send a message
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 226,230 ****
                  foreach my $Email (Mail::Address->parse($GetParam{$_})) {
                      if (!$Self->{CheckItemObject}->CheckEmail(Address => $Email->address())) {
!                          $Error{"$_ invalid"} .= $Self->{CheckItemObject}->CheckError();
                      }
                  }
--- 226,230 ----
                  foreach my $Email (Mail::Address->parse($GetParam{$_})) {
                      if (!$Self->{CheckItemObject}->CheckEmail(Address => $Email->address())) {
!                         $Error{"$_ invalid"} .= $Self->{CheckItemObject}->CheckError();
                      }
                  }
***************
*** 654,658 ****
                  foreach my $Email (Mail::Address->parse($Data{$_})) {
                      if (!$Self->{CheckItemObject}->CheckEmail(Address => $Email->address())) {
!                          $Error{"$_ invalid"} .= $Self->{CheckItemObject}->CheckError();
                      }
                  }
--- 654,658 ----
                  foreach my $Email (Mail::Address->parse($Data{$_})) {
                      if (!$Self->{CheckItemObject}->CheckEmail(Address => $Email->address())) {
!                         $Error{"$_ invalid"} .= $Self->{CheckItemObject}->CheckError();
                      }
                  }

Index: AgentTicketCustomerFollowUp.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentTicketCustomerFollowUp.pm,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** AgentTicketCustomerFollowUp.pm	2 Nov 2006 12:20:52 -0000	1.8
--- AgentTicketCustomerFollowUp.pm	1 Jan 2007 23:18:15 -0000	1.9
***************
*** 2,6 ****
  # Kernel/Modules/AgentTicketCustomerFollowUp.pm - to handle customer messages
  # if the agent is customer
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 2,6 ----
  # Kernel/Modules/AgentTicketCustomerFollowUp.pm - to handle customer messages
  # if the agent is customer
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 93,98 ****
              # get output back
              $Output .= $Self->{LayoutObject}->Notify(
!                 Info =>
!                   $Self->{LayoutObject}->{LanguageObject}->Get('You are the customer user of this message - customer modus!'),
              );
              # show spell check
--- 93,97 ----
              # get output back
              $Output .= $Self->{LayoutObject}->Notify(
!                 Info => $Self->{LayoutObject}->{LanguageObject}->Get('You are the customer user of this message - customer modus!'),
              );
              # show spell check
***************
*** 175,180 ****
                  );
              }
!            # redirect to zoom view
!            return $Self->{LayoutObject}->Redirect(OP => $Self->{LastScreenView});
          }
          else {
--- 174,179 ----
                  );
              }
!             # redirect to zoom view
!             return $Self->{LayoutObject}->Redirect(OP => $Self->{LastScreenView});
          }
          else {

Index: AgentTicketHistory.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentTicketHistory.pm,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** AgentTicketHistory.pm	29 Aug 2006 17:17:24 -0000	1.5
--- AgentTicketHistory.pm	1 Jan 2007 23:18:15 -0000	1.6
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentTicketHistory.pm - ticket history
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentTicketHistory.pm - ticket history
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 18,22 ****
  $VERSION =~ s/^\$.*:\W(.*)\W.+?$/$1/;
  
- # --
  sub new {
      my $Type = shift;
--- 18,21 ----
***************
*** 38,42 ****
      return $Self;
  }
! # --
  sub Run {
      my $Self = shift;
--- 37,41 ----
      return $Self;
  }
! 
  sub Run {
      my $Self = shift;
***************
*** 45,53 ****
      # check needed stuff
      if (!$Self->{TicketID}) {
!       # error page
!       return $Self->{LayoutObject}->ErrorScreen(
!           Message => "Can't show history, no TicketID is given!",
!           Comment => 'Please contact the admin.',
!       );
      }
      # check permissions
--- 44,52 ----
      # check needed stuff
      if (!$Self->{TicketID}) {
!         # error page
!         return $Self->{LayoutObject}->ErrorScreen(
!             Message => "Can't show history, no TicketID is given!",
!             Comment => 'Please contact the admin.',
!         );
      }
      # check permissions
***************
*** 116,120 ****
      return $Output;
  }
- # --
  
! 1;
--- 115,118 ----
      return $Output;
  }
  
! 1;
\ No newline at end of file

Index: AgentTicketMailbox.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentTicketMailbox.pm,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -r1.13 -r1.14
*** AgentTicketMailbox.pm	2 Nov 2006 12:20:52 -0000	1.13
--- AgentTicketMailbox.pm	1 Jan 2007 23:18:15 -0000	1.14
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentTicketMailbox.pm - to view all locked tickets
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentTicketMailbox.pm - to view all locked tickets
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 33,45 ****
  
      # check all needed objects
!     foreach (qw(ParamObject DBObject QueueObject LayoutObject ConfigObject LogObject
!       UserObject)) {
          die "Got no $_" if (!$Self->{$_});
      }
  
      $Self->{StateObject} = Kernel::System::State->new(%Param);
- 
      $Self->{HighlightColor2} = $Self->{ConfigObject}->Get('HighlightColor2');
- 
      $Self->{StartHit} = $Self->{ParamObject}->GetParam(Param => 'StartHit') || 1;
      $Self->{PageShown} = $Self->{UserShowTickets} || $Self->{ConfigObject}->Get('PreferencesGroups')->{QueueViewShownTickets}->{DataSelected} || 10;
--- 33,42 ----
  
      # check all needed objects
!     foreach (qw(ParamObject DBObject QueueObject LayoutObject ConfigObject LogObject UserObject)) {
          die "Got no $_" if (!$Self->{$_});
      }
  
      $Self->{StateObject} = Kernel::System::State->new(%Param);
      $Self->{HighlightColor2} = $Self->{ConfigObject}->Get('HighlightColor2');
      $Self->{StartHit} = $Self->{ParamObject}->GetParam(Param => 'StartHit') || 1;
      $Self->{PageShown} = $Self->{UserShowTickets} || $Self->{ConfigObject}->Get('PreferencesGroups')->{QueueViewShownTickets}->{DataSelected} || 10;
***************
*** 53,57 ****
      my $Output;
      my $QueueID = $Self->{QueueID};
- 
      my $SortBy = $Self->{ParamObject}->GetParam(Param => 'SortBy') || $Self->{ConfigObject}->Get('Ticket::Frontend::MailboxSortBy::Default') || 'Age';
      my $OrderBy = $Self->{ParamObject}->GetParam(Param => 'OrderBy') || $Self->{ConfigObject}->Get('Ticket::Frontend::MailboxOrder::Default') || 'Up';
--- 50,53 ----
***************
*** 145,149 ****
              Result => 'ARRAY',
              Limit => 1000,
- #            StateType => 'Open',
              Locks => ['lock'],
              OwnerIDs => [$Self->{UserID}],
--- 141,144 ----
***************
*** 214,218 ****
              Result => 'ARRAY',
              Limit => 1000,
- #            StateType => 'Open',
              Locks => ['lock'],
              OwnerIDs => [$Self->{UserID}],
--- 209,212 ----
***************
*** 250,257 ****
  
              my $Message = '';
-             # -------------------------------------------
              # put all tickets to ToDo where last sender type is customer / system or ! UserID
-             # -------------------------------------------
- 
              # show just unseen tickets as new
              if ($Self->{ConfigObject}->Get('Ticket::NewMessageMode') eq 'ArticleSeen') {
--- 244,248 ----
***************
*** 263,267 ****
                  if (!$Flag{seen}) {
                      $Message = 'New message!';
!                  }
              }
              else {
--- 254,258 ----
                  if (!$Flag{seen}) {
                      $Message = 'New message!';
!                 }
              }
              else {
***************
*** 329,333 ****
      if ($Param{UntilTime} < 0 && $Param{State} !~ /^pending auto/i) {
          $Param{Message} .= $Self->{LayoutObject}->{LanguageObject}->Get('Timeover').' '.
!           $Self->{LayoutObject}->CustomerAge(Age => $Param{UntilTime}, Space => ' ').'!';
      }
      # create PendingUntil string if UntilTime is < -1
--- 320,324 ----
      if ($Param{UntilTime} < 0 && $Param{State} !~ /^pending auto/i) {
          $Param{Message} .= $Self->{LayoutObject}->{LanguageObject}->Get('Timeover').' '.
!             $Self->{LayoutObject}->CustomerAge(Age => $Param{UntilTime}, Space => ' ').'!';
      }
      # create PendingUntil string if UntilTime is < -1

Index: AgentTicketMerge.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentTicketMerge.pm,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -r1.12 -r1.13
*** AgentTicketMerge.pm	8 Dec 2006 17:35:16 -0000	1.12
--- AgentTicketMerge.pm	1 Jan 2007 23:18:15 -0000	1.13
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentTicketMerge.pm - to merge tickets
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentTicketMerge.pm - to merge tickets
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 148,152 ****
          }
          # check errors
!         if ($Self->{TicketID} == $MainTicketID || !$Self->{TicketObject}->TicketMerge(MainTicketID => $MainTicketID, MergeTicketID => $Self->{TicketID}, UserID => $Self->{UserID})) {
              my $Output = $Self->{LayoutObject}->Header();
              $Output .= $Self->{LayoutObject}->NavigationBar();
--- 148,158 ----
          }
          # check errors
!         if ($Self->{TicketID} == $MainTicketID ||
!             !$Self->{TicketObject}->TicketMerge(
!                 MainTicketID => $MainTicketID,
!                 MergeTicketID => $Self->{TicketID},
!                 UserID => $Self->{UserID},
!             )
!         ) {
              my $Output = $Self->{LayoutObject}->Header();
              $Output .= $Self->{LayoutObject}->NavigationBar();
***************
*** 167,171 ****
                      return $Self->{LayoutObject}->ErrorScreen(
                          Message => "Can't forward ticket to $Address! It's a local ".
!                           "address! You need to move it!",
                          Comment => 'Please contact the admin.',
                      );
--- 173,177 ----
                      return $Self->{LayoutObject}->ErrorScreen(
                          Message => "Can't forward ticket to $Address! It's a local ".
!                             "address! You need to move it!",
                          Comment => 'Please contact the admin.',
                      );
***************
*** 203,207 ****
                  return $Self->{LayoutObject}->Redirect(OP => $Self->{LastScreenOverview});
              }
! 	}
      }
      else {
--- 209,213 ----
                  return $Self->{LayoutObject}->Redirect(OP => $Self->{LastScreenOverview});
              }
!         }
      }
      else {

Index: AgentTicketMove.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentTicketMove.pm,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -r1.13 -r1.14
*** AgentTicketMove.pm	29 Nov 2006 08:55:30 -0000	1.13
--- AgentTicketMove.pm	1 Jan 2007 23:18:15 -0000	1.14
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentTicketMove.pm - move tickets to queues
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentTicketMove.pm - move tickets to queues
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 191,200 ****
      }
      elsif ($Self->{TicketObject}->MoveTicket(
!           QueueID => $Self->{DestQueueID},
!           UserID => $Self->{UserID},
!           TicketID => $Self->{TicketID},
!           SendNoNotification => $NewUserID,
!           Comment => $Self->{Comment},
!       ) ) {
          # set state
          if ($Self->{ConfigObject}->Get('Ticket::Frontend::MoveSetState') && $Self->{NewStateID}) {
--- 191,200 ----
      }
      elsif ($Self->{TicketObject}->MoveTicket(
!         QueueID => $Self->{DestQueueID},
!         UserID => $Self->{UserID},
!         TicketID => $Self->{TicketID},
!         SendNoNotification => $NewUserID,
!         Comment => $Self->{Comment},
!     )) {
          # set state
          if ($Self->{ConfigObject}->Get('Ticket::Frontend::MoveSetState') && $Self->{NewStateID}) {
***************
*** 300,310 ****
          my $Counter = 0;
          foreach my $User (reverse @{$Param{OldUser}}) {
!           if ($Counter) {
!             if (!$UserHash{$User->{UserID}}) {
!                 $UserHash{$User->{UserID}} = "$Counter: $User->{UserLastname} ".
!                   "$User->{UserFirstname} ($User->{UserLogin})";
              }
!           }
!           $Counter++;
          }
      }
--- 300,310 ----
          my $Counter = 0;
          foreach my $User (reverse @{$Param{OldUser}}) {
!             if ($Counter) {
!                 if (!$UserHash{$User->{UserID}}) {
!                     $UserHash{$User->{UserID}} = "$Counter: $User->{UserLastname} ".
!                         "$User->{UserFirstname} ($User->{UserLogin})";
!                 }
              }
!             $Counter++;
          }
      }

Index: AgentTicketNote.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentTicketNote.pm,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -r1.19 -r1.20
*** AgentTicketNote.pm	13 Dec 2006 12:52:59 -0000	1.19
--- AgentTicketNote.pm	1 Jan 2007 23:18:15 -0000	1.20
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentTicketNote.pm - to add notes to a ticket
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentTicketNote.pm - to add notes to a ticket
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 620,624 ****
                      if (!$UserHash{$User->{UserID}}) {
                          $UserHash{$User->{UserID}} = "$Counter: $User->{UserLastname} ".
!                           "$User->{UserFirstname} ($User->{UserLogin})";
                      }
                  }
--- 620,624 ----
                      if (!$UserHash{$User->{UserID}}) {
                          $UserHash{$User->{UserID}} = "$Counter: $User->{UserLastname} ".
!                             "$User->{UserFirstname} ($User->{UserLogin})";
                      }
                  }
***************
*** 694,698 ****
          if (!$Self->{Config}->{StateDefault}) {
              $StateList{''} = '-';
- #            $State{SelectedID} = $Param{StateID};
          }
          if (!$Param{NewStateID}) {
--- 694,697 ----
***************
*** 743,747 ****
          if (!$Self->{Config}->{PriorityDefault}) {
              $PriorityList{''} = '-';
- #            $Priority{SelectedID} = $Param{PriorityID};
          }
          if (!$Param{NewPriorityID}) {
--- 742,745 ----
***************
*** 810,814 ****
                  if (!$UserHash{$User->{UserID}}) {
                      $UserHash{$User->{UserID}} = "$Counter: $User->{UserLastname} ".
!                       "$User->{UserFirstname} ($User->{UserLogin})";
                  }
              }
--- 808,812 ----
                  if (!$UserHash{$User->{UserID}}) {
                      $UserHash{$User->{UserID}} = "$Counter: $User->{UserLastname} ".
!                         "$User->{UserFirstname} ($User->{UserLogin})";
                  }
              }

Index: AgentTicketPhone.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentTicketPhone.pm,v
retrieving revision 1.28
retrieving revision 1.29
diff -C2 -r1.28 -r1.29
*** AgentTicketPhone.pm	15 Nov 2006 07:21:52 -0000	1.28
--- AgentTicketPhone.pm	1 Jan 2007 23:18:15 -0000	1.29
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentTicketPhone.pm - to handle phone calls
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentTicketPhone.pm - to handle phone calls
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 140,144 ****
                  if ($Article{CustomerUserID}) {
                      %CustomerData = $Self->{CustomerUserObject}->CustomerUserDataGet(
!                          User => $Article{CustomerUserID},
                      );
                  }
--- 140,144 ----
                  if ($Article{CustomerUserID}) {
                      %CustomerData = $Self->{CustomerUserObject}->CustomerUserDataGet(
!                         User => $Article{CustomerUserID},
                      );
                  }
***************
*** 926,930 ****
      if ($Param{To}) {
          foreach (keys %{$Param{To}}) {
!              $NewTo{"$_||$Param{To}->{$_}"} = $Param{To}->{$_};
          }
      }
--- 926,930 ----
      if ($Param{To}) {
          foreach (keys %{$Param{To}}) {
!             $NewTo{"$_||$Param{To}->{$_}"} = $Param{To}->{$_};
          }
      }

Index: AgentTicketPlain.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/AgentTicketPlain.pm,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** AgentTicketPlain.pm	29 Aug 2006 17:17:24 -0000	1.4
--- AgentTicketPlain.pm	1 Jan 2007 23:18:15 -0000	1.5
***************
*** 1,5 ****
  # --
  # Kernel/Modules/AgentTicketPlain.pm - to get a plain view
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/AgentTicketPlain.pm - to get a plain view
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 18,22 ****
  $VERSION =~ s/^\$.*:\W(.*)\W.+?$/$1/;
  
- # --
  sub new {
      my $Type = shift;
--- 18,21 ----
***************
*** 42,53 ****
      return $Self;
  }
! # --
  sub Run {
      my $Self = shift;
      my %Param = @_;
  
-     # --
      # check needed stuff
-     # --
      if (!$Self->{ArticleID}) {
          return $Self->{LayoutObject}->ErrorScreen(
--- 41,50 ----
      return $Self;
  }
! 
  sub Run {
      my $Self = shift;
      my %Param = @_;
  
      # check needed stuff
      if (!$Self->{ArticleID}) {
          return $Self->{LayoutObject}->ErrorScreen(
***************
*** 56,62 ****
          );
      }
-     # --
      # check permissions
-     # --
      if (!$Self->{TicketObject}->Permission(
          Type => 'ro',
--- 53,57 ----
***************
*** 67,71 ****
      }
  
- 
      my %Article = $Self->{TicketObject}->ArticleGet(ArticleID => $Self->{ArticleID});
      my $Text = $Self->{TicketObject}->ArticlePlain(ArticleID => $Self->{ArticleID});
--- 62,65 ----
***************
*** 74,83 ****
              # return new page
              return $Self->{LayoutObject}->Attachment(
- #                Type => 'attached',
                  Filename => "Ticket-$Article{TicketNumber}-TicketID-$Self->{TicketID}-ArticleID-$Self->{ArticleID}.eml",
                  ContentType => 'text/plain',
                  Content => $Text,
                  Type => 'attachment',
!            );
          }
          else {
--- 68,76 ----
              # return new page
              return $Self->{LayoutObject}->Attachment(
                  Filename => "Ticket-$Article{TicketNumber}-TicketID-$Self->{TicketID}-ArticleID-$Self->{ArticleID}.eml",
                  ContentType => 'text/plain',
                  Content => $Text,
                  Type => 'attachment',
!             );
          }
          else {
***************
*** 118,122 ****
      }
  }
- # --
  
! 1;
--- 111,114 ----
      }
  }
  
! 1;
\ No newline at end of file

Index: CustomerPreferences.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/CustomerPreferences.pm,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -r1.13 -r1.14
*** CustomerPreferences.pm	2 Nov 2006 12:20:52 -0000	1.13
--- CustomerPreferences.pm	1 Jan 2007 23:18:15 -0000	1.14
***************
*** 1,5 ****
  # --
  # Kernel/Modules/CustomerPreferences.pm - provides agent preferences
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/CustomerPreferences.pm - provides agent preferences
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 129,133 ****
      my %Param = @_;
  
!    $Self->{LayoutObject}->Block(
          Name => 'Body',
          Data => {
--- 129,133 ----
      my %Param = @_;
  
!     $Self->{LayoutObject}->Block(
          Name => 'Body',
          Data => {

Index: CustomerTicketMessage.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/CustomerTicketMessage.pm,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -r1.12 -r1.13
*** CustomerTicketMessage.pm	2 Nov 2006 13:02:03 -0000	1.12
--- CustomerTicketMessage.pm	1 Jan 2007 23:18:15 -0000	1.13
***************
*** 1,5 ****
  # --
  # Kernel/Modules/CustomerTicketMessage.pm - to handle customer messages
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/CustomerTicketMessage.pm - to handle customer messages
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 33,38 ****
      }
      # check needed Opjects
!     foreach (qw(ParamObject DBObject TicketObject LayoutObject LogObject QueueObject
!        ConfigObject)) {
          if (!$Self->{$_}) {
              $Self->{LayoutObject}->FatalError(Message => "Got no $_!");
--- 33,37 ----
      }
      # check needed Opjects
!     foreach (qw(ParamObject DBObject TicketObject LayoutObject LogObject QueueObject ConfigObject)) {
          if (!$Self->{$_}) {
              $Self->{LayoutObject}->FatalError(Message => "Got no $_!");
***************
*** 115,120 ****
          $Output .= $Self->{LayoutObject}->CustomerNavigationBar();
          $Output .= $Self->_MaskNew(
!               %TicketFreeTextHTML,
!               %FreeTime,
          );
          $Output .= $Self->{LayoutObject}->CustomerFooter();
--- 114,119 ----
          $Output .= $Self->{LayoutObject}->CustomerNavigationBar();
          $Output .= $Self->_MaskNew(
!             %TicketFreeTextHTML,
!             %FreeTime,
          );
          $Output .= $Self->{LayoutObject}->CustomerFooter();
***************
*** 128,133 ****
          my ($NewQueueID, $To) = split(/\|\|/, $Dest);
          if (!$To) {
!           $NewQueueID = $Self->{ParamObject}->GetParam(Param => 'NewQueueID') || '';
!           $To = 'System';
          }
          # fallback, if no dest is given
--- 127,132 ----
          my ($NewQueueID, $To) = split(/\|\|/, $Dest);
          if (!$To) {
!             $NewQueueID = $Self->{ParamObject}->GetParam(Param => 'NewQueueID') || '';
!             $To = 'System';
          }
          # fallback, if no dest is given
***************
*** 262,283 ****
          %TicketFreeTime = ();
          foreach (1..2) {
!               foreach my $Type (qw(Year Month Day Hour Minute)) {
!                   $TicketFreeTime{"TicketFreeTime".$_.$Type} =  $Self->{ParamObject}->GetParam(Param => "TicketFreeTime".$_.$Type);
!               }
          }
          # set ticket free time
          foreach (1..2) {
!               if (defined($TicketFreeTime{"TicketFreeTime".$_."Year"}) &&
!                   defined($TicketFreeTime{"TicketFreeTime".$_."Month"}) &&
!                   defined($TicketFreeTime{"TicketFreeTime".$_."Day"}) &&
!                   defined($TicketFreeTime{"TicketFreeTime".$_."Hour"}) &&
!                   defined($TicketFreeTime{"TicketFreeTime".$_."Minute"})) {
!                   $Self->{TicketObject}->TicketFreeTimeSet(
!                       %TicketFreeTime,
!                       TicketID => $TicketID,
!                       Counter => $_,
!                       UserID => $Self->{ConfigObject}->Get('CustomerPanelUserID'),
!                   );
!               }
          }
          # create article
--- 261,282 ----
          %TicketFreeTime = ();
          foreach (1..2) {
!             foreach my $Type (qw(Year Month Day Hour Minute)) {
!                 $TicketFreeTime{"TicketFreeTime".$_.$Type} =  $Self->{ParamObject}->GetParam(Param => "TicketFreeTime".$_.$Type);
!             }
          }
          # set ticket free time
          foreach (1..2) {
!             if (defined($TicketFreeTime{"TicketFreeTime".$_."Year"}) &&
!                 defined($TicketFreeTime{"TicketFreeTime".$_."Month"}) &&
!                 defined($TicketFreeTime{"TicketFreeTime".$_."Day"}) &&
!                 defined($TicketFreeTime{"TicketFreeTime".$_."Hour"}) &&
!                 defined($TicketFreeTime{"TicketFreeTime".$_."Minute"})) {
!                 $Self->{TicketObject}->TicketFreeTimeSet(
!                     %TicketFreeTime,
!                     TicketID => $TicketID,
!                     Counter => $_,
!                     UserID => $Self->{ConfigObject}->Get('CustomerPanelUserID'),
!                 );
!             }
          }
          # create article
***************
*** 304,343 ****
              Queue => $Self->{QueueObject}->QueueLookup(QueueID => $NewQueueID),
          )) {
!           # get pre loaded attachment
!           my @AttachmentData = $Self->{UploadCachObject}->FormIDGetAllFilesData(
!               FormID => $Self->{FormID},
!           );
!           foreach my $Ref (@AttachmentData) {
!               $Self->{TicketObject}->ArticleWriteAttachment(
!                   %{$Ref},
!                   ArticleID => $ArticleID,
!                   UserID => $Self->{ConfigObject}->Get('CustomerPanelUserID'),
!               );
!           }
!           # get submit attachment
!           my %UploadStuff = $Self->{ParamObject}->GetUploadAll(
!               Param => 'file_upload',
!               Source => 'String',
!           );
!           if (%UploadStuff) {
!               $Self->{TicketObject}->ArticleWriteAttachment(
!                   %UploadStuff,
!                   ArticleID => $ArticleID,
!                   UserID => $Self->{ConfigObject}->Get('CustomerPanelUserID'),
!               );
!           }
!           # remove pre submited attachments
!           $Self->{UploadCachObject}->FormIDRemove(FormID => $Self->{FormID});
!           # redirect
!           return $Self->{LayoutObject}->Redirect(
!               OP => "Action=$NextScreen&TicketID=$TicketID",
!           );
!       }
!       else {
!           my $Output = $Self->{LayoutObject}->CustomerHeader(Title => 'Error');
!           $Output .= $Self->{LayoutObject}->CustomerError();
!           $Output .= $Self->{LayoutObject}->CustomerFooter();
!           return $Output;
!       }
      }
      else {
--- 303,342 ----
              Queue => $Self->{QueueObject}->QueueLookup(QueueID => $NewQueueID),
          )) {
!             # get pre loaded attachment
!             my @AttachmentData = $Self->{UploadCachObject}->FormIDGetAllFilesData(
!                 FormID => $Self->{FormID},
!             );
!             foreach my $Ref (@AttachmentData) {
!                 $Self->{TicketObject}->ArticleWriteAttachment(
!                     %{$Ref},
!                     ArticleID => $ArticleID,
!                     UserID => $Self->{ConfigObject}->Get('CustomerPanelUserID'),
!                 );
!             }
!             # get submit attachment
!             my %UploadStuff = $Self->{ParamObject}->GetUploadAll(
!                 Param => 'file_upload',
!                 Source => 'String',
!             );
!             if (%UploadStuff) {
!                 $Self->{TicketObject}->ArticleWriteAttachment(
!                     %UploadStuff,
!                     ArticleID => $ArticleID,
!                     UserID => $Self->{ConfigObject}->Get('CustomerPanelUserID'),
!                 );
!             }
!             # remove pre submited attachments
!             $Self->{UploadCachObject}->FormIDRemove(FormID => $Self->{FormID});
!             # redirect
!             return $Self->{LayoutObject}->Redirect(
!                 OP => "Action=$NextScreen&TicketID=$TicketID",
!             );
!         }
!         else {
!             my $Output = $Self->{LayoutObject}->CustomerHeader(Title => 'Error');
!             $Output .= $Self->{LayoutObject}->CustomerError();
!             $Output .= $Self->{LayoutObject}->CustomerFooter();
!             return $Output;
!         }
      }
      else {
***************
*** 379,384 ****
      if (%NewTos) {
          foreach (keys %NewTos) {
!              $NewTos{"$_||$NewTos{$_}"} = $NewTos{$_};
!              delete $NewTos{$_};
          }
      }
--- 378,383 ----
      if (%NewTos) {
          foreach (keys %NewTos) {
!             $NewTos{"$_||$NewTos{$_}"} = $NewTos{$_};
!             delete $NewTos{$_};
          }
      }

Index: CustomerTicketOverView.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/CustomerTicketOverView.pm,v
retrieving revision 1.39
retrieving revision 1.40
diff -C2 -r1.39 -r1.40
*** CustomerTicketOverView.pm	2 Nov 2006 13:02:03 -0000	1.39
--- CustomerTicketOverView.pm	1 Jan 2007 23:18:15 -0000	1.40
***************
*** 1,5 ****
  # --
  # Kernel/Modules/CustomerTicketOverView.pm - status for all open tickets
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/CustomerTicketOverView.pm - status for all open tickets
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 40,45 ****
  
      # all static variables
!     $Self->{ViewableSenderTypes} = $Self->{ConfigObject}->Get('Ticket::ViewableSenderTypes')
!           || die 'No Config entry "Ticket::ViewableSenderTypes"!';
      # get params
      $Self->{ShowClosedTickets} = $Self->{ParamObject}->GetParam(Param => 'ShowClosedTickets');
--- 40,45 ----
  
      # all static variables
!     $Self->{ViewableSenderTypes} = $Self->{ConfigObject}->Get('Ticket::ViewableSenderTypes') ||
!         die 'No Config entry "Ticket::ViewableSenderTypes"!';
      # get params
      $Self->{ShowClosedTickets} = $Self->{ParamObject}->GetParam(Param => 'ShowClosedTickets');
***************
*** 104,108 ****
      my $StateType = '';
      if (!$ShowClosed) {
!        $StateType = 'Open';
      }
  
--- 104,108 ----
      my $StateType = '';
      if (!$ShowClosed) {
!         $StateType = 'Open';
      }
  

Index: CustomerTicketSearch.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/CustomerTicketSearch.pm,v
retrieving revision 1.22
retrieving revision 1.23
diff -C2 -r1.22 -r1.23
*** CustomerTicketSearch.pm	15 Nov 2006 07:28:38 -0000	1.22
--- CustomerTicketSearch.pm	1 Jan 2007 23:18:15 -0000	1.23
***************
*** 1,5 ****
  # --
  # Kernel/Modules/CustomerTicketSearch.pm - Utilities for tickets
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/CustomerTicketSearch.pm - Utilities for tickets
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 84,103 ****
      else {
          foreach (qw(TicketNumber From To Cc Subject Body CustomerID ResultForm TimeSearchType StateType
!           TicketFreeTime1
!           TicketFreeTime1Start TicketFreeTime1StartDay TicketFreeTime1StartMonth
!           TicketFreeTime1StartYear
!           TicketFreeTime1Stop TicketFreeTime1StopDay TicketFreeTime1StopMonth
!           TicketFreeTime1StopYear
!           TicketFreeTime2
!           TicketFreeTime2Start TicketFreeTime2StartDay TicketFreeTime2StartMonth
!           TicketFreeTime2StartYear
!           TicketFreeTime2Stop TicketFreeTime2StopDay TicketFreeTime2StopMonth
!           TicketFreeTime2StopYear
!           TicketCreateTimePointFormat TicketCreateTimePoint
!           TicketCreateTimePointStart
!           TicketCreateTimeStart TicketCreateTimeStartDay TicketCreateTimeStartMonth
!           TicketCreateTimeStartYear
!           TicketCreateTimeStop TicketCreateTimeStopDay TicketCreateTimeStopMonth
!           TicketCreateTimeStopYear
          )) {
              # get search string params (get submitted params)
--- 84,103 ----
      else {
          foreach (qw(TicketNumber From To Cc Subject Body CustomerID ResultForm TimeSearchType StateType
!             TicketFreeTime1
!             TicketFreeTime1Start TicketFreeTime1StartDay TicketFreeTime1StartMonth
!             TicketFreeTime1StartYear
!             TicketFreeTime1Stop TicketFreeTime1StopDay TicketFreeTime1StopMonth
!             TicketFreeTime1StopYear
!             TicketFreeTime2
!             TicketFreeTime2Start TicketFreeTime2StartDay TicketFreeTime2StartMonth
!             TicketFreeTime2StartYear
!             TicketFreeTime2Stop TicketFreeTime2StopDay TicketFreeTime2StopMonth
!             TicketFreeTime2StopYear
!             TicketCreateTimePointFormat TicketCreateTimePoint
!             TicketCreateTimePointStart
!             TicketCreateTimeStart TicketCreateTimeStartDay TicketCreateTimeStartMonth
!             TicketCreateTimeStartYear
!             TicketCreateTimeStop TicketCreateTimeStopDay TicketCreateTimeStopMonth
!             TicketCreateTimeStopYear
          )) {
              # get search string params (get submitted params)
***************
*** 111,122 ****
          # get array params
          foreach (qw(StateIDs StateTypeIDs PriorityIDs OwnerIDs ResponsibleIDs
!           TicketFreeKey1 TicketFreeText1 TicketFreeKey2 TicketFreeText2
!           TicketFreeKey3 TicketFreeText3 TicketFreeKey4 TicketFreeText4
!           TicketFreeKey5 TicketFreeText5 TicketFreeKey6 TicketFreeText6
!           TicketFreeKey7 TicketFreeText7 TicketFreeKey8 TicketFreeText8
!           TicketFreeKey9 TicketFreeText9 TicketFreeKey10 TicketFreeText10
!           TicketFreeKey11 TicketFreeText11 TicketFreeKey12 TicketFreeText12
!           TicketFreeKey13 TicketFreeText13 TicketFreeKey14 TicketFreeText14
!           TicketFreeKey15 TicketFreeText15 TicketFreeKey16 TicketFreeText16)) {
              # get search array params (get submitted params)
              my @Array = $Self->{ParamObject}->GetArray(Param => $_);
--- 111,123 ----
          # get array params
          foreach (qw(StateIDs StateTypeIDs PriorityIDs OwnerIDs ResponsibleIDs
!             TicketFreeKey1 TicketFreeText1 TicketFreeKey2 TicketFreeText2
!             TicketFreeKey3 TicketFreeText3 TicketFreeKey4 TicketFreeText4
!             TicketFreeKey5 TicketFreeText5 TicketFreeKey6 TicketFreeText6
!             TicketFreeKey7 TicketFreeText7 TicketFreeKey8 TicketFreeText8
!             TicketFreeKey9 TicketFreeText9 TicketFreeKey10 TicketFreeText10
!             TicketFreeKey11 TicketFreeText11 TicketFreeKey12 TicketFreeText12
!             TicketFreeKey13 TicketFreeText13 TicketFreeKey14 TicketFreeText14
!             TicketFreeKey15 TicketFreeText15 TicketFreeKey16 TicketFreeText16
!         )) {
              # get search array params (get submitted params)
              my @Array = $Self->{ParamObject}->GetArray(Param => $_);
***************
*** 178,232 ****
          }
          elsif ($GetParam{TimeSearchType} eq 'TimeSlot') {
!           foreach (qw(Month Day)) {
!               if ($GetParam{"TicketCreateTimeStart$_"} <= 9) {
!                   $GetParam{"TicketCreateTimeStart$_"} = '0'.$GetParam{"TicketCreateTimeStart$_"};
!               }
!           }
!           foreach (qw(Month Day)) {
!               if ($GetParam{"TicketCreateTimeStop$_"} <= 9) {
!                   $GetParam{"TicketCreateTimeStop$_"} = '0'.$GetParam{"TicketCreateTimeStop$_"};
!               }
!           }
!           if ($GetParam{TicketCreateTimeStartDay} && $GetParam{TicketCreateTimeStartMonth} && $GetParam{TicketCreateTimeStartYear}) {
!               $GetParam{TicketCreateTimeNewerDate} = $GetParam{TicketCreateTimeStartYear}.
!                 '-'.$GetParam{TicketCreateTimeStartMonth}.
!                 '-'.$GetParam{TicketCreateTimeStartDay}.
!                 ' 00:00:01';
!           }
!           if ($GetParam{TicketCreateTimeStopDay} && $GetParam{TicketCreateTimeStopMonth} && $GetParam{TicketCreateTimeStopYear}) {
!               $GetParam{TicketCreateTimeOlderDate} = $GetParam{TicketCreateTimeStopYear}.
!                 '-'.$GetParam{TicketCreateTimeStopMonth}.
!                 '-'.$GetParam{TicketCreateTimeStopDay}.
!                 ' 23:59:59';
!           }
!         }
!         elsif ($GetParam{TimeSearchType} eq 'TimePoint') {
!           if ($GetParam{TicketCreateTimePoint} && $GetParam{TicketCreateTimePointStart} && $GetParam{TicketCreateTimePointFormat}) {
!             my $Time = 0;
!             if ($GetParam{TicketCreateTimePointFormat} eq 'minute') {
!                 $Time = $GetParam{TicketCreateTimePoint};
!             }
!             elsif ($GetParam{TicketCreateTimePointFormat} eq 'hour') {
!                 $Time = $GetParam{TicketCreateTimePoint} * 60;
!             }
!             elsif ($GetParam{TicketCreateTimePointFormat} eq 'day') {
!                 $Time = $GetParam{TicketCreateTimePoint} * 60 * 24;
!             }
!             elsif ($GetParam{TicketCreateTimePointFormat} eq 'week') {
!                 $Time = $GetParam{TicketCreateTimePoint} * 60 * 24 * 7;
              }
!             elsif ($GetParam{TicketCreateTimePointFormat} eq 'month') {
!                 $Time = $GetParam{TicketCreateTimePoint} * 60 * 24 * 30;
              }
!             elsif ($GetParam{TicketCreateTimePointFormat} eq 'year') {
!                 $Time = $GetParam{TicketCreateTimePoint} * 60 * 24 * 365;
              }
!             if ($GetParam{TicketCreateTimePointStart} eq 'Before') {
!                 $GetParam{TicketCreateTimeOlderMinutes} = $Time;
              }
!             else {
!                 $GetParam{TicketCreateTimeNewerMinutes} = $Time;
              }
-           }
          }
          # free time
--- 179,233 ----
          }
          elsif ($GetParam{TimeSearchType} eq 'TimeSlot') {
!             foreach (qw(Month Day)) {
!                 if ($GetParam{"TicketCreateTimeStart$_"} <= 9) {
!                     $GetParam{"TicketCreateTimeStart$_"} = '0'.$GetParam{"TicketCreateTimeStart$_"};
!                 }
              }
!             foreach (qw(Month Day)) {
!                 if ($GetParam{"TicketCreateTimeStop$_"} <= 9) {
!                     $GetParam{"TicketCreateTimeStop$_"} = '0'.$GetParam{"TicketCreateTimeStop$_"};
!                 }
              }
!             if ($GetParam{TicketCreateTimeStartDay} && $GetParam{TicketCreateTimeStartMonth} && $GetParam{TicketCreateTimeStartYear}) {
!                 $GetParam{TicketCreateTimeNewerDate} = $GetParam{TicketCreateTimeStartYear}.
!                     '-'.$GetParam{TicketCreateTimeStartMonth}.
!                     '-'.$GetParam{TicketCreateTimeStartDay}.
!                     ' 00:00:01';
              }
!             if ($GetParam{TicketCreateTimeStopDay} && $GetParam{TicketCreateTimeStopMonth} && $GetParam{TicketCreateTimeStopYear}) {
!                 $GetParam{TicketCreateTimeOlderDate} = $GetParam{TicketCreateTimeStopYear}.
!                     '-'.$GetParam{TicketCreateTimeStopMonth}.
!                     '-'.$GetParam{TicketCreateTimeStopDay}.
!                     ' 23:59:59';
              }
!         }
!         elsif ($GetParam{TimeSearchType} eq 'TimePoint') {
!             if ($GetParam{TicketCreateTimePoint} && $GetParam{TicketCreateTimePointStart} && $GetParam{TicketCreateTimePointFormat}) {
!                 my $Time = 0;
!                 if ($GetParam{TicketCreateTimePointFormat} eq 'minute') {
!                     $Time = $GetParam{TicketCreateTimePoint};
!                 }
!                 elsif ($GetParam{TicketCreateTimePointFormat} eq 'hour') {
!                     $Time = $GetParam{TicketCreateTimePoint} * 60;
!                 }
!                 elsif ($GetParam{TicketCreateTimePointFormat} eq 'day') {
!                     $Time = $GetParam{TicketCreateTimePoint} * 60 * 24;
!                 }
!                 elsif ($GetParam{TicketCreateTimePointFormat} eq 'week') {
!                     $Time = $GetParam{TicketCreateTimePoint} * 60 * 24 * 7;
!                 }
!                 elsif ($GetParam{TicketCreateTimePointFormat} eq 'month') {
!                     $Time = $GetParam{TicketCreateTimePoint} * 60 * 24 * 30;
!                 }
!                 elsif ($GetParam{TicketCreateTimePointFormat} eq 'year') {
!                     $Time = $GetParam{TicketCreateTimePoint} * 60 * 24 * 365;
!                 }
!                 if ($GetParam{TicketCreateTimePointStart} eq 'Before') {
!                     $GetParam{TicketCreateTimeOlderMinutes} = $Time;
!                 }
!                 else {
!                     $GetParam{TicketCreateTimeNewerMinutes} = $Time;
!                 }
              }
          }
          # free time
***************
*** 274,348 ****
  
          foreach (@ViewableIDs) {
!           $Counter++;
!           # build search result
!           if ($Counter >= $Self->{StartHit} && $Counter < ($Self->{SearchPageShown}+$Self->{StartHit}) ) {
!             # get first article data
!             my %Data = $Self->{TicketObject}->ArticleFirstArticle(TicketID => $_);
!             # get whole article (if configured!)
!             if ($Self->{ConfigObject}->Get('CustomerSearchArticleTreeCSV') && $GetParam{ResultForm} eq 'CSV') {
!                 my @Article = $Self->{TicketObject}->ArticleGet(
!                     TicketID => $_
!                 );
!                 foreach my $Articles (@Article) {
!                     if ($Articles->{Body}) {
!                         $Data{ArticleTree} .= "\n-->||$Articles->{ArticleType}||$Articles->{From}||".$Articles->{Created}."||<--------------\n".$Articles->{Body};
                      }
                  }
!             }
!             # customer info
!             my %CustomerData = ();
!             if ($Data{CustomerUserID}) {
!                 %CustomerData = $Self->{CustomerUserObject}->CustomerUserDataGet(
!                     User => $Data{CustomerUserID},
!                 );
!             }
!             elsif ($Data{CustomerID}) {
!                 %CustomerData = $Self->{CustomerUserObject}->CustomerUserDataGet(
!                     CustomerID => $Data{CustomerID},
!                 );
!             }
!             # customer info (customer name)
!             if ($CustomerData{UserLogin}) {
!                 $Data{CustomerName} = $Self->{CustomerUserObject}->CustomerName(
!                     UserLogin => $CustomerData{UserLogin},
!                 );
!             }
!             # user info
!             my %UserInfo = $Self->{UserObject}->GetUserData(
!                 User => $Data{Owner},
!                 Cached => 1
!             );
!             # generate ticket result
!             if ($GetParam{ResultForm} eq 'CSV') {
!                 # csv quote
!                 foreach (keys %Data) {
!                     $Data{$_} =~ s/"/""/g if ($Data{$_});
!                 }
!                 $Param{StatusTable} .= $Self->MaskCSVResult(
!                     %Data,
!                     %UserInfo,
!                     AccountedTime => $Self->{TicketObject}->TicketAccountedTimeGet(TicketID => $_),
!                 )."\n";
!             }
!             else {
!                 # Condense down the subject
!                 my $Subject = $Self->{TicketObject}->TicketSubjectClean(
!                     TicketNumber => $Data{TicketNumber},
!                     Subject => $Data{Subject} || '',
                  );
!                 $Data{Age} = $Self->{LayoutObject}->CustomerAge(Age => $Data{Age}, Space => ' ');
!                 # customer info string
!                 $Data{CustomerName} = '('.$Data{CustomerName}.')' if ($Data{CustomerName});
!                 # add blocks to template
!                 $Self->{LayoutObject}->Block(
!                     Name => 'Record',
!                     Data => {
                          %Data,
-                         Subject => $Subject,
                          %UserInfo,
!                     },
!                 );
              }
-           }
          }
          # start html page
--- 275,349 ----
  
          foreach (@ViewableIDs) {
!             $Counter++;
!             # build search result
!             if ($Counter >= $Self->{StartHit} && $Counter < ($Self->{SearchPageShown}+$Self->{StartHit}) ) {
!                 # get first article data
!                 my %Data = $Self->{TicketObject}->ArticleFirstArticle(TicketID => $_);
!                 # get whole article (if configured!)
!                 if ($Self->{ConfigObject}->Get('CustomerSearchArticleTreeCSV') && $GetParam{ResultForm} eq 'CSV') {
!                     my @Article = $Self->{TicketObject}->ArticleGet(
!                         TicketID => $_
!                     );
!                     foreach my $Articles (@Article) {
!                         if ($Articles->{Body}) {
!                             $Data{ArticleTree} .= "\n-->||$Articles->{ArticleType}||$Articles->{From}||".$Articles->{Created}."||<--------------\n".$Articles->{Body};
!                         }
                      }
                  }
!                 # customer info
!                 my %CustomerData = ();
!                 if ($Data{CustomerUserID}) {
!                     %CustomerData = $Self->{CustomerUserObject}->CustomerUserDataGet(
!                         User => $Data{CustomerUserID},
!                     );
!                 }
!                 elsif ($Data{CustomerID}) {
!                     %CustomerData = $Self->{CustomerUserObject}->CustomerUserDataGet(
!                         CustomerID => $Data{CustomerID},
!                     );
!                 }
!                 # customer info (customer name)
!                 if ($CustomerData{UserLogin}) {
!                     $Data{CustomerName} = $Self->{CustomerUserObject}->CustomerName(
!                         UserLogin => $CustomerData{UserLogin},
!                     );
!                 }
!                 # user info
!                 my %UserInfo = $Self->{UserObject}->GetUserData(
!                     User => $Data{Owner},
!                     Cached => 1
                  );
!                 # generate ticket result
!                 if ($GetParam{ResultForm} eq 'CSV') {
!                     # csv quote
!                     foreach (keys %Data) {
!                         $Data{$_} =~ s/"/""/g if ($Data{$_});
!                     }
!                     $Param{StatusTable} .= $Self->MaskCSVResult(
                          %Data,
                          %UserInfo,
!                         AccountedTime => $Self->{TicketObject}->TicketAccountedTimeGet(TicketID => $_),
!                     )."\n";
!                 }
!                 else {
!                     # Condense down the subject
!                     my $Subject = $Self->{TicketObject}->TicketSubjectClean(
!                         TicketNumber => $Data{TicketNumber},
!                         Subject => $Data{Subject} || '',
!                     );
!                     $Data{Age} = $Self->{LayoutObject}->CustomerAge(Age => $Data{Age}, Space => ' ');
!                     # customer info string
!                     $Data{CustomerName} = '('.$Data{CustomerName}.')' if ($Data{CustomerName});
!                     # add blocks to template
!                     $Self->{LayoutObject}->Block(
!                         Name => 'Record',
!                         Data => {
!                             %Data,
!                             Subject => $Subject,
!                             %UserInfo,
!                         },
!                     );
!                 }
              }
          }
          # start html page
***************
*** 464,471 ****
      );
      $Param{'StatesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef(
!         Data => { $Self->{StateObject}->StateList(
!              UserID => $Self->{UserID},
!              Action => $Self->{Action},
!              )
          },
          Name => 'StateIDs',
--- 465,473 ----
      );
      $Param{'StatesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef(
!         Data => {
!             $Self->{StateObject}->StateList(
!                 UserID => $Self->{UserID},
!                 Action => $Self->{Action},
!             )
          },
          Name => 'StateIDs',
***************
*** 484,490 ****
      );
      $Param{'PriotitiesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef(
!         Data => { $Self->{PriorityObject}->PriorityList(
!             UserID => $Self->{UserID},
!             Action => $Self->{Action},
              ),
          },
--- 486,493 ----
      );
      $Param{'PriotitiesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef(
!         Data => {
!             $Self->{PriorityObject}->PriorityList(
!                 UserID => $Self->{UserID},
!                 Action => $Self->{Action},
              ),
          },
***************
*** 673,675 ****
  }
  
! 1;
--- 676,678 ----
  }
  
! 1;
\ No newline at end of file

Index: Installer.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/Modules/Installer.pm,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -r1.41 -r1.42
*** Installer.pm	2 Nov 2006 13:02:03 -0000	1.41
--- Installer.pm	1 Jan 2007 23:18:15 -0000	1.42
***************
*** 1,5 ****
  # --
  # Kernel/Modules/Installer.pm - provides the DB installer
! # Copyright (C) 2001-2006 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
--- 1,5 ----
  # --
  # Kernel/Modules/Installer.pm - provides the DB installer
! # Copyright (C) 2001-2007 OTRS GmbH, http://otrs.org/
  # --
  # $Id$
***************
*** 208,212 ****
  
          if ($DB{DBAction} eq 'Create') {
!           # FIXME !!! use $DB{Type}!!!
              $Self->{LayoutObject}->Block(
                  Name => 'DatabaseResult',
--- 208,212 ----
  
          if ($DB{DBAction} eq 'Create') {
!             # FIXME !!! use $DB{Type}!!!
              $Self->{LayoutObject}->Block(
                  Name => 'DatabaseResult',



More information about the cvs-log mailing list