diff options
author | sunnavy <sunnavy@bestpractical.com> | 2022-08-03 23:01:14 +0300 |
---|---|---|
committer | sunnavy <sunnavy@bestpractical.com> | 2022-08-03 23:21:32 +0300 |
commit | 81f85c43edf0153caa69b435f1a2561104b44428 (patch) | |
tree | ee6fcbf25b880723521d1b8471a64a498930b254 | |
parent | ce54ef6409ecc4e59cccfa97c99697d6fea35f8e (diff) |
Switch from CreatedBy to Creator in search formats5.0/search-format-creator
This is for consistency as "Creator" is also used in search criteria and
sorting. For existing searches with "CreatedBy" in format, it will
continue working.
-rw-r--r-- | share/html/Elements/ColumnMap | 5 | ||||
-rw-r--r-- | share/html/Search/Elements/BuildFormatString | 6 | ||||
-rw-r--r-- | t/web/query_builder.t | 2 |
3 files changed, 9 insertions, 4 deletions
diff --git a/share/html/Elements/ColumnMap b/share/html/Elements/ColumnMap index 8a5b89fcb1..a69e7800a5 100644 --- a/share/html/Elements/ColumnMap +++ b/share/html/Elements/ColumnMap @@ -176,6 +176,11 @@ $WCOLUMN_MAP = $COLUMN_MAP = { title => 'Created By', # loc value => sub { return $_[0]->CreatorObj->Name } }, + Creator => { + attribute => 'Creator', + title => 'Creator', # loc + value => sub { return $_[0]->CreatorObj->Name } + }, LastUpdated => { attribute => 'LastUpdated', title => 'Last Updated', # loc diff --git a/share/html/Search/Elements/BuildFormatString b/share/html/Search/Elements/BuildFormatString index 15f0351c18..31ea4c5430 100644 --- a/share/html/Search/Elements/BuildFormatString +++ b/share/html/Search/Elements/BuildFormatString @@ -79,7 +79,7 @@ if ( $Class eq 'RT::Transactions' ) { @fields = qw( id ObjectId ObjectType ObjectName Type Field TimeTaken OldValue NewValue ReferenceType OldReference NewReference - Created CreatedRelative CreatedBy Description Content PlainContent HTMLContent + Created CreatedRelative Creator Description Content PlainContent HTMLContent TicketId TicketSubject TicketQueue TicketStatus TicketOwner TicketCreator TicketLastUpdatedBy TicketCreated TicketStarted TicketResolved TicketTold TicketLastUpdated TicketDue @@ -113,7 +113,7 @@ elsif ( $Class eq 'RT::Assets' ) { $Format ||= RT->Config->Get('AssetDefaultSearchResultFormat'); @fields = qw( id Name Description Status - CreatedBy LastUpdatedBy + Creator LastUpdatedBy Created CreatedRelative LastUpdated LastUpdatedRelative @@ -153,7 +153,7 @@ else { Status ExtendedStatus UpdateStatus Type - OwnerName OwnerNameEdit Requestors Cc AdminCc CreatedBy LastUpdatedBy + OwnerName OwnerNameEdit Requestors Cc AdminCc Creator LastUpdatedBy Priority InitialPriority FinalPriority diff --git a/t/web/query_builder.t b/t/web/query_builder.t index da318d3946..0c628f28d5 100644 --- a/t/web/query_builder.t +++ b/t/web/query_builder.t @@ -430,7 +430,7 @@ diag "make sure the list of columns available in the 'Order by'/'Add Columns' dr Requestors Cc AdminCc - CreatedBy + Creator LastUpdatedBy Priority InitialPriority |