Add screenshot image to pdf export
Some checks failed
/ Run system tests (push) Waiting to run
/ Build, push and deploy image (push) Blocked by required conditions
/ Run tests (push) Has been cancelled

This commit is contained in:
david 2024-11-23 22:05:01 +01:00
parent c36230b8ba
commit fd11eaff33
2 changed files with 6 additions and 1 deletions

View file

@ -98,7 +98,7 @@ module PdfDocuments
def safe_display(value, &block)
return if value.blank?
yield
yield(value)
end
def bold(text)
@ -106,5 +106,9 @@ module PdfDocuments
@prawn_document.text text
end
end
def image(attachable, **args)
@prawn_document.image ActiveStorage::Blob.service.path_for(attachable.key), **args
end
end
end