summaryrefslogtreecommitdiffhomepage
path: root/lib/axlsx/workbook/workbook.rb
diff options
context:
space:
mode:
authorRandy Morgan <[email protected]>2012-12-04 09:53:38 +0900
committerRandy Morgan <[email protected]>2012-12-04 09:53:38 +0900
commit979523372fb05a7c3da574759a13e82a491bf94f (patch)
tree56f6fa524614544b95194a74d8cb8f3e19211276 /lib/axlsx/workbook/workbook.rb
parent4fd9cc1cdeaec83643e1044d4f1f62f6d6c14d87 (diff)
downloadcaxlsx-979523372fb05a7c3da574759a13e82a491bf94f.tar.gz
caxlsx-979523372fb05a7c3da574759a13e82a491bf94f.zip
Moved defined names in workbook to be serialized before pivot tables
This fixes https://github.com/randym/axlsx/issues/150
Diffstat (limited to 'lib/axlsx/workbook/workbook.rb')
-rw-r--r--lib/axlsx/workbook/workbook.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/axlsx/workbook/workbook.rb b/lib/axlsx/workbook/workbook.rb
index c1d304a4..54dd9df1 100644
--- a/lib/axlsx/workbook/workbook.rb
+++ b/lib/axlsx/workbook/workbook.rb
@@ -313,6 +313,7 @@ require 'axlsx/workbook/worksheet/selection.rb'
end
end
str << '</sheets>'
+ defined_names.to_xml_string(str)
unless pivot_tables.empty?
str << '<pivotCaches>'
pivot_tables.each_with_index do |pivot_table, index|
@@ -321,7 +322,6 @@ require 'axlsx/workbook/worksheet/selection.rb'
end
str << '</pivotCaches>'
end
- defined_names.to_xml_string(str)
str << '</workbook>'
end