gitlab-org--gitlab-foss/app/services/milestones/create_service.rb
2016-04-07 10:59:24 -03:00

13 lines
264 B
Ruby

module Milestones
class CreateService < Milestones::BaseService
def execute
milestone = project.milestones.new(params)
if milestone.save!
event_service.open_milestone(milestone, current_user)
end
milestone
end
end
end