Beispiel #1
0
        ITicketDialogViewModel CreateViewModel(ITicketListItemViewModel parameter, ITicketDetailsView view)
        {
            var closeCommand = closeCommandFactory.Create(view);

            var ticket      = ticketRepository.GetAll().FirstOrDefault(p => p.Id == parameter.Id);
            var saveCommand = saveTicketCommandFactory.Create(ticket, view);
            var viewModel   = ticketDialogViewModelFactory.Create(ticket, closeCommand, saveCommand,
                                                                  Strings.TicketDetails.EditHeaderText);

            return(viewModel);
        }
Beispiel #2
0
 ICloseCommand CreateCloseCommand(ITicketDetailsView view)
 {
     return(closeCommandFactory.Create(view));
 }
Beispiel #3
0
 public LoginViewModel(ICloseCommandFactory closeCommandFactory, IClosable closable,
                       ICurrentUserViewModelFactory currentUserViewModelFactory, ILoginCommandFactory loginCommandFactory)
 {
     CloseCommand = closeCommandFactory.Create(closable);
     LoginCommand = loginCommandFactory.Create(this, closable);
 }