You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I can't set margin in Controller but can set normally in wicked_pdf.rb in Initializer
header won't show no matter where i set this option config in Controller or wicked_pdf.rb it won't even show in wkhtmltopdf command for example [wicked_pdf]: ["/Users/appleclub/.rbenv/versions/2.5.1/gemsets/leadcombo/bin/wkhtmltopdf", "--enable-local-file-access", "--lowquality", "--margin-top", "0.1", "--margin-bottom", "0.1", "--margin-left", "0.1", "--margin-right", "0.1", "file:////var/folders/h3/p73w345x36v093ff9xwh3zqh0000gn/T/wicked_pdf20231012-58597-1yy4e4p.html", "/var/folders/h3/p73w345x36v093ff9xwh3zqh0000gn/T/wicked_pdf_generated_file20231012-58597-l0ov39.pdf"]
this is what show in rails
Expected or desired behavior
can set margin freely in controller so I can set for multiple pdf not default
header show properly
System specifications
wicked_pdf gem version (output of cat Gemfile.lock | grep wicked_pdf): 2.7.0
wkhtmltopdf version (output of wkhtmltopdf --version): 0.12.6 (with patched qt)
whtmltopdf provider gem and version if one is used:
platform/distribution and version (e.g. Windows 10 / Ubuntu 16.04 / Heroku cedar): Mac OS
class PdfController < ApplicationController
def pdf_detail
id = params["id"].to_i
@lead = CustomerLead.find(id)
response.headers['Content-Disposition'] = "inline; filename=#{@lead.company.name} - #{@lead.full_name}(#{@lead.source_detail}).pdf"
respond_to do |format|
format.html
format.pdf do
render pdf: "pdfdetail",template: 'pdf/pdf_detail.html.erb' , disposition: 'inline' , layout: 'pdf.html.erb'
end
end
end
end
Issue description
There's a lot of issue I've face. for example
[wicked_pdf]: ["/Users/appleclub/.rbenv/versions/2.5.1/gemsets/leadcombo/bin/wkhtmltopdf", "--enable-local-file-access", "--lowquality", "--margin-top", "0.1", "--margin-bottom", "0.1", "--margin-left", "0.1", "--margin-right", "0.1", "file:////var/folders/h3/p73w345x36v093ff9xwh3zqh0000gn/T/wicked_pdf20231012-58597-1yy4e4p.html", "/var/folders/h3/p73w345x36v093ff9xwh3zqh0000gn/T/wicked_pdf_generated_file20231012-58597-l0ov39.pdf"]
this is what show in rails
Expected or desired behavior
System specifications
wicked_pdf gem version (output of
cat Gemfile.lock | grep wicked_pdf
): 2.7.0wkhtmltopdf version (output of
wkhtmltopdf --version
): 0.12.6 (with patched qt)whtmltopdf provider gem and version if one is used:
platform/distribution and version (e.g. Windows 10 / Ubuntu 16.04 / Heroku cedar): Mac OS
wicked_pdf.rb
pdf_controller
app/view/pdf/header.html.erb
The text was updated successfully, but these errors were encountered: