Esempio n. 1
0
        private void UpdateBuilds()
        {
            BuildResourceFilter filter = this.CreateBuildResourceFilter();

            if (this.viewmodel.SelectedBuildFilter == BuildFilter.Completed)
            {
                var dateFilter = this.CompletedBuildsDateFilter.SelectedItem as BuildDateFilter;
                this.viewmodel.AssignBuilds(this.repository.GetCompletedBuilds(filter, dateFilter.TimeSpan));
            }
            else
            {
                this.viewmodel.AssignBuilds(this.repository.GetQueuedBuilds(filter));
            }
        }
Esempio n. 2
0
        private void UpdateBuilds()
        {
            if (!this.dispatcherTimer.IsEnabled && this.CheckBoxAutoRefresh.IsChecked == true)
            {
                this.dispatcherTimer.Start();
            }

            BuildResourceFilter filter = this.CreateBuildResourceFilter();

            if (this.viewmodel.SelectedBuildFilter == BuildFilter.Completed)
            {
                var dateFilter = this.CompletedBuildsDateFilter.SelectedItem as BuildDateFilter;
                if (dateFilter != null)
                {
                    this.viewmodel.AssignBuilds(this.repository.GetCompletedBuilds(filter, dateFilter.TimeSpan));
                }
            }
            else
            {
                this.viewmodel.AssignBuilds(this.repository.GetQueuedBuilds(filter));
            }
        }