@@ -33,6 +33,6 @@ |
||
| 33 | 33 | ->getStyle($coordString) |
| 34 | 34 | ->applyFromArray(['fill' => array( |
| 35 | 35 | 'type' => \PHPExcel_Style_Fill::FILL_SOLID, |
| 36 | - 'color' => array('rgb' => $options['color']), )]); |
|
| 36 | + 'color' => array('rgb' => $options['color']),)]); |
|
| 37 | 37 | } |
| 38 | 38 | } |
@@ -303,7 +303,7 @@ |
||
| 303 | 303 | } |
| 304 | 304 | |
| 305 | 305 | if(isset($propertyName)) { |
| 306 | - return $this->$propertyName; |
|
| 306 | + return $this->$propertyName; |
|
| 307 | 307 | } |
| 308 | 308 | } |
| 309 | 309 | |
@@ -302,7 +302,7 @@ |
||
| 302 | 302 | break; |
| 303 | 303 | } |
| 304 | 304 | |
| 305 | - if(isset($propertyName)) { |
|
| 305 | + if (isset($propertyName)) { |
|
| 306 | 306 | return $this->$propertyName; |
| 307 | 307 | } |
| 308 | 308 | } |
@@ -122,15 +122,15 @@ discard block |
||
| 122 | 122 | return $this; |
| 123 | 123 | } |
| 124 | 124 | |
| 125 | - /** |
|
| 126 | - * Increment the value for a key that makes up part of the currently focused |
|
| 127 | - * data object. |
|
| 128 | - * |
|
| 129 | - * @param string $key The index to use |
|
| 130 | - * @param int $value The value to increment by |
|
| 131 | - * @return $this |
|
| 132 | - * @throws \Exception if there is no data point, column or invalid type |
|
| 133 | - */ |
|
| 125 | + /** |
|
| 126 | + * Increment the value for a key that makes up part of the currently focused |
|
| 127 | + * data object. |
|
| 128 | + * |
|
| 129 | + * @param string $key The index to use |
|
| 130 | + * @param int $value The value to increment by |
|
| 131 | + * @return $this |
|
| 132 | + * @throws \Exception if there is no data point, column or invalid type |
|
| 133 | + */ |
|
| 134 | 134 | public function increment($key, $value = 1) |
| 135 | 135 | { |
| 136 | 136 | if (!$this->currentDataPoint) { |
@@ -154,15 +154,15 @@ discard block |
||
| 154 | 154 | return $this; |
| 155 | 155 | } |
| 156 | 156 | |
| 157 | - /** |
|
| 158 | - * Directly set the value for a key that makes up part of the currently focused |
|
| 159 | - * data object. |
|
| 160 | - * |
|
| 161 | - * @param string $key The index to use |
|
| 162 | - * @param string|integer $value The value to set |
|
| 163 | - * @return $this |
|
| 164 | - * @throws \Exception |
|
| 165 | - */ |
|
| 157 | + /** |
|
| 158 | + * Directly set the value for a key that makes up part of the currently focused |
|
| 159 | + * data object. |
|
| 160 | + * |
|
| 161 | + * @param string $key The index to use |
|
| 162 | + * @param string|integer $value The value to set |
|
| 163 | + * @return $this |
|
| 164 | + * @throws \Exception |
|
| 165 | + */ |
|
| 166 | 166 | public function set($key, $value) |
| 167 | 167 | { |
| 168 | 168 | if (!$this->currentDataPoint) { |
@@ -177,13 +177,13 @@ discard block |
||
| 177 | 177 | return $this; |
| 178 | 178 | } |
| 179 | 179 | |
| 180 | - /** |
|
| 181 | - * Set a focus for the current data object for which data can be manipulated. |
|
| 182 | - * If the key doesn't exist, it will be created using default column values. |
|
| 183 | - * |
|
| 184 | - * @param string $key The reference key to be used |
|
| 185 | - * @return $this |
|
| 186 | - */ |
|
| 180 | + /** |
|
| 181 | + * Set a focus for the current data object for which data can be manipulated. |
|
| 182 | + * If the key doesn't exist, it will be created using default column values. |
|
| 183 | + * |
|
| 184 | + * @param string $key The reference key to be used |
|
| 185 | + * @return $this |
|
| 186 | + */ |
|
| 187 | 187 | public function setPoint($key) |
| 188 | 188 | { |
| 189 | 189 | if (!isset($this->currentDataSet[$key])) { |
@@ -194,14 +194,14 @@ discard block |
||
| 194 | 194 | return $this; |
| 195 | 195 | } |
| 196 | 196 | |
| 197 | - /** |
|
| 198 | - * Add a data point which will be shown on the report. This function should be |
|
| 199 | - * used prior to any kind of data manipulation as it will not setup a data |
|
| 200 | - * structure for manipulation. |
|
| 201 | - * |
|
| 202 | - * @param string $key The index to use |
|
| 203 | - * @return $this |
|
| 204 | - */ |
|
| 197 | + /** |
|
| 198 | + * Add a data point which will be shown on the report. This function should be |
|
| 199 | + * used prior to any kind of data manipulation as it will not setup a data |
|
| 200 | + * structure for manipulation. |
|
| 201 | + * |
|
| 202 | + * @param string $key The index to use |
|
| 203 | + * @return $this |
|
| 204 | + */ |
|
| 205 | 205 | public function addPoint($key) |
| 206 | 206 | { |
| 207 | 207 | if (!in_array($key, $this->dataPoints)) { |
@@ -212,20 +212,20 @@ discard block |
||
| 212 | 212 | return $this; |
| 213 | 213 | } |
| 214 | 214 | |
| 215 | - /** |
|
| 216 | - * Define a type of data that will be presented on the report or metadata that |
|
| 217 | - * will be used for calculations. In the latter case, within the options array |
|
| 218 | - * set "visible" to false. |
|
| 219 | - * At a minimum, the key needs to be set. In this case, the type will be string |
|
| 220 | - * and the key converted in to a title |
|
| 221 | - * . |
|
| 222 | - * |
|
| 223 | - * @param string $key A reference key for the piece of data |
|
| 224 | - * @param string|integer $defaultValue The default also defines type of column |
|
| 225 | - * @param array $options Additional parameters for the column to use |
|
| 226 | - * |
|
| 227 | - * @return $this |
|
| 228 | - */ |
|
| 215 | + /** |
|
| 216 | + * Define a type of data that will be presented on the report or metadata that |
|
| 217 | + * will be used for calculations. In the latter case, within the options array |
|
| 218 | + * set "visible" to false. |
|
| 219 | + * At a minimum, the key needs to be set. In this case, the type will be string |
|
| 220 | + * and the key converted in to a title |
|
| 221 | + * . |
|
| 222 | + * |
|
| 223 | + * @param string $key A reference key for the piece of data |
|
| 224 | + * @param string|integer $defaultValue The default also defines type of column |
|
| 225 | + * @param array $options Additional parameters for the column to use |
|
| 226 | + * |
|
| 227 | + * @return $this |
|
| 228 | + */ |
|
| 229 | 229 | public function column( |
| 230 | 230 | $key, |
| 231 | 231 | $defaultValue = '', |
@@ -258,15 +258,15 @@ discard block |
||
| 258 | 258 | } |
| 259 | 259 | |
| 260 | 260 | /** |
| 261 | - * Manually set the data which will be used for the current set. when |
|
| 262 | - * using this function, it will expect an associative array of arrays where |
|
| 263 | - * each entry has a further array of values which have a key matching that of |
|
| 264 | - * the meta data. |
|
| 265 | - * TODO - This is quite messy, rewrite more efficiently. |
|
| 266 | - * |
|
| 267 | - * @param array $inputData A set of data which conforms to the column specification |
|
| 268 | - * @return $this |
|
| 269 | - */ |
|
| 261 | + * Manually set the data which will be used for the current set. when |
|
| 262 | + * using this function, it will expect an associative array of arrays where |
|
| 263 | + * each entry has a further array of values which have a key matching that of |
|
| 264 | + * the meta data. |
|
| 265 | + * TODO - This is quite messy, rewrite more efficiently. |
|
| 266 | + * |
|
| 267 | + * @param array $inputData A set of data which conforms to the column specification |
|
| 268 | + * @return $this |
|
| 269 | + */ |
|
| 270 | 270 | public function setData($inputData) |
| 271 | 271 | { |
| 272 | 272 | // Combine raw data with the meta data |
@@ -45,7 +45,7 @@ |
||
| 45 | 45 | // Draw the edge line |
| 46 | 46 | $start = $nav->coord('current', 'initial'); |
| 47 | 47 | $end = $nav->coord('current', ($nav->row() - 1)); |
| 48 | - $coordString = $start.':'.$end; |
|
| 48 | + $coordString = $start . ':' . $end; |
|
| 49 | 49 | |
| 50 | 50 | $context->style('border', $coordString, ['edge' => 'right']); |
| 51 | 51 | $context->style('align', $coordString, ['edge' => 'right']); |
@@ -34,8 +34,8 @@ discard block |
||
| 34 | 34 | $context->write($context->query()->getTitle()); |
| 35 | 35 | |
| 36 | 36 | // Get the last column of the headings |
| 37 | - $rangeEndColumn = $nav->column()+$meta->columnCount()-1; |
|
| 38 | - $headingRange = $nav->coord().':'.$nav->coord($rangeEndColumn, false); |
|
| 37 | + $rangeEndColumn = $nav->column() + $meta->columnCount() - 1; |
|
| 38 | + $headingRange = $nav->coord() . ':' . $nav->coord($rangeEndColumn, false); |
|
| 39 | 39 | |
| 40 | 40 | $context->style('merge', $headingRange); |
| 41 | 41 | $nav->down(); |
@@ -61,7 +61,7 @@ discard block |
||
| 61 | 61 | $start = $nav->coord('initial', 'current'); |
| 62 | 62 | $end = $nav->coord(($nav->column() - 1), 'current'); |
| 63 | 63 | |
| 64 | - $context->style('border', $start.':'.$end, ['edge' => 'bottom']); |
|
| 64 | + $context->style('border', $start . ':' . $end, ['edge' => 'bottom']); |
|
| 65 | 65 | |
| 66 | 66 | $nav->reset('set'); |
| 67 | 67 | } |
@@ -71,6 +71,6 @@ |
||
| 71 | 71 | $start = $nav->coord('current', 'initial'); |
| 72 | 72 | $end = $nav->coord('current', ($nav->row() - 1)); |
| 73 | 73 | |
| 74 | - $context->style('border', $start.':'.$end, ['edge' => 'left']); |
|
| 74 | + $context->style('border', $start . ':' . $end, ['edge' => 'left']); |
|
| 75 | 75 | } |
| 76 | 76 | } |