Live-Templates, dynamic-tasklist and show-to macro
Hi,
i just created a global template, which people should use for their home space.
They only have to add {live-template:PersonalSpace}
I noticed that a show-to:space=edit doesn't work as it should. So even the owner of a personal space can't see anything between the show-to macros.
Without live-template it works.
I'm now using this workaround:
{report-on:injected=true}{show-to:user=%content:space>space:creator>user:name%}{hide-if:action=edit}\[{link-to:page edit}Edit{link-to}\]{hide-if}{show-to}{report-on}
It used to be {show-to:space=edit}{hide-if:action=edit}\[{link-to:page edit}Edit{link-to}\]{hide-if}{show-to}
Another problem i noticed is, that you can't use dynamictasklist in this templates.
You always get the error message i attached here.
Is it a bug of dynamictasklist or a bug in live-template or is it simply not possible cause on how dynamictasklist saves its data.
regards Christian

i just created a global template, which people should use for their home space.
They only have to add {live-template:PersonalSpace}
I noticed that a show-to:space=edit doesn't work as it should. So even the owner of a personal space can't see anything between the show-to macros.
Without live-template it works.
I'm now using this workaround:
{report-on:injected=true}{show-to:user=%content:space>space:creator>user:name%}{hide-if:action=edit}\[{link-to:page edit}Edit{link-to}\]{hide-if}{show-to}{report-on}
It used to be {show-to:space=edit}{hide-if:action=edit}\[{link-to:page edit}Edit{link-to}\]{hide-if}{show-to}
Another problem i noticed is, that you can't use dynamictasklist in this templates.
You always get the error message i attached here.
Is it a bug of dynamictasklist or a bug in live-template or is it simply not possible cause on how dynamictasklist saves its data.
regards Christian

1
person has this question
I have this question, too!
Tell me when someone answers.
The more people who ask this question, the more it gets noticed.
The more people who ask this question, the more it gets noticed.
The company marked this question as answered.
-
Inappropriate?Theoretically there is no difference between having your wiki code in a live template and having it on the page itself - it is rendered with the same engine, in the same context. The only issue is if the macro modifies the actual wiki markup (see comments on dynamictasklist below)
With regards to {show-to}, you have an error in the syntax. Try {show-to:space=@self:edit}. You always have to specify the space key, or use '@self' for the current space.
With regards to dynamictasklist, it's quite possible it won't work in a live template since I believe it stores it's data as wiki markup on the page itself, so if you're using live-template, it won't be able to modify the data because it doesn't exist there. -
Inappropriate?Hmm, i mixed up the syntax.
You're right, it's working now without report-on.
with regards to dynamic-tasklist,
i was thinking the same. Solved it in a different way.
thanks
Loading Profile...



EMPLOYEE