Skip to content
GitLab
Next
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • GitLab FOSS GitLab FOSS
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 1
    • Merge requests 1
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Code review
    • Insights
    • Issue
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • GitLab.orgGitLab.org
  • GitLab FOSSGitLab FOSS
  • Merge requests
  • !20379

Resolve "Disable GCP free credit banner at instance level"

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Dennis Tang requested to merge 48578-disable-gcp-free-credit-banner-at-instance-level into master Jul 04, 2018
  • Overview 39
  • Commits 12
  • Pipelines 16
  • Changes 12

What does this MR do?

Adds the option to hide third-party offers in the Admin -> Application Settings section.

If this option is left unchecked, i.e., display third party offers, the user will still be able to opt-out of it once they click the "x" on the offer, as it functioned before.

Are there points in the code the reviewer needs to double check?

Nope.

Why was this MR needed?

See issue.

Screenshots (if relevant)

Database Checklist

When adding migrations:

  • Updated db/schema.rb
  • Added a down method so the migration can be reverted
  • Added the output of the migration(s) to the MR body
== 20180704204006 AddHideThirdPartyOffersToApplicationSettings: migrating =====
-- transaction_open?()
   -> 0.0000s
-- execute("SET statement_timeout TO 0")
   -> 0.0004s
-- transaction()
-- add_column(:application_settings, :hide_third_party_offers, :boolean, {:default=>nil})
   -> 0.0026s
-- change_column_default(:application_settings, :hide_third_party_offers, false)
   -> 0.0076s
   -> 0.0117s
-- transaction_open?()
   -> 0.0000s
-- exec_query("SELECT COUNT(*) AS count FROM \"application_settings\"")
   -> 0.0007s
-- exec_query("SELECT  \"application_settings\".\"id\" FROM \"application_settings\"  ORDER BY \"application_settings\".\"id\" ASC LIMIT 1")
   -> 0.0004s
-- exec_query("SELECT  \"application_settings\".\"id\" FROM \"application_settings\" WHERE \"application_settings\".\"id\" >= 1  ORDER BY \"application_settings\".\"id\" ASC LIMIT 1 OFFSET 1")
   -> 0.0005s
-- execute("UPDATE \"application_settings\" SET \"hide_third_party_offers\" = 'f' WHERE \"application_settings\".\"id\" >= 1")
   -> 0.0012s
-- change_column_null(:application_settings, :hide_third_party_offers, false)
   -> 0.0013s
== 20180704204006 AddHideThirdPartyOffersToApplicationSettings: migrated (0.0228s)

Does this MR meet the acceptance criteria?

  • Changelog entry added, if necessary
  • Documentation created/updated
  • API support added
  • Tests added for this feature/bug
  • Conform by the code review guidelines
    • Has been reviewed by a UX Designer
    • Has been reviewed by a Frontend maintainer
    • Has been reviewed by a Backend maintainer
    • Has been reviewed by a Database specialist
  • Conform by the merge request performance guides
  • Conform by the style guides
  • Conform by the database guides
  • If you have multiple commits, please combine them into a few logically organized commits by squashing them
  • Internationalization required/considered
  • End-to-end tests pass (package-and-qa manual pipeline job)

What are the relevant issue numbers?

Closes #48578 (closed)

Edited Jul 10, 2018 by Rémy Coutable
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: 48578-disable-gcp-free-credit-banner-at-instance-level