diff -Nru otrs2-6.2.1/AUTHORS.md otrs2-6.2.2/AUTHORS.md --- otrs2-6.2.1/AUTHORS.md 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/AUTHORS.md 2021-12-14 15:52:34.000000000 +0000 @@ -133,12 +133,14 @@ * Zoran Ilibasic * Zoran Ilibasic * Zoran Ilibasic +* anonymous * b1-luettje <53084931+b1-luettje@users.noreply.github.com> * dennykorsukewitz * dennykorsukewitz * djurici * jsinagowitz <91074418+jsinagowitz@users.noreply.github.com> * juanmclavero +* meisterheister <35762852+meisterheister@users.noreply.github.com> * otrsintern * paulfolkers <83212096+paulfolkers@users.noreply.github.com> * reneeb diff -Nru otrs2-6.2.1/CHANGES.md otrs2-6.2.2/CHANGES.md --- otrs2-6.2.1/CHANGES.md 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/CHANGES.md 2021-12-14 15:52:34.000000000 +0000 @@ -1,3 +1,22 @@ +# 6.2.2 2021-12-15 + - 2021-12-14 Added ProcessListTreeView in AgentTicketProcess and CustomerTicketProcess. + - 2021-12-14 Added missing translation for process and activity in CustomerTicketZoom.tt. + - 2021-12-14 Removed translation for process in AdminProcessManagement. + - 2021-12-14 Fixed bug, too long process / activity names are not translated. + - 2021-12-03 Fixed - Links in dynamic fields are shortened so that the link no longer works (CustomerTicketZoom). + - 2021-12-02 Fixed Bug - Avoidable error message / entry in logfiles (#123). [#123](https://github.com/znuny/Znuny/issues/123) + - 2021-12-01 Fixed wrong POD of TransitionAction::AppointmentCreate. + - 2021-11-30 Added _ReplaceAdditionalAttributes to ProcessManagement/TransitionAction. + - 2021-11-29 Fixed POD of Kernel::System::ProcessManagement::TransitionAction::DynamicFieldRemove::Run. + - 2021-11-26 Fixed error "Parameter 'Config' must be a hash ref with data!" (#173). Thanks to @meisterheister. [#173](https://github.com/znuny/Znuny/issues/173) + - 2021-11-25 Removed error log if !IsHashRefWithData( Config ) in `SanitizeConfig`. This is to strict and not needed. + - 2021-11-25 Sector Nord AG: Replaced hardcoded attributes with a dynamic Sysconfig in Kernel/System/Ticket/Event/NotificationEvent.pm (#171). Thanks to @LuBroering (Lukas Bröring SectorNord AG). [#171](https://github.com/znuny/Znuny/issues/171) + - 2021-11-25 Add option '--no-tablespaces' to scripts/backup.pl (#136). Thanks to @meisterheister. [#136](https://github.com/znuny/Znuny/issues/136) + - 2021-11-25 Prevents error message "no TicketID" on sending an answer if no TicketID exists (#133). Thanks to @Reedu. [#133](https://github.com/znuny/Znuny/issues/133) + - 2021-11-25 Fixed - "No TicketID is given!" on each outgoing reply #170 https://github.com/znuny/Znuny/issues/170.Thanks to @Reedu. [#133](https://github.com/znuny/Znuny/issues/133) + - 2021-11-25 Fixed - Bug - Regression Error Message in Log #126 https://github.com/znuny/Znuny/issues/126. Thanks to @Reedu. [#133](https://github.com/znuny/Znuny/issues/133) + - 2021-11-15 Fixed CPANUpdate console command to also work on FreeBSD. Thanks to @papeng. [#162](https://github.com/znuny/Znuny/issues/162) + # 6.2.1 2021-10-27 - 2021-10-26 Fixed call to encode_base64 in Kernel::System::Ticket. Thanks to @Reedu. [#160](https://github.com/znuny/Znuny/issues/160) - 2021-10-25 Console command Dev::Code::CPANUpdate now uses proxy and SSL settings of SysConfig options WebUserAgent::Proxy, WebUserAgent::NoProxy and WebUserAgent::DisableSSLVerification. @@ -70,6 +89,23 @@ - 2021-06-15 Use ticket title as the default appointment title (#90). Thanks to Renée Bäcker (@reneeb). [#90](https://github.com/znuny/Znuny/pull/90) - 2021-06-15 Column list validation before saving agent preferences (#84). Thanks to Paweł Bogusławski (@pboguslawski). [#84](https://github.com/znuny/Znuny/pull/84) +# 6.0.39 2021-12-15 + - 2021-12-14 Added ProcessListTreeView in AgentTicketProcess and CustomerTicketProcess. + - 2021-12-14 Added missing translation for process and activity in CustomerTicketZoom.tt. + - 2021-12-14 Removed translation for process in AdminProcessManagement. + - 2021-12-14 Fixed bug, too long process / activity names are not translated. + - 2021-12-03 Deactivated business solution daemon tasks. + - 2021-12-03 Fixed - Links in dynamic fields are shortened so that the link no longer works (CustomerTicketZoom). + - 2021-12-01 Fixed Bug - Avoidable error message / entry in logfiles (#123). [#123](https://github.com/znuny/Znuny/issues/123) + - 2021-11-26 Fixed error "Parameter 'Config' must be a hash ref with data!" (#173). Thanks to @meisterheister. [#173](https://github.com/znuny/Znuny/issues/173) + - 2021-11-25 Removed error log if !IsHashRefWithData( Config ) in `SanitizeConfig`. This is to strict and not needed. + - 2021-11-25 Sector Nord AG: Replaced hardcoded attributes with a dynamic Sysconfig in Kernel/System/Ticket/Event/NotificationEvent.pm (#171). Thanks to @LuBroering (Lukas Bröring SectorNord AG). [#171](https://github.com/znuny/Znuny/issues/171) + - 2021-11-25 Add option '--no-tablespaces' to scripts/backup.pl (#136). Thanks to @meisterheister. [#136](https://github.com/znuny/Znuny/issues/136) + - 2021-11-25 Prevents error message "no TicketID" on sending an answer if no TicketID exists (#133). Thanks to @Reedu. [#133](https://github.com/znuny/Znuny/issues/133) + - 2021-11-25 Fixed - "No TicketID is given!" on each outgoing reply #170 https://github.com/znuny/Znuny/issues/170.Thanks to @Reedu. [#133](https://github.com/znuny/Znuny/issues/133) + - 2021-11-25 Fixed - Bug - Regression Error Message in Log #126 https://github.com/znuny/Znuny/issues/126. Thanks to @Reedu. [#133](https://github.com/znuny/Znuny/issues/133) + - 2021-11-15 Fixed CPANUpdate console command to also work on FreeBSD. Thanks to @papeng. [#162](https://github.com/znuny/Znuny/issues/162) + # 6.0.38 2021-10-27 - 2021-10-21 Fixed error log message for missing days in Kernel::System::SysConfig::ValueType::WorkingHours::ModifiedValueGet(). [#122](https://github.com/znuny/Znuny/issues/122) - 2021-10-21 Fixed "Need Ticket ID" error when switching templates in AgentTicketCommon modules. [#127](https://github.com/znuny/Znuny/issues/127) diff -Nru otrs2-6.2.1/debian/changelog otrs2-6.2.2/debian/changelog --- otrs2-6.2.1/debian/changelog 2021-10-29 09:44:38.000000000 +0000 +++ otrs2-6.2.2/debian/changelog 2021-12-17 08:40:39.000000000 +0000 @@ -1,3 +1,16 @@ +otrs2 (6.2.2-2) unstable; urgency=medium + + * Execute migration scripts for version 6.2.2. + + -- Patrick Matthäi Fri, 17 Dec 2021 09:40:39 +0100 + +otrs2 (6.2.2-1) unstable; urgency=medium + + * New upstream release. + - Remove patch 07-otrs-business-check. + + -- Patrick Matthäi Fri, 17 Dec 2021 09:15:54 +0100 + otrs2 (6.2.1-1) unstable; urgency=medium * New upstream release. diff -Nru otrs2-6.2.1/debian/patches/07-otrs-business-check.diff otrs2-6.2.2/debian/patches/07-otrs-business-check.diff --- otrs2-6.2.1/debian/patches/07-otrs-business-check.diff 2021-10-29 09:44:38.000000000 +0000 +++ otrs2-6.2.2/debian/patches/07-otrs-business-check.diff 1970-01-01 00:00:00.000000000 +0000 @@ -1,25 +0,0 @@ -# Per default deactivate OTRSBusinessEntitlementCheck and -# OTRSBusinessAvailabilityCheck cronjob, since they connect to cloud.otrs.com. -# Closes: #806263 - -diff -Naur otrs-6.0.1.orig/Kernel/Config/Files/XML/Daemon.xml otrs-6.0.1/Kernel/Config/Files/XML/Daemon.xml ---- otrs-6.0.1.orig/Kernel/Config/Files/XML/Daemon.xml 2017-11-17 18:04:24.000000000 +0100 -+++ otrs-6.0.1/Kernel/Config/Files/XML/Daemon.xml 2017-11-30 10:22:39.728508767 +0100 -@@ -755,7 +755,7 @@ - - - -- -+ - Checks the entitlement status of OTRS Business Solution™. - Daemon::SchedulerCronTaskManager::Task - -@@ -772,7 +772,7 @@ - - - -- -+ - Checks the availability of OTRS Business Solution™ for this system. - Daemon::SchedulerCronTaskManager::Task - diff -Nru otrs2-6.2.1/debian/patches/series otrs2-6.2.2/debian/patches/series --- otrs2-6.2.1/debian/patches/series 2021-10-29 09:44:38.000000000 +0000 +++ otrs2-6.2.2/debian/patches/series 2021-12-17 08:40:39.000000000 +0000 @@ -3,7 +3,6 @@ 04-opt.diff 05-database.diff 06-no-installer.diff -07-otrs-business-check.diff 08-usable-apache-config.diff 09-disable-DashboardProductNotify.diff 11-do-not-test-file-writes.diff diff -Nru otrs2-6.2.1/debian/rules otrs2-6.2.2/debian/rules --- otrs2-6.2.1/debian/rules 2021-10-29 09:44:38.000000000 +0000 +++ otrs2-6.2.2/debian/rules 2021-12-17 08:40:39.000000000 +0000 @@ -19,8 +19,8 @@ $(OTRS_DST)$(DB_DIR)/install/pgsql cp debian/schemas/DBUpdate-to-6.0.32 \ $(OTRS_DST)$(DB_BASE)/scripts/otrs2/upgrade/pgsql/6.0.32 - cp debian/schemas/DBUpdate-to-6.1.1 \ - $(OTRS_DST)$(DB_BASE)/scripts/otrs2/upgrade/pgsql/6.1.1 + cp debian/schemas/DBUpdate-to-6.2.2 \ + $(OTRS_DST)$(DB_BASE)/scripts/otrs2/upgrade/pgsql/6.2.2 # MySQL cat scripts/database/otrs-schema.mysql.sql \ scripts/database/otrs-initial_insert.mysql.sql \ @@ -28,8 +28,8 @@ $(OTRS_DST)$(DB_DIR)/install/mysql cp debian/schemas/DBUpdate-to-6.0.32 \ $(OTRS_DST)$(DB_BASE)/scripts/otrs2/upgrade/mysql/6.0.32 - cp debian/schemas/DBUpdate-to-6.1.1 \ - $(OTRS_DST)$(DB_BASE)/scripts/otrs2/upgrade/mysql/6.1.1 + cp debian/schemas/DBUpdate-to-6.2.2 \ + $(OTRS_DST)$(DB_BASE)/scripts/otrs2/upgrade/mysql/6.2.2 # Remove useless stuff. rm -rf $(OTRS_DST)$(OTRSHOME)/scripts/auto_build rm -rf $(OTRS_DST)/var/lib/otrs/httpd/htdocs/js/thirdparty/ckeditor-*/plugins/exportpdf/tests/ diff -Nru otrs2-6.2.1/debian/schemas/DBUpdate-to-6.1.1 otrs2-6.2.2/debian/schemas/DBUpdate-to-6.1.1 --- otrs2-6.2.1/debian/schemas/DBUpdate-to-6.1.1 2021-10-29 09:44:38.000000000 +0000 +++ otrs2-6.2.2/debian/schemas/DBUpdate-to-6.1.1 1970-01-01 00:00:00.000000000 +0000 @@ -1,5 +0,0 @@ -#!/bin/sh - -# needs to be run in $OTRS_HOME - -su otrs -s /bin/sh -c "cd /usr/share/otrs && /usr/bin/perl ./scripts/MigrateToZnuny6_1.pl --non-interactive --verbose" diff -Nru otrs2-6.2.1/debian/schemas/DBUpdate-to-6.2.2 otrs2-6.2.2/debian/schemas/DBUpdate-to-6.2.2 --- otrs2-6.2.1/debian/schemas/DBUpdate-to-6.2.2 1970-01-01 00:00:00.000000000 +0000 +++ otrs2-6.2.2/debian/schemas/DBUpdate-to-6.2.2 2021-12-17 08:40:39.000000000 +0000 @@ -0,0 +1,6 @@ +#!/bin/sh + +# needs to be run in $OTRS_HOME + +su otrs -s /bin/sh -c "cd /usr/share/otrs && /usr/bin/perl ./scripts/MigrateToZnuny6_2.pl --non-interactive --verbose" +su otrs -s /bin/sh -c "cd /usr/share/otrs && /usr/bin/perl ./bin/otrs.Console.pl Maint::Config::Rebuild --cleanup || true" diff -Nru otrs2-6.2.1/Kernel/Config/Files/XML/Daemon.xml otrs2-6.2.2/Kernel/Config/Files/XML/Daemon.xml --- otrs2-6.2.1/Kernel/Config/Files/XML/Daemon.xml 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Config/Files/XML/Daemon.xml 2021-12-14 15:52:34.000000000 +0000 @@ -721,24 +721,7 @@ - - Sends registration information to OTRS group. - Daemon::SchedulerCronTaskManager::Task - - - RegistrationUpdateSend - 30 * * * * - Kernel::System::Console::Command::Maint::Registration::UpdateSend - Execute - 1 - - - - - - - - + Collect support data for asynchronous plug-in modules. Daemon::SchedulerCronTaskManager::Task @@ -749,40 +732,6 @@ Execute 1 - - - - - - - - Checks the entitlement status of OTRS Business Solution™. - Daemon::SchedulerCronTaskManager::Task - - - OTRSBusinessEntitlementCheck - 25,45 */1 * * * - Kernel::System::Console::Command::Maint::OTRSBusiness::EntitlementCheck - Execute - 1 - - - - - - - - - Checks the availability of OTRS Business Solution™ for this system. - Daemon::SchedulerCronTaskManager::Task - - - OTRSBusinessAvailabilityCheck - 15,35,55 */1 * * * - Kernel::System::Console::Command::Maint::OTRSBusiness::AvailabilityCheck - Execute - 1 - diff -Nru otrs2-6.2.1/Kernel/Config/Files/XML/Framework.xml otrs2-6.2.2/Kernel/Config/Files/XML/Framework.xml --- otrs2-6.2.1/Kernel/Config/Files/XML/Framework.xml 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Config/Files/XML/Framework.xml 2021-12-14 15:52:34.000000000 +0000 @@ -849,7 +849,7 @@ - + Defines the module to display a notification in different interfaces on different occasions for OTRS Business Solution™. Frontend::Agent::FrontendNotification @@ -859,7 +859,7 @@ - + Defines the module to display a notification in different interfaces on different occasions for OTRS Business Solution™. Frontend::Customer::FrontendNotification diff -Nru otrs2-6.2.1/Kernel/Config/Files/XML/ProcessManagement.xml otrs2-6.2.2/Kernel/Config/Files/XML/ProcessManagement.xml --- otrs2-6.2.1/Kernel/Config/Files/XML/ProcessManagement.xml 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Config/Files/XML/ProcessManagement.xml 2021-12-14 15:52:34.000000000 +0000 @@ -596,6 +596,16 @@ + + Shows existing parent/child (separated by ::) process lists in the form of a tree or a list. + Frontend::Agent::View::TicketProcess + + + Tree view + List view + + + Determines the next possible ticket states, for process tickets in the customer interface. Frontend::Customer::View::TicketProcess @@ -606,6 +616,16 @@ + + Shows existing parent/child (separated by ::) process lists in the form of a tree or a list. + Frontend::Customer::View::TicketProcess + + + Tree view + List view + + + Controls if CustomerID is read-only in the agent interface. Frontend::Agent::View::TicketProcess @@ -743,7 +763,7 @@ (* required for Custom) 12 (number of time units) (* required for Custom) minutes|hours|days (* required for Custom) beforestart|afterstart|beforeend|afterend (Possible notification types for the "relative" type) - (optional) 123 (dynamic field for saving the appointment ID (suitable for linking the appointment later) + (optional) AppointmentID (dynamic field for saving the appointment ID (suitable for linking the appointment later) diff -Nru otrs2-6.2.1/Kernel/Config/Files/XML/Ticket.xml otrs2-6.2.2/Kernel/Config/Files/XML/Ticket.xml --- otrs2-6.2.1/Kernel/Config/Files/XML/Ticket.xml 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Config/Files/XML/Ticket.xml 2021-12-14 15:52:34.000000000 +0000 @@ -10541,6 +10541,39 @@ 320 + + Ignores not ticket related attributes. + Core::Event::Ticket::NotificationEvent + + + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + + + Defines all the parameters for this notification transport. Frontend::Admin::View::NotificationEvent diff -Nru otrs2-6.2.1/Kernel/Modules/AgentTicketProcess.pm otrs2-6.2.2/Kernel/Modules/AgentTicketProcess.pm --- otrs2-6.2.1/Kernel/Modules/AgentTicketProcess.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Modules/AgentTicketProcess.pm 2021-12-14 15:52:34.000000000 +0000 @@ -5745,8 +5745,10 @@ $Param{Errors}->{ProcessEntityIDInvalid} = ' ServerError' if ( $Param{ProcessEntityID} && !$Param{ProcessList}->{ $Param{ProcessEntityID} } ); - # get layout object my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout'); + my $ConfigObject = $Kernel::OM->Get('Kernel::Config'); + + my $Config = $ConfigObject->Get('Ticket::Frontend::AgentTicketProcess'); $Param{ProcessList} = $LayoutObject->BuildSelection( Class => 'Modernize Validate_Required' . ( $Param{Errors}->{ProcessEntityIDInvalid} || ' ' ), @@ -5755,7 +5757,8 @@ SelectedID => $Param{ProcessEntityID}, PossibleNone => 1, Sort => 'AlphanumericValue', - Translation => 0, + Translation => 1, + TreeView => $Config->{ProcessListTreeView} || 0, AutoComplete => 'off', ); diff -Nru otrs2-6.2.1/Kernel/Modules/CustomerTicketProcess.pm otrs2-6.2.2/Kernel/Modules/CustomerTicketProcess.pm --- otrs2-6.2.1/Kernel/Modules/CustomerTicketProcess.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Modules/CustomerTicketProcess.pm 2021-12-14 15:52:34.000000000 +0000 @@ -4004,8 +4004,10 @@ $Param{Errors}->{ProcessEntityIDInvalid} = ' ServerError' if ( $Param{ProcessEntityID} && !$Param{ProcessList}->{ $Param{ProcessEntityID} } ); - # get layout object my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout'); + my $ConfigObject = $Kernel::OM->Get('Kernel::Config'); + + my $Config = $ConfigObject->Get('Ticket::Frontend::CustomerTicketProcess'); $Param{ProcessList} = $LayoutObject->BuildSelection( Class => 'Modernize Validate_Required' . ( $Param{Errors}->{ProcessEntityIDInvalid} || ' ' ), @@ -4014,7 +4016,8 @@ SelectedID => $Param{ProcessEntityID}, PossibleNone => 1, Sort => 'AlphanumericValue', - Translation => 0, + Translation => 1, + TreeView => $Config->{ProcessListTreeView} || 0, AutoComplete => 'off', ); diff -Nru otrs2-6.2.1/Kernel/Modules/CustomerTicketZoom.pm otrs2-6.2.2/Kernel/Modules/CustomerTicketZoom.pm --- otrs2-6.2.1/Kernel/Modules/CustomerTicketZoom.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Modules/CustomerTicketZoom.pm 2021-12-14 15:52:34.000000000 +0000 @@ -1346,7 +1346,7 @@ Title => $ValueStrg->{Title}, Link => $DynamicFieldConfig->{Config}->{Link}, LinkPreview => $DynamicFieldConfig->{Config}->{LinkPreview}, - $DynamicFieldConfig->{Name} => $ValueStrg->{Value}, + $DynamicFieldConfig->{Name} => $ValueStrg->{Title}, }, ); } diff -Nru otrs2-6.2.1/Kernel/Output/HTML/Dashboard/TicketGeneric.pm otrs2-6.2.2/Kernel/Output/HTML/Dashboard/TicketGeneric.pm --- otrs2-6.2.1/Kernel/Output/HTML/Dashboard/TicketGeneric.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Output/HTML/Dashboard/TicketGeneric.pm 2021-12-14 15:52:34.000000000 +0000 @@ -325,10 +325,8 @@ if ( $Self->{Config}->{IsProcessWidget} ) { # get process management configuration - $Self->{ProcessManagementProcessID} - = $Kernel::OM->Get('Kernel::Config')->Get('Process::DynamicFieldProcessManagementProcessID'); - $Self->{ProcessManagementActivityID} - = $Kernel::OM->Get('Kernel::Config')->Get('Process::DynamicFieldProcessManagementActivityID'); + $Self->{ProcessManagementProcessID} = $ConfigObject->Get('Process::DynamicFieldProcessManagementProcessID'); + $Self->{ProcessManagementActivityID} = $ConfigObject->Get('Process::DynamicFieldProcessManagementActivityID'); # get the list of processes in the system my $ProcessListHash = $Kernel::OM->Get('Kernel::System::ProcessManagement::Process')->ProcessList( diff -Nru otrs2-6.2.1/Kernel/Output/HTML/Templates/Standard/AdminProcessManagement.tt otrs2-6.2.2/Kernel/Output/HTML/Templates/Standard/AdminProcessManagement.tt --- otrs2-6.2.1/Kernel/Output/HTML/Templates/Standard/AdminProcessManagement.tt 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Output/HTML/Templates/Standard/AdminProcessManagement.tt 2021-12-14 15:52:34.000000000 +0000 @@ -141,8 +141,8 @@ [% RenderBlockStart("ProcessRow") %] - - [% Translate(Data.Name) | html %] + + [% Data.Name | html %] [% Translate(Data.Description) | truncate(80) | html %] diff -Nru otrs2-6.2.1/Kernel/Output/HTML/Templates/Standard/AgentTicketZoom/TicketInformation.tt otrs2-6.2.2/Kernel/Output/HTML/Templates/Standard/AgentTicketZoom/TicketInformation.tt --- otrs2-6.2.1/Kernel/Output/HTML/Templates/Standard/AgentTicketZoom/TicketInformation.tt 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Output/HTML/Templates/Standard/AgentTicketZoom/TicketInformation.tt 2021-12-14 15:52:34.000000000 +0000 @@ -190,7 +190,7 @@
-

