void OnIntervalChange(long IntervalDuration) { SelectedInterval = IntervalFilter.GetIntervalFilters().Where(i => i.Duration == IntervalDuration).FirstOrDefault(); SelectedFilterInterval = IntervalDuration; FilterCurrentChartData(IntervalDuration); }
protected override void OnInitialized() { SelectedInterval = IntervalFilter.GetIntervalFilters()[3]; SelectedFilterInterval = IntervalFilter.GetIntervalFilters()[3].Duration; ActiveTimeFilterDuration = TimeFilter.GetFilters()[4].Duration; Start = End.AddDays(-4); FilterIntervals(ActiveTimeFilterDuration.Value); TimeFilters.Add(new TimeFilter() { Name = "MAX", Duration = (long)(MaxDate - MinDate).TotalMilliseconds }); base.OnInitialized(); }
void FilterIntervals(long filterDuration) { IntervalFilters = IntervalFilter.GetIntervalFilters().Where(i => i.Duration < filterDuration && filterDuration / i.Duration < 200).ToList(); }