inherited_resources 1.1.2 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (102) hide show
  1. data/.gitignore +1 -0
  2. data/CHANGELOG +6 -0
  3. data/Gemfile +12 -0
  4. data/Gemfile.lock +86 -0
  5. data/README.rdoc +91 -37
  6. data/Rakefile +0 -22
  7. data/inherited_resources.gemspec +24 -0
  8. data/lib/inherited_resources.rb +7 -2
  9. data/lib/inherited_resources/actions.rb +4 -4
  10. data/lib/inherited_resources/base.rb +11 -10
  11. data/lib/inherited_resources/base_helpers.rb +32 -3
  12. data/lib/inherited_resources/class_methods.rb +102 -10
  13. data/lib/inherited_resources/shallow_helpers.rb +87 -0
  14. data/lib/inherited_resources/url_helpers.rb +48 -2
  15. data/lib/inherited_resources/version.rb +1 -1
  16. data/test/aliases_test.rb +1 -1
  17. data/test/association_chain_test.rb +1 -1
  18. data/test/base_test.rb +16 -8
  19. data/test/belongs_to_test.rb +44 -2
  20. data/test/belongs_to_with_shallow_test.rb +93 -0
  21. data/test/class_methods_test.rb +6 -4
  22. data/test/customized_base_test.rb +1 -1
  23. data/test/customized_belongs_to_test.rb +2 -2
  24. data/test/customized_redirect_to_test.rb +32 -0
  25. data/test/defaults_test.rb +117 -11
  26. data/test/locales/en.yml +17 -0
  27. data/test/nested_belongs_to_test.rb +1 -1
  28. data/test/nested_belongs_to_with_shallow_test.rb +123 -0
  29. data/test/nested_model_with_shallow_test.rb +133 -0
  30. data/test/optional_belongs_to_test.rb +4 -4
  31. data/test/polymorphic_test.rb +5 -5
  32. data/test/redirect_to_test.rb +1 -1
  33. data/test/singleton_test.rb +5 -2
  34. data/test/test_helper.rb +8 -24
  35. data/test/url_helpers_test.rb +243 -2
  36. data/test/views/cars/edit.html.erb +1 -0
  37. data/test/views/cars/index.html.erb +1 -0
  38. data/test/views/cars/new.html.erb +1 -0
  39. data/test/views/cars/show.html.erb +1 -0
  40. data/test/views/cities/edit.html.erb +1 -0
  41. data/test/views/cities/index.html.erb +1 -0
  42. data/test/views/cities/new.html.erb +1 -0
  43. data/test/views/cities/show.html.erb +1 -0
  44. data/test/views/comments/edit.html.erb +1 -0
  45. data/test/views/comments/index.html.erb +1 -0
  46. data/test/views/comments/new.html.erb +1 -0
  47. data/test/views/comments/show.html.erb +1 -0
  48. data/test/views/educations/new.html.erb +0 -0
  49. data/test/views/employees/edit.html.erb +1 -0
  50. data/test/views/employees/index.html.erb +1 -0
  51. data/test/views/employees/new.html.erb +1 -0
  52. data/test/views/employees/show.html.erb +1 -0
  53. data/test/views/groups/edit.html.erb +0 -0
  54. data/test/views/managers/edit.html.erb +1 -0
  55. data/test/views/managers/new.html.erb +1 -0
  56. data/test/views/managers/show.html.erb +1 -0
  57. data/test/views/painters/edit.html.erb +1 -0
  58. data/test/views/painters/index.html.erb +1 -0
  59. data/test/views/painters/new.html.erb +1 -0
  60. data/test/views/painters/show.html.erb +1 -0
  61. data/test/views/pets/edit.html.erb +1 -0
  62. data/test/views/pets/index.html.erb +1 -0
  63. data/test/views/pets/new.html.erb +1 -0
  64. data/test/views/pets/show.html.erb +1 -0
  65. data/test/views/plates/edit.html.erb +1 -0
  66. data/test/views/plates/index.html.erb +1 -0
  67. data/test/views/plates/new.html.erb +1 -0
  68. data/test/views/plates/show.html.erb +1 -0
  69. data/test/views/products/edit.html.erb +1 -0
  70. data/test/views/products/index.html.erb +1 -0
  71. data/test/views/products/new.html.erb +1 -0
  72. data/test/views/products/show.html.erb +1 -0
  73. data/test/views/professors/edit.html.erb +1 -0
  74. data/test/views/professors/index.html.erb +1 -0
  75. data/test/views/professors/new.html.erb +1 -0
  76. data/test/views/professors/show.html.erb +1 -0
  77. data/test/views/projects/index.html.erb +1 -0
  78. data/test/views/projects/index.json.erb +1 -0
  79. data/test/views/projects/respond_to_skip_default_template.html.erb +1 -0
  80. data/test/views/projects/respond_with_resource.html.erb +1 -0
  81. data/test/views/students/edit.html.erb +1 -0
  82. data/test/views/students/new.html.erb +1 -0
  83. data/test/views/tags/edit.html.erb +1 -0
  84. data/test/views/tags/index.html.erb +1 -0
  85. data/test/views/tags/new.html.erb +1 -0
  86. data/test/views/tags/show.html.erb +1 -0
  87. data/test/views/trees/edit.html.erb +1 -0
  88. data/test/views/trees/index.html.erb +1 -0
  89. data/test/views/trees/new.html.erb +1 -0
  90. data/test/views/trees/show.html.erb +1 -0
  91. data/test/views/university/professors/edit.html.erb +1 -0
  92. data/test/views/university/professors/index.html.erb +1 -0
  93. data/test/views/university/professors/new.html.erb +1 -0
  94. data/test/views/university/professors/show.html.erb +1 -0
  95. data/test/views/users/create.js.erb +1 -0
  96. data/test/views/users/destroy.js.erb +1 -0
  97. data/test/views/users/edit.html.erb +1 -0
  98. data/test/views/users/index.html.erb +1 -0
  99. data/test/views/users/new.html.erb +1 -0
  100. data/test/views/users/show.html.erb +1 -0
  101. data/test/views/users/update.js.erb +1 -0
  102. metadata +180 -9
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
File without changes
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
File without changes
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ Index JSON
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Create JS
@@ -0,0 +1 @@
1
+ Destroy JS
@@ -0,0 +1 @@
1
+ Edit HTML
@@ -0,0 +1 @@
1
+ Index HTML
@@ -0,0 +1 @@
1
+ New HTML
@@ -0,0 +1 @@
1
+ Show HTML
@@ -0,0 +1 @@
1
+ Update JS
metadata CHANGED
@@ -1,12 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: inherited_resources
3
3
  version: !ruby/object:Gem::Version
