Exemplo n.º 1
0
 /**
  * @param $task Task
  * @param $start_date string
  * @param $end_date string
  * @param $position
  * @return GanttBar
  *
  * Create a Gantt bar that represents a task with subtasks, this gives it 'wings' at each end to 
  * represent it spanning the subtasks.
  * $start_date and $end_date should be YYYY-MM-DD formatted dates
  */
 private function makeGroup(Task $task, $start_date, $end_date, $position)
 {
     $bar = new GanttBar($position, $task->name, $start_date, $end_date, $task->getField('duration')->formatted, 8);
     $bar->rightMark->Show();
     $bar->rightMark->SetType(MARK_RIGHTTRIANGLE);
     $bar->rightMark->SetWidth(8);
     $bar->rightMark->SetColor('#0077BD');
     $bar->rightMark->SetFillColor('#0077BD');
     $bar->leftMark->Show();
     $bar->leftMark->SetType(MARK_LEFTTRIANGLE);
     $bar->leftMark->SetWidth(8);
     $bar->leftMark->SetColor('#0077BD');
     $bar->leftMark->SetFillColor('#0077BD');
     $bar->setColor('#0077BD');
     $bar->SetPattern(BAND_SOLID, '#0077BD');
     return $bar;
 }