socialforge/app/api/mobile/apis/journal_for_messages.rb

20 lines
449 B
Ruby

#coding=utf-8
module Mobile
module Apis
class JournalForMessages< Grape::API
resources :journal_for_messages do
desc "get special journal"
get ':id' do
authenticate!
user = current_user
jour = JournalsForMessage.find params[:id]
present :data, jour, with: Mobile::Entities::Jours,user: user
present :status, 0
end
end
end
end
end