Permalink
Browse files

Fix Issue 59: Allow for Multiple Themes (thanks @tmilewski)

  • Loading branch information...
1 parent 434de21 commit e6dc0227207e913b7ba8f3ed6823eb0799e7446b @amatsuda amatsuda committed Apr 19, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 lib/kaminari/helpers/tags.rb
@@ -16,11 +16,12 @@ class Tag
def initialize(template, options = {}) #:nodoc:
@template, @options = template, options.dup
@param_name = @options.delete(:param_name)
+ @theme = @options[:theme] ? "#{@options.delete(:theme)}/" : ''
@params = @options[:params] ? template.params.merge(@options.delete :params) : template.params
end
def to_s(locals = {}) #:nodoc:
- @template.render :partial => "kaminari/#{self.class.name.demodulize.underscore}", :locals => @options.merge(locals)
+ @template.render :partial => "kaminari/#{@theme}#{self.class.name.demodulize.underscore}", :locals => @options.merge(locals)
end
def page_url_for(page)

0 comments on commit e6dc022

Please sign in to comment.