using macros inside user macros

francis
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
January 4, 2015

Hi,

 

I got a user macro 'abc' which is a panel macro with predefined values - pretty straightforward

 

## Macro title: CMPanel
## Macro has a body: Y
## Body processing: 
## Output: Selected output option
##
## Developed by: idalko
## Date created: dd/mm/yyyy
## Installed by: idalko
## @param title:title=Title|type=string|required=false|desc=panel title

<ac:macro ac:name="panel"><ac:parameter ac:name="bgColor">transparent</ac:parameter><ac:parameter ac:name="titleBGColor">#555555</ac:parameter><ac:parameter ac:name="title">$paramtitle</ac:parameter><ac:parameter ac:name="borderStyle">solid</ac:parameter><ac:parameter ac:name="borderColor">#555555</ac:parameter><ac:parameter ac:name="titleColor">#FFCC00</ac:parameter><ac:rich-text-body>$body</ac:rich-text-body></ac:macro>

 

This works fine, until I add another macro in the body of the macro itself.  For instance, if I add a dynamic tasklist in this macro, the panel expands to the bottom of the page.  All formatting is lost.

 

The storage format does look ok, but the formatting is completely wrong.

Any ideas ?

 

Francis



2 answers

0 votes
Alejandro Conde Carrillo
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 26, 2015

Hello Francis.

I am afraid that is a known issue: https://jira.atlassian.com/browse/CONF-25507. We will have to wait for the developers to fix this.

0 votes
Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 5, 2015

For "macro body processing" in the user macro do you have it set to "Rendered"?

francis
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
January 5, 2015

Yes - it is set to rendered

Alex Medved _ConfiForms_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 5, 2015

I have tried your case, Francis, on Confluence 5.6.6 and can also confirm that if you have a tasklist inside a panel macro it works, but if you put it inside your cmpanel, it simply does not render it... inside the editor all looks good though.. very strange

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events