9
10
11
12
13
14
15
16
17
18
19
20
|
# File 'lib/axlsx_rails/template_handler.rb', line 9
def self.call(template)
"xlsx_author = defined?(xlsx_author).nil? ? nil : xlsx_author;\n" +
"xlsx_created_at = defined?(xlsx_created_at).nil? ? nil : xlsx_created_at;\n" +
"xlsx_use_shared_strings = defined?(xlsx_use_shared_strings).nil? ? nil : xlsx_use_shared_strings;\n" +
"xlsx_package = Axlsx::Package.new(\n" +
":author => xlsx_author,\n" +
":created_at => xlsx_created_at,\n" +
":use_shared_strings => xlsx_use_shared_strings\n" +
");\n" +
template.source +
";\nxlsx_package.to_stream.string;"
end
|