Ejemplo n.º 1
0
        public AddItemWindow(ItemListViewModel viewModel, ItemService itemService, CategoryService categoryService)
        {
            _viewModel = viewModel;

            _itemService  = itemService;
            _categService = categoryService;
            DataContext   = _viewModel;

            InitializeComponent();
        }
Ejemplo n.º 2
0
        public ItemsMenu(ItemListViewModel viewModel, ItemService itemService)
        {
            _viewModel   = viewModel;
            _itemService = itemService;
            DataContext  = _viewModel;

            InitializeComponent();
            CollectionView view = (CollectionView)CollectionViewSource.GetDefaultView(ItemsDataGrid.ItemsSource);

            view.Filter = ItemsFilter;
        }