示例#1
0
        private async void AddPurchaseOil_Click(object sender, RoutedEventArgs e)
        {
            if (_companiesGuids.Count == 0)
            {
                return;
            }

            Guid theCompany;

            if (_PURCHASES.SelectedValue != null)
            {
                theCompany = (Guid)_PURCHASES.SelectedValue;
            }
            else
            {
                theCompany = (_companiesGuids).First();
            }

            var wind = new AddPurchase(theCompany, false)
            {
                Owner = Window.GetWindow(this)
            };

            wind.ShowDialog();
            await Refresh(_companiesGuids, _fromDate, _toDate);
        }
示例#2
0
        private async void AddPurchaseOil_Click(object sender, RoutedEventArgs e)
        {
            if (_companiesGuids.Count == 0) return;

            Guid theCompany;

            if (_PURCHASES.SelectedValue != null)
                theCompany = (Guid)_PURCHASES.SelectedValue;
            else
                theCompany = (_companiesGuids).First();

            var wind = new AddPurchase(theCompany, false) { Owner = Window.GetWindow(this) };
            wind.ShowDialog();
            await Refresh(_companiesGuids, _fromDate, _toDate);
        }