예제 #1
0
파일: Bank.xaml.cs 프로젝트: vazeele/MDM
        private void TbPage_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (!(e.Source is TabControl))
            {
                return;
            }

            if (tb_Bank.IsSelected)
            {
                if (bankmodel == null)
                {
                    bankmodel = new BankModel(this);
                }
            }
            else if (tb_BankBranch.IsSelected)
            {
                if (bankbranchmodel == null)
                {
                    bankbranchmodel = new BankBranchModel(this);
                }
            }
            else if (tb_BankAccount.IsSelected)
            {
                if (bankaccountmodel == null)
                {
                    bankaccountmodel = new BankAccountModel(this);
                }
            }
        }
예제 #2
0
파일: Bank.xaml.cs 프로젝트: vazeele/MDM
 private void BtRefresh_Click(object sender, RoutedEventArgs e)
 {
     if (tb_Bank.IsSelected)
     {
         BankSearchControl.ResetSearchControl();
         bankmodel = new BankModel(this);
     }
     else if (tb_BankBranch.IsSelected)
     {
         BankBranchSearchControl.ResetSearchControl();
         bankbranchmodel = new BankBranchModel(this);
     }
     else if (tb_BankAccount.IsSelected)
     {
         BankAccountSearchControl.ResetSearchControl();
         bankaccountmodel = new BankAccountModel(this);
     }
 }