Skip to main content
Announcements
YOUR OPINION MATTERS! Please take the Qlik Experience survey you received via email. Survey ends June 14.
cancel
Showing results for 
Search instead for 
Did you mean: 
_jespers_
Partner - Creator II
Partner - Creator II

Access to extension object ID in properties.js

Is there any way that I can access the extension object id in properties.js?

I'm building a custom component in properties.js where I need to know the Id of the extension object.

Properties.js

define( [

        "qlik"

    ],

    function (qlik) {

    var customComponent = {

        type: "string",

        component: {

            template: '<div>Custom Component Template</div>',

            controller: ['$scope', function ( $scope ){

                // I want to get access to the extension object ID here

            }]

        },

        ref: "customComponent",

        defaultValue: "default"

    };

    var myCustomSection = {

        component: "expandable-items",

        translation: "Widget.Settings",

        items: {

            header1: {

                type: 'items',

                translation: "Component",

                items: {

                    item1: customComponent

                }

            }

        }

    };

    return {

        type: "items",

        component: "accordion",

        items: {

            customSection: myCustomSection

        }

    };

} );

I do not want to use $rootScope from the main.js file since if you have the same object multiple times on the sheet the $rootScope variable is being overwritten (maybe there is a way to avoid this and have a unique $rootScope for current extension?)


Regards

Jesper

0 Replies