Commit de9bb3bc authored by Mayra Cabrera's avatar Mayra Cabrera

Merge branch 'jivanvl-add-missing-check-analytics-page' into 'master'

Add missing check for analytics page

See merge request gitlab-org/gitlab!49638
parents c2759d79 e198007e
......@@ -186,12 +186,15 @@ class Projects::PipelinesController < Projects::ApplicationController
def charts
@charts = {}
@counts = {}
return unless Feature.enabled?(:graphql_pipeline_analytics)
@charts[:week] = Gitlab::Ci::Charts::WeekChart.new(project)
@charts[:month] = Gitlab::Ci::Charts::MonthChart.new(project)
@charts[:year] = Gitlab::Ci::Charts::YearChart.new(project)
@charts[:pipeline_times] = Gitlab::Ci::Charts::PipelineTime.new(project)
@counts = {}
@counts[:total] = @project.all_pipelines.count(:all)
@counts[:success] = @project.all_pipelines.success.count(:all)
@counts[:failed] = @project.all_pipelines.failed.count(:all)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment