Actions
Bug #93527
closedAssigned form-object does not overwrite default-values
Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Fluid
Target version:
-
Start date:
2021-02-17
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
9
PHP Version:
7.3
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
In the documentation of input viewhelpers of a form, it states "If used in conjunction with <f:form object='…'>, 'name' and 'value' properties will be ignored."
However only the name property is getting ignored. The (default) value attribute overwrites whatever the assigned object contains.
Testcase:
<f:form name="object" object="{object}">
With default value: <f:form.textfield type="text" property="withDefaultValue" value="Defaultvalue"/><br/>
Only default value: <f:form.textfield type="text" property="onlyDefaultValue" value="Defaultvalue"/><br/>
No default value: <f:form.textfield type="text" property="noDefaultValue" /><br/>
</f:form>
public function showAction() {
$this->view->assign('object', [
"withDefaultValue" => "Value from object",
"noDefaultValue" => "Value from object",
]);
}
Expected result:
Actual result:
Files
Actions