factorize departements and regions options
This commit is contained in:
parent
aa8ce15c2a
commit
08fb49d176
13 changed files with 27 additions and 26 deletions
|
@ -10,7 +10,7 @@ class EditableChamp::DepartementsComponent < EditableChamp::EditableChampBaseCom
|
|||
end
|
||||
|
||||
def options
|
||||
APIGeoService.departements.map { ["#{_1[:code]} – #{_1[:name]}", _1[:code]] }
|
||||
APIGeoService.departement_options
|
||||
end
|
||||
|
||||
def select_options
|
||||
|
|
|
@ -10,7 +10,7 @@ class EditableChamp::RegionsComponent < EditableChamp::EditableChampBaseComponen
|
|||
private
|
||||
|
||||
def options
|
||||
APIGeoService.regions.map { [_1[:name], _1[:code]] }
|
||||
APIGeoService.region_options
|
||||
end
|
||||
|
||||
def select_options
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue