2011-11-16 00:39:16 +00:00
|
|
|
class Locomotive::BasePresenter
|
|
|
|
|
|
|
|
include ActionView::Helpers::SanitizeHelper
|
|
|
|
extend ActionView::Helpers::SanitizeHelper::ClassMethods
|
|
|
|
include ActionView::Helpers::TextHelper
|
|
|
|
include ActionView::Helpers::NumberHelper
|
|
|
|
|
|
|
|
attr_reader :source
|
|
|
|
|
|
|
|
def initialize(object)
|
|
|
|
@source = object
|
|
|
|
end
|
|
|
|
|
2011-11-19 14:47:56 +00:00
|
|
|
def id
|
|
|
|
@source._id.to_s
|
|
|
|
end
|
|
|
|
|
2011-11-16 00:39:16 +00:00
|
|
|
# def as_json(options = {})
|
|
|
|
# @source.as_json(options)
|
|
|
|
# end
|
|
|
|
|
|
|
|
end
|