attestation_template v2: show
This commit is contained in:
parent
f6b10731d3
commit
f6001c8eae
11 changed files with 241 additions and 0 deletions
|
@ -0,0 +1,17 @@
|
|||
module Administrateurs
|
||||
class AttestationTemplateV2sController < AdministrateurController
|
||||
before_action :retrieve_procedure, :retrieve_attestation_template
|
||||
|
||||
def show
|
||||
json_body = @attestation_template.json_body&.deep_symbolize_keys
|
||||
@body = TiptapService.to_html(json_body, {})
|
||||
|
||||
render layout: 'attestation'
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def retrieve_attestation_template
|
||||
@attestation_template = @procedure.attestation_template || @procedure.build_attestation_template
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue