Example #1
0
        public virtual void Process(GetLookupSourceItemsArgs args)
        {
            var replaceTokensArgs = new ReplaceLookupSourceQueryTokensArgs(args.Item, args.Source);

            CorePipeline.Run("elision.replaceLookupSourceQueryTokens", replaceTokensArgs);
            args.Source = replaceTokensArgs.Query;
        }
Example #2
0
        public string ReplacesStringFieldValue(string query)
        {
            using (var db = GetFakeDb())
            {
                var item = db.GetItem("/sitecore/content/page");

                var processor = new ReplaceItemFieldValueTokens();
                var args      = new ReplaceLookupSourceQueryTokensArgs(item, query);
                processor.Process(args);

                return(args.Query);
            }
        }