Пример #1
0
        private void addNewExpensesButton_Click(object sender, RoutedEventArgs e)
        {
            var SaveUpdateNewExpensesWindowScreen = new SaveUpdateNewExpensesWindow(0, null);

            if (SaveUpdateNewExpensesWindowScreen.ShowDialog() == true)
            {
                goodsListView4.ItemsSource = busExpenses.GetAllExpenses();

                return;
            }
            else
            {
                return;
            }
        }
Пример #2
0
        private void editMenuItem_Click(object sender, RoutedEventArgs e)
        {
            var deletedGoodsIndex = goodsListView4.SelectedIndex;

            if (deletedGoodsIndex == -1)
            {
                return;
            }

            var SaveUpdateNewExpensesWindowScreen = new SaveUpdateNewExpensesWindow(1, (Expens)goodsListView4.SelectedItem);

            if (SaveUpdateNewExpensesWindowScreen.ShowDialog() == true)
            {
                goodsListView4.ItemsSource = busExpenses.GetAllExpenses();

                return;
            }
            else
            {
                return;
            }
        }