Class: Types::Ci::DetailedStatusType

Inherits:
BaseObject
  • Object
show all
Defined in:
app/graphql/types/ci/detailed_status_type.rb

Overview

rubocop: disable Graphql/AuthorizeTypes This is presented through `PipelineType` that has its own authorization

Instance Method Summary collapse

Methods inherited from BaseObject

accepts, assignable?, authorization, authorize, authorized?, #current_user

Methods included from Gitlab::Graphql::Present

#present, #unpresented

Instance Method Details

#actionObject


39
40
41
42
43
44
45
46
47
48
49
50
51
# File 'app/graphql/types/ci/detailed_status_type.rb', line 39

def action
  if object.has_action?
    {
      button_title: object.action_button_title,
      icon: object.action_icon,
      method: object.action_method,
      path: object.action_path,
      title: object.action_title
    }
  else
    nil
  end
end

#id(parent:) ⇒ Object


35
36
37
# File 'app/graphql/types/ci/detailed_status_type.rb', line 35

def id(parent:)
  "#{object.id}-#{parent.id}"
end