Add latest changes from gitlab-org/gitlab@master
This commit is contained in:
parent
a7d1525878
commit
4c8b21b315
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: Separate entities into own class files
|
||||
merge_request: 24950
|
||||
author: Rajendra Kadam
|
||||
type: added
|
|
@ -128,47 +128,6 @@ module API
|
|||
projects_relation + projects_relation.map(&:forked_from_project).compact
|
||||
end
|
||||
end
|
||||
|
||||
class Trigger < Grape::Entity
|
||||
include ::API::Helpers::Presentable
|
||||
|
||||
expose :id
|
||||
expose :token
|
||||
expose :description
|
||||
expose :created_at, :updated_at, :last_used
|
||||
expose :owner, using: Entities::UserBasic
|
||||
end
|
||||
|
||||
class Variable < Grape::Entity
|
||||
expose :variable_type, :key, :value
|
||||
expose :protected?, as: :protected, if: -> (entity, _) { entity.respond_to?(:protected?) }
|
||||
expose :masked?, as: :masked, if: -> (entity, _) { entity.respond_to?(:masked?) }
|
||||
expose :environment_scope, if: -> (entity, _) { entity.respond_to?(:environment_scope) }
|
||||
end
|
||||
|
||||
class Pipeline < PipelineBasic
|
||||
expose :before_sha, :tag, :yaml_errors
|
||||
|
||||
expose :user, with: Entities::UserBasic
|
||||
expose :created_at, :updated_at, :started_at, :finished_at, :committed_at
|
||||
expose :duration
|
||||
expose :coverage
|
||||
expose :detailed_status, using: DetailedStatusEntity do |pipeline, options|
|
||||
pipeline.detailed_status(options[:current_user])
|
||||
end
|
||||
end
|
||||
|
||||
class PipelineSchedule < Grape::Entity
|
||||
expose :id
|
||||
expose :description, :ref, :cron, :cron_timezone, :next_run_at, :active
|
||||
expose :created_at, :updated_at
|
||||
expose :owner, using: Entities::UserBasic
|
||||
end
|
||||
|
||||
class PipelineScheduleDetails < PipelineSchedule
|
||||
expose :last_pipeline, using: Entities::PipelineBasic
|
||||
expose :variables, using: Entities::Variable
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module API
|
||||
module Entities
|
||||
class Pipeline < Entities::PipelineBasic
|
||||
expose :before_sha, :tag, :yaml_errors
|
||||
|
||||
expose :user, with: Entities::UserBasic
|
||||
expose :created_at, :updated_at, :started_at, :finished_at, :committed_at
|
||||
expose :duration
|
||||
expose :coverage
|
||||
expose :detailed_status, using: DetailedStatusEntity do |pipeline, options|
|
||||
pipeline.detailed_status(options[:current_user])
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
|
@ -0,0 +1,12 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module API
|
||||
module Entities
|
||||
class PipelineSchedule < Grape::Entity
|
||||
expose :id
|
||||
expose :description, :ref, :cron, :cron_timezone, :next_run_at, :active
|
||||
expose :created_at, :updated_at
|
||||
expose :owner, using: Entities::UserBasic
|
||||
end
|
||||
end
|
||||
end
|
|
@ -0,0 +1,10 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module API
|
||||
module Entities
|
||||
class PipelineScheduleDetails < Entities::PipelineSchedule
|
||||
expose :last_pipeline, using: Entities::PipelineBasic
|
||||
expose :variables, using: Entities::Variable
|
||||
end
|
||||
end
|
||||
end
|
|
@ -0,0 +1,15 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module API
|
||||
module Entities
|
||||
class Trigger < Grape::Entity
|
||||
include ::API::Helpers::Presentable
|
||||
|
||||
expose :id
|
||||
expose :token
|
||||
expose :description
|
||||
expose :created_at, :updated_at, :last_used
|
||||
expose :owner, using: Entities::UserBasic
|
||||
end
|
||||
end
|
||||
end
|
|
@ -0,0 +1,12 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module API
|
||||
module Entities
|
||||
class Variable < Grape::Entity
|
||||
expose :variable_type, :key, :value
|
||||
expose :protected?, as: :protected, if: -> (entity, _) { entity.respond_to?(:protected?) }
|
||||
expose :masked?, as: :masked, if: -> (entity, _) { entity.respond_to?(:masked?) }
|
||||
expose :environment_scope, if: -> (entity, _) { entity.respond_to?(:environment_scope) }
|
||||
end
|
||||
end
|
||||
end
|
|
@ -11244,33 +11244,21 @@ msgstr ""
|
|||
msgid "LicenseCompliance|Add licenses manually to approve or blacklist"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Approve"
|
||||
msgid "LicenseCompliance|Allow"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Approve license"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Approve license?"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Approved"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Blacklist"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Blacklist license"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Blacklist license?"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Blacklisted"
|
||||
msgid "LicenseCompliance|Allowed"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Cancel"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Denied"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Deny"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Here you can approve or blacklist licenses for this project. Using %{ci} or %{license} will allow you to see if there are any unmanaged licenses and approve or blacklist them in merge request."
|
||||
msgstr ""
|
||||
|
||||
|
@ -11312,6 +11300,9 @@ msgstr ""
|
|||
msgid "LicenseCompliance|License name"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|License review"
|
||||
msgstr ""
|
||||
|
||||
msgid "LicenseCompliance|Packages"
|
||||
msgstr ""
|
||||
|
||||
|
@ -11357,6 +11348,9 @@ msgstr ""
|
|||
msgid "Licenses|Components"
|
||||
msgstr ""
|
||||
|
||||
msgid "Licenses|Detected in Project"
|
||||
msgstr ""
|
||||
|
||||
msgid "Licenses|Displays licenses detected in the project, based on the %{linkStart}latest pipeline%{linkEnd} scan"
|
||||
msgstr ""
|
||||
|
||||
|
@ -11372,6 +11366,15 @@ msgstr ""
|
|||
msgid "Licenses|Name"
|
||||
msgstr ""
|
||||
|
||||
msgid "Licenses|Policies"
|
||||
msgstr ""
|
||||
|
||||
msgid "Licenses|Policy"
|
||||
msgstr ""
|
||||
|
||||
msgid "Licenses|Specified policies in this project"
|
||||
msgstr ""
|
||||
|
||||
msgid "Licenses|The license list details information about the licenses used within your project."
|
||||
msgstr ""
|
||||
|
||||
|
|
Loading…
Reference in New Issue