예제 #1
0
        private void BtnAddSaleItem_Click(object sender, RoutedEventArgs e)
        {
            frmSaleItemDetails window = new frmSaleItemDetails(_saleItemManager, _inventoryManager);

            if (window.ShowDialog() == true)
            {
                populateSaleItemTypes();
                populateSaleItemList();
                lblStatusMessage.Content = "New Sale Item Saved!";
            }
        }
예제 #2
0
        private void showPopulatedSaleItemDetailWindow()
        {
            SaleItem item = (SaleItem)dgSaleItemList.SelectedItem;

            if (item != null)
            {
                frmSaleItemDetails window = new frmSaleItemDetails(
                    item, _user, _saleItemManager, _inventoryManager);
                if (window.ShowDialog() == true)
                {
                    populateSaleItemTypes();
                    populateSaleItemList();
                    lblStatusMessage.Content = "Changes to Sale Item: " + item.ItemSize + " " +
                                               item.Flavor + " " + item.ItemName + ", Saved!";
                }
            }
        }