4
+ hash: 31
4
5
  prerelease: false
5
6
  segments:
6
7
  - 1
7
- - 1
8
8
  - 2
9
- version: 1.1.2
9
+ - 0
10
+ version: 1.2.0
10
11
  platform: ruby
11
12
  authors:
12
13
  - "Jos\xC3\xA9 Valim"
@@ -14,16 +15,18 @@ autorequire:
14
15
  bindir: bin
15
16
  cert_chain: []
16
17
 
17
- date: 2010-04-03 00:00:00 +02:00
18
+ date: 2011-01-25 00:00:00 +01:00
18
19
  default_executable:
19
20
  dependencies:
20
21
  - !ruby/object:Gem::Dependency
21
22
  name: responders
22
23
  prerelease: false
23
24
  requirement: &id001 !ruby/object:Gem::Requirement
25
+ none: false
24
26
  requirements:
25
27
  - - ~>
26
28
  - !ruby/object:Gem::Version
29
+ hash: 7
27
30
  segments:
28
31
  - 0
29
32
  - 6
@@ -35,9 +38,11 @@ dependencies:
35
38
  name: has_scope
36
39
  prerelease: false
37
40
  requirement: &id002 !ruby/object:Gem::Requirement
41
+ none: false
38
42
  requirements:
39
43
  - - ~>
