diff options
author | Douwe Maan <douwe@gitlab.com> | 2015-11-17 18:53:56 +0100 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2015-11-17 18:53:56 +0100 |
commit | e945ec02804bb28dbd228d8002a159c8da0fcc38 (patch) | |
tree | 72600162a61e7990d6c62ce5af90f5e649cc1e86 /app/views/projects/blob/new.html.haml | |
parent | 0b540a0fadf172277639910023fcf8b713ad35aa (diff) | |
download | gitlab-ce-e945ec02804bb28dbd228d8002a159c8da0fcc38.tar.gz |
Add "Start a new merge request" option to every commit form
Diffstat (limited to 'app/views/projects/blob/new.html.haml')
-rw-r--r-- | app/views/projects/blob/new.html.haml | 24 |
1 files changed, 5 insertions, 19 deletions
diff --git a/app/views/projects/blob/new.html.haml b/app/views/projects/blob/new.html.haml index 0439e55131e..1ff68005450 100644 --- a/app/views/projects/blob/new.html.haml +++ b/app/views/projects/blob/new.html.haml @@ -2,32 +2,18 @@ = render "header_title" .gray-content-block.top-block - Create a new file + %h3.page-title + Create New File .file-editor - = form_tag(namespace_project_create_blob_path(@project.namespace, @project, @id), method: :post, class: 'form-horizontal form-new-file js-requires-input') do + = form_tag(namespace_project_create_blob_path(@project.namespace, @project, @id), method: :post, class: 'form-horizontal js-new-blob-form js-requires-input') do = render 'projects/blob/editor', ref: @ref - = render 'shared/commit_message_container', params: params, - placeholder: 'Add new file' - - - unless @project.empty_repo? - .form-group.branch - = label_tag 'branch', class: 'control-label' do - Branch - .col-sm-10 - = text_field_tag 'new_branch', @ref, class: "form-control js-quick-submit" - - .form-group.destination - .col-sm-offset-2.col-sm-10 - .checkbox - = label_tag :create_merge_request do - = check_box_tag :create_merge_request, 1, false - Start a new merge request + = render 'shared/new_commit_form', placeholder: "Add new file" = hidden_field_tag 'content', '', id: 'file-content' - = hidden_field_tag 'original_branch', @ref = render 'projects/commit_button', ref: @ref, cancel_path: namespace_project_tree_path(@project.namespace, @project, @id) :javascript blob = new NewBlob(gon.relative_url_root + "#{Gitlab::Application.config.assets.prefix}", null) + new NewCommitForm($('.js-new-blob-form')) |