File tree Expand file tree Collapse file tree 2 files changed +7
-13
lines changed
app/code/Magento/PageBuilder
Model/Config/ContentType/AdditionalData/Provider/Uploader Expand file tree Collapse file tree 2 files changed +7
-13
lines changed Original file line number Diff line number Diff line change 10
10
11
11
use Magento \PageBuilder \Model \Config \ContentType \AdditionalData \ProviderInterface ;
12
12
use Magento \Backend \Model \Url ;
13
+ use Magento \Ui \Component \Form \Element \DataType \Media \OpenDialogUrl as OpenDialogConfig ;
13
14
14
15
/**
15
16
* Provides open dialog URL for media gallery slideout
@@ -22,20 +23,20 @@ class OpenDialogUrl implements ProviderInterface
22
23
private $ urlBuilder ;
23
24
24
25
/**
25
- * @var string
26
+ * @var OpenDialogConfig
26
27
*/
27
- private $ openDialogPath ;
28
+ private $ openDialogConfig ;
28
29
29
30
/**
30
31
* @param Url $urlBuilder
31
- * @param array $openDialogPath
32
+ * @param OpenDialogConfig $openDialogCOnfig
32
33
*/
33
34
public function __construct (
34
35
Url $ urlBuilder ,
35
- array $ openDialogPath
36
+ OpenDialogConfig $ openDialogConfig
36
37
) {
37
38
$ this ->urlBuilder = $ urlBuilder ;
38
- $ this ->openDialogPath = array_shift ( $ openDialogPath ) ;
39
+ $ this ->openDialogConfig = $ openDialogConfig ;
39
40
}
40
41
41
42
/**
@@ -44,7 +45,7 @@ public function __construct(
44
45
public function getData (string $ itemName ) : array
45
46
{
46
47
return [
47
- $ itemName => $ this ->urlBuilder ->getUrl ($ this ->openDialogPath , ['_secure ' => true ])
48
+ $ itemName => $ this ->urlBuilder ->getUrl ($ this ->openDialogConfig -> getOpenDialogUrl () , ['_secure ' => true ])
48
49
];
49
50
}
50
51
}
Original file line number Diff line number Diff line change 12
12
<type name =" Magento\Catalog\Block\Product\ImageFactory" >
13
13
<plugin name =" designLoader" type =" Magento\PageBuilder\Plugin\DesignLoader" />
14
14
</type >
15
- <type name =" Magento\PageBuilder\Model\Config\ContentType\AdditionalData\Provider\Uploader\OpenDialogUrl" >
16
- <arguments >
17
- <argument name =" openDialogPath" xsi : type =" array" >
18
- <item name =" default" xsi : type =" string" >cms/wysiwyg_images/index</item >
19
- </argument >
20
- </arguments >
21
- </type >
22
15
<virtualType name =" Magento\PageBuilder\Block\Adminhtml\ContentType\Edit\ModalCloseButton" type =" Magento\PageBuilder\Block\Adminhtml\ContentType\Edit\CloseButton" >
23
16
<arguments >
24
17
<argument name =" targetName" xsi : type =" string" >ns = pagebuilder_modal_form, index = modal</argument >
You can’t perform that action at this time.
0 commit comments