using AsbWitsInfo; using System.Collections.Generic; namespace AsbCloudInfrastructure.Services; public class WitsInfoService { private readonly InfoService witsInfoService; public WitsInfoService(IEnumerable? customItems = null, IEnumerable? customRecords = null) { witsInfoService = new InfoService(customItems, customRecords); } public object GetItems(int idRecord = -1) { object items; if (idRecord > 0) items = witsInfoService.ItemInfoStore.Where(i => i.RecordId == idRecord); else items = witsInfoService.ItemInfoStore.Where(i => true); return items; } public object GetRecords(int idRecord = -1) { object items; if (idRecord > 0) items = witsInfoService.RecordInfoStore.Where(i => i.RecordId == idRecord); else items = witsInfoService.RecordInfoStore.Where(i => true); return items; } }