public UserModify(GoodsListViewModel goodsListView, GoodsModifyViewModel goodsModifyView, Goods goods)
 {
     InitializeComponent();
     this.goodsListView   = goodsListView;
     this.goodsModifyView = goodsModifyView;
     this.goods           = goods;
     FillData();
 }
 public UserModify(GoodsListViewModel goodsListView, GoodsModifyViewModel goodsModifyView)
 {
     this.goodsModifyView = goodsModifyView;
     this.goodsListView   = goodsListView;
     DataContext          = goodsListView;
     InitializeComponent();
     goodsCollection = (CollectionViewSource)(Resources["GoodsCollection"]);
 }
Пример #3
0
        protected override void OnStartup(StartupEventArgs e)
        {
            var container = Boostraper.Init();

            GoodsListViewModel   goodsListViewModel   = container.Resolve <GoodsListViewModel>();
            GoodsModifyViewModel goodsModifyViewModel = container.Resolve <GoodsModifyViewModel>();
            MainWindow           window = new MainWindow(goodsListViewModel, goodsModifyViewModel);

            window.Show();
        }
Пример #4
0
        public MainWindow(GoodsListViewModel goodsListView, GoodsModifyViewModel goodsModifyViewModel)
        {
            _goodsListView            = goodsListView;
            this.goodsModifyViewModel = goodsModifyViewModel;
            DataContext = _goodsListView;
            InitializeComponent();

            goodsCollection         = (CollectionViewSource)(Resources["GoodsCollection"]);
            goodsCollection.Filter += GoodsCollection_Filter;
        }