Class: Boards::Issues::CreateService

Inherits:
BaseService show all
Defined in:
app/services/boards/issues/create_service.rb

Instance Attribute Summary collapse

Attributes inherited from BaseService

#current_user, #params, #parent

Attributes inherited from BaseService

#current_user, #params

Instance Method Summary collapse

Methods included from BaseServiceUtility

#deny_visibility_level, #event_service, #log_error, #log_info, #notification_service, #system_hook_service, #todo_service, #visibility_level

Methods included from Gitlab::Allowable

#can?

Constructor Details

#initialize(parent, project, user, params = {}) ⇒ CreateService

Returns a new instance of CreateService.


8
9
10
11
12
# File 'app/services/boards/issues/create_service.rb', line 8

def initialize(parent, project, user, params = {})
  @project = project

  super(parent, user, params)
end

Instance Attribute Details

#projectObject

Returns the value of attribute project


6
7
8
# File 'app/services/boards/issues/create_service.rb', line 6

def project
  @project
end

Instance Method Details

#executeObject


14
15
16
# File 'app/services/boards/issues/create_service.rb', line 14

def execute
  create_issue(params.merge(issue_params))
end