In my Magento 2.1.1 shop with 2 custom modules some of my admin content pages are not loading. (Widget, theme and shedule are loading fine - others not :-( )
For all of these I get "Not registered handle" error: Not registered handle cms_page_listing_data_source Not registered handle cms_block_listing_data_source Not registered handle design_config_listing_data_source
While all of these do exist in the xml files. app/vendor/magento/module-cms/view/adminhtml/ui_component/cms_page_listing.xml ...
Seems like this first occorred when I added the "demo" store option to the shop ... but I'm not sure.
Any help would be great!
Thanks Stijn
The problem here is that someone defined a handle in the etc/adminhtml/di.xml
search for something like this
<type name="Magento\Framework\View\Element\UiComponent\DataProvider\CollectionFactory">
<arguments>
<argument name="collections" xsi:type="array">
<item name="NameOfHandle" xsi:type="string">Vendor\Module\Model\ResourceModel\Something\Collection</item>
</argument>
</arguments>
</type>
<virtualType name="Vendor\Module\Model\ResourceModel\Something\Collection" type="Magento\Framework\View\Element\UiComponent\DataProvider\SearchResult">
<arguments>
<argument name="mainTable" xsi:type="string">NameOfTable</argument>
<argument name="resourceModel" xsi:type="string">Vendor\Module\Model\ResourceModel\Something</argument>
</arguments>
</virtualType>
Do not search for the handle that he can not find. Just go over etc/adminhtml/di.xml in your modules and search for
<type name="Magento\Framework\View\Element\UiComponent\DataProvider\CollectionFactory">
Move that bit of code to etc/di.xml
instead of etc/adminhtml/di.xml