demarches-normaliennes/app/serializers/cadastre_serializer.rb

18 lines
284 B
Ruby
Raw Normal View History

2017-10-27 15:36:36 +02:00
class CadastreSerializer < ActiveModel::Serializer
attributes :value, :type_de_champ
def value
object.geometry
end
def type_de_champ
{
id: -1,
libelle: 'cadastre',
type_champ: 'cadastre',
order_place: -1,
descripton: ''
}
end
end