controllers: use template:
rather than file:
to render PDFs
ActionView now throws an error if a relative path is used with `file:`.
This commit is contained in:
parent
185c74d891
commit
3f3d6ae399
5 changed files with 6 additions and 6 deletions
|
@ -121,7 +121,7 @@ class AttestationTemplate < ApplicationRecord
|
|||
def build_pdf(dossier)
|
||||
attestation = render_attributes_for(dossier: dossier)
|
||||
attestation_view = ApplicationController.render(
|
||||
file: 'new_administrateur/attestation_templates/show',
|
||||
template: 'new_administrateur/attestation_templates/show',
|
||||
formats: :pdf,
|
||||
assigns: { attestation: attestation }
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue