public DayConfigControl(List <UIDay> _uIDays, INavigation navigation, IScheduleOperation scheduleOperation, bool _isActive, Schedules schedules, Entities.Scheduler scheduler = null) { InitializeComponent(); this.uIDays = _uIDays; IntervalList = BuildIntervalList(); if (scheduler != null) { SetIntervalValue(scheduler); SetStartAndStopValue(scheduler); SetDaysValue(scheduler); SetInterval(); SetActiveStatusValue(scheduler); } this.scheduleOperation = scheduleOperation; weekControl = new WeekControl(weekFrameLayout); weekControl.DaysList = this.uIDays; weekFrameLayout.Children.Add(weekControl); WeekCardControl weekCardControl = new WeekCardControl(); weekCardControl.DaysList = this.uIDays; weekexpand.Children.Add(weekCardControl); rawSchedules = schedules; this.navigation = navigation; BindingContext = this; if (scheduler == null) { isActive = _isActive; toggle.IsToggled = _isActive; } toggle.Toggled += Toggle_Toggled; }
/// <summary> /// /// </summary> /// <param name="uIDays"></param> /// <param name="scheduleOperation"></param> /// <param name="id"></param> /// <param name="startTimeSpan"></param> /// <param name="stopTimeSpan"></param> /// <param name="interval"></param> /// <param name="active"></param> /// <param name="schedules">Entier schedule list(original)</param> public ConfigurationSettingPage(List <UIDay> uIDays, IScheduleOperation scheduleOperation, string id, TimeSpan startTimeSpan, TimeSpan stopTimeSpan, string interval, bool active, Schedules schedules) { InitializeComponent(); BindingContext = this; this.uIDays = uIDays; this.scheduleOperation = scheduleOperation; this.id = id; SelectedStartTime = rawStartTimeSpan = startTimeSpan; SelectedStopTime = rawStopTimeSpan = stopTimeSpan; this.interval = interval; IsActive = active; Interval = Convert.ToInt32(interval); BuildDayView(uIDays); schedulesRawList = schedules; }