one if less deep
This commit is contained in:
parent
cd3e645046
commit
92e29c6e13
1 changed files with 6 additions and 8 deletions
|
@ -558,14 +558,12 @@ class TypeDeChamp < ApplicationRecord
|
|||
APIGeoService.departements.map { ["#{_1[:code]} – #{_1[:name]}", _1[:code]] }.sort
|
||||
elsif region?
|
||||
APIGeoService.regions.map { [_1[:name], _1[:code]] }
|
||||
elsif choice_type?
|
||||
if drop_down_list?
|
||||
drop_down_options
|
||||
elsif yes_no?
|
||||
Champs::YesNoChamp.options
|
||||
elsif checkbox?
|
||||
Champs::CheckboxChamp.options
|
||||
end
|
||||
elsif drop_down_list?
|
||||
drop_down_options
|
||||
elsif yes_no?
|
||||
Champs::YesNoChamp.options
|
||||
elsif checkbox?
|
||||
Champs::CheckboxChamp.options
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue