#coding=utf-8

module Mobile
  module Apis
    class Issues< Grape::API
      resources :issues do
        include IssuesHelper

        desc "get special issuse"
        get ':id' do
          user = UserWechat.find_by_openid(params[:openid]).user
          issue = Issue.find params[:id]
          present :data, issue, with: Mobile::Entities::Issue,user: user
          present :status, 0
        end
      end
    end
  end
end
