File tree Expand file tree Collapse file tree 1 file changed +4
-10
lines changed Expand file tree Collapse file tree 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)
227227 */
228228 public function setValues ($ values , $ erase = FALSE , $ onlyDisabled = FALSE )
229229 {
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 );
235233 }
236234 }
237235
@@ -250,11 +248,7 @@ protected function loadHttpData()
250248 return ;
251249 }
252250
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 ());
258252 }
259253
260254
You can’t perform that action at this time.
0 commit comments