2016-03-30 17:47:44 +08:00
|
|
|
#coding=utf-8
|
|
|
|
|
|
|
|
module Mobile
|
|
|
|
module Apis
|
|
|
|
class Whomeworks< Grape::API
|
|
|
|
resources :whomeworks do
|
|
|
|
|
|
|
|
desc "get one homework"
|
|
|
|
get ':id' do
|
|
|
|
homework = HomeworkCommon.find params[:id]
|
|
|
|
present :data, homework, with: Mobile::Entities::Whomework
|
|
|
|
present :status, 0
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|