@@ -36,6 +36,10 @@ discard block |
||
36 | 36 | */ |
37 | 37 | protected $start_date; |
38 | 38 | public function getStartDate() { return $this->start_date; } |
39 | + |
|
40 | + /** |
|
41 | + * @param integer $start_date |
|
42 | + */ |
|
39 | 43 | public function setStartDate($start_date) { return $this->start_date = $start_date; } |
40 | 44 | |
41 | 45 | /** |
@@ -126,14 +130,14 @@ discard block |
||
126 | 130 | } |
127 | 131 | |
128 | 132 | /** |
129 | - * @return GraphOnTrackerV5_Engine The engine associated to the concrete chart |
|
133 | + * @return GraphOnTrackersV5_Engine_Burndown The engine associated to the concrete chart |
|
130 | 134 | */ |
131 | 135 | protected function getEngine() { |
132 | 136 | return new GraphOnTrackersV5_Engine_Burndown(); |
133 | 137 | } |
134 | 138 | |
135 | 139 | /** |
136 | - * @return ChartDataBuilder The data builder associated to the concrete chart |
|
140 | + * @return GraphOnTrackersV5_Burndown_DataBuilder The data builder associated to the concrete chart |
|
137 | 141 | */ |
138 | 142 | protected function getChartDataBuilder($artifacts) { |
139 | 143 | return new GraphOnTrackersV5_Burndown_DataBuilder($this,$artifacts); |
@@ -39,6 +39,10 @@ discard block |
||
39 | 39 | */ |
40 | 40 | protected $start_date; |
41 | 41 | public function getStartDate() { return $this->start_date; } |
42 | + |
|
43 | + /** |
|
44 | + * @param integer $start_date |
|
45 | + */ |
|
42 | 46 | public function setStartDate($start_date) { return $this->start_date = $start_date; } |
43 | 47 | |
44 | 48 | /** |
@@ -53,6 +57,10 @@ discard block |
||
53 | 57 | */ |
54 | 58 | protected $stop_date; |
55 | 59 | public function getStopDate() { return $this->stop_date; } |
60 | + |
|
61 | + /** |
|
62 | + * @param integer $stop_date |
|
63 | + */ |
|
56 | 64 | public function setStopDate($stop_date) { return $this->stop_date = $stop_date; } |
57 | 65 | |
58 | 66 | /** |
@@ -141,14 +149,14 @@ discard block |
||
141 | 149 | } |
142 | 150 | |
143 | 151 | /** |
144 | - * @return GraphOnTrackerV5_Engine The engine associated to the concrete chart |
|
152 | + * @return GraphOnTrackersV5_Engine_CumulativeFlow The engine associated to the concrete chart |
|
145 | 153 | */ |
146 | 154 | protected function getEngine() { |
147 | 155 | return new GraphOnTrackersV5_Engine_CumulativeFlow(); |
148 | 156 | } |
149 | 157 | |
150 | 158 | /** |
151 | - * @return ChartDataBuilder The data builder associated to the concrete chart |
|
159 | + * @return GraphOnTrackersV5_CumulativeFlow_DataBuilder The data builder associated to the concrete chart |
|
152 | 160 | */ |
153 | 161 | protected function getChartDataBuilder($artifacts) { |
154 | 162 | return new GraphOnTrackersV5_CumulativeFlow_DataBuilder($this,$artifacts); |
@@ -230,7 +230,11 @@ |
||
230 | 230 | * |
231 | 231 | * @param string The report name. |
232 | 232 | * @param string The report description. |
233 | - * @return id on success, false on failure. |
|
233 | + * @param integer $user_id |
|
234 | + * @param string $name |
|
235 | + * @param string $description |
|
236 | + * @param integer $scope |
|
237 | + * @return GraphOnTrackersV5_Report|null on success, false on failure. |
|
234 | 238 | */ |
235 | 239 | public static function create($atid, $user_id, $name, $description, $scope) { |
236 | 240 | $sql = sprintf("INSERT INTO plugin_graphontrackersv5_report_graphic |
@@ -33,6 +33,9 @@ |
||
33 | 33 | DataAccessObject::DataAccessObject($da); |
34 | 34 | } |
35 | 35 | |
36 | + /** |
|
37 | + * @param string $scope |
|
38 | + */ |
|
36 | 39 | public function searchByTrackerIdAndScope($tracker_id, $scope) { |
37 | 40 | $sql = "SELECT * FROM plugin_graphontrackersv5_report_graphic WHERE group_artifact_id = "; |
38 | 41 | $sql .= $this->da->escapeInt($tracker_id); |
@@ -44,6 +44,8 @@ |
||
44 | 44 | |
45 | 45 | /** |
46 | 46 | * Copy the charts from Report $from_report to Report $to_report |
47 | + * @param GraphOnTrackersV5_Report $from_report |
|
48 | + * @param GraphOnTrackersV5_Report|null $to_report |
|
47 | 49 | */ |
48 | 50 | public function copyCharts($from_report, $to_report) { |
49 | 51 | foreach($from_report->getCharts() as $c) { |
@@ -31,6 +31,10 @@ discard block |
||
31 | 31 | */ |
32 | 32 | protected $start_date; |
33 | 33 | public function getStartDate() { return $this->start_date; } |
34 | + |
|
35 | + /** |
|
36 | + * @param integer $start_date |
|
37 | + */ |
|
34 | 38 | public function setStartDate($start_date) { return $this->start_date = $start_date; } |
35 | 39 | |
36 | 40 | /** |
@@ -38,12 +42,20 @@ discard block |
||
38 | 42 | */ |
39 | 43 | protected $duration; |
40 | 44 | public function getDuration() { return $this->duration; } |
45 | + |
|
46 | + /** |
|
47 | + * @param integer $duration |
|
48 | + */ |
|
41 | 49 | public function setDuration($duration) { return $this->duration = $duration; } |
42 | 50 | |
43 | 51 | /** |
44 | 52 | * The remaining effort field |
45 | 53 | */ |
46 | 54 | protected $remaining_field; |
55 | + |
|
56 | + /** |
|
57 | + * @return boolean |
|
58 | + */ |
|
47 | 59 | public function getRemainingField() { return $this->remaining_field; } |
48 | 60 | public function setRemainingField($remaining_field) { return $this->remaining_field = $remaining_field; } |
49 | 61 | |
@@ -51,6 +63,10 @@ discard block |
||
51 | 63 | * The done field |
52 | 64 | */ |
53 | 65 | protected $done_field; |
66 | + |
|
67 | + /** |
|
68 | + * @return boolean |
|
69 | + */ |
|
54 | 70 | public function getDoneField() { return $this->done_field; } |
55 | 71 | public function setDoneField($done_field) { return $this->done_field = $done_field; } |
56 | 72 | |
@@ -78,7 +94,7 @@ discard block |
||
78 | 94 | |
79 | 95 | /** |
80 | 96 | * Create an instance of the chart |
81 | - * @return GraphOnTrackersV5_Chart |
|
97 | + * @return GraphOnTrackersV5_Scrum_Chart_Burnup|null |
|
82 | 98 | */ |
83 | 99 | public static function create($graphic_report, $id, $rank, $title, $description, $width, $height) { |
84 | 100 | $sql = sprintf("INSERT INTO plugin_graphontrackersv5_scrum_burnup |
@@ -121,14 +137,14 @@ discard block |
||
121 | 137 | |
122 | 138 | |
123 | 139 | /** |
124 | - * @return GraphOnTracker_Engine The engine associated to the concrete chart |
|
140 | + * @return GraphOnTrackersV5_Scrum_Burnup_Engine The engine associated to the concrete chart |
|
125 | 141 | */ |
126 | 142 | protected function getEngine() { |
127 | 143 | return new GraphOnTrackersV5_Scrum_Burnup_Engine(); |
128 | 144 | } |
129 | 145 | |
130 | 146 | /** |
131 | - * @return ChartDataBuilder The data builder associated to the concrete chart |
|
147 | + * @return GraphOnTrackersV5_Scrum_Burnup_DataBuilder The data builder associated to the concrete chart |
|
132 | 148 | */ |
133 | 149 | protected function getChartDataBuilder($artifacts) { |
134 | 150 | return new GraphOnTrackersV5_Scrum_Burnup_DataBuilder($this,$artifacts); |
@@ -46,6 +46,9 @@ discard block |
||
46 | 46 | $engine->duration = $this->chart->getDuration(); |
47 | 47 | } |
48 | 48 | |
49 | + /** |
|
50 | + * @param integer $effort_field_id |
|
51 | + */ |
|
49 | 52 | protected function getBurnDownData($effort_field_id, $type) { |
50 | 53 | $artifact_ids = explode(',', $this->artifacts['id']); |
51 | 54 | $sql = "SELECT c.artifact_id AS id, TO_DAYS(FROM_UNIXTIME(submitted_on)) - TO_DAYS(FROM_UNIXTIME(0)) as day, value |
@@ -58,6 +61,9 @@ discard block |
||
58 | 61 | return new GraphOnTrackersV5_Burndown_Data(db_query($sql), $artifact_ids); |
59 | 62 | } |
60 | 63 | |
64 | + /** |
|
65 | + * @param Tracker_FormElement_Field $effort_field |
|
66 | + */ |
|
61 | 67 | protected function isValidEffortField($effort_field, $type) { |
62 | 68 | return $effort_field && $effort_field->userCanRead(UserManager::instance()->getCurrentUser()); |
63 | 69 | } |
@@ -100,6 +100,9 @@ discard block |
||
100 | 100 | return $this->filterEmptyLines($result);; |
101 | 101 | } |
102 | 102 | |
103 | + /** |
|
104 | + * @param Tracker_FormElement_Field $observed_field |
|
105 | + */ |
|
103 | 106 | protected function isValidObservedField($observed_field, $type) { |
104 | 107 | return $observed_field && $observed_field->userCanRead(UserManager::instance()->getCurrentUser()); |
105 | 108 | } |
@@ -116,7 +119,6 @@ discard block |
||
116 | 119 | /** |
117 | 120 | * |
118 | 121 | * Fetch the colors, and initialize an empty result array. => $tempData[timestamp][label_id] = 0 |
119 | - * @param int $field_id ID of the observed field |
|
120 | 122 | * @return array $resultArray Initialized array for this graph |
121 | 123 | */ |
122 | 124 | private function initEmptyResultArrayFromField($engine) { |
@@ -149,7 +151,7 @@ discard block |
||
149 | 151 | /** |
150 | 152 | * |
151 | 153 | * Get the the last changeset BEFORE the timestamp for each artifact |
152 | - * @param int $beforeTimestamp |
|
154 | + * @param double $timestamp |
|
153 | 155 | * @return $changesets array of changeset_id |
154 | 156 | */ |
155 | 157 | private function getLastChangesetsBefore($timestamp) { |
@@ -60,6 +60,9 @@ |
||
60 | 60 | return $data; |
61 | 61 | } |
62 | 62 | |
63 | + /** |
|
64 | + * @param string $column |
|
65 | + */ |
|
63 | 66 | protected function extractDataFromResult($res, $ids, $column) { |
64 | 67 | $data = array(); |
65 | 68 | if ($res && db_numrows($res)) { |