2013-12-23 11:48:06 +01:00
|
|
|
module SharedHelper
|
|
|
|
# provide input_html for password autocompletion
|
|
|
|
def autocomplete_flag_to_password_html(password_autocomplete)
|
|
|
|
case password_autocomplete
|
2021-03-01 15:27:26 +01:00
|
|
|
when true then { autocomplete: 'on' }
|
|
|
|
when false then { autocomplete: 'off' }
|
|
|
|
when 'store-only' then { autocomplete: 'off', data: { store: 'on' } }
|
|
|
|
else {}
|
2013-12-23 11:48:06 +01:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|