40
44
  - !ruby/object:Gem::Version
45
+ hash: 11
41
46
  segments:
42
47
  - 0
43
48
  - 5
@@ -46,18 +51,22 @@ dependencies:
46
51
  type: :runtime
47
52
  version_requirements: *id002
48
53
  description: Inherited Resources speeds up development by making your controllers inherit all restful actions so you just have to focus on what is important.
49
- email: jose.valim@gmail.com
54
+ email: developers@plataformatec.com.br
50
55
  executables: []
51
56
 
52
57
  extensions: []
53
58
 
54
- extra_rdoc_files:
55
- - README.rdoc
59
+ extra_rdoc_files: []
60
+
56
61
  files:
62
+ - .gitignore
57
63
  - CHANGELOG
64
+ - Gemfile
65
+ - Gemfile.lock
58
66
  - MIT-LICENSE
59
67
  - README.rdoc
60
68
  - Rakefile
69
+ - inherited_resources.gemspec
61
70
  - lib/generators/rails/USAGE
62
71
  - lib/generators/rails/inherited_resources_controller_generator.rb
63
72
  - lib/generators/rails/templates/controller.rb
@@ -71,36 +80,127 @@ files:
71
80
  - lib/inherited_resources/dsl.rb
72
81
  - lib/inherited_resources/polymorphic_helpers.rb
73
82
  - lib/inherited_resources/responder.rb
83
+ - lib/inherited_resources/shallow_helpers.rb
74
84
  - lib/inherited_resources/singleton_helpers.rb
75
85
  - lib/inherited_resources/url_helpers.rb
76
86
  - lib/inherited_resources/version.rb
