|
|
@ -33,8 +33,8 @@ class ExportShixunReportService
|
|
|
|
base_css = %w(app/templates/shared/main.css app/templates/shixun_work/shixun_work.css app/templates/shared/codemirror.css)
|
|
|
|
base_css = %w(app/templates/shared/main.css app/templates/shixun_work/shixun_work.css app/templates/shared/codemirror.css)
|
|
|
|
base_css.each { |css| kit.stylesheets << Rails.root.join(css) }
|
|
|
|
base_css.each { |css| kit.stylesheets << Rails.root.join(css) }
|
|
|
|
|
|
|
|
|
|
|
|
file_name = "#{Rails.root}/files/archiveZip/#{filename}"
|
|
|
|
file = Tempfile.new(filename)
|
|
|
|
kit.to_pdf(file_name)
|
|
|
|
kit.to_pdf(file.path)
|
|
|
|
file
|
|
|
|
file
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|