Bug #81891
closed
Flexform: renderType => selectTree not loading
Added by Arun Chandran over 7 years ago.
Updated about 6 years ago.
Description
Hi,
In TYPO3 8.7 LTS, we are facing an issue with "selectTree" render type in TCA/Flexforms. Seems like the issue with low internet connections. Can't see any errors in the debug console. If reload the TCA again and again, sometimes the tree displayed. Please see the attached screen.
Thank you.
Files
Any update for this issue? It still exists.
Thank you.
- Subject changed from renderType => selectTree not loading to Flexform: renderType => selectTree not loading
- Priority changed from Should have to Must have
I could confirm this bug, but I don't think it's related with low internet connections.
I've also done some debuggings, which shows that the value $result['selectTreeCompileItems'] in
\TYPO3\CMS\Backend\Form\FormDataProvider\TcaSelectTreeItems::addData is false for those tree flexform fields, so no database requests are done in that tree fetchData ajax request. But toggling that flag manually doesn’t solve the bug. So it seems that there are some other reasons, which explains that false behavior.
Thank you for further investigations.
I could reliable simulate this with throttling the internet connection. I tracked it down to /typo3/sysext/backend/Resources/Public/JavaScript/FormEngine/Element/SelectTreeElement.js where $('.typo3-tceforms-tree .treeRecord').each(function (i, element) doesn't get executed, when $('.typo3-tceforms-tree .treeRecord') isn't loaded quick enough, which means the SelectTree isn't initialized.
So I wrapped it into a document.ready statement. I don't know if that is the best way to do it, but it solved the problem:
$(document).ready(function() {
$('.typo3-tceforms-tree .treeRecord').each(function (i, element) {
....
});
- Status changed from New to Under Review
- Category set to Performance
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
- Status changed from Resolved to Closed
Also available in: Atom
PDF