File tree Expand file tree Collapse file tree 2 files changed +117
-214
lines changed
Test/Unit/Block/System/Config Expand file tree Collapse file tree 2 files changed +117
-214
lines changed Original file line number Diff line number Diff line change 3
3
* Copyright © 2013-2017 Magento, Inc. All rights reserved.
4
4
* See COPYING.txt for license details.
5
5
*/
6
+
6
7
namespace Magento \Config \Block \System \Config ;
7
8
8
9
use Magento \Config \App \Config \Type \System ;
@@ -350,21 +351,21 @@ protected function _initElement(
350
351
$ data = $ this ->_configData [$ path ];
351
352
$ inherit = false ;
352
353
353
- if ($ field ->hasBackendModel ()) {
354
- $ backendModel = $ field ->getBackendModel ();
355
- $ backendModel ->setPath ($ path )
356
- ->setValue ($ data )
357
- ->setWebsite ($ this ->getWebsiteCode ())
358
- ->setStore ($ this ->getStoreCode ())
359
- ->afterLoad ();
360
- $ data = $ backendModel ->getValue ();
361
- }
362
-
363
354
} elseif ($ field ->getConfigPath () !== null ) {
364
355
$ data = $ this ->getConfigValue ($ field ->getConfigPath ());
365
356
} else {
366
357
$ data = $ this ->getConfigValue ($ path );
367
358
}
359
+
360
+ if ($ field ->hasBackendModel ()) {
361
+ $ backendModel = $ field ->getBackendModel ();
362
+ $ backendModel ->setPath ($ path )
363
+ ->setValue ($ data )
364
+ ->setWebsite ($ this ->getWebsiteCode ())
365
+ ->setStore ($ this ->getStoreCode ())
366
+ ->afterLoad ();
367
+ $ data = $ backendModel ->getValue ();
368
+ }
368
369
}
369
370
$ fieldRendererClass = $ field ->getFrontendModel ();
370
371
if ($ fieldRendererClass ) {
You can’t perform that action at this time.
0 commit comments