@@ -279,7 +279,8 @@ discard block |
||
| 279 | 279 | $row['count'] = $this->count; |
| 280 | 280 | $row['url'] = $modx->makeUrl($row['id']); |
| 281 | 281 | |
| 282 | - if (!$row['wasNull']) { // needs writing a document |
|
| 282 | + if (!$row['wasNull']) { |
|
| 283 | +// needs writing a document |
|
| 283 | 284 | $docname = $this->getFileName($row['id'], $row['alias'], $prefix, $suffix); |
| 284 | 285 | $filename = $dirpath . $docname; |
| 285 | 286 | if (!is_file($filename)) { |
@@ -307,7 +308,8 @@ discard block |
||
| 307 | 308 | $this->output[] = $this->parsePlaceholder($_lang['export_site_exporting_document'], $row); |
| 308 | 309 | } |
| 309 | 310 | if ($row['isfolder'] === '1' && ($modx->config['suffix_mode'] !== '1' || strpos($row['alias'], |
| 310 | - '.') === false)) { // needs making a folder |
|
| 311 | + '.') === false)) { |
|
| 312 | +// needs making a folder |
|
| 311 | 313 | $end_dir = ($row['alias'] !== '') ? $row['alias'] : $row['id']; |
| 312 | 314 | $dir_path = $dirpath . $end_dir; |
| 313 | 315 | if (strpos($dir_path, MODX_BASE_PATH) === false) { |
@@ -177,7 +177,8 @@ |
||
| 177 | 177 | * @return bool|string |
| 178 | 178 | */ |
| 179 | 179 | public function putChunk($chunkName) |
| 180 | - { // alias name >.< |
|
| 180 | + { |
|
| 181 | +// alias name >.< |
|
| 181 | 182 | $modx = evolutionCMS(); |
| 182 | 183 | |
| 183 | 184 | return $modx->getChunk($chunkName); |
@@ -2,4 +2,6 @@ |
||
| 2 | 2 | |
| 3 | 3 | use Exception; |
| 4 | 4 | |
| 5 | -class ServiceNotFoundException extends Exception{} |
|
| 5 | +class ServiceNotFoundException extends Exception |
|
| 6 | +{ |
|
| 7 | +} |
|
@@ -2,4 +2,6 @@ |
||
| 2 | 2 | |
| 3 | 3 | use Exception; |
| 4 | 4 | |
| 5 | -class ContainerException extends Exception{} |
|
| 5 | +class ContainerException extends Exception |
|
| 6 | +{ |
|
| 7 | +} |
|
@@ -373,7 +373,8 @@ discard block |
||
| 373 | 373 | * @return bool|mixed|mysqli_result |
| 374 | 374 | */ |
| 375 | 375 | public function save($fields, $table, $where = '') |
| 376 | - { // This is similar to "replace into table". |
|
| 376 | + { |
|
| 377 | +// This is similar to "replace into table". |
|
| 377 | 378 | |
| 378 | 379 | if ($where === '') { |
| 379 | 380 | $mode = 'insert'; |
@@ -490,7 +491,7 @@ discard block |
||
| 490 | 491 | { |
| 491 | 492 | $out = false; |
| 492 | 493 | if ($ds instanceof mysqli_result) { |
| 493 | - switch($mode){ |
|
| 494 | + switch($mode) { |
|
| 494 | 495 | case 'assoc': |
| 495 | 496 | $out = $ds->fetch_assoc(); |
| 496 | 497 | break; |
@@ -1,3 +1,5 @@ |
||
| 1 | 1 | <?php namespace EvolutionCMS\Interfaces; |
| 2 | 2 | |
| 3 | -interface ManagerApiInterface{} |
|
| 3 | +interface ManagerApiInterface |
|
| 4 | +{ |
|
| 5 | +} |
|
@@ -1,3 +1,5 @@ |
||
| 1 | 1 | <?php namespace EvolutionCMS\Interfaces; |
| 2 | 2 | |
| 3 | -interface ServiceProviderInterface{} |
|
| 3 | +interface ServiceProviderInterface |
|
| 4 | +{ |
|
| 5 | +} |
|
@@ -1,3 +1,5 @@ |
||
| 1 | 1 | <?php namespace EvolutionCMS\Interfaces; |
| 2 | 2 | |
| 3 | -interface PasswordHashInterface{} |
|
| 3 | +interface PasswordHashInterface |
|
| 4 | +{ |
|
| 5 | +} |
|
@@ -11,7 +11,8 @@ discard block |
||
| 11 | 11 | # ----------------------------------------- |
| 12 | 12 | # |
| 13 | 13 | |
| 14 | -class DataGrid implements DataGridInterface{ |
|
| 14 | +class DataGrid implements DataGridInterface |
|
| 15 | +{ |
|
| 15 | 16 | |
| 16 | 17 | public $ds; // datasource |
| 17 | 18 | public $id; |
@@ -75,7 +76,8 @@ discard block |
||
| 75 | 76 | |
| 76 | 77 | public static $dataGridCnt; |
| 77 | 78 | |
| 78 | - public function __construct($id, $ds, $pageSize = 20, $pageNumber = -1) { |
|
| 79 | + public function __construct($id, $ds, $pageSize = 20, $pageNumber = -1) |
|
| 80 | + { |
|
| 79 | 81 | // set id |
| 80 | 82 | self::$dataGridCnt++; |
| 81 | 83 | $this->id = $this->id ? empty($id) : "dg" . self::$dataGridCnt; |
@@ -89,11 +91,13 @@ discard block |
||
| 89 | 91 | $this->pagerLocation = 'top-right'; |
| 90 | 92 | } |
| 91 | 93 | |
| 92 | - public function setDataSource($ds) { |
|
| 94 | + public function setDataSource($ds) |
|
| 95 | + { |
|
| 93 | 96 | $this->ds = $ds; |
| 94 | 97 | } |
| 95 | 98 | |
| 96 | - public function render() { |
|
| 99 | + public function render() |
|
| 100 | + { |
|
| 97 | 101 | $modx = evolutionCMS(); |
| 98 | 102 | $columnHeaderStyle = ($this->columnHeaderStyle) ? "style='" . $this->columnHeaderStyle . "'" : ''; |
| 99 | 103 | $columnHeaderClass = ($this->columnHeaderClass) ? "class='" . $this->columnHeaderClass . "'" : ""; |
@@ -128,7 +132,9 @@ discard block |
||
| 128 | 132 | |
| 129 | 133 | if($this->_isDataset && !$this->columns) { |
| 130 | 134 | $cols = $modx->getDatabase()->numFields($this->ds); |
| 131 | - for($i = 0; $i < $cols; $i++) $this->columns .= ($i ? "," : "") . $modx->getDatabase()->fieldName($this->ds, $i); |
|
| 135 | + for($i = 0; $i < $cols; $i++) { |
|
| 136 | + $this->columns .= ($i ? "," : "") . $modx->getDatabase()->fieldName($this->ds, $i); |
|
| 137 | + } |
|
| 132 | 138 | } |
| 133 | 139 | |
| 134 | 140 | // start grid |
@@ -207,7 +213,8 @@ discard block |
||
| 207 | 213 | |
| 208 | 214 | // format column values |
| 209 | 215 | |
| 210 | - public function RenderRowFnc($n, $row) { |
|
| 216 | + public function RenderRowFnc($n, $row) |
|
| 217 | + { |
|
| 211 | 218 | if($this->_alt == 0) { |
| 212 | 219 | $Style = $this->_itemStyle; |
| 213 | 220 | $Class = $this->_itemClass; |
@@ -237,7 +244,8 @@ discard block |
||
| 237 | 244 | return $o; |
| 238 | 245 | } |
| 239 | 246 | |
| 240 | - public function formatColumnValue($row, $value, $type, &$align) { |
|
| 247 | + public function formatColumnValue($row, $value, $type, &$align) |
|
| 248 | + { |
|
| 241 | 249 | if(strpos($type, ":") !== false) { |
| 242 | 250 | list($type, $type_format) = explode(":", $type, 2); |
| 243 | 251 | } |