Chris@0
|
1 #--
|
Chris@0
|
2 # Copyright (c) 2004-2006 David Heinemeier Hansson
|
Chris@0
|
3 #
|
Chris@0
|
4 # Permission is hereby granted, free of charge, to any person obtaining
|
Chris@0
|
5 # a copy of this software and associated documentation files (the
|
Chris@0
|
6 # "Software"), to deal in the Software without restriction, including
|
Chris@0
|
7 # without limitation the rights to use, copy, modify, merge, publish,
|
Chris@0
|
8 # distribute, sublicense, and/or sell copies of the Software, and to
|
Chris@0
|
9 # permit persons to whom the Software is furnished to do so, subject to
|
Chris@0
|
10 # the following conditions:
|
Chris@0
|
11 #
|
Chris@0
|
12 # The above copyright notice and this permission notice shall be
|
Chris@0
|
13 # included in all copies or substantial portions of the Software.
|
Chris@0
|
14 #
|
Chris@0
|
15 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
Chris@0
|
16 # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
Chris@0
|
17 # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
Chris@0
|
18 # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
Chris@0
|
19 # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
Chris@0
|
20 # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
Chris@0
|
21 # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
Chris@0
|
22 #++
|
Chris@0
|
23
|
Chris@0
|
24 require 'pagination'
|
Chris@0
|
25 require 'pagination_helper'
|
Chris@0
|
26
|
Chris@0
|
27 ActionController::Base.class_eval do
|
Chris@0
|
28 include ActionController::Pagination
|
Chris@0
|
29 end
|
Chris@0
|
30
|
Chris@0
|
31 ActionView::Base.class_eval do
|
Chris@0
|
32 include ActionView::Helpers::PaginationHelper
|
Chris@0
|
33 end
|