87
+ - test/aliases_test.rb
88
+ - test/association_chain_test.rb
89
+ - test/base_test.rb
90
+ - test/belongs_to_test.rb
91
+ - test/belongs_to_with_shallow_test.rb
92
+ - test/class_methods_test.rb
93
+ - test/customized_base_test.rb
94
+ - test/customized_belongs_to_test.rb
95
+ - test/customized_redirect_to_test.rb
96
+ - test/defaults_test.rb
97
+ - test/locales/en.yml
98
+ - test/nested_belongs_to_test.rb
99
+ - test/nested_belongs_to_with_shallow_test.rb
100
+ - test/nested_model_with_shallow_test.rb
101
+ - test/optional_belongs_to_test.rb
102
+ - test/polymorphic_test.rb
103
+ - test/redirect_to_test.rb
104
+ - test/singleton_test.rb
105
+ - test/test_helper.rb
106
+ - test/url_helpers_test.rb
107
+ - test/views/cars/edit.html.erb
108
+ - test/views/cars/index.html.erb
109
+ - test/views/cars/new.html.erb
110
+ - test/views/cars/show.html.erb
111
+ - test/views/cities/edit.html.erb
112
+ - test/views/cities/index.html.erb
113
+ - test/views/cities/new.html.erb
114
+ - test/views/cities/show.html.erb
115
+ - test/views/comments/edit.html.erb
116
+ - test/views/comments/index.html.erb
117
+ - test/views/comments/new.html.erb
118
+ - test/views/comments/show.html.erb
119
+ - test/views/educations/new.html.erb
120
+ - test/views/employees/edit.html.erb
121
+ - test/views/employees/index.html.erb
122
+ - test/views/employees/new.html.erb
123
+ - test/views/employees/show.html.erb
124
+ - test/views/groups/edit.html.erb
125
+ - test/views/managers/edit.html.erb
126
+ - test/views/managers/new.html.erb
127
+ - test/views/managers/show.html.erb
128
+ - test/views/painters/edit.html.erb
129
+ - test/views/painters/index.html.erb
130
+ - test/views/painters/new.html.erb
131
+ - test/views/painters/show.html.erb
132
+ - test/views/pets/edit.html.erb
133
+ - test/views/pets/index.html.erb
134
+ - test/views/pets/new.html.erb
135
+ - test/views/pets/show.html.erb
136
+ - test/views/plates/edit.html.erb
137
+ - test/views/plates/index.html.erb
138
+ - test/views/plates/new.html.erb
139
+ - test/views/plates/show.html.erb
140
+ - test/views/products/edit.html.erb
141
+ - test/views/products/index.html.erb
142
+ - test/views/products/new.html.erb
143
+ - test/views/products/show.html.erb
144
+ - test/views/professors/edit.html.erb
145
+ - test/views/professors/index.html.erb
146
+ - test/views/professors/new.html.erb
147
+ - test/views/professors/show.html.erb
148
+ - test/views/projects/index.html.erb
149
+ - test/views/projects/index.json.erb
150
+ - test/views/projects/respond_to_skip_default_template.html.erb
151
+ - test/views/projects/respond_with_resource.html.erb
152
+ - test/views/students/edit.html.erb
153
+ - test/views/students/new.html.erb
154
+ - test/views/tags/edit.html.erb
155
+ - test/views/tags/index.html.erb
156
+ - test/views/tags/new.html.erb
157
+ - test/views/tags/show.html.erb
158
+ - test/views/trees/edit.html.erb
159
+ - test/views/trees/index.html.erb
160
+ - test/views/trees/new.html.erb
161
+ - test/views/trees/show.html.erb
162
+ - test/views/university/professors/edit.html.erb
163
+ - test/views/university/professors/index.html.erb
164
+ - test/views/university/professors/new.html.erb
165
+ - test/views/university/professors/show.html.erb
166
+ - test/views/users/create.js.erb
167
+ - test/views/users/destroy.js.erb
168
+ - test/views/users/edit.html.erb
169
+ - test/views/users/index.html.erb
170
+ - test/views/users/new.html.erb
171
+ - test/views/users/show.html.erb
172
+ - test/views/users/update.js.erb
77
173
  has_rdoc: true
78
174
  homepage: http://github.com/josevalim/inherited_resources
79
175
  licenses: []
80
176
 
81
177
  post_install_message:
82
- rdoc_options:
83
- - --charset=UTF-8
178
+ rdoc_options: []
179
+
84
180
  require_paths:
85
181
  - lib
86
182
  required_ruby_version: !ruby/object:Gem::Requirement
183
+ none: false
87
184
  requirements:
88
185
  - - ">="
89
186
  - !ruby/object:Gem::Version
187
+ hash: 3
90
188
  segments:
91
189
  - 0
92
190
  version: "0"
93
191
  required_rubygems_version: !ruby/object:Gem::Requirement
192
+ none: false
94
193
  requirements:
95
194
  - - ">="
96
195
  - !ruby/object:Gem::Version
196
+ hash: 3
97
197
  segments:
98
198
  - 0
99
199
  version: "0"
100
200
  requirements: []
101
201
 
102
202
  rubyforge_project: inherited_resources
103
- rubygems_version: 1.3.6
203
+ rubygems_version: 1.3.7
104
204
  signing_key:
105
205
  specification_version: 3
106
206
  summary: Inherited Resources speeds up development by making your controllers inherit all restful actions so you just have to focus on what is important.
@@ -109,14 +209,85 @@ test_files:
109
209
  - test/association_chain_test.rb
110
210
  - test/base_test.rb
111
211
  - test/belongs_to_test.rb
212
+ - test/belongs_to_with_shallow_test.rb
112
213
  - test/class_methods_test.rb
113
214
  - test/customized_base_test.rb
