compony 0.11.8 → 0.11.9
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.
- checksums.yaml +4 -4
- data/.yardopts +36 -1
- data/CHANGELOG.md +31 -0
- data/CLAUDE.md +85 -0
- data/Gemfile.lock +1 -1
- data/README.md +13 -3
- data/VERSION +1 -1
- data/compony.gemspec +3 -3
- data/doc/ComponentGenerator.html +1 -1
- data/doc/Components.html +1 -1
- data/doc/ComponentsGenerator.html +1 -1
- data/doc/Compony/Component.html +54 -54
- data/doc/Compony/ComponentMixins/Default/Labelling.html +1 -1
- data/doc/Compony/ComponentMixins/Default/Standalone/ResourcefulVerbDsl.html +1 -1
- data/doc/Compony/ComponentMixins/Default/Standalone/StandaloneDsl.html +109 -70
- data/doc/Compony/ComponentMixins/Default/Standalone/VerbDsl.html +64 -28
- data/doc/Compony/ComponentMixins/Default/Standalone.html +1 -1
- data/doc/Compony/ComponentMixins/Default.html +1 -1
- data/doc/Compony/ComponentMixins/Resourceful.html +213 -74
- data/doc/Compony/ComponentMixins.html +1 -1
- data/doc/Compony/Components/Buttons/CssButton.html +1 -1
- data/doc/Compony/Components/Buttons/Link.html +1 -1
- data/doc/Compony/Components/Buttons.html +1 -1
- data/doc/Compony/Components/Destroy.html +83 -29
- data/doc/Compony/Components/Edit.html +110 -38
- data/doc/Compony/Components/Form.html +551 -208
- data/doc/Compony/Components/Index.html +1 -1
- data/doc/Compony/Components/List.html +3 -3
- data/doc/Compony/Components/New.html +110 -38
- data/doc/Compony/Components/Show.html +1 -1
- data/doc/Compony/Components/WithForm.html +194 -47
- data/doc/Compony/Components.html +1 -1
- data/doc/Compony/ControllerMixin.html +1 -1
- data/doc/Compony/Engine.html +1 -1
- data/doc/Compony/Intent.html +2 -2
- data/doc/Compony/ManageIntentsDsl.html +1 -1
- data/doc/Compony/MethodAccessibleHash.html +1 -1
- data/doc/Compony/ModelFields/Anchormodel.html +1 -1
- data/doc/Compony/ModelFields/Association.html +1 -1
- data/doc/Compony/ModelFields/Attachment.html +1 -1
- data/doc/Compony/ModelFields/Base.html +1 -1
- data/doc/Compony/ModelFields/Boolean.html +1 -1
- data/doc/Compony/ModelFields/Color.html +1 -1
- data/doc/Compony/ModelFields/Currency.html +1 -1
- data/doc/Compony/ModelFields/Date.html +1 -1
- data/doc/Compony/ModelFields/Datetime.html +1 -1
- data/doc/Compony/ModelFields/Decimal.html +1 -1
- data/doc/Compony/ModelFields/Email.html +1 -1
- data/doc/Compony/ModelFields/Float.html +1 -1
- data/doc/Compony/ModelFields/Integer.html +1 -1
- data/doc/Compony/ModelFields/Percentage.html +1 -1
- data/doc/Compony/ModelFields/Phone.html +1 -1
- data/doc/Compony/ModelFields/RichText.html +1 -1
- data/doc/Compony/ModelFields/String.html +1 -1
- data/doc/Compony/ModelFields/Text.html +1 -1
- data/doc/Compony/ModelFields/Time.html +1 -1
- data/doc/Compony/ModelFields/Url.html +1 -1
- data/doc/Compony/ModelFields.html +1 -1
- data/doc/Compony/ModelMixin.html +1 -1
- data/doc/Compony/NaturalOrdering.html +1 -1
- data/doc/Compony/RequestContext.html +1 -1
- data/doc/Compony/Version.html +1 -1
- data/doc/Compony/ViewHelpers.html +1 -1
- data/doc/Compony/VirtualModel.html +1 -1
- data/doc/Compony.html +1 -1
- data/doc/ComponyController.html +1 -1
- data/doc/_index.html +97 -1
- data/doc/file.CHANGELOG.html +758 -0
- data/doc/file.README.html +25 -4
- data/doc/file.basic_component.html +314 -0
- data/doc/file.cookbook.html +189 -0
- data/doc/file.destroy.html +105 -0
- data/doc/file.dsl_reference.html +672 -0
- data/doc/file.edit.html +109 -0
- data/doc/file.example.html +291 -0
- data/doc/file.example_advanced.html +257 -0
- data/doc/file.feasibility.html +115 -0
- data/doc/file.form.html +195 -0
- data/doc/file.generators.html +89 -0
- data/doc/file.glossary.html +217 -0
- data/doc/file.gotchas.html +222 -0
- data/doc/file.index.html +135 -0
- data/doc/file.inheritance.html +136 -0
- data/doc/file.installation.html +115 -0
- data/doc/file.integrations.html +218 -0
- data/doc/file.intents.html +265 -0
- data/doc/file.internal_datastructures.html +129 -0
- data/doc/file.list.html +253 -0
- data/doc/file.maintaining.html +127 -0
- data/doc/file.model_fields.html +137 -0
- data/doc/file.nesting.html +237 -0
- data/doc/file.new.html +109 -0
- data/doc/file.ownership.html +98 -0
- data/doc/file.patterns.html +669 -0
- data/doc/file.pre_built_components.html +99 -0
- data/doc/file.resourceful.html +181 -0
- data/doc/file.show.html +158 -0
- data/doc/file.standalone.html +233 -0
- data/doc/file.virtual_models.html +117 -0
- data/doc/file.with_form.html +157 -0
- data/doc/file_list.html +160 -0
- data/doc/guide/cookbook.md +41 -0
- data/doc/guide/dsl_reference.md +155 -0
- data/doc/guide/example_advanced.md +209 -0
- data/doc/guide/generators.md +1 -1
- data/doc/guide/glossary.md +42 -0
- data/doc/guide/gotchas.md +125 -0
- data/doc/guide/maintaining.md +64 -0
- data/doc/guide/patterns.md +681 -0
- data/doc/guide/pre_built_components/edit.md +1 -1
- data/doc/guide/pre_built_components/index.md +64 -1
- data/doc/guide/pre_built_components/list.md +111 -7
- data/doc/guide/pre_built_components/show.md +57 -2
- data/doc/guide/pre_built_components/with_form.md +56 -9
- data/doc/guide/pre_built_components.md +7 -2
- data/doc/guide/standalone.md +16 -1
- data/doc/index.html +25 -4
- data/doc/integrations.md +61 -0
- data/doc/llms.txt +62 -0
- data/doc/top-level-namespace.html +1 -1
- data/lib/compony/component.rb +8 -3
- data/lib/compony/component_mixins/default/standalone/standalone_dsl.rb +32 -15
- data/lib/compony/component_mixins/default/standalone/verb_dsl.rb +11 -3
- data/lib/compony/component_mixins/resourceful.rb +30 -16
- data/lib/compony/components/destroy.rb +21 -1
- data/lib/compony/components/edit.rb +25 -1
- data/lib/compony/components/form.rb +63 -21
- data/lib/compony/components/list.rb +1 -1
- data/lib/compony/components/new.rb +25 -1
- data/lib/compony/components/with_form.rb +20 -5
- data/lib/compony/intent.rb +1 -1
- metadata +43 -1
|
@@ -162,7 +162,7 @@
|
|
|
162
162
|
</div>
|
|
163
163
|
|
|
164
164
|
<div id="footer">
|
|
165
|
-
Generated on
|
|
165
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
166
166
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
167
167
|
0.9.34 (ruby-3.3.5).
|
|
168
168
|
</div>
|
|
@@ -546,7 +546,7 @@
|
|
|
546
546
|
|
|
547
547
|
|
|
548
548
|
<span class="summary_desc"><div class='inline'>
|
|
549
|
-
<p>DSL method If a block is given: Enters the DSL where row intents can be added or removed (use from Component#setup within the component).</p>
|
|
549
|
+
<p>DSL method If a block is given: Enters the DSL where row intents can be added or removed (use from <span class='object_link'><a href="../Component.html#setup-class_method" title="Compony::Component.setup (method)">Compony::Component.setup</a></span> within the component).</p>
|
|
550
550
|
</div></span>
|
|
551
551
|
|
|
552
552
|
</li>
|
|
@@ -2116,7 +2116,7 @@
|
|
|
2116
2116
|
</h3><div class="docstring">
|
|
2117
2117
|
<div class="discussion">
|
|
2118
2118
|
|
|
2119
|
-
<p>DSL method If a block is given: Enters the DSL where row intents can be added or removed (use from Component#setup within the component). If no block is given: Builds the declared intents for the given record and returns them (use in <code>content</code> or <code>before_render</code>, pass kwarg <code>:data</code>).</p>
|
|
2119
|
+
<p>DSL method If a block is given: Enters the DSL where row intents can be added or removed (use from <span class='object_link'><a href="../Component.html#setup-class_method" title="Compony::Component.setup (method)">Compony::Component.setup</a></span> within the component). If no block is given: Builds the declared intents for the given record and returns them (use in <code>content</code> or <code>before_render</code>, pass kwarg <code>:data</code>).</p>
|
|
2120
2120
|
|
|
2121
2121
|
|
|
2122
2122
|
</div>
|
|
@@ -2689,7 +2689,7 @@
|
|
|
2689
2689
|
</div>
|
|
2690
2690
|
|
|
2691
2691
|
<div id="footer">
|
|
2692
|
-
Generated on
|
|
2692
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
2693
2693
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
2694
2694
|
0.9.34 (ruby-3.3.5).
|
|
2695
2695
|
</div>
|
|
@@ -138,7 +138,7 @@
|
|
|
138
138
|
|
|
139
139
|
|
|
140
140
|
<h2>
|
|
141
|
-
|
|
141
|
+
DSL
|
|
142
142
|
<small><a href="#" class="summary_toggle">collapse</a></small>
|
|
143
143
|
</h2>
|
|
144
144
|
|
|
@@ -147,7 +147,7 @@
|
|
|
147
147
|
<li class="public ">
|
|
148
148
|
<span class="summary_signature">
|
|
149
149
|
|
|
150
|
-
<a href="#on_create_failed_respond-instance_method" title="#on_create_failed_respond (instance method)">#<strong>on_create_failed_respond</strong>
|
|
150
|
+
<a href="#on_create_failed_respond-instance_method" title="#on_create_failed_respond (instance method)">#<strong>on_create_failed_respond</strong> { ... } ⇒ void </a>
|
|
151
151
|
|
|
152
152
|
|
|
153
153
|
|
|
@@ -162,7 +162,7 @@
|
|
|
162
162
|
|
|
163
163
|
|
|
164
164
|
<span class="summary_desc"><div class='inline'>
|
|
165
|
-
<p>DSL method.</p>
|
|
165
|
+
<p>DSL method Overrides the response issued when the create failed (<code>@create_succeeded</code> is not true).</p>
|
|
166
166
|
</div></span>
|
|
167
167
|
|
|
168
168
|
</li>
|
|
@@ -171,7 +171,7 @@
|
|
|
171
171
|
<li class="public ">
|
|
172
172
|
<span class="summary_signature">
|
|
173
173
|
|
|
174
|
-
<a href="#on_created-instance_method" title="#on_created (instance method)">#<strong>on_created</strong>
|
|
174
|
+
<a href="#on_created-instance_method" title="#on_created (instance method)">#<strong>on_created</strong> { ... } ⇒ void </a>
|
|
175
175
|
|
|
176
176
|
|
|
177
177
|
|
|
@@ -186,7 +186,7 @@
|
|
|
186
186
|
|
|
187
187
|
|
|
188
188
|
<span class="summary_desc"><div class='inline'>
|
|
189
|
-
<p>DSL method Sets
|
|
189
|
+
<p>DSL method Sets an optional hook evaluated (with backfire) after a successful create but before responding.</p>
|
|
190
190
|
</div></span>
|
|
191
191
|
|
|
192
192
|
</li>
|
|
@@ -195,7 +195,7 @@
|
|
|
195
195
|
<li class="public ">
|
|
196
196
|
<span class="summary_signature">
|
|
197
197
|
|
|
198
|
-
<a href="#on_created_redirect_path-instance_method" title="#on_created_redirect_path (instance method)">#<strong>on_created_redirect_path</strong>
|
|
198
|
+
<a href="#on_created_redirect_path-instance_method" title="#on_created_redirect_path (instance method)">#<strong>on_created_redirect_path</strong> { ... } ⇒ void </a>
|
|
199
199
|
|
|
200
200
|
|
|
201
201
|
|
|
@@ -210,7 +210,7 @@
|
|
|
210
210
|
|
|
211
211
|
|
|
212
212
|
<span class="summary_desc"><div class='inline'>
|
|
213
|
-
<p>DSL method.</p>
|
|
213
|
+
<p>DSL method Overrides the redirect target used by the default <span class='object_link'><a href="#on_created_respond-instance_method" title="Compony::Components::New#on_created_respond (method)">#on_created_respond</a></span> (keeping the default flash).</p>
|
|
214
214
|
</div></span>
|
|
215
215
|
|
|
216
216
|
</li>
|
|
@@ -219,7 +219,7 @@
|
|
|
219
219
|
<li class="public ">
|
|
220
220
|
<span class="summary_signature">
|
|
221
221
|
|
|
222
|
-
<a href="#on_created_respond-instance_method" title="#on_created_respond (instance method)">#<strong>on_created_respond</strong>
|
|
222
|
+
<a href="#on_created_respond-instance_method" title="#on_created_respond (instance method)">#<strong>on_created_respond</strong> { ... } ⇒ void </a>
|
|
223
223
|
|
|
224
224
|
|
|
225
225
|
|
|
@@ -234,7 +234,7 @@
|
|
|
234
234
|
|
|
235
235
|
|
|
236
236
|
<span class="summary_desc"><div class='inline'>
|
|
237
|
-
<p>DSL method.</p>
|
|
237
|
+
<p>DSL method Overrides the response issued after a successful create.</p>
|
|
238
238
|
</div></span>
|
|
239
239
|
|
|
240
240
|
</li>
|
|
@@ -286,7 +286,7 @@
|
|
|
286
286
|
<div class="method_details first">
|
|
287
287
|
<h3 class="signature first" id="on_create_failed_respond-instance_method">
|
|
288
288
|
|
|
289
|
-
#<strong>on_create_failed_respond</strong>
|
|
289
|
+
#<strong>on_create_failed_respond</strong> { ... } ⇒ <tt>void</tt>
|
|
290
290
|
|
|
291
291
|
|
|
292
292
|
|
|
@@ -294,14 +294,32 @@
|
|
|
294
294
|
|
|
295
295
|
</h3><div class="docstring">
|
|
296
296
|
<div class="discussion">
|
|
297
|
-
|
|
298
|
-
<p>DSL method</p>
|
|
297
|
+
<p class="note returns_void">This method returns an undefined value.</p>
|
|
298
|
+
<p>DSL method Overrides the response issued when the create failed (<code>@create_succeeded</code> is not true). The default logs the errors with level <code>warn</code> and re-renders the component with HTTP 422 so the form shows errors.</p>
|
|
299
299
|
|
|
300
300
|
|
|
301
301
|
</div>
|
|
302
302
|
</div>
|
|
303
303
|
<div class="tags">
|
|
304
304
|
|
|
305
|
+
<p class="tag_title">Yields:</p>
|
|
306
|
+
<ul class="yield">
|
|
307
|
+
|
|
308
|
+
<li>
|
|
309
|
+
|
|
310
|
+
|
|
311
|
+
<span class='type'></span>
|
|
312
|
+
|
|
313
|
+
|
|
314
|
+
|
|
315
|
+
|
|
316
|
+
<div class='inline'>
|
|
317
|
+
<p>Runs in the component’s request context; expected to render or redirect.</p>
|
|
318
|
+
</div>
|
|
319
|
+
|
|
320
|
+
</li>
|
|
321
|
+
|
|
322
|
+
</ul>
|
|
305
323
|
|
|
306
324
|
</div><table class="source_code">
|
|
307
325
|
<tr>
|
|
@@ -309,12 +327,12 @@
|
|
|
309
327
|
<pre class="lines">
|
|
310
328
|
|
|
311
329
|
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
330
|
+
120
|
|
331
|
+
121
|
|
332
|
+
122</pre>
|
|
315
333
|
</td>
|
|
316
334
|
<td>
|
|
317
|
-
<pre class="code"><span class="info file"># File 'lib/compony/components/new.rb', line
|
|
335
|
+
<pre class="code"><span class="info file"># File 'lib/compony/components/new.rb', line 120</span>
|
|
318
336
|
|
|
319
337
|
<span class='kw'>def</span> <span class='id identifier rubyid_on_create_failed_respond'>on_create_failed_respond</span><span class='lparen'>(</span><span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
|
320
338
|
<span class='ivar'>@on_create_failed_respond_block</span> <span class='op'>=</span> <span class='id identifier rubyid_block'>block</span>
|
|
@@ -327,7 +345,7 @@
|
|
|
327
345
|
<div class="method_details ">
|
|
328
346
|
<h3 class="signature " id="on_created-instance_method">
|
|
329
347
|
|
|
330
|
-
#<strong>on_created</strong>
|
|
348
|
+
#<strong>on_created</strong> { ... } ⇒ <tt>void</tt>
|
|
331
349
|
|
|
332
350
|
|
|
333
351
|
|
|
@@ -335,14 +353,32 @@
|
|
|
335
353
|
|
|
336
354
|
</h3><div class="docstring">
|
|
337
355
|
<div class="discussion">
|
|
338
|
-
|
|
339
|
-
<p>DSL method Sets
|
|
356
|
+
<p class="note returns_void">This method returns an undefined value.</p>
|
|
357
|
+
<p>DSL method Sets an optional hook evaluated (with backfire) after a successful create but before responding. Suitable for post-create side effects (like an <code>after_create</code> that only fires when this component created the record). Do not redirect or render here - use <span class='object_link'><a href="#on_created_respond-instance_method" title="Compony::Components::New#on_created_respond (method)">#on_created_respond</a></span> / <span class='object_link'><a href="#on_created_redirect_path-instance_method" title="Compony::Components::New#on_created_redirect_path (method)">#on_created_redirect_path</a></span> for that.</p>
|
|
340
358
|
|
|
341
359
|
|
|
342
360
|
</div>
|
|
343
361
|
</div>
|
|
344
362
|
<div class="tags">
|
|
345
363
|
|
|
364
|
+
<p class="tag_title">Yields:</p>
|
|
365
|
+
<ul class="yield">
|
|
366
|
+
|
|
367
|
+
<li>
|
|
368
|
+
|
|
369
|
+
|
|
370
|
+
<span class='type'></span>
|
|
371
|
+
|
|
372
|
+
|
|
373
|
+
|
|
374
|
+
|
|
375
|
+
<div class='inline'>
|
|
376
|
+
<p>Runs in the component’s request context after <code>@data</code> was saved successfully.</p>
|
|
377
|
+
</div>
|
|
378
|
+
|
|
379
|
+
</li>
|
|
380
|
+
|
|
381
|
+
</ul>
|
|
346
382
|
|
|
347
383
|
</div><table class="source_code">
|
|
348
384
|
<tr>
|
|
@@ -350,12 +386,12 @@
|
|
|
350
386
|
<pre class="lines">
|
|
351
387
|
|
|
352
388
|
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
389
|
+
90
|
|
390
|
+
91
|
|
391
|
+
92</pre>
|
|
356
392
|
</td>
|
|
357
393
|
<td>
|
|
358
|
-
<pre class="code"><span class="info file"># File 'lib/compony/components/new.rb', line
|
|
394
|
+
<pre class="code"><span class="info file"># File 'lib/compony/components/new.rb', line 90</span>
|
|
359
395
|
|
|
360
396
|
<span class='kw'>def</span> <span class='id identifier rubyid_on_created'>on_created</span><span class='lparen'>(</span><span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
|
361
397
|
<span class='ivar'>@on_created_block</span> <span class='op'>=</span> <span class='id identifier rubyid_block'>block</span>
|
|
@@ -368,7 +404,7 @@
|
|
|
368
404
|
<div class="method_details ">
|
|
369
405
|
<h3 class="signature " id="on_created_redirect_path-instance_method">
|
|
370
406
|
|
|
371
|
-
#<strong>on_created_redirect_path</strong>
|
|
407
|
+
#<strong>on_created_redirect_path</strong> { ... } ⇒ <tt>void</tt>
|
|
372
408
|
|
|
373
409
|
|
|
374
410
|
|
|
@@ -376,14 +412,32 @@
|
|
|
376
412
|
|
|
377
413
|
</h3><div class="docstring">
|
|
378
414
|
<div class="discussion">
|
|
379
|
-
|
|
380
|
-
<p>DSL method</p>
|
|
415
|
+
<p class="note returns_void">This method returns an undefined value.</p>
|
|
416
|
+
<p>DSL method Overrides the redirect target used by the default <span class='object_link'><a href="#on_created_respond-instance_method" title="Compony::Components::New#on_created_respond (method)">#on_created_respond</a></span> (keeping the default flash). Defaults to the data’s Show, the owner’s Show, or the data’s Index.</p>
|
|
381
417
|
|
|
382
418
|
|
|
383
419
|
</div>
|
|
384
420
|
</div>
|
|
385
421
|
<div class="tags">
|
|
386
422
|
|
|
423
|
+
<p class="tag_title">Yields:</p>
|
|
424
|
+
<ul class="yield">
|
|
425
|
+
|
|
426
|
+
<li>
|
|
427
|
+
|
|
428
|
+
|
|
429
|
+
<span class='type'></span>
|
|
430
|
+
|
|
431
|
+
|
|
432
|
+
|
|
433
|
+
|
|
434
|
+
<div class='inline'>
|
|
435
|
+
<p>Runs in the component’s request context; expected to return a Rails path (e.g. via <code>Compony.path</code>).</p>
|
|
436
|
+
</div>
|
|
437
|
+
|
|
438
|
+
</li>
|
|
439
|
+
|
|
440
|
+
</ul>
|
|
387
441
|
|
|
388
442
|
</div><table class="source_code">
|
|
389
443
|
<tr>
|
|
@@ -391,12 +445,12 @@
|
|
|
391
445
|
<pre class="lines">
|
|
392
446
|
|
|
393
447
|
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
448
|
+
110
|
|
449
|
+
111
|
|
450
|
+
112</pre>
|
|
397
451
|
</td>
|
|
398
452
|
<td>
|
|
399
|
-
<pre class="code"><span class="info file"># File 'lib/compony/components/new.rb', line
|
|
453
|
+
<pre class="code"><span class="info file"># File 'lib/compony/components/new.rb', line 110</span>
|
|
400
454
|
|
|
401
455
|
<span class='kw'>def</span> <span class='id identifier rubyid_on_created_redirect_path'>on_created_redirect_path</span><span class='lparen'>(</span><span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
|
402
456
|
<span class='ivar'>@on_created_redirect_path_block</span> <span class='op'>=</span> <span class='id identifier rubyid_block'>block</span>
|
|
@@ -409,7 +463,7 @@
|
|
|
409
463
|
<div class="method_details ">
|
|
410
464
|
<h3 class="signature " id="on_created_respond-instance_method">
|
|
411
465
|
|
|
412
|
-
#<strong>on_created_respond</strong>
|
|
466
|
+
#<strong>on_created_respond</strong> { ... } ⇒ <tt>void</tt>
|
|
413
467
|
|
|
414
468
|
|
|
415
469
|
|
|
@@ -417,14 +471,32 @@
|
|
|
417
471
|
|
|
418
472
|
</h3><div class="docstring">
|
|
419
473
|
<div class="discussion">
|
|
420
|
-
|
|
421
|
-
<p>DSL method</p>
|
|
474
|
+
<p class="note returns_void">This method returns an undefined value.</p>
|
|
475
|
+
<p>DSL method Overrides the response issued after a successful create. The default shows a flash and redirects to <span class='object_link'><a href="#on_created_redirect_path-instance_method" title="Compony::Components::New#on_created_redirect_path (method)">#on_created_redirect_path</a></span>. If you override this, <span class='object_link'><a href="#on_created_redirect_path-instance_method" title="Compony::Components::New#on_created_redirect_path (method)">#on_created_redirect_path</a></span> is no longer called.</p>
|
|
422
476
|
|
|
423
477
|
|
|
424
478
|
</div>
|
|
425
479
|
</div>
|
|
426
480
|
<div class="tags">
|
|
427
481
|
|
|
482
|
+
<p class="tag_title">Yields:</p>
|
|
483
|
+
<ul class="yield">
|
|
484
|
+
|
|
485
|
+
<li>
|
|
486
|
+
|
|
487
|
+
|
|
488
|
+
<span class='type'></span>
|
|
489
|
+
|
|
490
|
+
|
|
491
|
+
|
|
492
|
+
|
|
493
|
+
<div class='inline'>
|
|
494
|
+
<p>Runs in the component’s request context; expected to render or redirect.</p>
|
|
495
|
+
</div>
|
|
496
|
+
|
|
497
|
+
</li>
|
|
498
|
+
|
|
499
|
+
</ul>
|
|
428
500
|
|
|
429
501
|
</div><table class="source_code">
|
|
430
502
|
<tr>
|
|
@@ -432,12 +504,12 @@
|
|
|
432
504
|
<pre class="lines">
|
|
433
505
|
|
|
434
506
|
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
507
|
+
100
|
|
508
|
+
101
|
|
509
|
+
102</pre>
|
|
438
510
|
</td>
|
|
439
511
|
<td>
|
|
440
|
-
<pre class="code"><span class="info file"># File 'lib/compony/components/new.rb', line
|
|
512
|
+
<pre class="code"><span class="info file"># File 'lib/compony/components/new.rb', line 100</span>
|
|
441
513
|
|
|
442
514
|
<span class='kw'>def</span> <span class='id identifier rubyid_on_created_respond'>on_created_respond</span><span class='lparen'>(</span><span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
|
443
515
|
<span class='ivar'>@on_created_respond_block</span> <span class='op'>=</span> <span class='id identifier rubyid_block'>block</span>
|
|
@@ -452,7 +524,7 @@
|
|
|
452
524
|
</div>
|
|
453
525
|
|
|
454
526
|
<div id="footer">
|
|
455
|
-
Generated on
|
|
527
|
+
Generated on Mon May 18 13:55:35 2026 by
|
|
456
528
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
457
529
|
0.9.34 (ruby-3.3.5).
|
|
458
530
|
</div>
|
|
@@ -755,7 +755,7 @@
|
|
|
755
755
|
</div>
|
|
756
756
|
|
|
757
757
|
<div id="footer">
|
|
758
|
-
Generated on
|
|
758
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
759
759
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
760
760
|
0.9.34 (ruby-3.3.5).
|
|
761
761
|
</div>
|