diff options
| author | Geremia Taglialatela <[email protected]> | 2023-04-08 11:53:12 +0200 |
|---|---|---|
| committer | Geremia Taglialatela <[email protected]> | 2023-04-08 11:53:12 +0200 |
| commit | 55526805cf28cc91a22df5811b26cd23bdefa8d3 (patch) | |
| tree | 2cbc6403b385078b0ed5e275c49f0c60522bdd16 /lib/axlsx/workbook/worksheet/pivot_table_cache_definition.rb | |
| parent | acf00d356494ef504c3de0e4a0db6b25f2bd7636 (diff) | |
| download | caxlsx-55526805cf28cc91a22df5811b26cd23bdefa8d3.tar.gz caxlsx-55526805cf28cc91a22df5811b26cd23bdefa8d3.zip | |
Fix space-related offenses
- Layout/SpaceAfterComma
- Layout/SpaceAroundEqualsInParameterDefault
- Layout/SpaceAroundOperators
- Layout/SpaceBeforeBlockBraces
- Layout/SpaceInsideBlockBraces
- Layout/SpaceInsideHashLiteralBraces
- Layout/SpaceInsideParens
Diffstat (limited to 'lib/axlsx/workbook/worksheet/pivot_table_cache_definition.rb')
| -rw-r--r-- | lib/axlsx/workbook/worksheet/pivot_table_cache_definition.rb | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/lib/axlsx/workbook/worksheet/pivot_table_cache_definition.rb b/lib/axlsx/workbook/worksheet/pivot_table_cache_definition.rb index 2c7c05e4..8813c84b 100644 --- a/lib/axlsx/workbook/worksheet/pivot_table_cache_definition.rb +++ b/lib/axlsx/workbook/worksheet/pivot_table_cache_definition.rb @@ -24,7 +24,7 @@ module Axlsx # The part name for this table # @return [String] def pn - "#{PIVOT_TABLE_CACHE_DEFINITION_PN % (index+1)}" + "#{PIVOT_TABLE_CACHE_DEFINITION_PN % (index + 1)}" end # The identifier for this cache @@ -46,17 +46,17 @@ module Axlsx def to_xml_string(str = '') str << '<?xml version="1.0" encoding="UTF-8"?>' str << ('<pivotCacheDefinition xmlns="' << XML_NS << '" xmlns:r="' << XML_NS_R << '" invalid="1" refreshOnLoad="1" recordCount="0">') - str << '<cacheSource type="worksheet">' - str << ( '<worksheetSource ref="' << pivot_table.range << '" sheet="' << pivot_table.data_sheet.name << '"/>') - str << '</cacheSource>' - str << ( '<cacheFields count="' << pivot_table.header_cells_count.to_s << '">') + str << '<cacheSource type="worksheet">' + str << ('<worksheetSource ref="' << pivot_table.range << '" sheet="' << pivot_table.data_sheet.name << '"/>') + str << '</cacheSource>' + str << ('<cacheFields count="' << pivot_table.header_cells_count.to_s << '">') pivot_table.header_cells.each do |cell| - str << ( '<cacheField name="' << cell.clean_value << '" numFmtId="0">') + str << ('<cacheField name="' << cell.clean_value << '" numFmtId="0">') str << '<sharedItems count="0">' str << '</sharedItems>' - str << '</cacheField>' + str << '</cacheField>' end - str << '</cacheFields>' + str << '</cacheFields>' str << '</pivotCacheDefinition>' end end |
