2023-03-02 13:24:24 -05:00
|
|
|
helpers do
|
|
|
|
|
|
|
|
def nullable(value)
|
|
|
|
if (value) and (value != '')
|
|
|
|
return value
|
|
|
|
else
|
|
|
|
return 'N/a'
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
def date_format(date)
|
|
|
|
dt = date.to_datetime
|
|
|
|
return dt.strftime('%B %d, %Y @ %I:%M:%S %p %Z')
|
|
|
|
end
|
|
|
|
|
|
|
|
def date_format_input(date)
|
|
|
|
dt = date.to_datetime
|
|
|
|
return dt.strftime('%Y-%m-%dT%H:%M:%S')
|
|
|
|
end
|
|
|
|
|
2023-03-03 14:19:20 -05:00
|
|
|
def serialize(num)
|
|
|
|
return num
|
|
|
|
end
|
|
|
|
|
2023-03-02 13:24:24 -05:00
|
|
|
end
|