Problem
I get error when I try to quick edit referenced custom blocks that are using complex inline entity form.
Is there some workaround for this? It's working with Inline entity form - Simple, but I need Complex because Complex is used when we can reference multiple custom bock types.
Replicate steps
1. Install Inline Entity Form module.
2. Create custom content type
3. Create Entity Reference field to reference some custom blocks
4. Manage form display and change widget to Inline entity form - Complex
5. Create test node
6. Go to node page, click on quick edit icon and try to edit custom block that is referenced.
Image with error attached.
Recent log message:
Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException: You have requested a non-existent service "content_translation.manager". in Drupal\Component\DependencyInjection\Container->get() (line 157 of E:\Work\TestProjects\d8testit\core\lib\Drupal\Component\DependencyInjection\Container.php).
| Comment | File | Size | Author |
|---|---|---|---|
| #9 | ief_complex_quick_edit_error-2855627-9.patch | 894 bytes | mjpa |
| #6 | Screen Shot 2019-05-02 at 9.14.47 AM.png | 81.76 KB | neeravbm |
| #5 | ief_complex_quick_edit_error-2855627-5.patch | 1.33 KB | pq |
| quick_edit_error.PNG | 23.13 KB | blast0344 |
Issue fork inline_entity_form-2855627
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
wim leersComment #3
thomas.frobieterYes we can confirm this problem still exist. It doesn't only exist for blocks, it also exists for other referenced entities and custom / ECK entities. The best would be to jump "one level lower" and inline edit like you would if you'd open that entity directly with its fields.
Comment #4
frobStill an issue, however if translations are enabled on the site then the config_translation content_translation and local modules are enabled the IEF form widget will display (though it cannot be used) and the log will have this error.
Warning: assert(): The container was serialized. failed in Drupal\Core\DependencyInjection\Container->__sleep() (line 28 of /var/www/fremont-mlc.local.ciservers.net/web/public/core/lib/Drupal/Core/DependencyInjection/Container.php)Comment #5
pq commentedAttached a patch that checks whether content_translation is enabled and if not returns FALSE from
InlineEntityFormBase->isTranslating().Comment #6
neeravbm commentedThe patch does resolve the error. Here are the steps I took to test the patch:
Comment #7
chris matthews commentedPer @joachim's comment in #2576445: Inline Entity Form stable release plan #20, this RTBC issue is blocked until #2974544: Convert tests from Simpletest to FunctionalJavascript is fixed.
Comment #8
oknate#2974544: Convert tests from Simpletest to FunctionalJavascript is in, this is unblocked.
#5 introduces some new services into the widget:
'module_handler' and 'content_translation.manager' need to be added to the constructor. Also, this should have test coverage.
Comment #9
mjpa commentedDifferent approach, just check the service exists rather than the module. No new services introduced then. The
content_translation.managerservice can't really go in the constructor as the classes can't be used if the module doesn't exist.Comment #10
mjpa commentedComment #11
podarok#9
Also, quickedit deprecated, so probably we can just drop this
Comment #14
shivam_tiwari commentedComment #15
podarok