public List <ProductBase> GetAllProducts(int connectorID, List <string> includes, int?skipCount = -1, int?takeCount = -1, DateTime?lastModified = null) { var productHelper = new Helpers.ProductHelper(); var result = productHelper.GetAllProducts(connectorID, includes, skipCount, takeCount, lastModified); return(result); }
internal List <SimpleProduct> GetChildProducts(int connectorID, int productID, ProductHelper productHelper) { lock (_childProducts) { if (_childProducts.Count == 0) { LoadChildProducts(); } } List <ChildProductData> filteredItems; if (_childProducts.ContainsKey(productID)) { filteredItems = _childProducts[productID]; } else { return(null); } var result = new List <SimpleProduct>(); foreach (var product in filteredItems) { var p = new SimpleProduct(); productHelper.FillProductWithBaseAttributes(p, product, connectorID, true, true); result.Add(p); } return(result); }