If the entity uses paragraphs the "add paragraph" field selector is displayed on the configure form, along with an error (see below).
If the paragraphs field is required, submitting the configure form will fail with "field is required". This prevents editing any field on the entity.
This possibly applies to any referenced entity handled via the entity_reference_revisions module and widget. Possibly inline entity form too?
Notice: Only variable references should be returned by reference in Drupal\views_bulk_edit\Plugin\Action\ModifyEntityValues->findFormElement() (line 361 of modules/contrib/views_bulk_edit/src/Plugin/Action/ModifyEntityValues.php).
Drupal\views_bulk_edit\Plugin\Action\ModifyEntityValues->findFormElement(Array) (Line: 357)
Drupal\views_bulk_edit\Plugin\Action\ModifyEntityValues->findFormElement(Array) (Line: 357)
Drupal\views_bulk_edit\Plugin\Action\ModifyEntityValues->findFormElement(Array) (Line: 313)
Drupal\views_bulk_edit\Plugin\Action\ModifyEntityValues->getSelectorForm('node', 'page', Array) (Line: 282)
Drupal\views_bulk_edit\Plugin\Action\ModifyEntityValues->getBundleForm('node', 'page', 'Generic page', Array, Object) (Line: 112)
Drupal\views_bulk_edit\Plugin\Action\ModifyEntityValues->buildConfigurationForm(Array, Object) (Line: 124)
Drupal\views_bulk_operations\Form\ConfigureAction->buildForm(Array, Object, 'content', 'page_1')
call_user_func_array(Array, Array) (Line: 514)
Drupal\Core\Form\FormBuilder->retrieveForm('views_bulk_operations_configure_action', Object) (Line: 271)
Drupal\Core\Form\FormBuilder->buildForm('views_bulk_operations_configure_action', Object) (Line: 74)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 582)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
call_user_func_array(Object, Array) (Line: 153)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 68)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 50)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 657)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)| Comment | File | Size | Author |
|---|---|---|---|
| #18 | interdiff-2934226-15-18.txt | 661 bytes | samuel.mortenson |
| #18 | 2934226-18.patch | 2.51 KB | samuel.mortenson |
Comments
Comment #2
brooke_heaton commentedI'm seeing this same issue.
Comment #3
brtamas commentedPatch attached.
Comment #4
benjy commentedWe could delete the return entirely? Would that resolve the issue?
Comment #5
graber commentedCan you check if this solves the problem as well?
Comment #7
graber commentedRight.
Comment #9
graber commentedSunday coding..
Comment #10
graber commentedComment #11
jibranWe should add tests here.
Comment #12
Chris CharltonPatch helped.
Comment #13
Chris CharltonJust want to reiterate, patch #10 helped get this unstuck for me.
Comment #14
trevorbradley commentedThis doesn't seem to be quite right. I have some paragraph form structures where #title and #type never seem to be at the same level. Abridged, my no-default multiple possible paragraph in a single paragraph field looks like:
#title and #type never seem to be at the same recursion level at the same time.
I'm going to try a different approach here, see if I can pass good Titles down through the recursive function without breaking VBO/VBE.
Comment #15
trevorbradley commentedOK, here's my attempt. While findFormElements drills down, it now keeps track of $title from previous iterations just in case this doesn't have them.
Appears to work better than what was there, but definitely needs review.
Comment #16
bfodeke commented#15 works for me. This happens to address two separate issues.
Comment #17
samuel.mortensonThe patch in #15 didn't work for me when using the "Paragraphs Classic" widget.
Comment #18
samuel.mortensonFacepalm, didn't mean to include my .idea folder.
Comment #19
drup16 commentedPatch from #18 works.
Comment #21
graber commentedHope this solves the issue for everyone, thanks!
Comment #22
joelsteidl commentedCurious if this actually allows creating Paragraphs on a node. Happy to open a new issue, but wanted to make sure it was different.
So far I can't get it working. Using 8.x-2.5 Views Bulk Operations & 8.x-2.4 Views Bulk Edit (tried dev as well)
I've tried Classic and Experimental widgets for the Paragraph.
I can add the Paragraph without error, but when I go edit the node, nothing is there for the Paragraph field.
Thank you!
Comment #23
trevorbradley commented@joelsteidl - as this ticket is fixed, passed and now part of the latest release, I'd strongly suggest making a new ticket.
Comment #24
joelsteidl commented@TrevorBradley
Thanks for the quick reply. Any input on versions of VBO/VBE that I should be using. I don't want to flag this as a new issue if I'm simply using the wrong versions.
Also, was this issue's original intent to make Paragraphs work with VBE or solve an error that was happening. Sorry, the issue is not super clear.
Comment #25
johnpitcairn commentedIt was to solve an error when VBO processing the parent entity.
Comment #26
trevorbradley commentedVBO and VBE both were recently updated (about 4 days ago). Try again with both those versions and verify your behaviour.
I'm not saying your issue is invalid! It's just that even if it were an issue with this ticket, it's going to have to be fixed in a new ticket. The code is committed and can only be repaired, not recalled...
Comment #28
osopolar@joelsteidl: Did you find the problem and got it work? Adding paragraphs with VBE is working for me only if a default paragraph type is defined for the form widget.