Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,456,296
Community Members
 
Community Events
176
Community Groups

Create roadmap from existing sprint plan in XLS

Edited

I want to load our 9 months sprint plan into a roadmap view. Adding bars manually, placing them in correct sprint and resizing them is too tedious task.

 

On load, the interface calls https://constructsecure.atlassian.net/wiki/rest/tinymce/1/macro/definition API which returns the data as URL encoded JSON string. Is there any way to convert my xls to a JSON, import it and create the roadmap with it?

title, startDate, description, duration provided in JSON format.

1 comment

I came up with a hack solution (see if it helps).

Open Confluence in Google Chrome

Open developer tools in popup out mode

Edit the page with roadmap (or insert a new roadmap)

Open the edit mode of the roadmap

In developer console, in sources tab, right click on 'top' and select 'Search in all files'

Enter search string 'click #toolbar-button-add-bar'

Click on the search result to open the file in sources tab. (Click on {} to beautify the source)

Locate the 'onAddBarClick' function

Add a breakpoint inside the function

In the roadmap edit screen, click on '+ Add bar'. This should hit the breakpoint.

In developer console, go to console tab and enter

var myThis = this;

Switch back to source tab and click the run button

Switch back to console

Enter the following functions

var myAddBar = function (laneIdx, title, startDate, duration) {
var d = myThis.model.get("lanes").at(laneIdx);
var c = d.get("bars");
var g = myThis.model.get("timeline");
var f = new Date(startDate);
//var h = g.get("displayOption") === Roadmap.TIMELINE_DISPLAY_OPTION.MONTH ? moment(f).startOf("month") : moment(f).startOf("isoWeek");
var h = moment(f);
c.add(new Roadmap.Bar({
title: title,
duration: duration,
rowIndex: d.getNumberOfRows(),
startDate: h.toDate()
}))
}


var myAddMarker = function (title, startDate) {
var g = myThis.model.get("markers");
var d = myThis.model.get("timeline");
var h = moment(new Date(startDate));
//var c = d.get("displayOption") === Roadmap.TIMELINE_DISPLAY_OPTION.MONTH ? h.date(15) : h.isoWeekday(4);
var c = h;
g.add(new Roadmap.Marker({
title: title,
markerDate: c.toDate()
}))
}

Now you can add a bar programatically with 

myAddBar(1, 'task 1', '2018-09-13 00:00:00', 1)

The laneIdx is the index of the lane starting with 0

The duration is dependent on what ever you have chosen in 'View by' view. 1 for 1 month or 1 week.

You could create you plan in a JSON or simple array format, paste it console, write your own function which loops on the array and calls the corresponding functions.

var m = [
[
"Sprint 1", "2018-08-27 00:00:00"],
["Sprint 2", "2018-09-10 00:00:00"],
["Sprint 3", "2018-09-24 00:00:00"],
["Sprint 4", "2018-10-08 00:00:00"],
["Sprint 5", "2018-10-22 00:00:00"]
]
m.forEach(function(mr) {myAddMarker(mr[0], mr[1])})

 

Comment

Log in or Sign up to comment
TAGS

Atlassian Community Events