【发布时间】:2016-03-16 04:10:52
【问题描述】:
我已阅读 Magento 的 DevDocs 并在 Google 上搜索过这个问题,但通常缺少的 registration.php 答案不适用于此处。
我在发布的 CE 2.0.0 版本上,我只是想在magento/vendor/ 中启用我的第一个最小测试模块,但是
bin/magento module:enable -c Tchsl_Test
结果:
未知模块:“Tchsl_Test”
我基于vendor/magento/中模块的命名约定和文件位置
在vendor/tchsl/module-test/etc/module.xml我有
<config xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
<module name="Tchsl_Test" />
</config>
在vendor/tchsl/module-test/registration.php我有
<?php
\Magento\Framework\Component\ComponentRegistrar::register(
\Magento\Framework\Component\ComponentRegistrar::MODULE,
'Tchsl_Test',
__DIR__
);
我错过了什么?
【问题讨论】:
标签: magento-2.0