demarches-normaliennes/app/models/champs/departement_champ.rb
2018-10-23 18:13:44 +02:00

5 lines
188 B
Ruby

class Champs::DepartementChamp < Champs::TextChamp
def self.departements
ApiGeo::API.departements.map { |liste| "#{liste[:code]} - #{liste[:nom]}" }.push('99 - Étranger')
end
end