| @@ 234-245 (lines=12) @@ | ||
| 231 | * |
|
| 232 | * @return Field|null |
|
| 233 | */ |
|
| 234 | public function __call($method, $arguments) |
|
| 235 | { |
|
| 236 | if ($className = static::findFieldClass($method)) { |
|
| 237 | $name = array_get($arguments, 0, ''); |
|
| 238 | ||
| 239 | $element = new $className($name, array_slice($arguments, 1)); |
|
| 240 | ||
| 241 | $this->pushField($element); |
|
| 242 | ||
| 243 | return $element; |
|
| 244 | } |
|
| 245 | } |
|
| 246 | ||
| 247 | /** |
|
| 248 | * Render the form. |
|
| @@ 985-996 (lines=12) @@ | ||
| 982 | * |
|
| 983 | * @return Field|void |
|
| 984 | */ |
|
| 985 | public function __call($method, $arguments) |
|
| 986 | { |
|
| 987 | if ($className = static::findFieldClass($method)) { |
|
| 988 | $column = array_get($arguments, 0, ''); //[0]; |
|
| 989 | ||
| 990 | $element = new $className($column, array_slice($arguments, 1)); |
|
| 991 | ||
| 992 | $this->pushField($element); |
|
| 993 | ||
| 994 | return $element; |
|
| 995 | } |
|
| 996 | } |
|
| 997 | ||
| 998 | /** |
|
| 999 | * Render the contents of the form when casting to string. |
|