Commit 63c1cdce authored by Marin Jankovski's avatar Marin Jankovski

Show @all in autocomplete list.

parent 73c1030d
...@@ -130,7 +130,7 @@ class ProjectsController < ApplicationController ...@@ -130,7 +130,7 @@ class ProjectsController < ApplicationController
[] []
end end
team_members = sorted(@project.team.members) team_members = sorted(@project.team.members)
participants = team_members + participating participants = [{ username: "all", name: "Group Members" }] + team_members + participating
@suggestions = { @suggestions = {
emojis: Emoji.names.map { |e| { name: e, path: view_context.image_url("emoji/#{e}.png") } }, emojis: Emoji.names.map { |e| { name: e, path: view_context.image_url("emoji/#{e}.png") } },
issues: @project.issues.select([:iid, :title, :description]), issues: @project.issues.select([:iid, :title, :description]),
......
...@@ -169,7 +169,12 @@ module Gitlab ...@@ -169,7 +169,12 @@ module Gitlab
end end
def reference_user(identifier, project = @project) def reference_user(identifier, project = @project)
if user = User.find_by(username: identifier) if identifier == "all"
options = html_options.merge(
class: "gfm gfm-team_member #{html_options[:class]}"
)
link_to("@all", project_url(project), options)
elsif user = User.find_by(username: identifier)
options = html_options.merge( options = html_options.merge(
class: "gfm gfm-team_member #{html_options[:class]}" class: "gfm gfm-team_member #{html_options[:class]}"
) )
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment