protected SchedulerTimelineViewBase(SchedulerViewType type, IScheduler scheduler) 
     : base(type, scheduler)
 {
     WorkDayCommand = true;
     Footer = true;
     ShowWorkHours = scheduler.ShowWorkHours;
 }
        private void schedulerControl1_RangeControlAutoAdjusting(object sender,
                                                                 RangeControlAdjustEventArgs e)
        {
            SchedulerViewType activeViewType = scheduler.ActiveViewType;

            if (activeViewType == SchedulerViewType.WorkWeek)
            {
                e.Scales[4].DisplayFormat = "dddd";
                e.Scales[4].Width         = 70;
            }

            if (activeViewType == SchedulerViewType.Month)
            {
                e.Scales.Clear();

                TimeScaleMonth monthScale = new TimeScaleMonth();
                monthScale.DisplayFormat = "MMMM yyyy";
                e.Scales.Add(monthScale);

                TwoWeekTimeScale twoWeekTimeScale = new TwoWeekTimeScale();
                twoWeekTimeScale.Width = 120;
                e.Scales.Add(twoWeekTimeScale);

                e.RangeMinimum = new DateTime(e.RangeMinimum.Year, 1, 1);
                e.RangeMaximum = e.RangeMinimum.AddYears(1);
            }
        }
Exemple #3
0
 protected SchedulerMultiDayView(SchedulerViewType type, IScheduler scheduler)
     : base(type, scheduler)
 {
     AllDaySlot     = true;
     WorkDayCommand = true;
     Footer         = true;
     ShowWorkHours  = scheduler.ShowWorkHours;
 }
        /// <summary>
        /// go to date
        /// </summary>
        /// <param name="date"></param>
        /// <param name="viewType"></param>
        public void GoToDate(DateTime date, SchedulerViewType viewType)
        {
            DateTime          old         = _control.SelectedInterval.Start;
            SchedulerViewType oldViewType = _control.ActiveViewType;

            _innerNavigate.GoToDate(date, viewType);
            UndoService.AddGotoDateAction(_innerNavigate, _control.SelectedInterval.Start, old, viewType, oldViewType);
        }
 protected SchedulerMultiDayView(SchedulerViewType type, IScheduler scheduler)
     : base(type, scheduler)
 {
     AllDaySlot = true;
     WorkDayCommand = true;
     Footer = true;
     ShowWorkHours = scheduler.ShowWorkHours;
 }
Exemple #6
0
        private void Scheduler_ActiveViewChanging(object sender, ActiveViewChangingEventArgs e)
        {
            ASPxSchedulerListEditor listEditor = (ASPxSchedulerListEditor)this.View.Editor;
            ASPxScheduler           scheduler  = listEditor.SchedulerControl;

            this._schedulerViewType = e.NewView.Type;
            scheduler.DataBind();
        }
Exemple #7
0
        private void scheduler_ActiveViewChanged(object sender, EventArgs e)
        {
            if (this.chVerticalAppointmentStyle == null)
            {
                return;
            }
            SchedulerViewType viewType = ((SchedulerControl)sender).ActiveView.Type;

            this.chVerticalAppointmentStyle.IsEnabled = Object.Equals(viewType, SchedulerViewType.Day) || Object.Equals(viewType, SchedulerViewType.WorkWeek);
        }
 public void GoToDate(System.DateTime date, SchedulerViewType viewType)
 {
     if (UseBaseService())
     {
         BaseService.GoToDate(date, viewType);
         return;
     }
     BaseService.GoToDate(date, viewType);
     Control.Start = DateTimeNavigationHelper.CalculateMonthFirstDate(date);
 }
Exemple #9
0
        object IValueConverter.Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            SchedulerViewType viewType = (SchedulerViewType)value;

            if (viewType.Equals(SchedulerViewType.Timeline))
            {
                return(Visibility.Visible);
            }

            return(Visibility.Collapsed);
        }
Exemple #10
0
 public GotoDateAction(
     IDateTimeNavigationService navigate
     , DateTime newValue
     , DateTime oldValue
     , SchedulerViewType newViewType
     , SchedulerViewType oldViewType)
 {
     Name             = "Goto date";
     this.navigate    = navigate;
     this.newValue    = newValue;
     this.oldValue    = oldValue;
     this.newViewType = newViewType;
     this.oldViewType = oldViewType;
 }
        public bool IsValid(object owner, Condition condition)
        {
            if (!(owner is IWorkspace1))
            {
                return(false);
            }
            IWorkspace1           workspace  = (IWorkspace1)owner;
            AppointmentController controller = workspace.FindController <AppointmentController>("");

            if (controller != null)
            {
                SchedulerViewType viewType;
                bool parseSuccess = SchedulerViewType.TryParse(condition.Name, true, out viewType);
                if (parseSuccess)
                {
                    return(controller.IsTheSameActiveViewType(viewType));
                }
            }
            return(false);
        }
Exemple #12
0
 protected SchedulerViewMultiDay(SchedulerViewType type)
     : base(type)
 {
     AllDaySlot = true;
 }
 private void SetCloneDoctorEventActive(SchedulerViewType type)
 {
     CloneDoctorEventAction.Active[CLONEDOCTOREVENTACTIVE] = FilterDoctorEventAction.SelectedItem != null &&
                                                             type == SchedulerViewType.WorkWeek;
 }
Exemple #14
0
 protected SchedulerViewBase(SchedulerViewType type)
 {
     Type  = type;
     Group = new SchedulerGroupSettings();
 }
Exemple #15
0
 public SchedulerViewBuilder Type(SchedulerViewType value)
 {
     base.Options["type"] = value;
     return(this);
 }
Exemple #16
0
 protected SchedulerViewBase(SchedulerViewType type, IScheduler scheduler)
 {
     Type      = type;
     Group     = new SchedulerGroupSettings();
     Scheduler = scheduler;
 }
Exemple #17
0
 public static void AddGotoDateAction(IDateTimeNavigationService navigate, DateTime newValue, DateTime oldValue, SchedulerViewType newViewType, SchedulerViewType oldViewType)
 {
     if (UndoService.CandAddAction)
     {
         UndoService.AddAction(new GotoDateAction(navigate, newValue, oldValue, newViewType, oldViewType));
     }
 }
Exemple #18
0
 protected SchedulerViewBase(SchedulerViewType type)
 {
     Type = type;
     Group = new SchedulerGroupSettings();
 }
Exemple #19
0
 protected SchedulerViewMultiDay(SchedulerViewType type) : base(type)
 {
     AllDaySlot = true;
 }
Exemple #20
0
 protected SchedulerViewBase(SchedulerViewType type, IScheduler scheduler)
 {
     Type = type;
     Group = new SchedulerGroupSettings();
     Scheduler = scheduler;
 }