public async Task <IActionResult> GetProductTypesAsync() { var ret = new List <ProductTypeViewModel>(); var products = await _listManager.GetAllProductTypeAsync(); foreach (var product in products) { ret.Add(new ProductTypeViewModel(product)); } return(Ok(ret)); }