Merge pull request #2902 from tchak/expose-commentaire-attachement-on-api

Expose commentaire attachement on api
This commit is contained in:
gregoirenovel 2018-10-30 17:37:31 +01:00 committed by GitHub
commit 3fc462fb89
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,5 +1,10 @@
class CommentaireSerializer < ActiveModel::Serializer
attributes :email,
:body,
:created_at
:created_at,
:attachment
def attachment
object.file_url
end
end