Been trying to call a PocketQuery query from within a User macro, just can't get to work
The reason why I want to use a User macro is because I can't parse all the parameters to the query automatically using the standard interface.
Thank you for using PocketQuery!
What have you tried so far and what does not work for you?
You should be able to render any PocketQuery macro within a user macro by adding its storage format. A basic pocketquery macro could look like this in storage format:
<ac:structured-macro ac:name="pocketquery" ac:schema-version="1"><ac:parameter ac:name="name">MyQuery</ac:parameter></ac:structured-macro>
You can also set parameters this way. If you need an example, go to a Confluence page where your PocketQuery macro is set, click on the three point icon on the top right and select "View storage format". Then you can copy the relevant section from there to your user macro and adjust what you need to.
Hope this helps!
P.S.: The fastest way to reach us at Scandio is usually through our service desk, if you need immediate support.
Thank you for the quick reply.
I have tried using the same syntax, but didn't include all the right parameters, that why it didn't work :)
Is it possible to call to call the pocketquery macro in a button like below
<button class="aui-button" onclick="$PocketQuery .....
Just as an info (properbly obvious) I'm all new to Confluence and the way the plugins works.
Happy to hear my answer helped :) If you officially "accept" it, others can see that the questions is solved.
Some general info: The code you include in the user macro simply executes the macro and adds the resulting HTML to the page. So executing it on button click is not possible this way.
Hi all! My name is Miles and I work on the Marketplace team. We’re looking for better ways to recommend and suggest apps that are truly crowd favorites, so of course we wanted to poll the Community. ...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs