the_sortable_tree 1.9.4 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (65) hide show
  1. data/MIT-LICENSE +4 -2
  2. data/README.md +237 -438
  3. data/app/assets/images/iconza/{gray → icons}/add.png +0 -0
  4. data/app/assets/images/iconza/{gray → icons}/delete.png +0 -0
  5. data/app/assets/images/iconza/{gray → icons}/edit.png +0 -0
  6. data/app/assets/images/iconza/icons/move.png +0 -0
  7. data/app/assets/images/iconza/{red/add.png → icons/red_add.png} +0 -0
  8. data/app/assets/images/iconza/{red/delete.png → icons/red_delete.png} +0 -0
  9. data/app/assets/images/iconza/{red/edit.png → icons/red_edit.png} +0 -0
  10. data/app/assets/images/iconza/icons/red_move.png +0 -0
  11. data/app/assets/javascripts/render_tree_helper.js.coffee +82 -0
  12. data/app/assets/javascripts/sortable_tree/initializer.js.coffee +54 -0
  13. data/app/assets/stylesheets/sortable_tree.css.scss +106 -0
  14. data/app/assets/stylesheets/tree.css.scss +26 -29
  15. data/app/controllers/the_sortable_tree_controller.rb +3 -2
  16. data/app/helpers/render_sortable_tree_helper.rb +62 -0
  17. data/app/helpers/render_tree_helper.rb +45 -0
  18. data/app/helpers/the_sortable_tree_helper.rb +67 -52
  19. data/app/views/sortable/client/_tree.html.erb +9 -0
  20. data/app/views/tree/client/_tree.html.erb +23 -0
  21. data/lib/fake.example +44 -0
  22. data/lib/generators/the_sortable_tree/views_generator.rb +29 -18
  23. data/lib/the_sortable_tree.rb +4 -8
  24. data/lib/the_sortable_tree/engine.rb +1 -1
  25. data/lib/the_sortable_tree/version.rb +1 -1
  26. metadata +31 -60
  27. data/app/assets/images/iconza/blue/add.png +0 -0
  28. data/app/assets/images/iconza/blue/delete.png +0 -0
  29. data/app/assets/images/iconza/blue/down.png +0 -0
  30. data/app/assets/images/iconza/blue/downloads_folder.png +0 -0
  31. data/app/assets/images/iconza/blue/edit.png +0 -0
  32. data/app/assets/images/iconza/blue/move.png +0 -0
  33. data/app/assets/images/iconza/blue/up.png +0 -0
  34. data/app/assets/images/iconza/gray/down.png +0 -0
  35. data/app/assets/images/iconza/gray/lock.png +0 -0
  36. data/app/assets/images/iconza/gray/mail.png +0 -0
  37. data/app/assets/images/iconza/gray/push_pin.png +0 -0
  38. data/app/assets/images/iconza/gray/up.png +0 -0
  39. data/app/assets/images/iconza/red/down.png +0 -0
  40. data/app/assets/images/iconza/red/newspaper.png +0 -0
  41. data/app/assets/images/iconza/red/trash.png +0 -0
  42. data/app/assets/images/iconza/red/up.png +0 -0
  43. data/app/assets/images/iconza/red/zoom.png +0 -0
  44. data/app/assets/javascripts/comments/base.js.coffee +0 -46
  45. data/app/assets/javascripts/sortable/base.js.coffee +0 -47
  46. data/app/assets/stylesheets/comments_tree.css.scss +0 -84
  47. data/app/assets/stylesheets/sortable.css.scss +0 -106
  48. data/app/views/comments/base/_children.html.haml +0 -1
  49. data/app/views/comments/base/_comment.html.haml +0 -8
  50. data/app/views/comments/base/_new_comment_form.html.haml +0 -18
  51. data/app/views/comments/base/_node.html.haml +0 -3
  52. data/app/views/comments/base/_tree.html.haml +0 -5
  53. data/app/views/sortable/base/_children.html.haml +0 -1
  54. data/app/views/sortable/base/_controls.html.haml +0 -16
  55. data/app/views/sortable/base/_link.html.haml +0 -7
  56. data/app/views/sortable/base/_new.html.haml +0 -3
  57. data/app/views/sortable/base/_node.html.haml +0 -3
  58. data/app/views/sortable/base/_tree.html.haml +0 -12
  59. data/app/views/tree/base/_children.html.haml +0 -1
  60. data/app/views/tree/base/_link.html.haml +0 -1
  61. data/app/views/tree/base/_node.html.haml +0 -3
  62. data/app/views/tree/base/_tree.html.haml +0 -3
  63. data/config/locales/en.yml +0 -31
  64. data/config/locales/ru.yml +0 -31
  65. data/lib/tasks/the_sortable_tree.rake +0 -4
