private void Add() { SupplierPurchaseRequest.Raise(new SupplierPurchaseConfirmation(Supplier.ID), x => { if (x.Confirmed) { Items.Add(x.SupplierPurchase); SelectedItem = x.SupplierPurchase; FixData(); } }); }
private void Update() { SupplierPurchaseRequest.Raise(new SupplierPurchaseConfirmation(SelectedItem, _purchaseService.GetPurchaseDetails(SelectedItem.ID)), x => { if (!x.Confirmed) { DataUtils.Copy(SelectedItem, _purchaseService.FindPurchase(SelectedItem.ID)); } else { FixData(); } }); }