debian-mirror-gitlab/app/services/projects/autocomplete_service.rb

16 lines
297 B
Ruby
Raw Normal View History

2015-04-26 12:48:37 +05:30
module Projects
class AutocompleteService < BaseService
def initialize(project)
@project = project
end
def issues
@project.issues.opened.select([:iid, :title])
end
def merge_requests
@project.merge_requests.opened.select([:iid, :title])
end
end
end