public void Fill(IBAWindow parentWindow, ProfileInformationDTO user, bool isActive)
 {
     this.parentView = parentWindow;
     this.user       = user;
     this.isActive   = isActive;
     fill();
 }
 public ScheduleEntriesDesignViewModel(IBAWindow parentView, ScheduleEntriesCalendar calendar)
 {
     this.calendar   = calendar;
     this.parentView = parentView;
     CollectionChangedEventManager.AddListener(ActivitiesReposidory.Instance, this);
     CollectionChangedEventManager.AddListener(CustomerGroupsReposidory.Instance, this);
     CollectionChangedEventManager.AddListener(CustomersReposidory.Instance, this);
 }
Пример #3
0
        public MyTrainingsViewModel(IBAWindow parentView, UserDTO user, CustomerDTO customer)
        {
            this.parentView     = parentView;
            User                = user;
            ActiveMonthDateTime = DateTime.Now;
            Customer            = customer;
            Guid?customerId = Customer != null ? Customer.GlobalId : (Guid?)null;
            Guid?userId     = User != null ? User.GlobalId : (Guid?)null;

            myTrainingsCache = MyTrainingsReposidory.GetCache(customerId, userId);
            CollectionChangedEventManager.AddListener(myTrainingsCache, this);
            updateButtons();
        }
        public void Fill(IBAWindow parentView, SupplementsCycleDefinitionContext context)
        {
            this.context    = context;
            this.parentView = parentView;
            this.Cycle      = context.CycleDefinition.StandardClone();
            Weeks.Clear();

            foreach (var day in definition.Weeks.OrderBy(x => x.CycleWeekStart))
            {
                Weeks.Add(new SupplementsCycleWeekViewModel(this, day));
            }
            updateButtons();
        }
Пример #5
0
 public CustomerGroupDetailsViewModel(IBAWindow parentView, CustomerGroupDTO @group)
 {
     this.parentView = parentView;
     this.group      = group;
     CollectionChangedEventManager.AddListener(CustomersReposidory.Instance, this);
     foreach (var customerDto in group.Customers)
     {
         members.Add(new GroupMemberItem(customerDto));
     }
     fillCustomers();
     ValidateCustomers();
     ValidateMembers();
 }
Пример #6
0
 public CustomerGroupsViewModel(IBAWindow parentView)
 {
     this.parentView = parentView;
     updateButtons();
     CollectionChangedEventManager.AddListener(CustomerGroupsReposidory.Instance, this);
 }
 public SaveScheduleEntriesViewModel(IBAWindow parent, SaveScheduleEntryRangeParam param)
 {
     this.parent = parent;
     this.param  = param;
 }
Пример #8
0
 public RemindersViewModel(IBAWindow parentView)
 {
     this.parentView = parentView;
     updateButtons();
     CollectionChangedEventManager.AddListener(ReminderItemsReposidory.Instance, this);
 }
 public usrCustomerInfoViewModel(IBAWindow parentWindow)
 {
     this.parentWindow = parentWindow;
 }