public AdminProductViewModel() { if (!System.ComponentModel.DesignerProperties.GetIsInDesignMode(new DependencyObject())) { ProductList = new ObservableCollection <ProductData>(ProductsClient.GetProductList()); CategoryList = new ObservableCollection <CategoryData>(CategoriesClient.GetCategoryList()); } }
public void RefreshProducts(object item) { productList = ProductsClient.GetProductList().Where(p => p.IsActive == true && p.IsCategoryActive == true).ToList(); SearchProducts(null); }