Hitachi Vantara Pentaho Community Forums
Results 1 to 3 of 3

Thread: Synchronization of postExecution

  1. #1

    Default Synchronization of postExecution

    Hi,

    I am trying to run Dasboards.init and then use the results of a component's postExecution function. So the code looks like:

    Dasboards.init([component]);
    Use results of component's postExecution;

    The problem is that the Dasboards.init() function completes, but the component's postExection function doesn't run until later. So the results are not available. Any ideas on how I can synchronize this?

    Thanks,
    Jeff
    Pentaho BI Solutions for ERP
    www.erpbisolutions.com

  2. #2
    Join Date
    Nov 2011
    Posts
    1,229

    Default

    If you use the latest CDF version with the refactored async component life cycle management, that should be easy because we trigger an event when calling postExecution.

    Otherwise, why not have the component postExecution call the function that uses its results ?
    Pedro Vale
    --
    CTools Product Development
    http://www.webdetails.pt

  3. #3

    Default

    Thanks Pedro. Yes, I can have the postExecution call the function that uses the results. But its not convenient as the function I call renders many components - not just the component using the results. I'm trying to use Enyojs with CDF (and having "some" success). The code looks like:

    Code:
    var listP = [];
    var query = new custQuery();
    query.widget.postExecution = function(){
    		for(i = 0; i < result.length; i++) {
    			if(i == 0){
    			    listP[0] = {content: result[0][1], active: true};
    			}
    			else{
    			    listP[i] = {content: result[i][1]};
    		}				
    }
    			theBody = new App();
    			theBody.renderInto(document.body);
    			}
    Dashboards.init([query.widget]);
    Where can I learn more about the new asynch component lifecycle?
    Pentaho BI Solutions for ERP
    www.erpbisolutions.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.