Skip to content

Commit

Permalink
Issue #3811: Enabled correct rendering for lenses on set DFs in Agent…
Browse files Browse the repository at this point in the history
…TicketZoom TicketInformation widget.
  • Loading branch information
stefanhaerter committed Sep 25, 2024
1 parent ba04b77 commit 59151a6
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion Kernel/Output/HTML/TicketZoom/TicketInformation.pm
Original file line number Diff line number Diff line change
Expand Up @@ -465,6 +465,21 @@ sub Run {
FIELD:
for my $Field (@FieldsSidebar) {

# check if field is set field
my $IsSetField = $Field->{FieldType} eq 'Set' ? 1 : 0;

# check if field is a lens field and points to a set field
if ( $Field->{FieldType} eq 'Lens' ) {
my $DynamicFieldObject = $Kernel::OM->Get('Kernel::System::DynamicField');
my $LensDFConfig = $DynamicFieldObject->DynamicFieldGet(
Name => $Field->{Name},
);
my $AttributeDFConfig = $Kernel::OM->Get('Kernel::System::DynamicField')->DynamicFieldGet(
ID => $LensDFConfig->{Config}{AttributeDF},
);
$IsSetField = $AttributeDFConfig->{FieldType} eq 'Set' ? 1 : 0;
}

# handle titles separately
if ( $Field->{TitleFieldConfig} ) {
my $Style = "padding-left:4px;font-size:$Field->{TitleFieldConfig}{FontSize}px;color:$Field->{TitleFieldConfig}{FontColor};";
Expand All @@ -490,7 +505,7 @@ sub Run {

next FIELD;
}
elsif ( $Field->{FieldType} eq 'Set' ) {
elsif ($IsSetField) {

$LayoutObject->Block(
Name => 'TicketDynamicField',
Expand Down

0 comments on commit 59151a6

Please sign in to comment.