diff options
author | Alfredo Sumaran <alfredo@gitlab.com> | 2016-06-15 02:12:42 -0500 |
---|---|---|
committer | Alfredo Sumaran <alfredo@gitlab.com> | 2016-06-16 00:28:45 -0500 |
commit | e8a467e0943cfc5aea1c2c42680bfa61e1733cc7 (patch) | |
tree | afba16d7a0b0524b7abc80e81bfdcab5e3c40a85 /app/views/projects | |
parent | 5d16d50cebb115773c1a16a141adab150eec8764 (diff) | |
download | gitlab-ce-e8a467e0943cfc5aea1c2c42680bfa61e1733cc7.tar.gz |
Implements TemplateDropdown class to create custom template dropdownstemplate_dropdown
Also License dropdown has been ported to use our GL dropdown instead of Select2.
Fixes tests to make it work with current implementation
Diffstat (limited to 'app/views/projects')
-rw-r--r-- | app/views/projects/blob/_editor.html.haml | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/app/views/projects/blob/_editor.html.haml b/app/views/projects/blob/_editor.html.haml index 4071b59c003..ae89637df60 100644 --- a/app/views/projects/blob/_editor.html.haml +++ b/app/views/projects/blob/_editor.html.haml @@ -13,12 +13,10 @@ required: true, class: 'form-control new-file-name' .pull-right - .license-selector.js-license-selector.hide - = select_tag :license_type, grouped_options_for_select(licenses_for_select, @project.repository.license_key), include_blank: true, class: 'select2 license-select', data: {placeholder: 'Choose a license template', project: @project.name, fullname: @project.namespace.human_name} - - .gitignore-selector.hidden - = dropdown_tag("Choose a .gitignore template", options: { toggle_class: 'js-gitignore-selector', title: "Choose a template", filter: true, placeholder: "Filter", data: { filenames: gitignore_names } } ) - + .license-selector.js-license-selector-wrap.hidden + = dropdown_tag("Choose a License template", options: { toggle_class: 'js-license-selector', title: "Choose a license", filter: true, placeholder: "Filter", data: { data: licenses_for_select, project: @project.name, fullname: @project.namespace.human_name } } ) + .gitignore-selector.js-gitignore-selector-wrap.hidden + = dropdown_tag("Choose a .gitignore template", options: { toggle_class: 'js-gitignore-selector', title: "Choose a template", filter: true, placeholder: "Filter", data: { data: gitignore_names } } ) .encoding-selector = select_tag :encoding, options_for_select([ "base64", "text" ], "text"), class: 'select2' |