We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 34926
    • 87 Posts
    Admittedly I am still getting my head around Ext JS. I was wondering if its possible to modify an existing rendered panel (in this case modx-resource-panel).

    Adding a Custom Field in RTFM shows outputting HTML to add custom fields to manager generated pages. That isn't very flexible in my opinion so I need some advice on adding and positioning an element inside the actual panel itself.

    Apologies if this isn't making much sense. Basically I am trying to add a textfield underneath the templates drop down when creating/editing documents via MODExt. To achieve this I have a plugin registering a script with the OnDocFormRender system event and the following line overwrites the entire panel:

    Ext.reg('modx-panel-resource', Argen.panel.Resource);



    Any suggestions would be massively appreciated.
      • 28215
      • 4,149 Posts
      Make sure your panel extends MODx.panel.Resource, as well as overwrites the xtype.

      Ext.extend(MODx.panel.Resource,Argen.panel.Resource,{
        // my custom methods here
      });
      
        shaun mccormick | bigcommerce mgr of software engineering, former modx co-architect | github | splittingred.com