Пример #1
0
        public CustomerProfile(int customerId)
        {
            this.context             = new BankAppDataContext();
            this.customer_queries    = new CustomerQueriesHandler(context);
            this.disposition_queries = new DispositionQueriesHandler(context);

            Customer = customer_queries.GetCustomer(customerId);
            this.ConnectedDispositions = disposition_queries.GetConnectedDispositions(Customer.CustomerId);
        }
Пример #2
0
        public EditCustomerViewModel(int id)
        {
            this.context = new BankAppDataContext();
            this.customerCommandHandler = new CustomerCommandHandler(context);
            this.customerQueriesHandler = new CustomerQueriesHandler(context);

            Customer = customerQueriesHandler.GetCustomer(id);
            Birthday = (DateTime)Customer.Birthday;
        }
Пример #3
0
        public AccountViewModel(int accountId, int customerId)
        {
            this.context          = new BankAppDataContext();
            this.customer_queries = new CustomerQueriesHandler(context);
            this.account_queries  = new AccountQueriesHandler(context);

            Account  = account_queries.GetAccountWithTransactions(accountId);
            Customer = customer_queries.GetCustomer(customerId);
        }