We had the same issue, luckily it isn't too hard to re-implement. I believe this should work exactly like before, but we might have skipped something we didn't need so just be aware of that.
AddDynamicFields.cs
using System.Collections.Generic;
using System.Linq;
using Sitecore;
using Sitecore.Abstractions;
using Sitecore.Buckets.Pipelines.UI.FillItem;
using Sitecore.ContentSearch;
using Sitecore.ContentSearch.SearchTypes;
using Sitecore.Data.Items;
using Sitecore.Globalization;
using YourSolution.DynamicFields
namespace YourSolution
{
public class AddDynamicFields : FillItemProcessor
{
public override void Process(FillItemArgs args)
{
foreach (var searchResultItem in args.ResultItems.OfType<SitecoreUISearchResultItem>())
{
Language itemLanguage;
Language.TryParse(searchResultItem.Language, out itemLanguage);
var version = Sitecore.Data.Version.Parse(searchResultItem.Version);
var item =
Context.ContentDatabase.GetItem(searchResultItem.ItemId, itemLanguage, version) ??
Context.Database.GetItem(searchResultItem.ItemId, itemLanguage, version);
if (item == null)
return;
LoadDynamicFields(item, searchResultItem);
}
}
private static void LoadDynamicFields(Item innerItem, SitecoreUISearchResultItem sitecoreItem)
{
if (sitecoreItem.DynamicFields == null)
sitecoreItem.DynamicFields = new List<KeyValuePair<string, string>>();
var dynamicFieldsArgs = new DynamicFieldsArgs { InnerItem = innerItem};
var corePipelineManager = ContentSearchManager.Locator.GetInstance<BaseCorePipelineManager>();
corePipelineManager.Run("buckets.dynamicFields", dynamicFieldsArgs);
sitecoreItem.DynamicFields = dynamicFieldsArgs.DynamicFields.ToList();
}
}
}
DynamicFieldsArgs.cs
using System.Collections.Generic;
using Sitecore.Buckets.Pipelines;
using Sitecore.Data.Items;
namespace YourSolution.DynamicFields
{
public class DynamicFieldsArgs : BucketsPipelineArgs
{
public Item InnerItem { get; set; }
public IDictionary<string, string> DynamicFields { get; set; } = new Dictionary<string, string>();
}
}
DynamicFieldsProcessor.cs
using Sitecore.Buckets.Pipelines;
namespace YourSolution.DynamicFields
{
public abstract class DynamicFieldsProcessor : BucketsPipelineProcessor<DynamicFieldsArgs>
{
}
}
Config patch
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/" xmlns:set="http://www.sitecore.net/xmlconfig/set/">
<sitecore>
<pipelines>
<buckets.fillItem>
<processor type="YourSolution.AddDynamicFields, YourSolution" />
</buckets.fillItem>
</pipelines>
</sitecore>
</configuration>