2018-02-13 18:18:20 +01:00
|
|
|
class Champs::CiviliteChamp < Champ
|
2024-04-02 11:04:00 +02:00
|
|
|
validates :value, inclusion: ["M.", "Mme"], allow_nil: true, allow_blank: false, if: :validate_champ_value_or_prefill?
|
2022-12-19 22:00:22 +01:00
|
|
|
|
2024-03-05 17:21:29 +01:00
|
|
|
def legend_label?
|
|
|
|
true
|
|
|
|
end
|
|
|
|
|
2020-03-23 16:50:59 +01:00
|
|
|
def html_label?
|
|
|
|
false
|
|
|
|
end
|
2023-02-27 15:33:25 +01:00
|
|
|
|
|
|
|
def female_input_id
|
|
|
|
"#{input_id}-female"
|
|
|
|
end
|
|
|
|
|
|
|
|
def male_input_id
|
|
|
|
"#{input_id}-male"
|
|
|
|
end
|
|
|
|
|
|
|
|
def focusable_input_id
|
|
|
|
female_input_id
|
|
|
|
end
|
2018-02-13 18:18:20 +01:00
|
|
|
end
|