コード例 #1
0
        public AdminWindow()
        {
            InitializeComponent();
            Container container = Container.Instance;

            this.productManager = container.Get <Managers.Product>("manager.product");
            this.orderManager   = container.Get <Managers.Order>("manager.order");


            productsDataGrid.ItemsSource = productManager.getAll();
            orderDataGrid.ItemsSource    = orderManager.getAll();
        }
コード例 #2
0
 private void RemoveProduct(object sender, RoutedEventArgs e)
 {
     Models.Product model = (sender as Button).DataContext as Models.Product;
     this.productManager.remove(model);
     productsDataGrid.ItemsSource = productManager.getAll();
 }