Commit c2913dc3 authored by James Edwards-Jones's avatar James Edwards-Jones

CSV export issues pluralization

Also fixed @issues_count in email after merge
parent ea7e8eaf
%p{ style: 'font-size:18px; text-align:center; line-height:30px;' } %p{ style: 'font-size:18px; text-align:center; line-height:30px;' }
Your CSV export of #{ @issues_count } issues from project Your CSV export of #{ pluralize(@written_count, 'issue') } from project
%a{ href: project_url(@project), style: "color:#3777b0; text-decoration:none; display:block;" } %a{ href: project_url(@project), style: "color:#3777b0; text-decoration:none; display:block;" }
= @project.full_name = @project.full_name
has been added to this email as an attachment. has been added to this email as an attachment.
......
Your CSV export of <%= @written_count %> issues from project <%= @project.full_name %> (<%= project_url(@project) %>) has been added to this email as an attachment. Your CSV export of <%= pluralize(@written_count, 'issue') %> from project <%= @project.full_name %> (<%= project_url(@project) %>) has been added to this email as an attachment.
<% if @truncated %> <% if @truncated %>
This attachment has been truncated to avoid exceeding a maximum allowed attachment size of 20MB. <%= @written_count %> of <%= @issues_count %> issues have been included. Consider re-exporting with a narrower selection of issues. This attachment has been truncated to avoid exceeding a maximum allowed attachment size of 20MB. <%= @written_count %> of <%= @issues_count %> issues have been included. Consider re-exporting with a narrower selection of issues.
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
.modal-header .modal-header
= icon('check', { class: 'export-checkmark' }) = icon('check', { class: 'export-checkmark' })
%strong %strong
#{cached_issuables_count_for_state(:issues, params[:state])} issues selected #{pluralize(cached_issuables_count_for_state(:issues, params[:state]), 'issue')} selected
.modal-body .modal-body
%div %div
The CSV export will be created in the background. Once finished, it will be sent to The CSV export will be created in the background. Once finished, it will be sent to
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment