public BankListViewModel( IBankRepository bankRepository, IBankAgent bankAgent) { this.bankRepository = bankRepository; this.bankAgent = bankAgent; ReloadCommand = base.AddNewCommand(new ActionCommand(Reload)); AddCommand = base.AddNewCommand(new ActionCommand(Add)); EditCommand = base.AddNewCommand(new ActionCommand(Edit, CanEdit)); DeleteCommand = base.AddNewCommand(new ActionCommand(Delete, CanDelete)); }
public BankAccountEditorViewModel( IBankAccountRepository bankAccountRepository, IBankRepository bankRepository, IBankAgent bankAgent, BankAccount entity ) { this.bankRepository = bankRepository; this.bankAccountRepository = bankAccountRepository; this.bankAgent = bankAgent; this.entity = entity; NewBankCommand = base.AddNewCommand(new ActionCommand(this.NewBank)); }