<?xml version="1.0"?>

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
    <type name="Magento\Catalog\Model\Category\DataProvider">
        <plugin name="ait_dataprovider" type="BelVG\AdditionalImageTemplate\Plugin\DataProviderPlugin"/>
    </type>
    <virtualType name="BelVG\AdditionalImageTemplate\ImageUpload" type="BelVG\AdditionalImageTemplate\Model\ImageUploader">
        <arguments>
            <argument name="baseTmpPath" xsi:type="string">catalog/tmp/category</argument>
            <argument name="basePath" xsi:type="string">catalog/category</argument>
            <argument name="allowedExtensions" xsi:type="array">
                <item name="jpg" xsi:type="string">jpg</item>
                <item name="jpeg" xsi:type="string">jpeg</item>
                <item name="gif" xsi:type="string">gif</item>
                <item name="png" xsi:type="string">png</item>
            </argument>
        </arguments>
    </virtualType>
    <type name="BelVG\AdditionalImageTemplate\Controller\Adminhtml\Image\Upload">
        <arguments>
            <argument name="imageUploader" xsi:type="object">BelVG\AdditionalImageTemplate\ImageUpload</argument>
        </arguments>
    </type>
</config>