Merge pull request #7942 from cirosantilli/commit-changes-uppercase
Make new and edit file submit more uniform
This commit is contained in:
commit
e261de255d
|
@ -0,0 +1,9 @@
|
|||
.form-actions
|
||||
.commit-button-annotation
|
||||
= button_tag 'Commit Changes',
|
||||
class: 'btn commit-btn js-commit-button btn-create'
|
||||
.message
|
||||
to branch
|
||||
%strong= ref
|
||||
= link_to 'Cancel', cancel_path,
|
||||
class: 'btn btn-cancel', data: {confirm: leave_edit_message}
|
|
@ -23,16 +23,11 @@
|
|||
%i.fa.fa-spinner.fa-spin
|
||||
= render 'shared/commit_message_container', params: params,
|
||||
placeholder: "Update #{@blob.name}"
|
||||
.form-actions
|
||||
= hidden_field_tag 'last_commit', @last_commit
|
||||
= hidden_field_tag 'content', '', id: "file-content"
|
||||
= hidden_field_tag 'from_merge_request_id', params[:from_merge_request_id]
|
||||
.commit-button-annotation
|
||||
= button_tag "Commit changes", class: 'btn commit-btn js-commit-button btn-primary'
|
||||
.message
|
||||
to branch
|
||||
%strong= @ref
|
||||
= link_to "Cancel", @after_edit_path, class: "btn btn-cancel", data: { confirm: leave_edit_message}
|
||||
= hidden_field_tag 'last_commit', @last_commit
|
||||
= hidden_field_tag 'content', '', id: "file-content"
|
||||
= hidden_field_tag 'from_merge_request_id', params[:from_merge_request_id]
|
||||
= render 'projects/commit_button', ref: @ref,
|
||||
cancel_path: @after_edit_path
|
||||
|
||||
:javascript
|
||||
ace.config.set("modePath", gon.relative_url_root + "#{Gitlab::Application.config.assets.prefix}/ace")
|
||||
|
|
|
@ -27,14 +27,9 @@
|
|||
.file-content.code
|
||||
%pre#editor= params[:content]
|
||||
|
||||
.form-actions
|
||||
= hidden_field_tag 'content', '', id: "file-content"
|
||||
.commit-button-annotation
|
||||
= button_tag "Commit changes", class: 'btn commit-btn js-commit-button btn-create'
|
||||
.message
|
||||
to branch
|
||||
%strong= @ref
|
||||
= link_to "Cancel", project_tree_path(@project, @id), class: "btn btn-cancel", data: { confirm: leave_edit_message}
|
||||
= hidden_field_tag 'content', '', id: 'file-content'
|
||||
= render 'projects/commit_button', ref: @ref,
|
||||
cancel_path: project_tree_path(@project, @id)
|
||||
|
||||
:javascript
|
||||
ace.config.set("modePath", gon.relative_url_root + "#{Gitlab::Application.config.assets.prefix}/ace-src-noconflict")
|
||||
|
|
|
@ -30,7 +30,7 @@ Feature: Project Source Browse Files
|
|||
And I edit code
|
||||
And I fill the new file name
|
||||
And I fill the commit message
|
||||
And I click on "Commit changes"
|
||||
And I click on "Commit Changes"
|
||||
Then I am redirected to the new file
|
||||
And I should see its new content
|
||||
|
||||
|
@ -46,7 +46,7 @@ Feature: Project Source Browse Files
|
|||
And I click button "Edit"
|
||||
And I edit code
|
||||
And I fill the commit message
|
||||
And I click on "Commit changes"
|
||||
And I click on "Commit Changes"
|
||||
Then I am redirected to the ".gitignore"
|
||||
And I should see its new content
|
||||
|
||||
|
|
|
@ -69,8 +69,8 @@ class Spinach::Features::ProjectSourceBrowseFiles < Spinach::FeatureSteps
|
|||
click_link 'Diff'
|
||||
end
|
||||
|
||||
step 'I click on "Commit changes"' do
|
||||
click_button 'Commit changes'
|
||||
step 'I click on "Commit Changes"' do
|
||||
click_button 'Commit Changes'
|
||||
end
|
||||
|
||||
step 'I click on "Remove"' do
|
||||
|
|
Loading…
Reference in New Issue