Skip to content

Ensure we don't show warning when there are <1000 epics on a roadmap

What does this MR do?

  • Prevent showing warning about epics limit on roadmap unless over 1000 epics match filters
  • Update warning to use gitlab-ui GlAlert component
  • Move warning under filter bar, following the initial design: #33338 (closed)

To test with over 1000 being returned in the roadmap, they require to have start date and end date:

  • Edit script ee/db/fixtures/development/22_epics.rb with the following, replacing group_id with the group id you wish to test with.
Gitlab::Seeder.quiet do
  Group.all.each do |group|
    if group.id === `group_id` then
      1000.times do
        epic_params = {
          title: FFaker::Lorem.sentence(6),
          description: FFaker::Lorem.paragraphs(3).join("\n\n"),
          author: group.users.sample,
          group: group
          start_date: Date.today,
          due_date: rand(5..10).days.from_now
        }

        Epic.create!(epic_params)
        print '.'
      end
    end
  end
end
  • Run bundle exec rake db:seed_fu FILTER=epics
  • You should have 1000 in your roadmap for the specified group

Screenshots (strongly suggested)

- Before After
When over 1000 epics are returned Screenshot_from_2020-11-18_10-46-26 Screenshot_from_2020-11-20_10-10-11
When less than 1000 epics are returned (filter is applied) Screenshot_from_2020-11-18_10-50-53 Screenshot_from_2020-11-18_10-50-20

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team

Related to #271401 (closed)

Edited by Florie Guibert

Merge request reports