diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-24 12:09:01 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-24 12:09:01 +0000 |
commit | 2c2dd5e36c4ed5f09f488be288882d98f9124d12 (patch) | |
tree | ad4c478bb1c588387a881b26a7db7c3237b9d4f3 /app/models/ci/build.rb | |
parent | 2ff184ad761fbfbe25a3d827c8f704349963a8d2 (diff) | |
download | gitlab-ce-2c2dd5e36c4ed5f09f488be288882d98f9124d12.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/ci/build.rb')
-rw-r--r-- | app/models/ci/build.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/app/models/ci/build.rb b/app/models/ci/build.rb index 369a793f3d5..d1edf3e9c03 100644 --- a/app/models/ci/build.rb +++ b/app/models/ci/build.rb @@ -172,6 +172,9 @@ module Ci scope :queued_before, ->(time) { where(arel_table[:queued_at].lt(time)) } scope :order_id_desc, -> { order('ci_builds.id DESC') } + PROJECT_ROUTE_AND_NAMESPACE_ROUTE = { project: [:project_feature, :route, { namespace: :route }] }.freeze + scope :preload_project_and_pipeline_project, -> { preload(PROJECT_ROUTE_AND_NAMESPACE_ROUTE, pipeline: PROJECT_ROUTE_AND_NAMESPACE_ROUTE) } + acts_as_taggable add_authentication_token_field :token, encrypted: :optional |