114
215
  - test/customized_belongs_to_test.rb
216
+ - test/customized_redirect_to_test.rb
115
217
  - test/defaults_test.rb
218
+ - test/locales/en.yml
116
219
  - test/nested_belongs_to_test.rb
220
+ - test/nested_belongs_to_with_shallow_test.rb
221
+ - test/nested_model_with_shallow_test.rb
117
222
  - test/optional_belongs_to_test.rb
118
223
  - test/polymorphic_test.rb
119
224
  - test/redirect_to_test.rb
120
225
  - test/singleton_test.rb
121
226
  - test/test_helper.rb
122
227
  - test/url_helpers_test.rb
228
+ - test/views/cars/edit.html.erb
229
+ - test/views/cars/index.html.erb
230
+ - test/views/cars/new.html.erb
231
+ - test/views/cars/show.html.erb
232
+ - test/views/cities/edit.html.erb
233
+ - test/views/cities/index.html.erb
234
+ - test/views/cities/new.html.erb
235
+ - test/views/cities/show.html.erb
236
+ - test/views/comments/edit.html.erb
237
+ - test/views/comments/index.html.erb
238
+ - test/views/comments/new.html.erb
239
+ - test/views/comments/show.html.erb
240
+ - test/views/educations/new.html.erb
241
+ - test/views/employees/edit.html.erb
242
+ - test/views/employees/index.html.erb
243
+ - test/views/employees/new.html.erb
244
+ - test/views/employees/show.html.erb
245
+ - test/views/groups/edit.html.erb
246
+ - test/views/managers/edit.html.erb
247
+ - test/views/managers/new.html.erb
248
+ - test/views/managers/show.html.erb
249
+ - test/views/painters/edit.html.erb
250
+ - test/views/painters/index.html.erb
251
+ - test/views/painters/new.html.erb
252
+ - test/views/painters/show.html.erb
253
+ - test/views/pets/edit.html.erb
254
+ - test/views/pets/index.html.erb
255
+ - test/views/pets/new.html.erb
256
+ - test/views/pets/show.html.erb
257
+ - test/views/plates/edit.html.erb
258
+ - test/views/plates/index.html.erb
259
+ - test/views/plates/new.html.erb
260
+ - test/views/plates/show.html.erb
261
+ - test/views/products/edit.html.erb
262
+ - test/views/products/index.html.erb
263
+ - test/views/products/new.html.erb
264
+ - test/views/products/show.html.erb
265
+ - test/views/professors/edit.html.erb
266
+ - test/views/professors/index.html.erb
267
+ - test/views/professors/new.html.erb
268
+ - test/views/professors/show.html.erb
269
+ - test/views/projects/index.html.erb
270
+ - test/views/projects/index.json.erb
271
+ - test/views/projects/respond_to_skip_default_template.html.erb
272
+ - test/views/projects/respond_with_resource.html.erb
273
+ - test/views/students/edit.html.erb
274
+ - test/views/students/new.html.erb
275
+ - test/views/tags/edit.html.erb
276
+ - test/views/tags/index.html.erb
277
+ - test/views/tags/new.html.erb
278
+ - test/views/tags/show.html.erb
279
+ - test/views/trees/edit.html.erb
280
+ - test/views/trees/index.html.erb
281
+ - test/views/trees/new.html.erb
282
+ - test/views/trees/show.html.erb
283
+ - test/views/university/professors/edit.html.erb
284
+ - test/views/university/professors/index.html.erb
285
+ - test/views/university/professors/new.html.erb
286
+ - test/views/university/professors/show.html.erb
287
+ - test/views/users/create.js.erb
288
+ - test/views/users/destroy.js.erb
289
+ - test/views/users/edit.html.erb
290
+ - test/views/users/index.html.erb
291
+ - test/views/users/new.html.erb
292
+ - test/views/users/show.html.erb
293
+ - test/views/users/update.js.erb