| Total Complexity | 7 |
| Total Lines | 36 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 15 | class PrefillViewHelper extends AbstractPrefillViewHelper |
||
| 16 | { |
||
| 17 | /** |
||
| 18 | * Initialize arguments |
||
| 19 | */ |
||
| 20 | public function initializeArguments() |
||
| 21 | { |
||
| 22 | parent::initializeArguments(); |
||
| 23 | $this->registerArgument('fieldname', 'string', 'FieldName', true); |
||
| 24 | $this->registerArgument('prefillSettings', 'array', 'PrefillSettings', false, []); |
||
| 25 | } |
||
| 26 | |||
| 27 | /** |
||
| 28 | * If the current field is available in POST data of the current request, return the value, otherwise |
||
| 29 | * a property from fe_user (if logged in and if the given field is configured to be prefilled) is returned. |
||
| 30 | * |
||
| 31 | * @return string |
||
| 32 | */ |
||
| 33 | public function render() |
||
| 51 | } |
||
| 52 | } |
||
| 53 |