示例#1
0
        public UnlockEventsViewModel()
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            UnlockEventCommand = new RelayCommand<Event>(UnlockEventCommandExecuted);
        }
 public EnquiryCorrespondenceViewModel()
 {
     SendEmailCommand = new RelayCommand(SendEmailCommandExecuted);
     SendLetterCommand = new RelayCommand(SendLetterCommandExecuted, () => false);
     AttachEmailCommand = new RelayCommand(AttachEmailCommandExecuted, () => false);
     ShowCorrespondenceCommand = new RelayCommand<CorrespondenceModel>(ShowCorrespondenceCommandExecuted);
 }
示例#3
0
        public SnoozeViewModel(EventReminderModel eventReminderModel)
        {
            EventReminder = eventReminderModel;

            OKCommand = new RelayCommand(OKCommandExecute, OKCommandCanExecute);
            CancelCommand = new RelayCommand(CancelCommandExecute);
        }
示例#4
0
        public SnoozeViewModel(FollowUpModel followUpModel)
        {
            FollowUp = followUpModel;

            OKCommand = new RelayCommand(OKCommandExecute, OKCommandCanExecute);
            CancelCommand = new RelayCommand(CancelCommandExecute);
        }
        public UpdatedRemindersViewModel(ObservableCollection<EventReminderModel> eventRemindersToBeUpdated)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();
            EventRemindersToBeUpdated = eventRemindersToBeUpdated;
            UpdateRemindersCommand = new RelayCommand(UpdateRemindersCommandExecuted);

        }
示例#6
0
        public NumberOfDaysViewModel()
        {
            SaveChangesCommand = new RelayCommand(SaveChangesCommandExecuted, SaveChangesCommandCanExecute);

            LoadSettings();

            this.PropertyChanged += NumberOfDaysViewModel_PropertyChanged;
        }
示例#7
0
        public FromTemplateViewModel(EventModel eventModel)
        {
            _event = eventModel;
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventsDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();
            OKCommand = new RelayCommand(OKCommandExecuted, OKCommandCanExecute);

        }
示例#8
0
        public EmailHeadersViewModel()
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            DeleteEmailHeaderCommand = new RelayCommand<EmailHeaderModel>(DeleteEmailHeaderCommandExecuted);
            EditEmailHeaderCommand = new RelayCommand<EmailHeaderModel>(EditEmailHeaderCommandExecuted);
        }
        public EventCorrespondenceViewModel()
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventsDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();

            SendEmailCommand = new RelayCommand(SendEmailCommandExecuted);
            ShowCorrespondenceCommand = new RelayCommand<CorrespondenceModel>(ShowCorrespondenceCommandExecuted);
        }
示例#10
0
        public MembershipGroupsViewModel()
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            DeleteMembershipGroupCommand = new RelayCommand<MembershipGroupModel>(DeleteMembershipGroupCommandExecuted);
            EditMembershipGroupCommand = new RelayCommand<MembershipGroupModel>(EditMembershipGroupCommandExecuted);
        }
示例#11
0
        public ClubInformationViewModel()
        {
            SaveChangesCommand = new RelayCommand(SaveChangesCommandExecuted, SaveChangesCommandCanExecute);

            LoadSettings();

            this.PropertyChanged += ClubInformationViewModel_PropertyChanged;
        }
示例#12
0
        public EventPaymentsViewModel()
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventsDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();

            AddPaymentCommand = new RelayCommand(AddPaymentCommandExecuted);
            DeletePaymentCommand = new RelayCommand<EventPaymentModel>(DeletePaymentCommandExecuted);
            EditPaymentCommand = new RelayCommand<EventPaymentModel>(EditPaymentCommandExecuted);
        }
        public AddMembershipLinkTypeViewModel(MembershipLinkTypeModel membershipLinkType)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            SaveCommand = new RelayCommand(SaveCommandExecuted, SaveCommandCanExecute);

            ProcessMembershipLinkType(membershipLinkType);
        }
