示例#1
0
        private void ExecuteAddCommand(object o)
        {
            var addController = new WindowAddController();
            var customer      = addController.AddCustomer();

            if (customer != null)
            {
                _customerRepository.Save(customer);
                _viewModel.Models.Add(customer);
            }
        }
示例#2
0
        public void ExecuteAddCommand(object obj)
        {
            WindowAddController winAddCtr = new WindowAddController();
            Customer            customer  = winAddCtr.AddCustomer();

            if (customer != null)
            {
                mViewModel.Models.Add(customer);
                mCustomerRepository.Save(customer);
            }
        }