How can I use a date as a variable within a template

I am attempting to create a template for our 4-weekly sprint reports.

Included within it are multiple tasks, assigned to various team members, and I want to add a due date to these tasks.  In a normal page, I would type '//' then select a date.

However, the two dates I care about are the sprint start date and sprint end date, and each of these appears many times in the template.

Therefore, I want to add $start_date and $end_date variables.

However, when I create a new page based on this template, confluence does not expand '//' into a date entry dialogue, and so the resultant tasks are not properly tagged with due dates.

 

Is there any way to achieve what I need here?

2 answers

I don't know if I understand your question correctly.

If you want to add the date picker to your blueprint template, the XML fragment (storage format) is this:

<time datetime="2016-02-26"/>

Don't know if this applies also to user templates (if you are referring to them).

This project may serve as an example: https://bitbucket.org/atlassian/confluence-business-blueprints/, especially BusinessBlueprintsContextProviderHelper

Hope this helps ...

Hi,

Our plugin the Page Tree Creator has a date picker and is very easy to use. It also supports multi-page templates without any programming skills.

I know, this is not exaclty the answer you are looking for, but give our Page Tree Creator a try.

Marketplace link: Page Tree Creator

Regards,
Stephan

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Oct 24, 2018 in Confluence

Atlassian Research opportunity with Confluence templates

Do you use templates with Confluence? Take part in a remote 1-hr workshop. You'll receive USD $100 for your time!   We're looking for people to participate in a   remote 1-hr workshop...

930 views 13 11
Join discussion

Atlassian User Groups

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!

Find my local user group

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

Groups near you