示例#14
0
        public AddProductGroupViewModel(ProductGroupModel productGroupModel)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            OKCommand = new RelayCommand(OKCommandExecuted, OKCommandCanExecute);

            ProcessProductGroup(productGroupModel);
        }
示例#15
0
        public EventDetailsViewModel(EventModel model)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventsDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();
            _contactsDataUnit = dataUnitLocator.ResolveDataUnit<IContactsDataUnit>();

            EditEventCommand = new RelayCommand<EventModel>(EditEventCommandExecuted, EditEventCommandCanExecute);

            Event = model;
        }
示例#16
0
        public AddTillViewModel(ObservableCollection<TillDivisionModel> tillDivisions)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            TillDivisions = new ObservableCollection<TillDivision>(tillDivisions.Select(tillDivision => tillDivision.TillDivision));
            OkCommand = new RelayCommand(OkCommandExecuted, OkCommandCanExecute);

            AddTill();
        }
示例#17
0
        public ProductGroupViewModel(TillDivisionGroupDepartmentModel tillDivisionGroupDepartmentModel)
        {
            TillDivision = tillDivisionGroupDepartmentModel.TillDivision;
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            DeleteProductGroupCommand = new RelayCommand<ProductGroupModel>(DeleteProductGroupCommandExecuted);
            EditProductGroupCommand = new RelayCommand<ProductGroupModel>(EditProductGroupCommandExecuted);

        }
        public EventAlternativeContactsViewModel()
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventsDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();

            AddAlternativeContactCommand = new RelayCommand(AddAlternativeContactCommandExecuted);
            FindContactCommand = new RelayCommand(FindContactCommandExecuted);
            DeleteAlternativeContactCommand = new RelayCommand<EventContact>(DeleteAlternativeContactCommandExecuted);
            EditAlternativeContactCommand = new RelayCommand<EventContact>(EditAlternativeContactCommandExecuted);
        }
示例#19
0
        public EventNotesViewModel()
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventsDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();

            AddNoteCommand = new RelayCommand(AddNoteCommandExecuted);
            DeleteNoteCommand = new RelayCommand<EventNoteModel>(DeleteNoteCommandExecuted);
            EditNoteCommand = new RelayCommand<EventNoteModel>(EditNoteCommandExecuted);
            OpenEnquiryCommand = new RelayCommand(OpenEnquiryCommandExecute);
        }
示例#20
0
        public AddGolfViewModel()
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            SaveCommand = new RelayCommand(SaveCommandExecuted, SaveCommandCanExecute);

            Golf = GetGolfModel();
            Golf.PropertyChanged += GolfOnPropertyChanged;
        }
示例#21
0
        public AddCalendarNoteViewModel(CalendarNoteModel note)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventsDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();

            SaveCommand = new RelayCommand(SaveCommandExecuted, SaveCommandCanExecute);
            CancelCommand = new RelayCommand(CancelCommandExecuted);

            ProcessNote(note);
        }
        public GolfFollowResourceViewModel(GolfModel golfModel)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            SubmitCommand = new RelayCommand(SubmitCommandExecuted);
            Golf = golfModel;
            GolfFollowResources = new ObservableCollection<GolfModel>();
            GolfFollowResources.CollectionChanged += GolfFollowResources_CollectionChanged;
        }
示例#23
0
        public AddCampaignViewModel(CampaignModel campaignModel)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _crmDataUnit = dataUnitLocator.ResolveDataUnit<ICrmDataUnit>();

            SubmitCommand = new RelayCommand(SubmitCommandExecuted, SubmitCommandCanExecute);
            CancelCommand = new RelayCommand(CancelCommandExecuted);

            ProcessCampaign(campaignModel);
        }
        public AddMembershipGroupAgeViewModel(MembershipGroupAgeModel membershipGroupAge)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            SaveCommand = new RelayCommand(SaveCommandExecuted, SaveCommandCanExecute);
            ExpandCollapseButtonCommand = new RelayCommand(ExpandCollapseButtonCommandExecuted);

            ProcessMembershipGroupAge(membershipGroupAge);
        }
