fix replace default value variable

pull/109/head
DocuSeal 2 years ago committed by Pete Matsyburka
parent c227a1988a
commit 0025928a35

@ -105,12 +105,16 @@ module Submitters
when 'time'
if with_time
I18n.l(Time.current.in_time_zone(template.account.timezone), format: :long, locale: template.account.locale)
else
e
end
when 'date'
I18n.l(Time.current.in_time_zone(template.account.timezone).to_date) if with_time
when 'name', 'full_name'
"#{attrs['first_name']} #{attrs['last_name']}".strip.presence || e
when 'role', 'email', 'phone'
if with_time
I18n.l(Time.current.in_time_zone(template.account.timezone).to_date)
else
e
end
when 'role', 'email', 'phone', 'name'
attrs[key] || e
else
e

Loading…
Cancel
Save