data/MIT-LICENSE CHANGED
@@ -1,4 +1,6 @@
1
- Copyright 2009-2012 Ilya N. Zykin, Matthew Clark
1
+ MIT License (MIT)
2
+
3
+ Copyright 2009-2013 Ilya N. Zykin (the-teacher), Mikhail Dieterle (Mik-die), Matthew Clark
2
4
 
3
5
  Permission is hereby granted, free of charge, to any person obtaining
4
6
  a copy of this software and associated documentation files (the
@@ -17,4 +19,4 @@ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
19
  NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
20
  LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
21
  OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
- WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md CHANGED
@@ -1,438 +1,237 @@
1
- ### TheSortableTree
2
-
3
- Awesome Helper for building sortable nested sets
4
-
5
- [TheSortableTree on RubyGems](http://rubygems.org/gems/the_sortable_tree)
6
-
7
- ### Keywords
8
-
9
- Sortable awesom_nested_set, Drag&Drop GUI for awesom_nested_set, View Helper for nested set, Nested Comments
10
-
11
- ### Description
12
-
13
- **sortable_tree** - recursive helper-method for rendering sortable awesome_nested_set tree.
14
-
15
- **sortable_tree** uses partials for rendering, that's why it is **so easy to customize**!
16
-
17
- ### Capabilities
18
-
19
- **Just Tree [default or tree option]**
20
-
21
- ![TheSortableTree](https://github.com/the-teacher/the_sortable_tree/raw/master/pic_min.jpg)
22
-
23
- **Drag&Drop Sortable Tree [sortable option]**
24
-
25
- ![TheSortableTree](https://github.com/the-teacher/the_sortable_tree/raw/master/pic.jpg)
26
-
27
- **Comments Tree [__comments__ option]**
28
-
29
- With New Comment form and reply functionality
30
-
31
- ![TheSortableTree](https://github.com/the-teacher/the_sortable_tree/raw/dev/comments.gif)
32
-
33
- ### LiveDemo and App for testcase creating
34
-
35
- https://github.com/the-teacher/the_sortable_tree_test_app
36
-
37
- ### Install
38
-
39
- gem 'haml'
40
- gem 'awesome_nested_set' # gem 'nested_set'
41
- gem 'the_sortable_tree'
42
-
43
- ```ruby
44
- bundle
45
- ```
46
-
47
- ### Example of using with Page Model
48
-
49
- ### Jquery
50
-
51
- **app/assets/javascripts/application.js**
52
-
53
- ``` ruby
54
- //= require jquery
55
- //= require jquery-ui
56
- //= require jquery_ujs
57
- ```
58
-
59
- ### Extend your Model
60
-
61
- ``` ruby
62
- class Page < ActiveRecord::Base
63
- include TheSortableTree::Scopes
64
- # any code here
65
- end
66
- ```
67
-
68
- ### Extend your Controller
69
-
70
- ``` ruby
71
- class PagesController < ApplicationController
72
- include TheSortableTreeController::Rebuild
73
- # any code here
74
- end
75
- ```
76
-
77
- or (for reversed tree)
78
-
79
- ``` ruby
80
- class PagesController < ApplicationController
81
- include TheSortableTreeController::ReversedRebuild
82
- # any code here
83
- end
84
- ```
85
-
86
- ### Extend your Routes
87
-
88
- ``` ruby
89
- resources :pages do
90
- collection do
91
- get :manage
92
- post :rebuild
93
- end
94
- end
95
- ```
96
-
97
- **manage** action or any else action for show sortable tree
98
-
99
- **rebuild** action is _required_ action for correctly work of **the_sortable_tree**
100
-
101
- ### Find your tree
102
-
103
- ``` ruby
104
- class PagesController < ApplicationController
105
- include TheSortableTreeController::Rebuild
106
-
107
- def manage
108
- @pages = Page.nested_set.all
109
- end
110
-
111
- # any code here
112
- end
113
-
114
- ```
115
-
116
- or
117
-
118
- ``` ruby
119
- class PagesController < ApplicationController
120
- include TheSortableTreeController::ReversedRebuild
121
-
122
- def manage
123
- @pages = Page.reversed_nested_set.all
124
- end
125
-
126
- # any code here
127
- end
128
- ```
129
-
130
- ### Extend your Layout (erb)
131
-
132
- ``` ruby
133
- <%= stylesheet_link_tag "application" %>
134
- <%= javascript_include_tag "application" %>
135
- <%= csrf_meta_tags %>
136
-
137
- <%= javascript_include_tag 'jquery.ui.nestedSortable' %>
138
-
139
- <%= javascript_include_tag 'sortable/base' %>
140
- <%= javascript_include_tag 'comments/base' %>
141
-
142
- <%= stylesheet_link_tag 'tree', :media => :all %>
143
- <%= stylesheet_link_tag 'sortable', :media => :all %>
144
- <%= stylesheet_link_tag 'comments_tree', :media => :all %>
145
- ```
146
-
147
- ### Or, if you're using Asset Pipeline
148
-
149
- In JS manifest file (application.js):
150
-
151
- ``` js
152
- //= require jquery
153
- //= require jquery_ujs
154
- //= require jquery-ui
155
- //= require jquery.ui.nestedSortable
156
- //= require sortable/base
157
- //= require comments/base
158
- //= require_tree .
159
- ```
160
-
161
- In CSS manifest file (application.css):
162
-
163
- ``` css
164
- /*
165
- *= require_self
166
- *= require_tree .
167
- *= require tree
168
- *= require sortable
169
- *= require comments_tree
170
- */
171
-
172
- ```
173
-
174
- ### Render your tree
175
-
176
- ``` ruby
177
- = sortable_tree @pages
178
- ```
179
-
180
- ### Render your sortable tree
181
-
182
- ``` ruby
183
- = sortable_tree @pages, :type => :sortable, :new_url => new_page_path, :max_levels => 4
184
- ```
185
-
186
- ### Render your comments tree (with New Form and Reply)
187
-
188
- Plz, read **Comments Doc** before using this
189
-
190
- ``` ruby
191
- = sortable_tree @comments, :type => :comments, :title => :name
192
- ```
193
-
194
- ### Comments Doc
195
-
196
- My comment Model looks like this:
197
-
198
- ``` ruby
199
- create_table :comments do |t|
200
- t.string :name
201
- t.string :email
202
-
203
- t.text :raw_content
204
- t.text :content
205
- end
206
- ```
207
-
208
- For me is very important to have 2 fields for **content**.
209
-
210
- **raw_content** is unsecure raw content from user (this name using in new comment form).
211
-
212
- **content** is prepared content once passed by content filters (Textile, Sanitize and others). This field using for rendering.
213
-
214
- There is base example of my Comment Model.
215
-
216
- ``` ruby
217
- class Comment < ActiveRecord::Base
218
- acts_as_nested_set
219
- include TheSortableTree::Scopes
220
- before_save :prepare_content
221
-
222
- private
223
-
224
- def prepare_content
225
- # Any content filters here
226
- self.content = "<b>#{self.raw_content}</b>"
227
- end
228
- end
229
- ```
230
-
231
- Plz, read **Comments Options** for modify Render Helper for your purposes.
232
-
233
- If you have Model like this:
234
-
235
- ``` ruby
236
- create_table :comments do |t|
237
- t.string :topic
238
- t.string :contacts
239
- t.text :content
240
- end
241
- ```
242
-
243
- You can call helper with next params:
244
-
245
- ``` ruby
246
- = sortable_tree @comments, :type => :comments, :title => :topic, :contacts_field => :contacts, :raw_content_field => :content, :content_field => :content
247
- ```
248
-
249
- ### Customization
250
-
251
- TheSortableTree view generator will copy a set of partials from gem to your View directory.
252
-
253
- ``` ruby
254
- rails g the_sortable_tree:views Model [option]
255
- ```
256
-
257
- ## Examples
258
-
259
- ### Customize your tree
260
-
261
- ``` ruby
262
- rails g the_sortable_tree:views Page
263
- ```
264
-
265
- And render with partials from **pages/tree/base**
266
-
267
- ``` ruby
268
- = sortable_tree @pages, :path => 'pages/tree/base'
269
- ```
270
-
271
- ### Customize your sortable tree
272
-
273
- ``` ruby
274
- rails g the_sortable_tree:views Page sortable
275
- ```
276
-
277
- And render with partials from **pages/sortable/base**
278
-
279
- ``` ruby
280
- = sortable_tree @pages, :path => 'pages/sortable/base', :new_url => new_page_path
281
- ```
282
-
283
- ### Customize your comments tree
284
-
285
- ``` ruby
286
- rails g the_sortable_tree:views Comment comments
287
- ```
288
-
289
- And render with partials from **comments/comments/base**
290
-
291
- ``` ruby
292
- = sortable_tree @comments, :path => 'comments/comments/base', :title => :name
293
- ```
294
-
295
- ### Troubleshooting
296
-
297
- If you need to render a part of tree:
298
-
299
- ``` ruby
300
- @root = Page.root
301
- @pages = @root.descendants.nested_set.all
302
- ```
303
-
304
- ``` ruby
305
- = @root.inspect
306
- = sortable_tree @pages
307
- ```
308
-
309
- If **TheSortableTree** can't correctly define a Name of your Model, just add **sortable_model** into your Controller:
310
-
311
- ``` ruby
312
- class Inventory::CategoriesController < ApplicationController
313
- include TheSortableTreeController::Rebuild
314
-
315
- def sortable_model
316
- Inventory::Category
317
- end
318
-
319
- def index
320
- @inventory_categories = Inventory::Category.nested_set.all
321
- end
322
-
323
- def manage
324
- @inventory_categories = Inventory::Category.nested_set.all
325
- end
326
- end
327
- ```
328
-
329
- How can I render a **select/options** menu in form? Should I use TheSortableTree?
330
-
331
- No. You should not. TheSortableTree is helper for building composite interfaces. Simple dropdown menu can be rendering with Awesome Nested Set Helper **sorted_nested_set_options**
332
-
333
- There is Example:
334
-
335
- ```ruby
336
- - sorted_nested_set_options(Catalog, lambda{ |catalog| catalog.lft }) do |catalog, level|
337
- - options << content_tag(:option, catalog.title, :value => catalog.id, :class => "level_#{level}")
338
-
339
- = f.select :catalog_id, options, {}
340
- ```
341
-
342
- ### Comments Options
343
-
344
- **node_id** - comment's id which should be set as value of hidden field **parend_id** when Reply link pressed (**:id** by default)
345
-
346
- **contacts_field** - **:email** field by default. If you want to hide contacts field - you should use customization by view generators
347
-
348
- **content_field** - field with prepared comment's content (**:content** by default)
349
-
350
- **raw_content_field** - field with raw comment's content (**:raw_content** by default, you can set it to **:content**)
351
-
352
- ### Common Options
353
-
354
- **id** - id field (**:id** by default)
355
-
356
- **title** - title field of node (**:title** by default)
357
-
358
- **path** - path to custom view partials (:path => 'pages/sortable/tree')
359
-
360
- **max_levels** - count of draggable levels or **max reply level** in comments tree. (**3** by default). **Can't be 0 (zero) and negative**
361
-
362
- **namespace** - namespace for admin sections for example. (**nil** by default)
363
-
364
- **opts[:level]** - view helper define level of recursion for each node. You can call **opts[:level]** into view partials
365
-
366
- ### Base partial's descriptions
367
-
368
- **_tree** - root container for nested set elements
369
-
370
- **_node** - element of tree (link to current node and nested set of children)
371
-
372
- **_link** - decoration of link to current element of tree
373
-
374
- **_children** - decoration of children
375
-
376
- **_new** - create new element link
377
-
378
- **_controls** - control elements for current node
379
-
380
- ### Can I use gem with Rails 2 or Rails 3.0?
381
-
382
- There is no strong dependencies for Rails 3.
383
-
384
- Take files from the gem and put it in your Rails 2 application.
385
-
386
- And fix errors :) Ha-Ha-Ha! You can ask me if you will do it.
387
-
388
- ### Changelog
389
-
390
- 1.9.4 - rm CoffeeScript document scope, ru locale, fix data-confirm
391
-
392
- 1.9.3 - Jeffery Utter patch for coffee script
393
-
394
- 1.9.2 - View Generators updated
395
-
396
- 1.9.1 - Rewrite with coffee => **assets/javascripts/sortable/base.js.coffee**
397
-
398
- 1.9.0 - 1) **Helper API changed!** 2) Comments tree with sand form and reply fu! 3) Way to manual set sortable Model klass into controller.
399
-
400
- 1.8.6 - fixed CamelCase names definition (by andisthejackass)
401
-
402
- 1.8.5 - helper can rendering a part tree
403
-
404
- 1.8.0 - stable release
405
-
406
- ### Is it fast?
407
-
408
- Hmmmm...
409
-
410
- * Development env
411
- * 584 elements
412
- * 3 levels deep
413
-
414
- Rendered by 50 sec.
415
-
416
- I think it is good result for rendering by partials.
417
-
418
- ### Can it be faster?
419
-
420
- Perhaps. Read next idea to learn more. There is no implementation now, sorry.
421
-
422
- https://github.com/the-teacher/the_sortable_tree/issues/milestones?with_issues=no
423
-
424
- ### ERB vs HAML vs SLIM
425
-
426
- HAML by default. You can use any Template Engine, but convert partials by yourself, plz.
427
-
428
- ### Contributors
429
-
430
- * https://github.com/the-teacher
431
- * https://github.com/winescout
432
- * https://github.com/gbrain
433
- * https://github.com/Mik-die
434
-
435
- ### Acknowledgments
436
-
437
- * https://github.com/mjsarfatti/nestedSortable
438
- * http://iconza.com
1
+ # TheSortableTree v2.0.0
2
+
3
+ Nested Set + Drag&Drop GUI. Very fast! Best render helper! **2000 nodes/sec**. Ready for rails 4 ([RubyGems](http://rubygems.org/gems/the_sortable_tree))
4
+
5
+ ## Sortable tree. Drag&Drop GUI
6
+
7
+ ![Drag&Drop GUI. Sotrable tree](https://raw.github.com/the-teacher/the_sortable_tree/master/docs/sortable.jpg)
8
+
9
+ ## Render tree
10
+
11
+ ![Render tree](https://raw.github.com/the-teacher/the_sortable_tree/master/docs/tree.jpg)
12
+
13
+ ## Keywords
14
+
15
+ Awesome nested set, Nested set, Ruby, Rails, Nested set view helper, Sortable nested set, Drag&Drop GUI for nested set, View helper for nested set, render tree
16
+
17
+ ## Install
18
+
19
+ **Gemfile** (Rails 4)
20
+
21
+ ```ruby
22
+ gem 'awesome_nested_set' # or any similar gem (gem 'nested_set')
23
+ gem 'the_sortable_tree'
24
+ ```
25
+
26
+ **Gemfile** (Rails 3)
27
+
28
+ ```ruby
29
+ gem 'awesome_nested_set'
30
+ gem 'the_sortable_tree', :branch => "rails_3"
31
+ ```
32
+
33
+ Console
34
+
35
+ ```ruby
36
+ bundle
37
+ ```
38
+
39
+ ## Using
40
+
41
+ #### JQuery and JavaScripts
42
+
43
+ **app/assets/javascripts/application.js**
44
+
45
+ Sortable GUI require JQuery libs
46
+
47
+ ```ruby
48
+ //= require jquery
49
+ //= require jquery-ui
50
+ //= require jquery_ujs
51
+ ```
52
+
53
+ Add next JS only for Sortable GUI
54
+
55
+ ```ruby
56
+ //= require jquery.ui.nestedSortable
57
+ //= require sortable_tree/initializer
58
+ ```
59
+
60
+ #### Stylesheets
61
+
62
+ **app/assets/stylesheets/application.css**
63
+
64
+ ```ruby
65
+ *= require tree
66
+ *= require sortable_tree
67
+ ```
68
+
69
+ ### Extend your Routes for Sortable GUI
70
+
71
+ ```ruby
72
+ resources :pages do
73
+ collection do
74
+ get :manage
75
+
76
+ # required for Sortable GUI server side actions
77
+ post :rebuild
78
+ end
79
+ end
80
+ ```
81
+
82
+ **manage** - just page, where you want render Sortable tree.
83
+
84
+ ### Extend your Model
85
+
86
+ ```ruby
87
+ class Page < ActiveRecord::Base
88
+ include TheSortableTree::Scopes
89
+
90
+ # any code here
91
+ end
92
+ ```
93
+
94
+ ### Extend your controller and find your tree
95
+
96
+ ```ruby
97
+ class PagesController < ApplicationController
98
+ include TheSortableTreeController::Rebuild
99
+
100
+ def manage
101
+ @pages = Page.nested_set.select('id, title, content, parent_id').all
102
+ end
103
+
104
+ # any code here
105
+ end
106
+ ```
107
+
108
+ ## Render Tree
109
+
110
+ **app/views/pages/manage.html.haml**
111
+
112
+ ```haml
113
+ %ol.tree= build_server_tree @pages
114
+ ```
115
+
116
+ ## Render Sortable Tree
117
+
118
+ **app/views/pages/manage.html.haml**
119
+
120
+ ```haml
121
+ %ol.sortable_tree{ data: { max_levels: 5, rebuild_url: rebuild_pages_url } }
122
+ = build_server_tree @pages, type: :sortable
123
+ ```
124
+
125
+ ## build_server_tree options
126
+
127
+ **Client side:**
128
+
129
+ Required params for sortable GUI! Must be defined at root element of tree.
130
+
131
+ 1. **max_levels** - maximum depth of nesting
132
+ 2. **rebuild_url** - URL to rebuild method on server side
133
+
134
+
135
+ ```ruby
136
+ %ol.sortable_tree{ data: { max_levels: 3, rebuild_url: rebuild_pages_url } }
137
+ ```
138
+
139
+ **Server side:**
140
+
141
+ ```ruby
142
+ options[:NAME]
143
+ ```
144
+
145
+ Optional params
146
+
147
+ 1. **id** - id field of node
148
+ 2. **title** - title field of node
149
+ 3. **type** - type of tree [tree|sortable]
150
+ 4. **namespace** - for example: **:admin**. **[]** - by default
151
+ 5. **render_module** - your own Render Tree Helper
152
+
153
+ **Rendering runtime params (see code of render helpers):**
154
+
155
+ You can use next options, when rendering run:
156
+
157
+ 1. **level** - level number
158
+ 2. **root** - root flag [true|false]
159
+ 3. **klass** - class name
160
+ 4. **has_children** - has children flag [true|false]
161
+ 5. **children** - array of children
162
+
163
+ ## Customization
164
+
165
+ Try to run next view generators:
166
+
167
+ Render helpers for HTML tree generation
168
+
169
+ ```ruby
170
+ bundle exec rails g the_sortable_tree:views tree
171
+ bundle exec rails g the_sortable_tree:views sortable
172
+ ```
173
+
174
+ Base Render helper of gem
175
+
176
+ ```ruby
177
+ bundle exec rails g the_sortable_tree:views helper
178
+ ```
179
+
180
+ Assets of gem
181
+
182
+ ```ruby
183
+ bundle exec rails g the_sortable_tree:views assets
184
+ ```
185
+
186
+ ## I want to know more
187
+
188
+ 1. [How to change HTML code of tree?](https://github.com/the-teacher/the_sortable_tree/blob/master/docs/How_to_change_HTML_code_of_tree.md)
189
+ 2. [How to create new tree HTML Builder helper?](https://github.com/the-teacher/the_sortable_tree/blob/master/docs/How_to_create_new_tree_Render_Helper.md)
190
+ 3. [I need to render reversed tree](https://github.com/the-teacher/the_sortable_tree/blob/master/docs/I_need_to_render_reversed_tree.md)
191
+ 4. [Gem can't correctly define a Name of your Model](https://github.com/the-teacher/the_sortable_tree/blob/master/docs/How_to_correctly_define_a_Name_of_your_Model.md)
192
+ 5. [ChangeLog](https://github.com/the-teacher/the_sortable_tree/blob/master/docs/ChangeLog.md)
193
+
194
+ ## Is it fast? Yes, it is!
195
+
196
+ BANCHMARK:
197
+
198
+ - Server Side, 16.000 nodes, 3 levels
199
+ - Views: 7999.6ms | ActiveRecord: 79.2ms
200
+ - WebInspector full time ~ 9.64s
201
+
202
+ total: ~**2000 nodes/sec**
203
+
204
+ ## Looking for maintainers
205
+
206
+ Do you want to be open source contributor? There are some ideas:
207
+
208
+ Try to create view helpers for:
209
+
210
+ 1. Mongoid NestedSet
211
+ 2. acts_as_ordered_tree
212
+ 5. Expand tree via AJAX
213
+ 4. Comments Tree gem
214
+ 3. gem Ancestry (???)
215
+
216
+ ## The MIT License (MIT)
217
+
218
+ Copyright 2009-2013 Ilya N. Zykin (the-teacher), Mikhail Dieterle (Mik-die), Matthew Clark
219
+
220
+ Permission is hereby granted, free of charge, to any person obtaining
221
+ a copy of this software and associated documentation files (the
222
+ "Software"), to deal in the Software without restriction, including
223
+ without limitation the rights to use, copy, modify, merge, publish,
224
+ distribute, sublicense, and/or sell copies of the Software, and to
225
+ permit persons to whom the Software is furnished to do so, subject to
226
+ the following conditions:
227
+
228
+ The above copyright notice and this permission notice shall be
229
+ included in all copies or substantial portions of the Software.
230
+
231
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
232
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
233
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
234
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
235
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
236
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
237
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.