BankTerminationView.xaml.cs 786 B

12345678910111213141516171819202122232425262728
  1. using Muchinfo.MTPClient.Bank.ViewModels;
  2. using System;
  3. using System.Windows;
  4. namespace Muchinfo.MTPClient.Bank.Views
  5. {
  6. /// <summary>
  7. /// BankTerminationView.xaml 的交互逻辑
  8. /// </summary>
  9. public partial class BankTerminationView : Window
  10. {
  11. public BankTerminationView()
  12. {
  13. InitializeComponent();
  14. this.DataContext = new Muchinfo.MTPClient.Bank.ViewModels.BankTerminationViewModel(this);
  15. this.Closed += AmountManagerView_Closed;
  16. }
  17. void AmountManagerView_Closed(object sender, EventArgs e)
  18. {
  19. var viewmodel = this.DataContext as BankTerminationViewModel;
  20. if (viewmodel != null)
  21. {
  22. viewmodel.Cleanup();
  23. }
  24. }
  25. }
  26. }