Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-6842

ProjectMgr: GanttChart fails, in case of dependencies for tasks

Agile BoardAttach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    Description

      the problen is in line 127:
      taskInfo.preDecessor = latestTaskIds
      This line causes brackets around ids (e.g.: [10098] )
      And these brackets cannot be processed by jsgantt.
      So in case of dependencies the ganttchart will not be displayed.

      To fix it, the ids could be processed in a loop:

      count = 0;
      if (UtilValidate.isNotEmpty(latestTaskIds)) {
        taskInfo.preDecessor = "";
          for (i in latestTaskIds) {
         if (count>0) {
          taskInfo.preDecessor = taskInfo.preDecessor +", " + i; 
         } else {
         taskInfo.preDecessor = taskInfo.preDecessor + i;
        }
        count ++;
        }
      }
      

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            jleroux Jacques Le Roux
            AgM3 Ralf
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment