7 Replies Latest reply: Aug 10, 2018 1:58 PM by Arthur Zuco RSS

    Adding "Export Data" to DAR Template

    Clever Anjos

      I´ve been using this great template DAR Mashup


      Now I have the requirement to add a "Send to Excel" feature.

      Steps I´ve done so far.

      1) Changed the .js file to have a pointer to my object (there can be dozen of them into the page) (Maybe there´s a smarter way of doing this)


      2) Changed the qliksense-card.html to exibit a button when maximized


      <div class="card-actions">
             <paper-icon-button icon="fullscreen" on-tap="fullscreenEnter" hidden$="{{fullscreen}}"></paper-icon-button>
             <paper-icon-button icon="cloud-download" on-tap="download" hidden$="{{!fullscreen}}"></paper-icon-button>
         <paper-icon-button icon="fullscreen-exit" on-tap="fullscreenExit" hidden$="{{!fullscreen}}"></paper-icon-button>



      3) How it looks now



      4) My current qliksense-card.html javascript

           is: 'qliksense-card',
        download: function(){
        var d = this.getContentChildren();
        if ( window.mashujObj[d[0].id] ) {
         var t = window.mashujObj[d[0].id];
          // have tried with t.exportData({download: true});
          // have tried with var qTable = qlik.table(window.mashujObj[d[0].id]);
                                 // qTable.exportData({download: true});


      None of them works.


      Any help?