summaryrefslogtreecommitdiff
path: root/app/views/projects/commit
diff options
context:
space:
mode:
authorBob Van Landuyt <bob@gitlab.com>2017-06-09 15:08:39 +0200
committerBob Van Landuyt <bob@gitlab.com>2017-06-15 14:47:04 +0200
commit49bef99c5fe2a5d856e060ca71264e7bc8d3c08d (patch)
tree93156a2e863b161bd179e9e9219384072e1154fa /app/views/projects/commit
parentb5a14e7404fc794a1959db1e4983ca7421c42791 (diff)
downloadgitlab-ce-49bef99c5fe2a5d856e060ca71264e7bc8d3c08d.tar.gz
Add a bunch of missing translations
Diffstat (limited to 'app/views/projects/commit')
-rw-r--r--app/views/projects/commit/_change.html.haml17
1 files changed, 9 insertions, 8 deletions
diff --git a/app/views/projects/commit/_change.html.haml b/app/views/projects/commit/_change.html.haml
index 281d823da52..b8d201a65c6 100644
--- a/app/views/projects/commit/_change.html.haml
+++ b/app/views/projects/commit/_change.html.haml
@@ -1,35 +1,36 @@
- case type.to_s
- when 'revert'
- - label = 'Revert'
- - branch_label = 'Revert in branch'
+ - label = n_('ChangeTypeAction|Revert')
+ - branch_label = _('ChangeTypeActionLabel|Revert in branch')
- when 'cherry-pick'
- - label = 'Cherry-pick'
- - branch_label = 'Pick into branch'
+ - label = n_('ChangeTypeAction|Cherry-pick')
+ - branch_label = n_('ChangeTypeActionLabel|Pick into branch')
+- change_type = commit.change_type_title(current_user)
.modal{ id: "modal-#{type}-commit" }
.modal-dialog
.modal-content
.modal-header
%a.close{ href: "#", "data-dismiss" => "modal" } ×
- %h3.page-title== #{label} this #{commit.change_type_title(current_user)}
+ %h3.page-title== _("%{action} this %{change_type}")
.modal-body
= form_tag [type.underscore, @project.namespace.becomes(Namespace), @project, commit], method: :post, remote: false, class: "form-horizontal js-#{type}-form js-requires-input" do
.form-group.branch
= label_tag 'start_branch', branch_label, class: 'control-label'
.col-sm-10
= hidden_field_tag :start_branch, @project.default_branch, id: 'start_branch'
- = dropdown_tag(@project.default_branch, options: { title: "Switch branch", filter: true, placeholder: "Search branches", toggle_class: 'js-project-refs-dropdown dynamic', dropdown_class: 'dropdown-menu-selectable', data: { field_name: "start_branch", selected: @project.default_branch, start_branch: @project.default_branch, refs_url: namespace_project_branches_path(@project.namespace, @project), submit_form_on_click: false } })
+ = dropdown_tag(@project.default_branch, options: { title: n_("BranchSwitcherTitle|Switch branch"), filter: true, placeholder: n_("BranchSwitcherPlaceholder|Search branches"), toggle_class: 'js-project-refs-dropdown dynamic', dropdown_class: 'dropdown-menu-selectable', data: { field_name: "start_branch", selected: @project.default_branch, start_branch: @project.default_branch, refs_url: namespace_project_branches_path(@project.namespace, @project), submit_form_on_click: false } })
- if can?(current_user, :push_code, @project)
.checkbox
= label_tag do
= check_box_tag 'create_merge_request', 1, true, class: 'js-create-merge-request', id: nil
- Start a <strong>new merge request</strong> with these changes
+ #{ _('Start a <strong>new merge request</strong> with these changes').html_safe }
- else
= hidden_field_tag 'create_merge_request', 1, id: nil
.form-actions
= submit_tag label, class: 'btn btn-create'
- = link_to "Cancel", '#', class: "btn btn-cancel", "data-dismiss" => "modal"
+ = link_to _("Cancel"), '#', class: "btn btn-cancel", "data-dismiss" => "modal"
- unless can?(current_user, :push_code, @project)
.inline.prepend-left-10