After an update from 5.0.1 to 5.0.2, our customisations are sometimes rendered. We add a badge-pill to the status to make it standout more and since the update, testing has shown that sometimes the Once file is used and sometimes it isnt.
It appears as if there is some sort of race condition/event happening where Once is sometimes processed and sometimes it is not.
local/html/Callbacks/OurApp/Elements/RT__Ticket/ColumnMap/Once:
<%INIT>
sub StatusInColour {
my $Ticket = shift;
my $status = $Ticket->Status;
my $badge = undef;
$badge = "badge-light";
if (not defined($status)) {
$status = "Not Set";
$badge = "dark-light";
}
if ($status eq 'new') {
$badge = "badge-info";
} elsif ($status eq 'open') {
$badge = "badge-warning";
} elsif ($status eq 'resolved') {
$badge = "badge-success";
} elsif ($status eq 'rejected') {
$badge = "badge-dark";
} elsif ($status eq 'stalled') {
$badge = "badge-secondary";
}
if ($badge) {
$status = "<span class=\"badge badge-pill $badge\" style=\"font-size: calc(100% + 1px);\">$status</span>";
}
return \"<b>$status</b>";
}
$COLUMN_MAP->{Status}->{value} = \&StatusInColour;
</%INIT>
<%ARGS>
$COLUMN_MAP => undef
</%ARGS>
Has anyone else experienced this?