PDA

View Full Version : Getting WCDF parameters



jangalian
02-11-2015, 06:06 AM
Hi all!
I've a relatively simple question: it is possible to ask the BA server the list of the parameters needed to render a WCDF dashboard trough API?

I know that for the PRPT reports you have to do a request similar to the following:

http://192.168.1.10:8080/pentaho/api/repos/: public:quattroc:Reports:consume-energy.prpt/parameter (http://192.168.1.10:8080/pentaho/api/repos/:public:quattroc:Reports:consume-energy.prpt/parameter)

Or, in alternatively: it is possible to pass initialization parameters during invocation e.g.

http://192.168.1.10:8080/pentaho/api/repos/: public:quattroc: Dashboard: Dashboard1.wcdf/generatedContent?myDateParam="july"

so to have my fancy dashboard preselected with "july"?

Thank you in advance

Matteo

pamval
02-12-2015, 06:07 AM
There's no built-in support for initialization parameters in CDE. You need to code it in your dashboard. We do have the notion of bookmarkable parameters (it's one of the options in the parameter properties). If the parameter is bookmarkable you can set its value in the query string using the # tag. Something like:


http://192.168.1.10:8080/pentaho/api/repos/: public:quattroc: Dashboard: Dashboard1.wcdf/generatedContent#bookmarkable={myDateParam: 'july'}

Not sure about the exact syntax after the hash, but search the ctools forums because I know there are similar threads there.