@@ -20,6 +20,9 @@ |
||
| 20 | 20 | return (is_array($parent_paths) && !empty($parent_paths) ? " AND p.`path` IN ('".implode("', '", $parent_paths)."')" : null); |
| 21 | 21 | } |
| 22 | 22 | |
| 23 | + /** |
|
| 24 | + * @param integer $filter_type |
|
| 25 | + */ |
|
| 23 | 26 | public function __processNavigationTypeFilter($filter, $filter_type = Datasource::FILTER_OR) |
| 24 | 27 | { |
| 25 | 28 | $types = preg_split('/'.($filter_type == Datasource::FILTER_AND ? '\+' : '(?<!\\\\),').'\s*/', $filter, -1, PREG_SPLIT_NO_EMPTY); |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | * @param XMLElement $result |
| 66 | 66 | * @param array $fields |
| 67 | 67 | * @param array $errors |
| 68 | - * @param object $post_values |
|
| 68 | + * @param XMLElement $post_values |
|
| 69 | 69 | * @throws Exception |
| 70 | 70 | * @return XMLElement |
| 71 | 71 | */ |
@@ -192,7 +192,6 @@ discard block |
||
| 192 | 192 | * Helper method to determine if a field is missing, or if the data |
| 193 | 193 | * provided was invalid. Used in conjunction with `array_reduce`. |
| 194 | 194 | * |
| 195 | - * @param array $a, |
|
| 196 | 195 | * @param array $b |
| 197 | 196 | * @return string |
| 198 | 197 | * 'missing' or 'invalid' |
@@ -214,7 +213,7 @@ discard block |
||
| 214 | 213 | * the XML. |
| 215 | 214 | * |
| 216 | 215 | * @throws Exception |
| 217 | - * @return XMLElement|void |
|
| 216 | + * @return XMLElement |
|
| 218 | 217 | * If `$_REQUEST{'redirect']` is set, and the Event executed successfully, |
| 219 | 218 | * the user will be redirected to the given location. If `$_REQUEST['redirect']` |
| 220 | 219 | * is not set, or the Event encountered errors, an XMLElement of the Event |
@@ -303,7 +302,7 @@ discard block |
||
| 303 | 302 | * If this Event is editing an existing entry, that Entry ID will |
| 304 | 303 | * be passed to this function. |
| 305 | 304 | * @throws Exception |
| 306 | - * @return XMLElement |
|
| 305 | + * @return boolean |
|
| 307 | 306 | * The result of the Event |
| 308 | 307 | */ |
| 309 | 308 | public function __doit(array $fields = array(), XMLElement &$result, $position = null, $entry_id = null) |
@@ -98,6 +98,9 @@ |
||
| 98 | 98 | Utilities: |
| 99 | 99 | -------------------------------------------------------------------------*/ |
| 100 | 100 | |
| 101 | + /** |
|
| 102 | + * @param string $field |
|
| 103 | + */ |
|
| 101 | 104 | public function set($field, $value) |
| 102 | 105 | { |
| 103 | 106 | if ($field === 'author_types' && !is_array($value)) { |
@@ -519,6 +519,9 @@ discard block |
||
| 519 | 519 | return self::__OK__; |
| 520 | 520 | } |
| 521 | 521 | |
| 522 | + /** |
|
| 523 | + * @param integer $entry_id |
|
| 524 | + */ |
|
| 522 | 525 | public function processRawFieldData($data, &$status, &$message = null, $simulate = false, $entry_id = null) |
| 523 | 526 | { |
| 524 | 527 | $status = self::__OK__; |
@@ -696,6 +699,10 @@ discard block |
||
| 696 | 699 | Filtering: |
| 697 | 700 | -------------------------------------------------------------------------*/ |
| 698 | 701 | |
| 702 | + /** |
|
| 703 | + * @param string $joins |
|
| 704 | + * @param string $where |
|
| 705 | + */ |
|
| 699 | 706 | public function buildDSRetrievalSQL($data, &$joins, &$where, $andOperation = false) |
| 700 | 707 | { |
| 701 | 708 | if (self::isFilterRegex($data[0])) { |
@@ -78,6 +78,9 @@ discard block |
||
| 78 | 78 | return ($rule ? General::validateString($data, $rule) : true); |
| 79 | 79 | } |
| 80 | 80 | |
| 81 | + /** |
|
| 82 | + * @param string $value |
|
| 83 | + */ |
|
| 81 | 84 | private function __replaceAmpersands($value) |
| 82 | 85 | { |
| 83 | 86 | return preg_replace('/&(?!(#[0-9]+|#x[0-9a-f]+|amp|lt|gt);)/i', '&', trim($value)); |
@@ -169,6 +172,9 @@ discard block |
||
| 169 | 172 | return self::__OK__; |
| 170 | 173 | } |
| 171 | 174 | |
| 175 | + /** |
|
| 176 | + * @param integer $entry_id |
|
| 177 | + */ |
|
| 172 | 178 | public function processRawFieldData($data, &$status, &$message = null, $simulate = false, $entry_id = null) |
| 173 | 179 | { |
| 174 | 180 | $status = self::__OK__; |
@@ -176,6 +176,10 @@ discard block |
||
| 176 | 176 | return $ids; |
| 177 | 177 | } |
| 178 | 178 | |
| 179 | + /** |
|
| 180 | + * @param string $field |
|
| 181 | + * @param string $value |
|
| 182 | + */ |
|
| 179 | 183 | public function set($field, $value) |
| 180 | 184 | { |
| 181 | 185 | if ($field == 'pre_populate_source' && !is_array($value)) { |
@@ -413,6 +417,9 @@ discard block |
||
| 413 | 417 | return self::__OK__; |
| 414 | 418 | } |
| 415 | 419 | |
| 420 | + /** |
|
| 421 | + * @param integer $entry_id |
|
| 422 | + */ |
|
| 416 | 423 | public function processRawFieldData($data, &$status, &$message = null, $simulate = false, $entry_id = null) |
| 417 | 424 | { |
| 418 | 425 | $status = self::__OK__; |
@@ -196,6 +196,9 @@ |
||
| 196 | 196 | return self::__OK__; |
| 197 | 197 | } |
| 198 | 198 | |
| 199 | + /** |
|
| 200 | + * @param integer $entry_id |
|
| 201 | + */ |
|
| 199 | 202 | public function processRawFieldData($data, &$status, &$message = null, $simulate = false, $entry_id = null) |
| 200 | 203 | { |
| 201 | 204 | $status = self::__OK__; |
@@ -122,6 +122,9 @@ discard block |
||
| 122 | 122 | return true; |
| 123 | 123 | } |
| 124 | 124 | |
| 125 | + /** |
|
| 126 | + * @param string $file |
|
| 127 | + */ |
|
| 125 | 128 | public static function getMetaInfo($file, $type) |
| 126 | 129 | { |
| 127 | 130 | $meta = array(); |
@@ -392,6 +395,9 @@ discard block |
||
| 392 | 395 | return self::__OK__; |
| 393 | 396 | } |
| 394 | 397 | |
| 398 | + /** |
|
| 399 | + * @param integer $entry_id |
|
| 400 | + */ |
|
| 395 | 401 | public function processRawFieldData($data, &$status, &$message = null, $simulate = false, $entry_id = null) |
| 396 | 402 | { |
| 397 | 403 | $status = self::__OK__; |
@@ -341,6 +341,10 @@ |
||
| 341 | 341 | return $file; |
| 342 | 342 | } |
| 343 | 343 | |
| 344 | + /** |
|
| 345 | + * @param string $class |
|
| 346 | + * @param string $ext |
|
| 347 | + */ |
|
| 344 | 348 | private function findFileWithExtension($class, $ext) |
| 345 | 349 | { |
| 346 | 350 | // PSR-4 lookup |