app/models/job/order_processor.rb in artfully_ose-1.2.0.pre.27 vs app/models/job/order_processor.rb in artfully_ose-1.2.0

- old
+ new

@@ -83,11 +83,12 @@ PassMailer.pass_info_for(self.order.person, self.order.organization.email,self.order.passes.collect(&:product)).deliver end end def generate_pdf - pdf_generator = PdfGeneration.new(order) - download_url = pdf_generator.generate - order.pdf = URI.parse(download_url) + pdf = PdfGeneration.new(order).generate + file = Tempfile.new(["#{order.id}", '.pdf']) + file << pdf.force_encoding("UTF-8") + order.pdf = file order.save end end