debian-mirror-gitlab/app/views/layouts/_init_auto_complete.html.haml

17 lines
821 B
Text
Raw Normal View History

2015-10-24 18:46:33 +05:30
- project = @target_project || @project
2016-09-13 17:45:13 +05:30
- noteable_type = @noteable.class if @noteable.present?
2016-11-03 12:29:30 +05:30
- if project
2017-09-10 17:25:29 +05:30
-# haml-lint:disable InlineJavaScript
2016-11-03 12:29:30 +05:30
:javascript
2017-09-10 17:25:29 +05:30
gl = window.gl || {};
gl.GfmAutoComplete = gl.GfmAutoComplete || {};
2017-08-17 22:00:37 +05:30
gl.GfmAutoComplete.dataSources = {
2017-09-10 17:25:29 +05:30
members: "#{members_project_autocomplete_sources_path(project, type: noteable_type, type_id: params[:id])}",
issues: "#{issues_project_autocomplete_sources_path(project)}",
mergeRequests: "#{merge_requests_project_autocomplete_sources_path(project)}",
labels: "#{labels_project_autocomplete_sources_path(project)}",
milestones: "#{milestones_project_autocomplete_sources_path(project)}",
commands: "#{commands_project_autocomplete_sources_path(project, type: noteable_type, type_id: params[:id])}"
2017-08-17 22:00:37 +05:30
};