Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Burn-Down chart is always empty #36

Open
cleankod opened this issue Aug 25, 2012 · 16 comments
Open

Burn-Down chart is always empty #36

cleankod opened this issue Aug 25, 2012 · 16 comments

Comments

@cleankod
Copy link

It doesn't draw anything...
It does draw the "Spent time" when I turn off the "Remaining estimate" then turn off "Spent time" and turn on "Spent time" again.

@AlexMcArrow
Copy link
Contributor

+1
Start date from 1970.
I think the problem is caused by the fact that "highcharts" receives incomplete (not valid) data.

@bcmedeiros
Copy link

Same problem here... I can only get some chart when uncheck "Remaining estimate".
AlexMcArrow, maybe you're right, but what should be the complete data to highcharts?

@caiiiyua
Copy link

Any update for this issue ?
I got the same problem with you guys.

  1. Start date from 1970
  2. No chart is drew
  3. Disable remaining estimate could see some of task draw on the chart.

@rackom
Copy link

rackom commented Oct 28, 2012

Same for me, burn down is empty no matter what I do.

@aqwerf
Copy link

aqwerf commented Nov 1, 2012

I found the problem point, and fix it temporarily (assets/javascripts/burndown.js)
After that, burndown chart works well.

--- burndown.js.orig    2012-11-01 17:21:28.926688667 +0900
+++ burndown.js 2012-11-01 18:04:41.162685890 +0900
@@ -45,7 +45,7 @@
         {
             if (!tasks.hasOwnProperty(id))
                 continue;
-            tasks[id].created_on = Date.fromMysql(tasks[id].created_on);
+            tasks[id].sprints_tasks.created_on = Date.fromMysql(tasks[id].sprints_tasks.created_on);
         }
         // loop through changes
         for (i = 0, len = changes.length; i < len; )
@@ -59,7 +59,7 @@
             {
                 if (!tasks.hasOwnProperty(id))
                     continue;
-                var task = tasks[id];
+                var task = tasks[id].sprints_tasks;
                 // delete tasks, that was created after current date
                 if (task.created_on > dateTime)
                     delete tasks[id];
@@ -76,9 +76,9 @@
             while (dateTime == changeDate)
             {
                 if (changes[i].prop_key == 'done_ratio')
-                    tasks[changes[i].issueId].done_ratio = changes[i].value;
+                    tasks[changes[i].issueId].sprints_tasks.done_ratio = changes[i].value;
                 else
-                    tasks[changes[i].issueId].estimated_hours = changes[i].value;
+                    tasks[changes[i].issueId].sprints_tasks.estimated_hours = changes[i].value;
                 // next change
                 i++;
                 if (i >= len)

@rackom
Copy link

rackom commented Nov 1, 2012

After that fix I get this:

Could not copy /opt/redmine/plugins/AgileDwarf/assets/javascripts/burndown.js to /opt/redmine/public/plugin_assets/AgileDwarf/javascripts/burndown.js: Permission denied - /opt/redmine/public/plugin_assets/AgileDwarf/javascripts/burndown.js

And even after I put back changes still the same error.

EDIT: I have changed permissions on that file and now it is OK. But no chart displays at all now.
EDIT 2: Had to restart apache server, my fault.

@geoff-intellipharm
Copy link

I added the the above fix by aqwerf and the charts at least display now just with no data on them.. they also start from 1970 so I am assuming that it is still broken somewhere. Does anyone know where it gets the data for this burn down? is it from the due dates set for the tasks?

Date.fromMysql = function(mysql) { if (typeof mysql != 'string') return null; // 2011/11/03 00:00:00 +0800 var t = mysql.split(/[\/ -:]/); // [Y, M, D] return Date.UTC(t[0], t[1] - 1, t[2]); };

After a bit of debugging I noticed that in the function above it returns the of the split var t incorrectly ... some of the dates passed to this function have the full UTC format with T and Z in them (i.e. 2012-11-02T12:04:00Z) perhaps it is this split that is not working correctly and hence passing invalid dates in the data for highcarts?

I don't have time to spend on fiddling with it but perhaps this might give someone some idea

@fleuryc
Copy link

fleuryc commented Nov 29, 2012

+1

@baumanno
Copy link

aqwerf's patch worked like a charm!
Apply patch (unfortunately it did'nt work with patch so had to do it manually) and restarted apache.

Thanks :)

@geoff-intellipharm
Copy link

^^ can you state which version of redmine this patch worked with?

Thanks!

@baumanno
Copy link

Sure, we have Redmine 2.1 running and cloned AgileDwarf from here

@nrchandan
Copy link

aqwerf's solution worked for me too! I modified the burndown.js manually and restarted redmine. Using latest redmine 2.2.3.

Now I have to look for solution to the tasks's tab problem. I don't see any tasks in that tab.

@AlexAndrascu
Copy link

Please commit this. I can confirm it's working. Thanks

arkadius pushed a commit to arkadius/AgileDwarf that referenced this issue Nov 16, 2013
…mment) (needs to be refined further to be platform independent); modified burndown.js according to iRessources#36 (comment) also fixed incorrect case of issueId to issueid
arkadius pushed a commit to arkadius/AgileDwarf that referenced this issue Nov 16, 2013
Apply patch from iRessources#36
@alfonsonishikawa
Copy link

alfonsonishikawa commented Jul 12, 2015

Sadly, the patch does not work with Redmine 1.3.2 :'(
Without the patch works with Redmine 1.3.2, but you must have at least one task with some "Spent Time" and "%Done > 0%". Otherwise, no graph is shown.

@julurigeethanjali
Copy link

aqwerf's solution worked for me. But when I turn off "Spent time" Remaining estimates graph is not plotted. All the tasks are having spent time. Please post a solution for this.. Thanks in advance

@acosonic
Copy link

acosonic commented Dec 3, 2015

I actually fixed it for newest version (fork) from greenius by completly removing sprints_tasks....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests