Class: Comment
- Inherits:
-
Flareshow::Resource
- Object
- Flareshow::Resource
- Comment
- Extended by:
- Flareshow::Searchable
- Defined in:
- lib/comment.rb
Instance Method Summary collapse
-
#permalink(mobile = false) ⇒ Object
permalink to this comment.
-
#post ⇒ Object
get the post for this comment.
-
#user ⇒ Object
user for this post.
Methods included from Flareshow::Searchable
Methods inherited from Flareshow::Resource
#cache, cache_response, #changes, create, default_params, #destroy, #destroyed?, find, first, #get, get_from_cache, #id, #initialize, list_cache, #method_missing, #method_name, #refresh, #resource_key, resource_key, #save, #set, store, #update
Constructor Details
This class inherits a constructor from Flareshow::Resource
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Flareshow::Resource
Instance Method Details
#permalink(mobile = false) ⇒ Object
permalink to this comment
9 10 11 12 13 14 15 |
# File 'lib/comment.rb', line 9 def permalink(mobile=false) if mobile "http://#{Flareshow::Service.server.host}/#{Flareshow::Service.server.domain}/shareflow/mobile/post/#{reply_to}" else "http://#{Flareshow::Service.server.host}/#{Flareshow::Service.server.domain}/shareflow/p/#{reply_to}?comment_id#{id}" end end |