Skip to Content

Issue extending a controller that extends another controller

In my SAPUI5 application I have a controller (Produzione-Stato) that extend another controller (ExcelGenerator). In the Component.js file I have added the following property:

customizing: {
       "sap.ui.controllerExtensions": {
            "cabot.ui.wt.controller.Produzione-Stato": {
                controllerName: "cabot.ui.wt.controller.ExcelGenerator",
                },
       }
}

The application works fine at this stage. However I would like the ExcelGenerator controller to extend another controller (say C2ExcelGenerator). I have tried to modify the Component.js file by adding the following:

customizing: {
       "sap.ui.controllerExtensions": {
            "cabot.ui.wt.controller.Produzione-Stato": {
                controllerName: "cabot.ui.wt.controller.ExcelGenerator",
                },
            "cabot.ui.wt.controller.ExcelGenerator": {
                 controllerName: "cabot.ui.wt.controller.C2ExcelGenerator",
                },
       }
}

This however throws exceptions errors. What is the correct approach to extend controllers on a multilevel stage or to have a controller that extend more than one controller? Thanks in advance!

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

0 Answers