示例#25
0
        public AddEventChargeViewModel(EventModel eventModel, EventChargeModel charge)
        {
            _event = eventModel;

            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventsDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();

            SubmitCommand = new RelayCommand(SubmitCommandExecuted, SubmitCommandCanExecute);

            ProcessCharge(charge);
        }
示例#26
0
        public AddEnquiryNoteViewModel(EnquiryModel enquiryModel, EnquiryNoteModel noteModel)
        {
            _enquiry = enquiryModel;
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _crmDataUnit = dataUnitLocator.ResolveDataUnit<ICrmDataUnit>();

            SubmitCommand = new RelayCommand(SubmitCommandExecuted, SubmitCommandCanExecute);
            CancelCommand = new RelayCommand(CancelCommandExecuted);

            ProcessNote(noteModel);
        }
示例#27
0
        public AddMemberNoteViewModel(MemberModel memberModel, MemberNoteModel noteModel)
        {
            Member = memberModel;
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _membershipDataUnit = dataUnitLocator.ResolveDataUnit<IMembershipDataUnit>();

            SubmitCommand = new RelayCommand(SubmitCommandExecuted, SubmitCommandCanExecute);
            CancelCommand = new RelayCommand(CancelCommandExecuted);

            ProcessNote(noteModel);
        }
示例#28
0
        public AddEmailHeaderViewModel(EmailHeaderModel emailHeader)
        {
            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _adminDataUnit = dataUnitLocator.ResolveDataUnit<IAdminDataUnit>();

            SaveCommand = new RelayCommand(SaveCommandExecuted, SaveCommandCanExecute);
            CancelCommand = new RelayCommand(CancelCommandExecuted);
            AddHeaderImageCommand = new RelayCommand(AddHeaderImageCommandExecuted);

            ProcessHeader(emailHeader);
        }
示例#29
0
        public AddNoteViewModel(EventModel eventModel, EventNoteModel noteModel)
        {
            _event = eventModel;

            var dataUnitLocator = ContainerAccessor.Instance.GetContainer().Resolve<IDataUnitLocator>();
            _eventsDataUnit = dataUnitLocator.ResolveDataUnit<IEventDataUnit>();

            SubmitCommand = new RelayCommand(SubmitCommandExecuted, SubmitCommandCanExecute);
            CancelCommand = new RelayCommand(CancelCommandExecuted);

            ProcessNote(noteModel);
        }
示例#30
0
        public MainViewModel()
        {
            NavigateToResourcesCommand = new RelayCommand(NavigateToResourcesCommandExecuted, NavigateToResourcesCommandCanExecute);
            NavigateToUsersCommand = new RelayCommand(NavigateToUsersCommandExecuted, NavigateToUsersCommandCanExecute);
            NavigateToUserGroupsCommand = new RelayCommand(NavigateToUserGroupsCommandExecuted, NavigateToUserGroupsCommandCanExecute);
            NavigateToEventsCommand = new RelayCommand(NavigateToEventsCommandExecuted, NavigateToEventsCommandCanExecute);
            NavigateToProductsCommand = new RelayCommand(NavigateToProductsExecuted, NavigateToProductsCanExecute);
            NavigateToSettingsCommand = new RelayCommand(NavigateToSettingsCommandExecuted, NavigateToSettingsCommandCanExecute);
            NavigateToCRMCommand = new RelayCommand(NavigateToCRMCommandExecuted, NavigateToCRMCommandCanExecute);
            NavigateToMembersCommand = new RelayCommand(NavigateToMembersCommandExecuted, NavigateToMembersCommandCanExecute);

        }