public EditPatternViewModel(PatternRepository patternRepository,
                                    ThreadReferenceRepository threadReferenceRepository,
                                    ThreadRepository threadRepository,
                                    IDialogService dialogService)
            : base(threadReferenceRepository, threadRepository, dialogService)
        {
            _patternRepository = patternRepository;

            GenerateOrderCommand = new RelayCommand(OnGenerateOrder, CanGenerateOrder);
        }
예제 #2
0
        public EditEntityWithThreadsViewModel(ThreadReferenceRepository threadReferenceRepository, ThreadRepository threadRepository, IDialogService dialogService)
        {
            _initialIds        = new List <int>();
            _threadIdsToRemove = new List <int>();

            _threadReferenceRepository = threadReferenceRepository;
            _threadRepository          = threadRepository;
            _dialogService             = dialogService;
            AddThreadModel             = new AddThreadModel();

            AddThreadCommand    = new RelayCommand(OnAddThread, CanAddThread);
            DeleteThreadCommand = new RelayCommand <TThread>(OnDeleteThread, CanDeleteThread);
        }
        public ManageInventoryViewModel(
            INavigationService navigationService,
            IDialogService dialogService,
            ThreadReferenceRepository threadReferenceRepository)
        {
            _dialogService             = dialogService;
            _threadReferenceRepository = threadReferenceRepository;

            SaveCommand                  = new RelayCommand(OnSave, CanSave);
            SearchCommand                = new RelayCommand(OnSearch, CanSearch);
            NewThreadReferenceCommand    = new RelayCommand(OnNewThreadReference);
            EditThreadReferenceCommand   = new RelayCommand <ThreadReference>(OnEditThreadReference);
            DeleteThreadReferenceCommand = new RelayCommand <ThreadReference>(OnDeleteThreadReference);
        }
예제 #4
0
 public EditOrderViewModel(
     OrderRepository orderRepository,
     ThreadReferenceRepository threadReferenceRepository,
     ThreadRepository threadRepository,
     IDialogService dialogService,
     ICurrentDateService dateTimeProvider)
     : base(threadReferenceRepository, threadRepository, dialogService)
 {
     _orderRepository     = orderRepository;
     _dateTimeProvider    = dateTimeProvider;
     CompleteOrderCommand = new RelayCommand(OnCompleteOrder);
     CancelOrderCommand   = new RelayCommand(OnCancelOrder, CanCancel);
     MakeOrderCommand     = new RelayCommand(OnMakeOrder, CanMakeOrder);
 }
예제 #5
0
 public ManageInventoryViewModelTests()
 {
     _threadReferenceRepository = Instance <ThreadReferenceRepository>();
 }
예제 #6
0
 public EditThreadReferenceViewModel(ThreadReferenceRepository threadReferenceRepository)
 {
     _threadReferenceRepository = threadReferenceRepository;
     SaveCommand = new RelayCommand(OnSave, CanSave);
 }
 public EditThreadReferencesViewModelTests() : base(new ThreadReference())
 {
     _threadReferenceRepository = Instance <ThreadReferenceRepository>();
 }