[% Data.Process | html %]

+

[% Translate(Data.Process) | html %]

diff -Nru otrs2-6.2.1/Kernel/Output/HTML/Templates/Standard/CustomerTicketZoom.tt otrs2-6.2.2/Kernel/Output/HTML/Templates/Standard/CustomerTicketZoom.tt --- otrs2-6.2.1/Kernel/Output/HTML/Templates/Standard/CustomerTicketZoom.tt 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/Output/HTML/Templates/Standard/CustomerTicketZoom.tt 2021-12-14 15:52:34.000000000 +0000 @@ -109,8 +109,8 @@
  • [% Translate("Responsible") | html %]: [% Data.ResponsibleName | html %]
  • [% RenderBlockEnd("Responsible") %] [% RenderBlockStart("ProcessData") %] -
  • [% Translate("Process") | html %]: [% Data.Process | html %]
  • -
  • [% Translate("Activity") | html %]: [% Data.Activity | html %]
  • +
  • [% Translate("Process") | html %]: [% Translate(Data.Process) | html %]
  • +
  • [% Translate("Activity") | html %]: [% Translate(Data.Activity) | html %]
  • [% RenderBlockEnd("ProcessData") %] # show ticket dynamic fields diff -Nru otrs2-6.2.1/Kernel/System/Console/Command/Dev/Code/CPANUpdate.pm otrs2-6.2.2/Kernel/System/Console/Command/Dev/Code/CPANUpdate.pm --- otrs2-6.2.1/Kernel/System/Console/Command/Dev/Code/CPANUpdate.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/Console/Command/Dev/Code/CPANUpdate.pm 2021-12-14 15:52:34.000000000 +0000 @@ -199,7 +199,7 @@ die "Error: Could not get DownloadURL." if !$DownloadURL; chomp $DownloadURL; - system("cd $TmpDir; wget -q -O - $DownloadURL | tar -xz --strip 1"); + system("cd $TmpDir; wget -q -O - $DownloadURL | tar -xzf - --strip 1"); if ( $ModuleConfig->{BuildBLib} ) { system("cd $TmpDir; perl Makefile.PL; make; cp -r $TmpDir/blib/lib/* $TargetPath"); diff -Nru otrs2-6.2.1/Kernel/System/Console/Command/Maint/OTRSBusiness/AvailabilityCheck.pm otrs2-6.2.2/Kernel/System/Console/Command/Maint/OTRSBusiness/AvailabilityCheck.pm --- otrs2-6.2.1/Kernel/System/Console/Command/Maint/OTRSBusiness/AvailabilityCheck.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/Console/Command/Maint/OTRSBusiness/AvailabilityCheck.pm 1970-01-01 00:00:00.000000000 +0000 @@ -1,115 +0,0 @@ -# -- -# Copyright (C) 2001-2021 OTRS AG, https://otrs.com/ -# Copyright (C) 2021 Znuny GmbH, https://znuny.org/ -# -- -# This software comes with ABSOLUTELY NO WARRANTY. For details, see -# the enclosed file COPYING for license information (GPL). If you -# did not receive this file, see https://www.gnu.org/licenses/gpl-3.0.txt. -# -- - -package Kernel::System::Console::Command::Maint::OTRSBusiness::AvailabilityCheck; - -use strict; -use warnings; -use utf8; - -use parent qw(Kernel::System::Console::BaseCommand); - -our @ObjectDependencies = ( - 'Kernel::System::DateTime', - 'Kernel::System::OTRSBusiness', - 'Kernel::System::SystemData', -); - -sub Configure { - my ( $Self, %Param ) = @_; - - $Self->Description('Check if OTRS Business Solution™ is available for the current system.'); - - $Self->AddOption( - Name => 'force', - Description => "Force to execute even if next update time has not been reached yet.", - Required => 0, - HasValue => 0, - ValueRegex => qr/.*/smx, - ); - - return; -} - -sub Run { - my ( $Self, %Param ) = @_; - - my $OTRSBusinessStr = "OTRS Business Solution™"; - - $Self->Print("Checking availability of $OTRSBusinessStr...\n"); - - my $Force = $Self->GetOption('force') || 0; - - # get OTRS business object - my $OTRSBusinessObject = $Kernel::OM->Get('Kernel::System::OTRSBusiness'); - - if ( !$Force ) { - - # first check if OTRS Business Solution™ package is installed - my $IsInstalled = $OTRSBusinessObject->OTRSBusinessIsInstalled(); - - # skip if it is not installed - return $Self->SkippCheck() if !$IsInstalled; - - # get system data object - my $SystemDataObject = $Kernel::OM->Get('Kernel::System::SystemData'); - - # get next update time - my $AvailabilityCheckNextUpdateTime = $SystemDataObject->SystemDataGet( - Key => 'OTRSBusiness::AvailabilityCheck::NextUpdateTime', - ); - - my $NextUpdateSystemTime; - - # if there is a defined NextUpdeTime convert it system time - if ($AvailabilityCheckNextUpdateTime) { - $NextUpdateSystemTime = $Kernel::OM->Create( - 'Kernel::System::DateTime', - ObjectParams => { - String => $AvailabilityCheckNextUpdateTime, - }, - ); - } - - # get current system time (to compare with next update time) - my $SystemTime = $Kernel::OM->Create('Kernel::System::DateTime'); - - # skip if is not time yet to check again - return $Self->SkippCheck() if $NextUpdateSystemTime - && $SystemTime < $NextUpdateSystemTime; - } - - # call the OTRS Business Solution™ availability cloud service - $OTRSBusinessObject->OTRSBusinessIsAvailable(); - - # return the off-line status to be tolerant to network failures - my $Success = $OTRSBusinessObject->OTRSBusinessIsAvailableOffline(); - - if ( !$Success ) { - $Self->Print(" $OTRSBusinessStr is not available for this system.\n"); - } - - # set the next update time - $OTRSBusinessObject->OTRSBusinessCommandNextUpdateTimeSet( - Command => 'AvailabilityCheck', - ); - - $Self->Print("Done.\n"); - return $Self->ExitCodeOk(); -} - -sub SkippCheck { - my ( $Self, %Param ) = @_; - - $Self->Print("No need to execute the availability check at this moment, skipping...\n"); - $Self->Print("Done.\n"); - return $Self->ExitCodeOk(); -} - -1; diff -Nru otrs2-6.2.1/Kernel/System/Console/Command/Maint/OTRSBusiness/EntitlementCheck.pm otrs2-6.2.2/Kernel/System/Console/Command/Maint/OTRSBusiness/EntitlementCheck.pm --- otrs2-6.2.1/Kernel/System/Console/Command/Maint/OTRSBusiness/EntitlementCheck.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/Console/Command/Maint/OTRSBusiness/EntitlementCheck.pm 1970-01-01 00:00:00.000000000 +0000 @@ -1,108 +0,0 @@ -# -- -# Copyright (C) 2001-2021 OTRS AG, https://otrs.com/ -# Copyright (C) 2021 Znuny GmbH, https://znuny.org/ -# -- -# This software comes with ABSOLUTELY NO WARRANTY. For details, see -# the enclosed file COPYING for license information (GPL). If you -# did not receive this file, see https://www.gnu.org/licenses/gpl-3.0.txt. -# -- - -package Kernel::System::Console::Command::Maint::OTRSBusiness::EntitlementCheck; - -use strict; -use warnings; -use utf8; - -use parent qw(Kernel::System::Console::BaseCommand); - -our @ObjectDependencies = ( - 'Kernel::System::DateTime', - 'Kernel::System::OTRSBusiness', - 'Kernel::System::SystemData', -); - -sub Configure { - my ( $Self, %Param ) = @_; - - $Self->Description('Check the OTRS Business Solution™ is entitled for this system.'); - - $Self->AddOption( - Name => 'force', - Description => "Force to execute even if next update time has not been reached yet.", - Required => 0, - HasValue => 0, - ValueRegex => qr/.*/smx, - ); - - return; -} - -sub Run { - my ( $Self, %Param ) = @_; - - my $OTRSBusinessStr = "OTRS Business Solution™"; - - $Self->Print("Checking the $OTRSBusinessStr entitlement status...\n"); - - my $Force = $Self->GetOption('force') || 0; - - # get OTRS Business object - my $OTRSBusinessObject = $Kernel::OM->Get('Kernel::System::OTRSBusiness'); - - my $OTRSBusinessInstalled = $OTRSBusinessObject->OTRSBusinessIsInstalled(); - - if ( !$Force && !$OTRSBusinessInstalled ) { - - $Self->Print("$OTRSBusinessStr is not installed in this system, skipping...\n"); - $Self->Print("Done.\n"); - return $Self->ExitCodeOk(); - } - - my $SystemDataObject = $Kernel::OM->Get('Kernel::System::SystemData'); - - my $AvailabilityCheckNextUpdateTime = $SystemDataObject->SystemDataGet( - Key => 'OTRSBusiness::EntitlementCheck::NextUpdateTime', - ); - - my $NextUpdateSystemTime; - - # if there is a defined NextUpdeTime convert it system time - if ($AvailabilityCheckNextUpdateTime) { - $NextUpdateSystemTime = $Kernel::OM->Create( - 'Kernel::System::DateTime', - ObjectParams => { - String => $AvailabilityCheckNextUpdateTime, - }, - ); - } - - my $SystemTime = $Kernel::OM->Create('Kernel::System::DateTime'); - - # do not update registration info before the next update (unless is forced) - if ( !$Force && $NextUpdateSystemTime && $SystemTime < $NextUpdateSystemTime ) { - $Self->Print("No need to execute the availability check at this moment, skipping...\n"); - $Self->Print("Done.\n"); - return $Self->ExitCodeOk(); - } - - my $Result = $OTRSBusinessObject->OTRSBusinessEntitlementStatus( - CallCloudService => 1, - ); - - my $IsInstalled = $OTRSBusinessObject->OTRSBusinessIsInstalled(); - - # set the next update time - $OTRSBusinessObject->OTRSBusinessCommandNextUpdateTimeSet( - Command => 'EntitlementCheck', - ); - - if ( lc $Result eq 'forbidden' && $IsInstalled ) { - $Self->PrintError("$OTRSBusinessStr is not entitled for this system."); - return $Self->ExitCodeError(); - } - - $Self->Print("Done.\n"); - return $Self->ExitCodeOk(); -} - -1; diff -Nru otrs2-6.2.1/Kernel/System/Console/Command/Maint/Registration/UpdateSend.pm otrs2-6.2.2/Kernel/System/Console/Command/Maint/Registration/UpdateSend.pm --- otrs2-6.2.1/Kernel/System/Console/Command/Maint/Registration/UpdateSend.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/Console/Command/Maint/Registration/UpdateSend.pm 1970-01-01 00:00:00.000000000 +0000 @@ -1,144 +0,0 @@ -# -- -# Copyright (C) 2001-2021 OTRS AG, https://otrs.com/ -# Copyright (C) 2021 Znuny GmbH, https://znuny.org/ -# -- -# This software comes with ABSOLUTELY NO WARRANTY. For details, see -# the enclosed file COPYING for license information (GPL). If you -# did not receive this file, see https://www.gnu.org/licenses/gpl-3.0.txt. -# -- - -package Kernel::System::Console::Command::Maint::Registration::UpdateSend; - -use strict; -use warnings; - -use parent qw(Kernel::System::Console::BaseCommand); - -our @ObjectDependencies = ( - 'Kernel::System::DateTime', - 'Kernel::Config', - 'Kernel::System::Registration', - 'Kernel::System::SystemData', -); - -sub Configure { - my ( $Self, %Param ) = @_; - - $Self->Description('Send an OTRS system registration update to OTRS Group.'); - - $Self->AddOption( - Name => 'force', - Description => "Force to execute even if next update time has not been reached yet.", - Required => 0, - HasValue => 0, - ValueRegex => qr/.*/smx, - ); - - $Self->AddOption( - Name => 'debug', - Description => "Output debug information while running.", - Required => 0, - HasValue => 0, - ValueRegex => qr/.*/smx, - ); - - return; -} - -sub Run { - my ( $Self, %Param ) = @_; - - $Self->Print("Sending system registration update...\n"); - - # check if cloud services are disabled - my $CloudServicesDisabled = $Kernel::OM->Get('Kernel::Config')->Get('CloudServices::Disabled') || 0; - - if ($CloudServicesDisabled) { - $Self->Print("Done.\n"); - return $Self->ExitCodeOk(); - } - - my $RegistrationObject = $Kernel::OM->Get('Kernel::System::Registration'); - - my %RegistrationData = $RegistrationObject->RegistrationDataGet(); - - if ( !$RegistrationData{State} || $RegistrationData{State} ne 'registered' ) { - $Self->Print("System is not registered, skipping...\n"); - $Self->Print("Done.\n"); - return $Self->ExitCodeOk(); - } - - my $NextUpdateSystemTime; - - # if there is a defined NextUpdeTime convert it system time - if ( $RegistrationData{NextUpdateTime} ) { - $NextUpdateSystemTime = $Kernel::OM->Create( - 'Kernel::System::DateTime', - ObjectParams => { - String => $RegistrationData{NextUpdateTime}, - }, - ); - } - - my $SystemTime = $Kernel::OM->Create('Kernel::System::DateTime'); - - my $Force = $Self->GetOption('force') || 0; - - # do not update registration info before the next update (unless is forced) - if ( !$Force && $NextUpdateSystemTime && $SystemTime < $NextUpdateSystemTime ) { - $Self->Print("No need to send the registration update at this moment, skipping...\n"); - $Self->Print("Done.\n"); - return $Self->ExitCodeOk(); - } - - # send the registration update - my %Result = $Kernel::OM->Get('Kernel::System::Registration')->RegistrationUpdateSend( - Debug => $Self->GetOption('debug') || 0, - ); - - # if everything is OK return successfully - if ( $Result{Success} ) { - $Self->Print("Done.\n"); - return $Self->ExitCodeOk(); - } - - # if there was a error get the registration information once again - my %UpdatedRegistrationData = $RegistrationObject->RegistrationDataGet(); - - my $NextUpdateTime = $UpdatedRegistrationData{NextUpdateTime} // ''; - $RegistrationData{NextUpdateTime} //= ''; - - # if the next update time was not set or is the same as the original, there should be a - # communications issue with the portal, retry in two hours - if ( !$NextUpdateTime || $RegistrationData{NextUpdateTime} eq $NextUpdateTime ) { - - # calculate next update time set it in two hours - $NextUpdateTime = $SystemTime->Clone(); - $NextUpdateTime->Add( Seconds => 60 * 60 * 2 ); - $NextUpdateTime = $NextUpdateTime->ToString(); - - # update or set the NextUpdateTime value - if ( defined $UpdatedRegistrationData{NextUpdateTime} ) { - - $Kernel::OM->Get('Kernel::System::SystemData')->SystemDataUpdate( - Key => 'Registration::NextUpdateTime', - Value => $NextUpdateTime, - UserID => 1, - ); - } - else { - - $Kernel::OM->Get('Kernel::System::SystemData')->SystemDataAdd( - Key => 'Registration::NextUpdateTime', - Value => $NextUpdateTime, - UserID => 1, - ); - } - } - - $Self->PrintError("System registration update was not sent successfully."); - $Self->PrintError("$Result{Reason}"); - return $Self->ExitCodeError(); -} - -1; diff -Nru otrs2-6.2.1/Kernel/System/DynamicField/Driver/ProcessManagement/ActivityID.pm otrs2-6.2.2/Kernel/System/DynamicField/Driver/ProcessManagement/ActivityID.pm --- otrs2-6.2.1/Kernel/System/DynamicField/Driver/ProcessManagement/ActivityID.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/DynamicField/Driver/ProcessManagement/ActivityID.pm 2021-12-14 15:52:34.000000000 +0000 @@ -122,6 +122,7 @@ ); } my $Value = $Activity->{Name} // ''; + $Value = $Param{LayoutObject}->{LanguageObject}->Translate($Value); my $Title = $Value; # HTMLOutput transformations diff -Nru otrs2-6.2.1/Kernel/System/DynamicField/Driver/ProcessManagement/ProcessID.pm otrs2-6.2.2/Kernel/System/DynamicField/Driver/ProcessManagement/ProcessID.pm --- otrs2-6.2.1/Kernel/System/DynamicField/Driver/ProcessManagement/ProcessID.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/DynamicField/Driver/ProcessManagement/ProcessID.pm 2021-12-14 15:52:34.000000000 +0000 @@ -118,7 +118,7 @@ } my $Value = $Process->{Name} // ''; - + $Value = $Param{LayoutObject}->{LanguageObject}->Translate($Value); my $Title = $Value; # HTMLOutput transformations diff -Nru otrs2-6.2.1/Kernel/System/DynamicField.pm otrs2-6.2.2/Kernel/System/DynamicField.pm --- otrs2-6.2.1/Kernel/System/DynamicField.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/DynamicField.pm 2021-12-14 15:52:34.000000000 +0000 @@ -1724,13 +1724,7 @@ return; } - if ( !IsHashRefWithData( $Param{Config} ) ) { - $LogObject->Log( - Priority => 'error', - Message => "Parameter 'Config' must be a hash ref with data!", - ); - return; - } + return if !IsHashRefWithData( $Param{Config} ); # Remove JavaScript, etc. from regex error messages. # This prevents execution of arbitrary JavaScript when showing diff -Nru otrs2-6.2.1/Kernel/System/EmailParser.pm otrs2-6.2.2/Kernel/System/EmailParser.pm --- otrs2-6.2.1/Kernel/System/EmailParser.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/EmailParser.pm 2021-12-14 15:52:34.000000000 +0000 @@ -747,7 +747,10 @@ elsif ( $PartData{ContentType} eq 'message/rfc822' ) { my ($SubjectString) = $Part->as_string() =~ m/^Subject: ([^\n]*(\n[ \t][^\n]*)*)/m; - my $Subject = $Self->_DecodeString( String => $SubjectString ) . '.eml'; + my $Subject = ''; + if ($SubjectString){ + $Subject = $Self->_DecodeString( String => $SubjectString ) . '.eml'; + } # cleanup filename $Subject = $Kernel::OM->Get('Kernel::System::Main')->FilenameCleanUp( diff -Nru otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/AppointmentCreate.pm otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/AppointmentCreate.pm --- otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/AppointmentCreate.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/AppointmentCreate.pm 2021-12-14 15:52:34.000000000 +0000 @@ -105,7 +105,7 @@ NotificationCustomDateTime => '2016-01-01 17:00:00', # (optional) Notification date time for custom template TicketAppointmentRuleID => '9bb20ea035e7a9930652a9d82d00c725', # (optional) Ticket appointment rule ID (for ticket appointments only!) - DynamicField_AppointmentID => '123', # (optional) dynamic field name to save the AppointmentID in a dynamic field (e.g. to link it afterwards) + DynamicField_AppointmentID => 'AppointmentID', # (optional) dynamic field name to save the AppointmentID in a dynamic field (e.g. to link it afterwards) UserID => 1, # (optional) UserID } @@ -148,6 +148,7 @@ # use ticket attributes if needed $Self->_ReplaceTicketAttributes(%Param); + $Self->_ReplaceAdditionalAttributes(%Param); # get calendar id if ( $Param{Config}->{CalendarName} ) { diff -Nru otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/ArticleSend.pm otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/ArticleSend.pm --- otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/ArticleSend.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/ArticleSend.pm 2021-12-14 15:52:34.000000000 +0000 @@ -153,6 +153,7 @@ # use ticket attributes if needed $Self->_ReplaceTicketAttributes(%Param); + $Self->_ReplaceAdditionalAttributes(%Param); my $RichText = $Param{Config}->{MimeType} =~ m{html}xmsi ? 1 : 0; @@ -186,7 +187,7 @@ ); next ATTACHMENT if !%Data; - push @{$Param{Config}->{Attachment}}, { + push @{ $Param{Config}->{Attachment} }, { Content => $Data{Content}, ContentType => $Data{ContentType}, Filename => $Data{Filename}, @@ -289,8 +290,8 @@ my $ArticleBackendObject = $ArticleObject->BackendForChannel( ChannelName => 'Email' ); $ArticleBackendObject->ArticleSend( - TicketID => $Param{Ticket}->{TicketID}, - UserID => $Param{UserID}, + TicketID => $Param{Ticket}->{TicketID}, + UserID => $Param{UserID}, %{ $Param{Config} || {} }, ); diff -Nru otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldIncrement.pm otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldIncrement.pm --- otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldIncrement.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldIncrement.pm 2021-12-14 15:52:34.000000000 +0000 @@ -111,6 +111,7 @@ # use ticket attributes if needed $Self->_ReplaceTicketAttributes(%Param); + $Self->_ReplaceAdditionalAttributes(%Param); my $Value = $Param{Config}->{Value} || 1; delete $Param{Config}->{Value}; diff -Nru otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldPendingTimeSet.pm otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldPendingTimeSet.pm --- otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldPendingTimeSet.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldPendingTimeSet.pm 2021-12-14 15:52:34.000000000 +0000 @@ -97,6 +97,7 @@ # use ticket attributes if needed $Self->_ReplaceTicketAttributes(%Param); + $Self->_ReplaceAdditionalAttributes(%Param); my %Ticket = %{ $Param{Ticket} || {} }; my $TicketID = $Param{Ticket}->{TicketID}; diff -Nru otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldRemove.pm otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldRemove.pm --- otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldRemove.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/DynamicFieldRemove.pm 2021-12-14 15:52:34.000000000 +0000 @@ -65,8 +65,10 @@ # Config is the hash stored in a Process::TransitionAction's config key Config => { - MasterSlave => 'Master', - UserID => 123, # optional, to override the UserID from the logged user + FieldName => 1, # required, name of field to be deleted without + # DynamicField_ decorator. + UserID => 123, # optional, to override the logged in user. + # Fields with the name UserID cannot be deleted. } ); diff -Nru otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/ExecuteInvoker.pm otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/ExecuteInvoker.pm --- otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/ExecuteInvoker.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/ExecuteInvoker.pm 2021-12-14 15:52:34.000000000 +0000 @@ -104,6 +104,7 @@ # use ticket attributes if needed $Self->_ReplaceTicketAttributes(%Param); + $Self->_ReplaceAdditionalAttributes(%Param); my $Webservice = $WebserviceObject->WebserviceGet( 'Name' => $Param{Config}->{Webservice} ); if ( !IsHashRefWithData($Webservice) ) { diff -Nru otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/LinkAdd.pm otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/LinkAdd.pm --- otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/LinkAdd.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/LinkAdd.pm 2021-12-14 15:52:34.000000000 +0000 @@ -103,6 +103,7 @@ # use ticket attributes if needed $Self->_ReplaceTicketAttributes(%Param); + $Self->_ReplaceAdditionalAttributes(%Param); $LinkObject->LinkAdd( UserID => $Param{UserID}, diff -Nru otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/TicketWatchSet.pm otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/TicketWatchSet.pm --- otrs2-6.2.1/Kernel/System/ProcessManagement/TransitionAction/TicketWatchSet.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/ProcessManagement/TransitionAction/TicketWatchSet.pm 2021-12-14 15:52:34.000000000 +0000 @@ -121,6 +121,7 @@ # use ticket attributes if needed $Self->_ReplaceTicketAttributes(%Param); + $Self->_ReplaceAdditionalAttributes(%Param); my $Action = $Param{Config}->{Action} || 'Subscribe'; diff -Nru otrs2-6.2.1/Kernel/System/Ticket/Event/NotificationEvent.pm otrs2-6.2.2/Kernel/System/Ticket/Event/NotificationEvent.pm --- otrs2-6.2.1/Kernel/System/Ticket/Event/NotificationEvent.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/Kernel/System/Ticket/Event/NotificationEvent.pm 2021-12-14 15:52:34.000000000 +0000 @@ -373,39 +373,22 @@ my $ArticleObject = $Kernel::OM->Get('Kernel::System::Ticket::Article'); + # get not ticket related attributes + my $IgnoredAttributes = $Kernel::OM->Get('Kernel::Config')->Get('Ticket::Event::NotificationEvent::IgnoredAttributes') || {}; + my %IgnoredAttributesHash; + for my $Key ( keys %{$IgnoredAttributes} ) { + if ( IsHashRefWithData( $IgnoredAttributes->{$Key} ) ) { + %IgnoredAttributesHash = ( %IgnoredAttributesHash, %{ $IgnoredAttributes->{$Key} } ); + } + } # get the search article fields to retrieve values for my %ArticleSearchableFields = $ArticleObject->ArticleSearchableFieldsList(); KEY: for my $Key ( sort keys %{ $Notification{Data} } ) { - # TODO: This function here should be fixed to not use hardcoded attribute values! # ignore not ticket related attributes - next KEY if $Key eq 'Recipients'; - next KEY if $Key eq 'SkipRecipients'; - next KEY if $Key eq 'RecipientAgents'; - next KEY if $Key eq 'RecipientGroups'; - next KEY if $Key eq 'RecipientRoles'; - next KEY if $Key eq 'TransportEmailTemplate'; - next KEY if $Key eq 'Events'; - next KEY if $Key eq 'ArticleSenderTypeID'; - next KEY if $Key eq 'ArticleIsVisibleForCustomer'; - next KEY if $Key eq 'ArticleCommunicationChannelID'; - next KEY if $Key eq 'ArticleAttachmentInclude'; - next KEY if $Key eq 'IsVisibleForCustomer'; - next KEY if $Key eq 'Transports'; - next KEY if $Key eq 'OncePerDay'; - next KEY if $Key eq 'VisibleForAgent'; - next KEY if $Key eq 'VisibleForAgentTooltip'; - next KEY if $Key eq 'LanguageID'; - next KEY if $Key eq 'SendOnOutOfOffice'; - next KEY if $Key eq 'AgentEnabledByDefault'; - next KEY if $Key eq 'EmailSecuritySettings'; - next KEY if $Key eq 'EmailSigningCrypting'; - next KEY if $Key eq 'EmailMissingCryptingKeys'; - next KEY if $Key eq 'EmailMissingSigningKeys'; - next KEY if $Key eq 'EmailDefaultSigningKeys'; - next KEY if $Key eq 'NotificationType'; + next KEY if %IgnoredAttributesHash && $IgnoredAttributesHash{$Key}; # ignore article searchable fields next KEY if $ArticleSearchableFields{$Key}; @@ -1255,4 +1238,4 @@ return 1; } -1; +1; \ No newline at end of file diff -Nru otrs2-6.2.1/scripts/backup.pl otrs2-6.2.2/scripts/backup.pl --- otrs2-6.2.1/scripts/backup.pl 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/scripts/backup.pl 2021-12-14 15:52:34.000000000 +0000 @@ -244,7 +244,7 @@ } if ( !system( - "( $DBDump -u $DatabaseUser $DatabasePw -h $DatabaseHost $Database || touch $ErrorIndicationFileName ) | $CompressCMD > $Directory/DatabaseBackup.sql.$CompressEXT" + "( $DBDump -u $DatabaseUser $DatabasePw -h $DatabaseHost $Database --no-tablespaces || touch $ErrorIndicationFileName ) | $CompressCMD > $Directory/DatabaseBackup.sql.$CompressEXT" ) && !-f $ErrorIndicationFileName ) diff -Nru otrs2-6.2.1/scripts/test/Console/Command/Maint/OTRSBusiness/AvailabilityCheck.t otrs2-6.2.2/scripts/test/Console/Command/Maint/OTRSBusiness/AvailabilityCheck.t --- otrs2-6.2.1/scripts/test/Console/Command/Maint/OTRSBusiness/AvailabilityCheck.t 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/scripts/test/Console/Command/Maint/OTRSBusiness/AvailabilityCheck.t 1970-01-01 00:00:00.000000000 +0000 @@ -1,160 +0,0 @@ -# -- -# Copyright (C) 2001-2021 OTRS AG, https://otrs.com/ -# Copyright (C) 2021 Znuny GmbH, https://znuny.org/ -# -- -# This software comes with ABSOLUTELY NO WARRANTY. For details, see -# the enclosed file COPYING for license information (GPL). If you -# did not receive this file, see https://www.gnu.org/licenses/gpl-3.0.txt. -# -- - -## no critic (Modules::RequireExplicitPackage) -use strict; -use warnings; -use utf8; - -use vars (qw($Self)); - -use Kernel::System::OTRSBusiness; - -# override some OTRSBusiness functions, to prevent a real cloud service call -local *Kernel::System::OTRSBusiness::OTRSBusinessIsInstalled = sub { - my ( $Self, %Param ) = @_; - - return 1; -}; - -# to check, if the cloud service function was called (the value will be set in the overwritten local function) -my $TestCloudServiceCall = 0; - -local *Kernel::System::OTRSBusiness::OTRSBusinessIsAvailable = sub { - my ( $Self, %Param ) = @_; - - $TestCloudServiceCall = 1; - - return 1; -}; - -# get needed objects -my $CommandObject = $Kernel::OM->Get('Kernel::System::Console::Command::Maint::OTRSBusiness::AvailabilityCheck'); -my $SystemDataObject = $Kernel::OM->Get('Kernel::System::SystemData'); - -# get helper object -$Kernel::OM->ObjectParamAdd( - 'Kernel::System::UnitTest::Helper' => { - RestoreDatabase => 1, - }, -); -my $Helper = $Kernel::OM->Get('Kernel::System::UnitTest::Helper'); - -my $NextUpdateTimeKey = 'OTRSBusiness::AvailabilityCheck::NextUpdateTime'; - -# delete the 'OTRSBusiness::AvailabilityCheck::NextUpdateTime' from the system data, if it already exists in the system -if ( defined $SystemDataObject->SystemDataGet( Key => $NextUpdateTimeKey ) ) { - $SystemDataObject->SystemDataDelete( - Key => $NextUpdateTimeKey, - UserID => 1, - ); -} - -$Helper->FixedTimeSet(); - -my $ExitCode = $CommandObject->Execute(); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::AvailabilityCheck exit code", -); - -$Self->True( - $TestCloudServiceCall, - "The function 'OTRSBusinessIsAvailable' was called from the console command.", -); - -# reset the test value -$TestCloudServiceCall = 0; - -# add two hours in seconds to the fixed time -my $FixedTimeAddSeconds = 60 * 60 * 2; - -# set the fixed time -$Helper->FixedTimeAddSeconds($FixedTimeAddSeconds); - -$ExitCode = $CommandObject->Execute(); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::AvailabilityCheck exit code", -); - -$Self->False( - $TestCloudServiceCall, - "The function 'OTRSBusinessIsAvailable' was not called from the console command.", -); - -# reset the test value -$TestCloudServiceCall = 0; - -$ExitCode = $CommandObject->Execute('--force'); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::AvailabilityCheck exit code", -); - -$Self->True( - $TestCloudServiceCall, - "The function 'OTRSBusinessIsAvailable' was called from the console command (with --force).", -); - -# reset the test value -$TestCloudServiceCall = 0; - -# add 28 hours in seconds to the fixed time -$FixedTimeAddSeconds = 60 * 60 * 28; - -# set the fixed time -$Helper->FixedTimeAddSeconds($FixedTimeAddSeconds); - -$ExitCode = $CommandObject->Execute(); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::AvailabilityCheck exit code", -); - -$Self->True( - $TestCloudServiceCall, - "The function 'OTRSBusinessIsAvailable' was called from the console command (because next update time reached).", -); - -# reset the test value -$TestCloudServiceCall = 0; - -# add one hours in seconds to the fixed time -$FixedTimeAddSeconds = 60 * 60 * 1; - -# set the fixed time -$Helper->FixedTimeAddSeconds($FixedTimeAddSeconds); - -$ExitCode = $CommandObject->Execute(); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::AvailabilityCheck exit code", -); - -$Self->False( - $TestCloudServiceCall, - "The function 'OTRSBusinessIsAvailable' was not called from the console command.", -); - -$Helper->FixedTimeUnset(); - -# cleanup cache is done by RestoreDatabase - -1; diff -Nru otrs2-6.2.1/scripts/test/Console/Command/Maint/OTRSBusiness/EntitlementCheck.t otrs2-6.2.2/scripts/test/Console/Command/Maint/OTRSBusiness/EntitlementCheck.t --- otrs2-6.2.1/scripts/test/Console/Command/Maint/OTRSBusiness/EntitlementCheck.t 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/scripts/test/Console/Command/Maint/OTRSBusiness/EntitlementCheck.t 1970-01-01 00:00:00.000000000 +0000 @@ -1,160 +0,0 @@ -# -- -# Copyright (C) 2001-2021 OTRS AG, https://otrs.com/ -# Copyright (C) 2021 Znuny GmbH, https://znuny.org/ -# -- -# This software comes with ABSOLUTELY NO WARRANTY. For details, see -# the enclosed file COPYING for license information (GPL). If you -# did not receive this file, see https://www.gnu.org/licenses/gpl-3.0.txt. -# -- - -## no critic (Modules::RequireExplicitPackage) -use strict; -use warnings; -use utf8; - -use vars (qw($Self)); - -use Kernel::System::OTRSBusiness; - -# override some OTRSBusiness functions, to prevent a real cloud service call -local *Kernel::System::OTRSBusiness::OTRSBusinessIsInstalled = sub { - my ( $Self, %Param ) = @_; - - return 1; -}; - -# to check, if the cloud service function was called (the value will be set in the overwritten local function) -my $TestCloudServiceCall = 0; - -local *Kernel::System::OTRSBusiness::OTRSBusinessEntitlementStatus = sub { - my ( $Self, %Param ) = @_; - - $TestCloudServiceCall = 1; - - return 1; -}; - -# get needed objects -my $CommandObject = $Kernel::OM->Get('Kernel::System::Console::Command::Maint::OTRSBusiness::EntitlementCheck'); -my $SystemDataObject = $Kernel::OM->Get('Kernel::System::SystemData'); - -# get helper object -$Kernel::OM->ObjectParamAdd( - 'Kernel::System::UnitTest::Helper' => { - RestoreDatabase => 1, - }, -); -my $Helper = $Kernel::OM->Get('Kernel::System::UnitTest::Helper'); - -my $NextUpdateTimeKey = 'OTRSBusiness::EntitlementCheck::NextUpdateTime'; - -# delete the 'OTRSBusiness::EntitlementCheck::NextUpdateTime' from the system data, if it already exists in the system -if ( defined $SystemDataObject->SystemDataGet( Key => $NextUpdateTimeKey ) ) { - $SystemDataObject->SystemDataDelete( - Key => $NextUpdateTimeKey, - UserID => 1, - ); -} - -$Helper->FixedTimeSet(); - -my $ExitCode = $CommandObject->Execute(); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::EntitlementCheck exit code", -); - -$Self->True( - $TestCloudServiceCall, - "The function 'OTRSBusinessEntitlementStatus' was called from the console command.", -); - -# reset the test value -$TestCloudServiceCall = 0; - -# add two hours in seconds to the fixed time -my $FixedTimeAddSeconds = 60 * 60 * 2; - -# set the fixed time -$Helper->FixedTimeAddSeconds($FixedTimeAddSeconds); - -$ExitCode = $CommandObject->Execute(); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::EntitlementCheck exit code", -); - -$Self->False( - $TestCloudServiceCall, - "The function 'OTRSBusinessEntitlementStatus' was not called from the console command.", -); - -# reset the test value -$TestCloudServiceCall = 0; - -$ExitCode = $CommandObject->Execute('--force'); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::EntitlementCheck exit code", -); - -$Self->True( - $TestCloudServiceCall, - "The function 'OTRSBusinessEntitlementStatus' was called from the console command (with --force).", -); - -# reset the test value -$TestCloudServiceCall = 0; - -# add 28 hours in seconds to the fixed time -$FixedTimeAddSeconds = 60 * 60 * 28; - -# set the fixed time -$Helper->FixedTimeAddSeconds($FixedTimeAddSeconds); - -$ExitCode = $CommandObject->Execute(); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::EntitlementCheck exit code", -); - -$Self->True( - $TestCloudServiceCall, - "The function 'OTRSBusinessEntitlementStatus' was called from the console command (because next update time reached).", -); - -# reset the test value -$TestCloudServiceCall = 0; - -# add one hours in seconds to the fixed time -$FixedTimeAddSeconds = 60 * 60 * 1; - -# set the fixed time -$Helper->FixedTimeAddSeconds($FixedTimeAddSeconds); - -$ExitCode = $CommandObject->Execute(); - -$Self->Is( - $ExitCode, - 0, - "Maint::OTRSBusiness::EntitlementCheck exit code", -); - -$Self->False( - $TestCloudServiceCall, - "The function 'OTRSBusinessEntitlementStatus' was not called from the console command.", -); - -$Helper->FixedTimeUnset(); - -# cleanup cache is done by RestoreDatabase - -1; diff -Nru otrs2-6.2.1/scripts/test/sample/EmailParser/PostMaster-Test10.box otrs2-6.2.2/scripts/test/sample/EmailParser/PostMaster-Test10.box --- otrs2-6.2.1/scripts/test/sample/EmailParser/PostMaster-Test10.box 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/scripts/test/sample/EmailParser/PostMaster-Test10.box 2021-12-14 15:52:34.000000000 +0000 @@ -4,7 +4,7 @@ Received: by mail.otrs.org (Postfix) id DD8A632C83C; Fri, 6 Jul 2007 12:17:38 +0200 (CEST) Date: Fri, 6 Jul 2007 12:17:38 +0200 (CEST) From: MAILER-DAEMON@mail.otrs.org (Mail Delivery System) -Subject: Undelivered Mail Returned to Sender +Subject: To: skywalker@otrs.org MIME-Version: 1.0 Content-Type: multipart/report; report-type=delivery-status; boundary="AB35D32CDC7.1183717058/mail.otrs.org" @@ -67,7 +67,7 @@ Content-Disposition: inline Content-Transfer-Encoding: base64 MIME-Version: 1.0 -Subject: [Ticket#2007070610001801] test mail +Subject: X-Powered-BY: OTRS - Open Ticket Request System (http://otrs.org/) X-Mailer: OTRS Mail Service (2.1.7) Date: Fri, 6 Jul 2007 12:17:31 +0200 diff -Nru otrs2-6.2.1/var/httpd/htdocs/js/Core.Agent.TicketCompose.js otrs2-6.2.2/var/httpd/htdocs/js/Core.Agent.TicketCompose.js --- otrs2-6.2.1/var/httpd/htdocs/js/Core.Agent.TicketCompose.js 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/var/httpd/htdocs/js/Core.Agent.TicketCompose.js 2021-12-14 15:52:34.000000000 +0000 @@ -75,8 +75,14 @@ function CheckSubject () { var CurrentSubject = $('#Subject').val(); + var TicketID = $('input[name=TicketID]').val(); + $('#SubjectWarning').remove(); + if ( !TicketID ) { + return; + } + $.ajax({ url: Core.Config.Get('Baselink'), type: 'POST', @@ -84,7 +90,7 @@ Action: Core.Config.Get('Action'), Subaction: 'CheckSubject', Subject: CurrentSubject, - TicketID: $('input[name=TicketID]').val(), + TicketID: TicketID, }, success : function(Response) { if (Response.Empty) { diff -Nru otrs2-6.2.1/var/processes/examples/Application_for_leave_pre.pm otrs2-6.2.2/var/processes/examples/Application_for_leave_pre.pm --- otrs2-6.2.1/var/processes/examples/Application_for_leave_pre.pm 2021-10-28 09:22:33.000000000 +0000 +++ otrs2-6.2.2/var/processes/examples/Application_for_leave_pre.pm 2021-12-14 15:52:34.000000000 +0000 @@ -59,6 +59,7 @@ ObjectType => 'Ticket', FieldOrder => 10001, Config => { + DefaultValue => '', }, }, { @@ -88,6 +89,7 @@ ObjectType => 'Ticket', FieldOrder => 10004, Config => { + DefaultValue => '', }, }, { @@ -97,6 +99,7 @@ ObjectType => 'Ticket', FieldOrder => 10005, Config => { + DefaultValue => '', }, }, { @@ -117,6 +120,7 @@ ObjectType => 'Ticket', FieldOrder => 10007, Config => { + DefaultValue => '', }, }, {