File tree 1 file changed +4
-10
lines changed
1 file changed +4
-10
lines changed Original file line number Diff line number Diff line change @@ -227,11 +227,9 @@ public function createOne($name = NULL)
227
227
*/
228
228
public function setValues ($ values , $ erase = FALSE , $ onlyDisabled = FALSE )
229
229
{
230
- if (!$ this ->form ->isAnchored () || !$ this ->form ->isSubmitted ()) {
231
- foreach ($ values as $ name => $ value ) {
232
- if ((is_array ($ value ) || $ value instanceof \Traversable) && !$ this ->getComponent ($ name , FALSE )) {
233
- $ this ->createOne ($ name );
234
- }
230
+ foreach ($ values as $ name => $ value ) {
231
+ if ((is_array ($ value ) || $ value instanceof \Traversable) && !$ this ->getComponent ($ name , FALSE )) {
232
+ $ this ->createOne ($ name );
235
233
}
236
234
}
237
235
@@ -250,11 +248,7 @@ protected function loadHttpData()
250
248
return ;
251
249
}
252
250
253
- foreach ((array ) $ this ->getHttpData () as $ name => $ value ) {
254
- if ((is_array ($ value ) || $ value instanceof \Traversable) && !$ this ->getComponent ($ name , FALSE )) {
255
- $ this ->createOne ($ name );
256
- }
257
- }
251
+ $ this ->setValues ((array ) $ this ->getHttpData ());
258
252
}
259
253
260
254
You can’t perform that action at this time.
0 commit comments