init
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
<?xml version="1.0"?>
|
||||
<!--
|
||||
/**
|
||||
* Copyright © Magento, Inc. All rights reserved.
|
||||
* See COPYING.txt for license details.
|
||||
*/
|
||||
-->
|
||||
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Acl/etc/acl.xsd">
|
||||
<acl>
|
||||
<resources>
|
||||
<resource id="Magento_Backend::admin">
|
||||
<resource id="Magento_TestModule4::all" title="TestModule4" sortOrder="1">
|
||||
<resource id="Magento_TestModule4::resource1" title="Resource1" sortOrder="20"/>
|
||||
<resource id="Magento_TestModule4::resource2" title="Resource2" sortOrder="10"/>
|
||||
<resource id="Magento_TestModule4::resource3" title="Resource3" sortOrder="30"/>
|
||||
</resource>
|
||||
</resource>
|
||||
</resources>
|
||||
</acl>
|
||||
</config>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0"?>
|
||||
<!--
|
||||
/**
|
||||
* Copyright © Magento, Inc. All rights reserved.
|
||||
* See COPYING.txt for license details.
|
||||
*/
|
||||
-->
|
||||
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
|
||||
<preference for="Magento\TestModule4\Service\V1\DataObjectServiceInterface" type="Magento\TestModule4\Service\V1\DataObjectService" />
|
||||
<preference for="Magento\TestModule4\Service\V1\Entity\ExtensibleRequestInterface" type="Magento\TestModule4\Service\V1\Entity\ExtensibleRequest" />
|
||||
<type name="Magento\TestModule4\Service\V1\Entity\ExtensibleRequest">
|
||||
<arguments>
|
||||
<argument name="resource" xsi:type="object">Magento\TestModule4\Model\ResourceModel\Item</argument>
|
||||
</arguments>
|
||||
</type>
|
||||
</config>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0"?>
|
||||
<!--
|
||||
/**
|
||||
* Copyright © Magento, Inc. All rights reserved.
|
||||
* See COPYING.txt for license details.
|
||||
*/
|
||||
-->
|
||||
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
|
||||
<module name="Magento_TestModule4" />
|
||||
</config>
|
||||
@@ -0,0 +1,39 @@
|
||||
<?xml version="1.0"?>
|
||||
<!--
|
||||
/**
|
||||
* Copyright © Magento, Inc. All rights reserved.
|
||||
* See COPYING.txt for license details.
|
||||
*/
|
||||
-->
|
||||
<routes xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Webapi:etc/webapi.xsd">
|
||||
<route method="GET" url="/V1/testmodule4/:id">
|
||||
<service class="Magento\TestModule4\Service\V1\DataObjectServiceInterface" method="getData" />
|
||||
<resources>
|
||||
<resource ref="Magento_TestModule4::resource1" />
|
||||
</resources>
|
||||
</route>
|
||||
<route method="GET" url="/V1/testmodule4/scalar/:id">
|
||||
<service class="Magento\TestModule4\Service\V1\DataObjectServiceInterface" method="scalarResponse" />
|
||||
<resources>
|
||||
<resource ref="Magento_TestModule4::resource1" />
|
||||
</resources>
|
||||
</route>
|
||||
<route method="POST" url="/V1/testmodule4/:id">
|
||||
<service class="Magento\TestModule4\Service\V1\DataObjectServiceInterface" method="updateData" />
|
||||
<resources>
|
||||
<resource ref="Magento_TestModule4::resource2" />
|
||||
</resources>
|
||||
</route>
|
||||
<route method="POST" url="/V1/testmodule4/:id/nested">
|
||||
<service class="Magento\TestModule4\Service\V1\DataObjectServiceInterface" method="nestedData" />
|
||||
<resources>
|
||||
<resource ref="Magento_TestModule4::resource3" />
|
||||
</resources>
|
||||
</route>
|
||||
<route method="POST" url="/V1/testmodule4/extensibleDataObject/:id">
|
||||
<service class="Magento\TestModule4\Service\V1\DataObjectServiceInterface" method="extensibleDataObject" />
|
||||
<resources>
|
||||
<resource ref="Magento_TestModule4::resource3" />
|
||||
</resources>
|
||||
</route>
|
||||
</routes>
|
||||
Reference in New Issue
Block a user