rails_admin 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.md +60 -51
- data/Rakefile +0 -0
- data/app/assets/javascripts/rails_admin/ra.widgets.coffee +12 -11
- data/app/assets/javascripts/rails_admin/ui.js.coffee +0 -3
- data/app/helpers/rails_admin/application_helper.rb +2 -2
- data/app/helpers/rails_admin/form_builder.rb +9 -5
- data/lib/rails_admin/adapters/active_record.rb +3 -1
- data/lib/rails_admin/adapters/mongoid.rb +5 -3
- data/lib/rails_admin/config/actions/show_in_app.rb +0 -1
- data/lib/rails_admin/config/fields/types/hidden.rb +9 -3
- data/lib/rails_admin/extensions/history/history.rb +4 -3
- data/lib/rails_admin/extensions/paper_trail/auditing_adapter.rb +2 -2
- data/lib/rails_admin/version.rb +1 -1
- data/spec/dummy_app/app/active_record/ball.rb +1 -0
- data/spec/dummy_app/app/active_record/category.rb +2 -0
- data/spec/dummy_app/app/active_record/cms/basic_page.rb +2 -0
- data/spec/dummy_app/app/active_record/comment.rb +2 -0
- data/spec/dummy_app/app/active_record/division.rb +5 -2
- data/spec/dummy_app/app/active_record/draft.rb +5 -3
- data/spec/dummy_app/app/active_record/fan.rb +2 -0
- data/spec/dummy_app/app/active_record/league.rb +3 -1
- data/spec/dummy_app/app/active_record/nested_field_test.rb +2 -1
- data/spec/dummy_app/app/active_record/player.rb +7 -7
- data/spec/dummy_app/app/active_record/team.rb +7 -5
- data/spec/dummy_app/app/active_record/user.rb +1 -1
- data/spec/dummy_app/app/mongoid/ball.rb +2 -0
- data/spec/dummy_app/app/mongoid/category.rb +2 -0
- data/spec/dummy_app/app/mongoid/cms/basic_page.rb +2 -0
- data/spec/dummy_app/app/mongoid/comment.rb +2 -0
- data/spec/dummy_app/app/mongoid/division.rb +3 -0
- data/spec/dummy_app/app/mongoid/draft.rb +2 -0
- data/spec/dummy_app/app/mongoid/fan.rb +2 -0
- data/spec/dummy_app/app/mongoid/league.rb +2 -0
- data/spec/dummy_app/app/mongoid/nested_field_test.rb +2 -2
- data/spec/dummy_app/app/mongoid/player.rb +3 -1
- data/spec/dummy_app/app/mongoid/team.rb +3 -1
- data/spec/dummy_app/app/mongoid/user.rb +2 -0
- data/spec/dummy_app/config/application.rb +1 -1
- data/spec/dummy_app/config/initializers/rails_admin.rb +0 -1
- data/spec/dummy_app/db/test.sqlite3 +0 -0
- data/spec/dummy_app/log/test.log +54065 -0
- data/spec/integration/history/rails_admin_history_spec.rb +17 -0
- data/spec/integration/rails_admin_spec.rb +13 -2
- data/spec/unit/abstract_model_spec.rb +17 -0
- metadata +6 -8
data/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# RailsAdmin [][travis] [][gemnasium] [][travis] [][gemnasium] [][pledgie]
|
|
2
2
|
RailsAdmin is a Rails engine that provides an easy-to-use interface for managing your data.
|
|
3
3
|
|
|
4
4
|
[travis]: http://travis-ci.org/sferik/rails_admin
|
|
@@ -18,7 +18,7 @@ Hoeven][plukevdh], and [Rein Henrichs][reinh].
|
|
|
18
18
|
[plukevdh]: https://github.com/plukevdh
|
|
19
19
|
[reinh]: https://github.com/reinh
|
|
20
20
|
|
|
21
|
-
##
|
|
21
|
+
## Features
|
|
22
22
|
|
|
23
23
|
* Display database tables
|
|
24
24
|
* Create new data
|
|
@@ -35,14 +35,14 @@ Hoeven][plukevdh], and [Rein Henrichs][reinh].
|
|
|
35
35
|
* ActiveRecord
|
|
36
36
|
* Mongoid [new]
|
|
37
37
|
|
|
38
|
-
##
|
|
38
|
+
## Demo
|
|
39
39
|
|
|
40
40
|
Take RailsAdmin for a [test drive][demo] with sample data. ([Source code.][dummy_app])
|
|
41
41
|
|
|
42
42
|
[demo]: http://rails-admin-tb.herokuapp.com/
|
|
43
43
|
[dummy_app]: https://github.com/bbenezech/dummy_app
|
|
44
44
|
|
|
45
|
-
##
|
|
45
|
+
## Installation
|
|
46
46
|
In your `Gemfile`, add the following dependencies:
|
|
47
47
|
|
|
48
48
|
gem 'fastercsv' # Only required on Ruby 1.8 and below
|
|
@@ -72,7 +72,7 @@ Optionally, you may wish to set up [Cancan](https://github.com/ryanb/cancan),
|
|
|
72
72
|
|
|
73
73
|
More on that in the [Wiki](https://github.com/sferik/rails_admin/wiki)
|
|
74
74
|
|
|
75
|
-
##
|
|
75
|
+
## Usage
|
|
76
76
|
Start the server:
|
|
77
77
|
|
|
78
78
|
$ rails server
|
|
@@ -80,63 +80,79 @@ Start the server:
|
|
|
80
80
|
You should now be able to administer your site at
|
|
81
81
|
[http://localhost:3000/admin](http://localhost:3000/admin).
|
|
82
82
|
|
|
83
|
-
##
|
|
83
|
+
## Configuration
|
|
84
84
|
|
|
85
85
|
All configuration documentation has moved to the wiki: https://github.com/sferik/rails_admin/wiki
|
|
86
86
|
|
|
87
|
-
##
|
|
88
|
-
|
|
87
|
+
## Screenshots
|
|
88
|
+

|
|
89
|
+

|
|
90
|
+

|
|
91
|
+

|
|
92
|
+

|
|
93
|
+
|
|
94
|
+
## Support
|
|
95
|
+
If you have a question, please check this README, the wiki, and the [list of
|
|
96
|
+
known issues][troubleshoot].
|
|
89
97
|
|
|
90
|
-
|
|
98
|
+
[troubleshoot]: https://github.com/sferik/rails_admin/wiki/Troubleshoot
|
|
91
99
|
|
|
92
100
|
If you still have a question, you can ask the [official RailsAdmin mailing
|
|
93
|
-
list]
|
|
94
|
-
|
|
95
|
-
|
|
101
|
+
list][list].
|
|
102
|
+
|
|
103
|
+
[list]: http://groups.google.com/group/rails_admin
|
|
96
104
|
|
|
97
|
-
If you think you found a bug in RailsAdmin, you can [submit an
|
|
98
|
-
issue](https://github.com/sferik/rails_admin#issues).
|
|
99
|
-
No feature requests or questions please (the mailing list is
|
|
100
|
-
active and is the preferred venue for feature requests and questions).
|
|
105
|
+
If you think you found a bug in RailsAdmin, you can [submit an issue][issues].
|
|
101
106
|
|
|
102
|
-
##
|
|
103
|
-
In the spirit of [free software]
|
|
104
|
-
|
|
107
|
+
## Contributing
|
|
108
|
+
In the spirit of [free software][free-sw], **everyone** is encouraged to help
|
|
109
|
+
improve this project.
|
|
110
|
+
|
|
111
|
+
[free-sw]: http://www.fsf.org/licensing/essays/free-sw.html
|
|
105
112
|
|
|
106
113
|
Here are some ways *you* can contribute:
|
|
107
114
|
|
|
108
115
|
* by using alpha, beta, and prerelease versions
|
|
109
116
|
* by reporting bugs
|
|
110
117
|
* by suggesting new features
|
|
111
|
-
* by [translating to a new language](https://github.com/sferik/rails_admin/wiki/Translations)
|
|
112
118
|
* by writing or editing documentation
|
|
113
119
|
* by writing specifications
|
|
114
|
-
* by writing code (**no patch is too small**: fix typos, add comments, clean up
|
|
120
|
+
* by writing code (**no patch is too small**: fix typos, add comments, clean up
|
|
121
|
+
inconsistent whitespace)
|
|
115
122
|
* by refactoring code
|
|
116
|
-
* by
|
|
123
|
+
* by fixing [issues][]
|
|
117
124
|
* by reviewing patches
|
|
118
|
-
* [financially]
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
bug report
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
125
|
+
* [financially][pledgie]
|
|
126
|
+
|
|
127
|
+
[issues]: https://github.com/sferik/rails_admin/issues
|
|
128
|
+
|
|
129
|
+
## Submitting an Issue
|
|
130
|
+
We use the [GitHub issue tracker][issues] to track bugs and features. Before
|
|
131
|
+
submitting a bug report or feature request, check to make sure it hasn't
|
|
132
|
+
already been submitted. When submitting a bug report, please include a [Gist][]
|
|
133
|
+
that includes a stack trace and any details that may be necessary to reproduce
|
|
134
|
+
the bug, including your gem version, Ruby version, and operating system.
|
|
135
|
+
Ideally, a bug report should include a pull request with failing specs.
|
|
136
|
+
|
|
137
|
+
[gist]: https://gist.github.com/
|
|
138
|
+
|
|
139
|
+
## Submitting a Pull Request
|
|
140
|
+
1. [Fork the repository.][fork]
|
|
141
|
+
2. [Create a topic branch.][branch]
|
|
142
|
+
3. Add specs for your unimplemented feature or bug fix.
|
|
143
|
+
4. Run `bundle exec rake spec`. If your specs pass, return to step 3.
|
|
144
|
+
5. Implement your feature or bug fix.
|
|
145
|
+
6. Run `bundle exec rake spec`. If your specs fail, return to step 5.
|
|
146
|
+
7. Run `open coverage/index.html`. If your changes are not completely covered
|
|
147
|
+
by your tests, return to step 3.
|
|
148
|
+
8. Add, commit, and push your changes.
|
|
149
|
+
9. [Submit a pull request.][pr]
|
|
150
|
+
|
|
151
|
+
[fork]: http://help.github.com/fork-a-repo/
|
|
152
|
+
[branch]: http://learn.github.com/p/branching.html
|
|
153
|
+
[pr]: http://help.github.com/send-pull-requests/
|
|
154
|
+
|
|
155
|
+
## Supported Ruby Versions
|
|
140
156
|
This library aims to support and is [tested against][travis] the following Ruby implementations:
|
|
141
157
|
|
|
142
158
|
* Ruby 1.8.7
|
|
@@ -147,10 +163,3 @@ This library aims to support and is [tested against][travis] the following Ruby
|
|
|
147
163
|
|
|
148
164
|
[rubinius]: http://rubini.us/
|
|
149
165
|
[jruby]: http://jruby.org/
|
|
150
|
-
|
|
151
|
-
## <a name="screenshots"></a>Screenshots
|
|
152
|
-

|
|
153
|
-

|
|
154
|
-

|
|
155
|
-

|
|
156
|
-

|
data/Rakefile
CHANGED
|
File without changes
|
|
@@ -4,7 +4,7 @@ $(document).live 'rails_admin.dom_ready', ->
|
|
|
4
4
|
|
|
5
5
|
# colorpicker
|
|
6
6
|
|
|
7
|
-
$('[data-color]').each ->
|
|
7
|
+
$('form [data-color]').each ->
|
|
8
8
|
that = this
|
|
9
9
|
$(this).ColorPicker
|
|
10
10
|
color: $(that).val()
|
|
@@ -20,24 +20,24 @@ $(document).live 'rails_admin.dom_ready', ->
|
|
|
20
20
|
|
|
21
21
|
# datetime
|
|
22
22
|
|
|
23
|
-
$('[data-datetimepicker]').each ->
|
|
23
|
+
$('form [data-datetimepicker]').each ->
|
|
24
24
|
$(this).datetimepicker $(this).data('options')
|
|
25
25
|
|
|
26
26
|
# enumeration
|
|
27
27
|
|
|
28
|
-
$('[data-enumeration]').each ->
|
|
28
|
+
$('form [data-enumeration]').each ->
|
|
29
29
|
$(this).filteringSelect $(this).data('options')
|
|
30
30
|
|
|
31
31
|
# fileupload
|
|
32
32
|
|
|
33
|
-
$('[data-fileupload]').each ->
|
|
33
|
+
$('form [data-fileupload]').each ->
|
|
34
34
|
input = this
|
|
35
35
|
$(this).find(".delete input[type='checkbox']").live 'click', ->
|
|
36
36
|
$(input).children('.toggle').toggle('slow')
|
|
37
37
|
|
|
38
38
|
# filtering-multiselect
|
|
39
39
|
|
|
40
|
-
$('[data-filteringmultiselect]').each ->
|
|
40
|
+
$('form [data-filteringmultiselect]').each ->
|
|
41
41
|
$(this).filteringMultiselect $(this).data('options')
|
|
42
42
|
if $(this).parents("#modal").length # hide link if we already are inside a dialog (endless issues on nested dialogs with JS)
|
|
43
43
|
$(this).parents('.control-group').find('.btn').remove()
|
|
@@ -46,7 +46,7 @@ $(document).live 'rails_admin.dom_ready', ->
|
|
|
46
46
|
|
|
47
47
|
# filtering-select
|
|
48
48
|
|
|
49
|
-
$('[data-filteringselect]').each ->
|
|
49
|
+
$('form [data-filteringselect]').each ->
|
|
50
50
|
$(this).filteringSelect $(this).data('options')
|
|
51
51
|
if $(this).parents("#modal").length # hide link if we already are inside a dialog (endless issues on nested dialogs with JS)
|
|
52
52
|
$(this).parents('.control-group').find('.btn').remove()
|
|
@@ -55,7 +55,7 @@ $(document).live 'rails_admin.dom_ready', ->
|
|
|
55
55
|
|
|
56
56
|
# nested-many
|
|
57
57
|
|
|
58
|
-
$('[data-nestedmany]').each ->
|
|
58
|
+
$('form [data-nestedmany]').each ->
|
|
59
59
|
field = $(this).parents('.control-group').first()
|
|
60
60
|
nav = field.find('> .controls > .nav')
|
|
61
61
|
content = field.find('> .tab-content')
|
|
@@ -81,7 +81,7 @@ $(document).live 'rails_admin.dom_ready', ->
|
|
|
81
81
|
|
|
82
82
|
# nested-one
|
|
83
83
|
|
|
84
|
-
$('[data-nestedone]').each ->
|
|
84
|
+
$('form [data-nestedone]').each ->
|
|
85
85
|
field = $(this).parents('.control-group').first()
|
|
86
86
|
nav = field.find("> .controls > .nav")
|
|
87
87
|
content = field.find("> .tab-content")
|
|
@@ -100,7 +100,7 @@ $(document).live 'rails_admin.dom_ready', ->
|
|
|
100
100
|
|
|
101
101
|
# polymorphic-association
|
|
102
102
|
|
|
103
|
-
$('[data-polymorphic]').each ->
|
|
103
|
+
$('form [data-polymorphic]').each ->
|
|
104
104
|
type_select = $(this)
|
|
105
105
|
field = type_select.parents('.control-group').first()
|
|
106
106
|
object_select = field.find('select').last()
|
|
@@ -124,11 +124,12 @@ $(document).live 'rails_admin.dom_ready', ->
|
|
|
124
124
|
|
|
125
125
|
# ckeditor
|
|
126
126
|
|
|
127
|
-
$('[data-richtext=ckeditor]').each ->
|
|
127
|
+
$('form [data-richtext=ckeditor]').not('.ckeditored').each ->
|
|
128
128
|
window.CKEDITOR_BASEPATH = '/assets/ckeditor/'
|
|
129
129
|
options = $(this).data('options')
|
|
130
130
|
if not window.CKEDITOR
|
|
131
131
|
$(window.document).append('<script src="' + options['jspath'] + '"><\/script>')
|
|
132
132
|
if instance = window.CKEDITOR.instances[this.id]
|
|
133
|
-
|
|
133
|
+
instance.destroy(true)
|
|
134
134
|
window.CKEDITOR.replace(this, options['options'])
|
|
135
|
+
$(this).addClass('ckeditored')
|
|
@@ -96,8 +96,8 @@ module RailsAdmin
|
|
|
96
96
|
actions.map do |action|
|
|
97
97
|
wording = wording_for(:menu, action)
|
|
98
98
|
%{
|
|
99
|
-
<li
|
|
100
|
-
<a class="pjax" href="#{url_for({ :action => action.action_name, :controller => 'rails_admin/main', :model_name => abstract_model.try(:to_param), :id => (object.try(:persisted?) && object.try(:id) || nil) })}">
|
|
99
|
+
<li title="#{wording if only_icon}" rel="#{'tooltip' if only_icon}" class="icon #{action.key}_#{parent}_link #{'active' if current_action?(action)}">
|
|
100
|
+
<a class="#{action.key == :show_in_app ? '' : 'pjax'}" href="#{url_for({ :action => action.action_name, :controller => 'rails_admin/main', :model_name => abstract_model.try(:to_param), :id => (object.try(:persisted?) && object.try(:id) || nil) })}">
|
|
101
101
|
<i class="#{action.link_icon}"></i>
|
|
102
102
|
<span#{only_icon ? " style='display:none'" : ""}>#{wording}</span>
|
|
103
103
|
</a>
|
|
@@ -41,12 +41,16 @@ module RailsAdmin
|
|
|
41
41
|
end
|
|
42
42
|
|
|
43
43
|
def field_wrapper_for field, nested_in
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
44
|
+
if field.label
|
|
45
|
+
# do not show nested field if the target is the origin
|
|
46
|
+
unless field.inverse_of.presence && field.inverse_of == nested_in
|
|
47
|
+
@template.content_tag(:div, :class => "control-group #{field.type_css_class} #{field.css_class} #{'error' if field.errors.present?}", :id => "#{dom_id(field)}_field") do
|
|
48
|
+
label(field.method_name, field.label, :class => 'control-label') +
|
|
49
|
+
(field.nested_form ? field_for(field) : input_for(field))
|
|
50
|
+
end
|
|
49
51
|
end
|
|
52
|
+
else
|
|
53
|
+
(field.nested_form ? field_for(field) : input_for(field))
|
|
50
54
|
end
|
|
51
55
|
end
|
|
52
56
|
|
|
@@ -35,7 +35,9 @@ module RailsAdmin
|
|
|
35
35
|
scope = scope.where(model.primary_key => options[:bulk_ids]) if options[:bulk_ids]
|
|
36
36
|
scope = scope.where(query_conditions(options[:query])) if options[:query]
|
|
37
37
|
scope = scope.where(filter_conditions(options[:filters])) if options[:filters]
|
|
38
|
-
|
|
38
|
+
if options[:page] && options[:per]
|
|
39
|
+
scope = scope.send(Kaminari.config.page_method_name, options[:page]).per(options[:per])
|
|
40
|
+
end
|
|
39
41
|
scope = scope.reorder("#{options[:sort]} #{options[:sort_reverse] ? 'asc' : 'desc'}") if options[:sort]
|
|
40
42
|
scope
|
|
41
43
|
end
|
|
@@ -35,11 +35,13 @@ module RailsAdmin
|
|
|
35
35
|
scope = scope.any_in(:_id => options[:bulk_ids]) if options[:bulk_ids]
|
|
36
36
|
scope = scope.where(query_conditions(options[:query])) if options[:query]
|
|
37
37
|
scope = scope.where(filter_conditions(options[:filters])) if options[:filters]
|
|
38
|
-
|
|
38
|
+
if options[:page] && options[:per]
|
|
39
|
+
scope = scope.send(Kaminari.config.page_method_name, options[:page]).per(options[:per])
|
|
40
|
+
end
|
|
39
41
|
scope = sort_by(options, scope) if options[:sort]
|
|
40
42
|
scope
|
|
41
43
|
end
|
|
42
|
-
|
|
44
|
+
|
|
43
45
|
def count(options = {},scope=nil)
|
|
44
46
|
all(options.merge({:limit => false, :page => false}), scope).count
|
|
45
47
|
end
|
|
@@ -317,7 +319,7 @@ module RailsAdmin
|
|
|
317
319
|
association.foreign_key.to_sym rescue nil
|
|
318
320
|
end
|
|
319
321
|
end
|
|
320
|
-
|
|
322
|
+
|
|
321
323
|
def association_type_lookup(macro)
|
|
322
324
|
case macro.to_sym
|
|
323
325
|
when :belongs_to, :referenced_in, :embedded_in
|
|
@@ -10,10 +10,16 @@ module RailsAdmin
|
|
|
10
10
|
register_instance_option :view_helper do
|
|
11
11
|
:hidden_field
|
|
12
12
|
end
|
|
13
|
-
|
|
14
|
-
register_instance_option
|
|
15
|
-
|
|
13
|
+
|
|
14
|
+
register_instance_option :label do
|
|
15
|
+
false
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
register_instance_option :help do
|
|
19
|
+
false
|
|
16
20
|
end
|
|
21
|
+
|
|
22
|
+
|
|
17
23
|
end
|
|
18
24
|
end
|
|
19
25
|
end
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
class RailsAdmin::History < ActiveRecord::Base
|
|
2
|
-
|
|
3
2
|
self.table_name = :rails_admin_histories
|
|
4
3
|
|
|
5
4
|
IGNORED_ATTRS = Set[:id, :created_at, :created_on, :deleted_at, :updated_at, :updated_on, :deleted_on]
|
|
6
5
|
|
|
6
|
+
attr_accessible :message, :item, :table, :username
|
|
7
|
+
|
|
7
8
|
def self.latest
|
|
8
9
|
self.limit(100)
|
|
9
10
|
end
|
|
@@ -53,7 +54,7 @@ class RailsAdmin::History < ActiveRecord::Base
|
|
|
53
54
|
else
|
|
54
55
|
history = history.order('created_at DESC')
|
|
55
56
|
end
|
|
56
|
-
all ? history : history.
|
|
57
|
+
all ? history : history.send(Kaminari.config.page_method_name, page.presence || "1").per(per_page)
|
|
57
58
|
end
|
|
58
59
|
|
|
59
60
|
def self.history_for_object(model, object, query, sort, sort_reverse, all, page, per_page = (RailsAdmin::Config.default_items_per_page || 20))
|
|
@@ -64,6 +65,6 @@ class RailsAdmin::History < ActiveRecord::Base
|
|
|
64
65
|
else
|
|
65
66
|
history = history.order('created_at DESC')
|
|
66
67
|
end
|
|
67
|
-
all ? history : history.
|
|
68
|
+
all ? history : history.send(Kaminari.config.page_method_name, page.presence || "1").per(per_page)
|
|
68
69
|
end
|
|
69
70
|
end
|
|
@@ -69,7 +69,7 @@ module RailsAdmin
|
|
|
69
69
|
versions = Version.where :item_type => model.model.name
|
|
70
70
|
versions = versions.where("event LIKE ?", "%#{query}%") if query.present?
|
|
71
71
|
versions = versions.order(sort_reverse == "true" ? "#{sort} DESC" : sort)
|
|
72
|
-
versions = all ? versions : versions.
|
|
72
|
+
versions = all ? versions : versions.send(Kaminari.config.page_method_name, page.presence || "1").per(per_page)
|
|
73
73
|
versions.map{|version| VersionProxy.new(version, @user_class)}
|
|
74
74
|
end
|
|
75
75
|
|
|
@@ -83,7 +83,7 @@ module RailsAdmin
|
|
|
83
83
|
versions = Version.where :item_type => model.model.name, :item_id => object.id
|
|
84
84
|
versions = versions.where("event LIKE ?", "%#{query}%") if query.present?
|
|
85
85
|
versions = versions.order(sort_reverse == "true" ? "#{sort} DESC" : sort)
|
|
86
|
-
versions = all ? versions : versions.
|
|
86
|
+
versions = all ? versions : versions.send(Kaminari.config.page_method_name, page.presence || "1").per(per_page)
|
|
87
87
|
versions.map{|version| VersionProxy.new(version, @user_class)}
|
|
88
88
|
end
|
|
89
89
|
end
|
data/lib/rails_admin/version.rb
CHANGED