@@ -7,9 +7,7 @@ |
||
7 | 7 | use SilverStripe\ORM\FieldType\DBDate; |
8 | 8 | use SilverStripe\ORM\FieldType\DBField; |
9 | 9 | use SilverStripe\ORM\FieldType\DBDatetime; |
10 | -use SilverStripe\ORM\DataObject; |
|
11 | 10 | use SilverStripe\Dev\SapphireTest; |
12 | -use SilverStripe\Security\Member; |
|
13 | 11 | |
14 | 12 | class DBDateTest extends SapphireTest |
15 | 13 | { |
@@ -418,6 +418,7 @@ discard block |
||
418 | 418 | * |
419 | 419 | * @param string$html |
420 | 420 | * @param DataObject $node |
421 | + * @param string $html |
|
421 | 422 | * @return string |
422 | 423 | */ |
423 | 424 | protected function getNodeClassFromTree($html, $node) |
@@ -434,6 +435,10 @@ discard block |
||
434 | 435 | return ''; |
435 | 436 | } |
436 | 437 | |
438 | + /** |
|
439 | + * @param string $expected |
|
440 | + * @param string $actual |
|
441 | + */ |
|
437 | 442 | protected function assertHTMLSame($expected, $actual, $message = '') |
438 | 443 | { |
439 | 444 | // Trim each line, strip empty lines |
@@ -2,7 +2,6 @@ |
||
2 | 2 | |
3 | 3 | namespace SilverStripe\ORM\Tests; |
4 | 4 | |
5 | -use DOMDocument; |
|
6 | 5 | use SilverStripe\Dev\CSSContentParser; |
7 | 6 | use SilverStripe\Dev\SapphireTest; |
8 | 7 | use SilverStripe\ORM\DataObject; |
@@ -312,7 +312,7 @@ discard block |
||
312 | 312 | /** |
313 | 313 | * Assign value posted from form submission |
314 | 314 | * |
315 | - * @param mixed $value |
|
315 | + * @param string $value |
|
316 | 316 | * @param mixed $data |
317 | 317 | * @return $this |
318 | 318 | */ |
@@ -337,7 +337,7 @@ discard block |
||
337 | 337 | * |
338 | 338 | * When $html5=true, assign value from ISO 8601 string. |
339 | 339 | * |
340 | - * @param mixed $value |
|
340 | + * @param string $value |
|
341 | 341 | * @param mixed $data |
342 | 342 | * @return $this |
343 | 343 | */ |
@@ -250,7 +250,7 @@ discard block |
||
250 | 250 | /** |
251 | 251 | * Assign value posted from form submission |
252 | 252 | * |
253 | - * @param mixed $value |
|
253 | + * @param string $value |
|
254 | 254 | * @param mixed $data |
255 | 255 | * @return $this |
256 | 256 | */ |
@@ -267,7 +267,7 @@ discard block |
||
267 | 267 | /** |
268 | 268 | * Set time assigned from database value |
269 | 269 | * |
270 | - * @param mixed $value |
|
270 | + * @param string $value |
|
271 | 271 | * @param mixed $data |
272 | 272 | * @return $this |
273 | 273 | */ |
@@ -270,6 +270,9 @@ discard block |
||
270 | 270 | |
271 | 271 | |
272 | 272 | |
273 | + /** |
|
274 | + * @param boolean $disabled |
|
275 | + */ |
|
273 | 276 | public function setDisabled($disabled) |
274 | 277 | { |
275 | 278 | parent::setDisabled($disabled); |
@@ -279,6 +282,9 @@ discard block |
||
279 | 282 | return $this; |
280 | 283 | } |
281 | 284 | |
285 | + /** |
|
286 | + * @param boolean $readonly |
|
287 | + */ |
|
282 | 288 | public function setReadonly($readonly) |
283 | 289 | { |
284 | 290 | parent::setReadonly($readonly); |
@@ -371,6 +377,10 @@ discard block |
||
371 | 377 | $this->children->removeByName($fieldName, $dataFieldOnly); |
372 | 378 | } |
373 | 379 | |
380 | + /** |
|
381 | + * @param string $fieldName |
|
382 | + * @param FormField $newField |
|
383 | + */ |
|
374 | 384 | public function replaceField($fieldName, $newField) |
375 | 385 | { |
376 | 386 | return $this->children->replaceField($fieldName, $newField); |
@@ -456,6 +466,7 @@ discard block |
||
456 | 466 | * the children collection. Doesn't work recursively. |
457 | 467 | * |
458 | 468 | * @param string|FormField |
469 | + * @param string $field |
|
459 | 470 | * @return int Position in children collection (first position starts with 0). Returns FALSE if the field can't |
460 | 471 | * be found. |
461 | 472 | */ |
@@ -138,7 +138,7 @@ discard block |
||
138 | 138 | } |
139 | 139 | |
140 | 140 | /** |
141 | - * @param $bool |
|
141 | + * @param boolean $bool |
|
142 | 142 | * @return $this |
143 | 143 | */ |
144 | 144 | public function setHTML5($bool) |
@@ -151,7 +151,7 @@ discard block |
||
151 | 151 | * Assign value posted from form submission, based on {@link $datetimeFormat}. |
152 | 152 | * When $html5=true, this needs to be normalised ISO format (with "T" separator). |
153 | 153 | * |
154 | - * @param mixed $value |
|
154 | + * @param string $value |
|
155 | 155 | * @param mixed $data |
156 | 156 | * @return $this |
157 | 157 | */ |
@@ -317,7 +317,7 @@ discard block |
||
317 | 317 | * When $html5=true, assign value from ISO 8601 normalised string (with a "T" separator). |
318 | 318 | * Falls back to an ISO 8601 string (with a whitespace separator). |
319 | 319 | * |
320 | - * @param mixed $value |
|
320 | + * @param string $value |
|
321 | 321 | * @param mixed $data |
322 | 322 | * @return $this |
323 | 323 | */ |
@@ -492,6 +492,9 @@ discard block |
||
492 | 492 | return $this; |
493 | 493 | } |
494 | 494 | |
495 | + /** |
|
496 | + * @param boolean $bool |
|
497 | + */ |
|
495 | 498 | public function setReadonly($bool) |
496 | 499 | { |
497 | 500 | parent::setReadonly($bool); |
@@ -49,6 +49,9 @@ discard block |
||
49 | 49 | return parent::login($request, Authenticator::CMS_LOGIN); |
50 | 50 | } |
51 | 51 | |
52 | + /** |
|
53 | + * @param string $action |
|
54 | + */ |
|
52 | 55 | public function Link($action = null) |
53 | 56 | { |
54 | 57 | /** @skipUpgrade */ |
@@ -79,6 +82,9 @@ discard block |
||
79 | 82 | return null; |
80 | 83 | } |
81 | 84 | |
85 | + /** |
|
86 | + * @param string $title |
|
87 | + */ |
|
82 | 88 | public function getResponseController($title) |
83 | 89 | { |
84 | 90 | // Use $this to prevent use of Page to render underlying templates |
@@ -7,7 +7,6 @@ |
||
7 | 7 | use SilverStripe\Control\Director; |
8 | 8 | use SilverStripe\Admin\LeftAndMain; |
9 | 9 | use SilverStripe\Control\HTTPResponse; |
10 | -use SilverStripe\Control\Session; |
|
11 | 10 | use SilverStripe\Core\Convert; |
12 | 11 | use SilverStripe\Core\Manifest\ModuleLoader; |
13 | 12 | use SilverStripe\ORM\FieldType\DBField; |
@@ -111,7 +111,7 @@ |
||
111 | 111 | /** |
112 | 112 | * Global permissions required to edit |
113 | 113 | * |
114 | - * @param array $permissions |
|
114 | + * @param string[] $permissions |
|
115 | 115 | * @return $this |
116 | 116 | */ |
117 | 117 | public function setGlobalEditPermissions($permissions) |
@@ -161,7 +161,7 @@ |
||
161 | 161 | } |
162 | 162 | |
163 | 163 | /** |
164 | - * @param string|bool|array $content If passed as an array, values will be concatenated with a comma. |
|
164 | + * @param string $content If passed as an array, values will be concatenated with a comma. |
|
165 | 165 | * @return array |
166 | 166 | */ |
167 | 167 | public static function getHTMLChunks($content) |