2010-06-03 15:32:40 +00:00
|
|
|
module Models
|
|
|
|
module Extensions
|
|
|
|
module Page
|
2010-06-01 00:06:46 +00:00
|
|
|
module Render
|
|
|
|
|
|
|
|
def render(context)
|
|
|
|
self.template.render(context)
|
|
|
|
|
|
|
|
if self.layout
|
|
|
|
self.layout.template.render(context)
|
|
|
|
else
|
|
|
|
::Liquid::Template.parse("{{ content_for_layout }}").render(context)
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
2010-06-03 15:32:40 +00:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
2010-06-01 00:06:46 +00:00
|
|
|
end
|