mirror of
https://github.com/meineerde/redmine.git
synced 2026-04-01 21:51:14 +00:00
Fixed CSV content for parent issue column (#13608).
git-svn-id: http://svn.redmine.org/redmine/trunk@13555 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
8c6c38a006
commit
db63f5a925
@ -128,6 +128,8 @@ module QueriesHelper
|
|||||||
when 'IssueRelation'
|
when 'IssueRelation'
|
||||||
other = value.other_issue(issue)
|
other = value.other_issue(issue)
|
||||||
l(value.label_for(issue)) + " ##{other.id}"
|
l(value.label_for(issue)) + " ##{other.id}"
|
||||||
|
when 'Issue'
|
||||||
|
value.id
|
||||||
else
|
else
|
||||||
value
|
value
|
||||||
end
|
end
|
||||||
|
|||||||
@ -472,6 +472,18 @@ class IssuesControllerTest < ActionController::TestCase
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def test_index_csv_should_fill_parent_column_with_parent_id
|
||||||
|
Issue.delete_all
|
||||||
|
parent = Issue.generate!
|
||||||
|
child = Issue.generate!(:parent_issue_id => parent.id)
|
||||||
|
|
||||||
|
with_settings :default_language => 'en' do
|
||||||
|
get :index, :format => 'csv', :c => %w(parent)
|
||||||
|
end
|
||||||
|
lines = response.body.split
|
||||||
|
assert_include "#{child.id},#{parent.id}", lines
|
||||||
|
end
|
||||||
|
|
||||||
def test_index_csv_big_5
|
def test_index_csv_big_5
|
||||||
with_settings :default_language => "zh-TW" do
|
with_settings :default_language => "zh-TW" do
|
||||||
str_utf8 = "\xe4\xb8\x80\xe6\x9c\x88".force_encoding('UTF-8')
|
str_utf8 = "\xe4\xb8\x80\xe6\x9c\x88".force_encoding('UTF-8')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user