Esempio n. 1
0
        private void Replace(Call call)
        {
            var sampleItem = new SampleItem(_sampleItems.Count, "Item 0");

            RemoveItem(sampleItem.Name);             // Remove previous result so refocus works
            _dataRepoItems.Save(call, sampleItem.ToString(), sampleItem);
            _sampleItems.Add(sampleItem);
        }
Esempio n. 2
0
        public static ItemIdentifier ToItemIdentifier(this SampleItem sampleItem)
        {
            var item = new ItemIdentifier(
                itemKey: sampleItem.ItemKey,
                itemName: sampleItem.ToString(),
                bankKey: sampleItem.BankKey);

            return(item);
        }
Esempio n. 3
0
        /// <summary>
        /// Constructs an ItemViewerService URL for a single item
        /// </summary>
        private string GetItemViewerUrlSingleItem(SampleItem sampleItem)
        {
            if (sampleItem == null)
            {
                return(null);
            }

            string baseUrl = context.AppSettings.SettingsConfig.ItemViewerServiceURL;

            return($"{baseUrl}/items?ids={sampleItem.ToString()}");
        }
Esempio n. 4
0
        public string GetItemNames(SampleItem item)
        {
            if (item == null)
            {
                return(string.Empty);
            }

            var itemNames = item.ToString();

            if (item.IsPerformanceItem)
            {
                itemNames = string.Join(",", GetAssociatedPerformanceItems(item).Select(d => d.ToString()));
            }

            return(itemNames);
        }