4 Replies Latest reply: Dec 3, 2014 3:02 PM by Karl Fredberg RSS

    qListObjectDef and qHyperCubeDef in the same extension?

    Karl Fredberg

      Is it possible to have a qListObjectDef and qHyperCubeDef in the same extension?

        • Re: qListObjectDef and qHyperCubeDef in the same extension?
          Erik Wetterberg

          Yes it is. You can also have multiple hypercubes and listobjects.

           

          Erik

            • Re: Re: qListObjectDef and qHyperCubeDef in the same extension?
              Karl Fredberg

              I have tried but they seem to interfere with each others. When a field is added it screws up both the dimension and the measure. This is how I tested it and it didn't work.

               

                      initialProperties : {
                          version: 1.0,
                          qHyperCubeDef : {
                              qDimensions : [],
                              qMeasures : [],
                              qInitialDataFetch : [{
                                  qWidth : 10,
                                  qHeight : 50
                              }]
                          },
                          qListObjectDef : {
                              qShowAlternatives : true,
                              qFrequencyMode : "V",
                              qSortCriterias : {
                                  qSortByState : 1
                              },
                              qInitialDataFetch : [{
                                  qWidth : 2,
                                  qHeight : 1000
                              }]
                          }
                      },
                      definition : {
                          type : "items",
                          component : "accordion",
                          items : {
                              dimensions : {
                                  uses : "dimensions",
                                  min : 1
                              },
                              measures : {
                                  uses : "measures",
                                  min : 0
                              },
                              field : {
                                  type : "items",
                                  label : "Fields",
                                  translation : "Field",
                                  ref : "qListObjectDef",
                                  min : 1,
                                  max : 1,
                                  items : {
                                      label : {
                                          type : "string",
                                          ref : "qListObjectDef.qDef.qFieldLabels.0",
                                          translation : "Common.Label",
                                          show : true
                                      },
              

               

              How would you set it up?

                • Re: Re: qListObjectDef and qHyperCubeDef in the same extension?
                  Karl Fredberg

                  I get an error

                  TypeError: Cannot read property 'offsetTop' of undefined


                    • Re: Re: Re: qListObjectDef and qHyperCubeDef in the same extension?
                      Karl Fredberg

                      Found a solution!

                      If you put the qListObjectDef inside another object, they don't interfere anymore.

                       

                      dateField : {
                                     qListObjectDef : {
                                          qShowAlternatives : true,
                                          qFrequencyMode : "V",
                                          qSortCriterias : {
                                              qSortByState : 1
                                          },
                                          qInitialDataFetch : [{
                                              qWidth : 2,
                                              qHeight : 1000
                                          }]
                                      },
                                  },
                                  qHyperCubeDef : {
                                          qDimensions : [],
                                          qMeasures : [],
                                          qInitialDataFetch : [{
                                              qWidth : 10,
                                              qHeight : 50
                                          }]
                                      },
                                              
                              },