Here is my extended Ext.tree.Panel:
Ext.define('WP.view.portlet.Tree', {
extend: 'Ext.tree.Panel',
alias: 'widget.portlettree',
store: 'Portlets',
rootVisible: false,
viewConfig: {
plugins: {
ptype: 'treeviewdragdrop'
}
}
});
When the page is loaded an error is thrown from the PluginManager.js file, line 58:
Uncaught TypeError: Cannot read property 'init' of null
The examples from Sencha use the same configuration, so I'm not sure what I'm missing that is causing this error. Thank you in advance.
The correct way to fix this would be to require the plugin in your project.
In this case Ext.tree.plugin.TreeViewDragDrop.
For example:
Ext.application({
requires: [
'Ext.chart.Chart',
'Ext.chart.series.Line',
'Ext.chart.series.Column',
'Ext.chart.axis.Numeric',
'Ext.chart.axis.Category',
'Ext.layout.container.Border',
'Ext.tree.plugin.TreeViewDragDrop'
],
...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With