void Execute_Update_Terminal(object para) { Views.vTerminalEntry TransactionEntryv = new Views.vTerminalEntry(); ViewModels.vmTerminalEntry TransactionEntryvm = new vmTerminalEntry(COMMON.SaveMode.Mode.Update, Selected_Terminal); TransactionEntryv.DataContext = TransactionEntryvm; TransactionEntryvm.CloseAction = new Action(() => { TransactionEntryv.Close(); Update_Terminal_Collections(); }); TransactionEntryv.ShowDialog(); }
void Execute_AddNew_Terminal(object para) { Views.vTerminalEntry TermEntryv = new Views.vTerminalEntry(); ViewModels.vmTerminalEntry TermEntryvm = new vmTerminalEntry(COMMON.SaveMode.Mode.AddNew, new BOL.Terminal.objTerminal()); TermEntryv.DataContext = TermEntryvm; if (TermEntryvm.CloseAction == null) { TermEntryvm.CloseAction = new Action(() => { TermEntryv.Close(); Update_Terminal_Collections(); }); } TermEntryv.ShowDialog(); }