Skip to content

Commit

Permalink
Add callback to EditCustomFieldSelect before rendering values
Browse files Browse the repository at this point in the history
In some cases, we might want to modify or restrict the values that are
displayed in the custom field select box. This callback allows us to do
that.
  • Loading branch information
richieri-bps committed Apr 8, 2024
1 parent cf34cad commit 506bd66
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions share/html/Elements/EditCustomFieldSelect
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,8 @@ $MaxValues => 1
% $_ = lc $_ foreach @Default;
% my $selected;
% my $CFVs = CachedCustomFieldValues($CustomField);
% $m->callback( CallbackPage => '/Elements/EditCustomFieldSelect', CallbackName => 'MassageCustomFieldValues',
% CustomField => $CustomField, CustomFieldValues => $CFVs, ARGSRef => \%ARGS );
% my @levels;
% while ( my $value = $CFVs->Next ) {
% my $name = $value->Name;
Expand Down

0 comments on commit 506bd66

Please sign in to comment.