Closed Guite closed 11 years ago
@drak @cmfcmf @phaidon
No idea :-) However it should work if you add it to https://github.com/zikula/core/blob/1.3/src/app/ZikulaKernel.php by hand. I don't know if auto-adding is already implemented. @drak
Is the composer.json correct?
I might be wrong, but I tried to test Symfony routing and with the AcmeExampleModule and tried to use @AcmeExampleModule/Controller
in routing.yml
, it always said "bundle not registered" (or similar).
Symfony routing is not enabled. Maybe the composer.json is not correctly formed - that is a common reason.
This is how it looks like (composer validate says it is ok):
{
"name": "cmfcmf/usagestatistics",
"description": "CmfcmfUsageStatisticsModule module generated by ModuleStudio 0.6.1.",
"version": "1.0.0",
"type": "zikula-module",
"license": "LGPL-3.0+",
"authors": [
{
"homepage": "https://www.github.com/cmfcmf/UsageStatistics"
}
],
"autoload": {
"psr-0": { "Cmfcmf\\UsageStatisticsModule\\": "" }
},
"require": {
"php": ">5.3.3"
},
"suggest": {
},
"extra": {
"zikula": {
"class": "Cmfcmf\\UsageStatisticsModule\\CmfcmfUsageStatisticsModule"
}
}
}
BTW: I know Routing is not enabled. I enabled it 'by hand'.
You can email me the zip of the module, but I cant look till much later today or tomorrow.
Btw- you should call it name: "cmfcmf/usage-statistics"
I just tried placing the following code in index.php and the two MOST-1.3.6 generated modules as well as the example module return true
…
$x = ModUtil::isOO('AcmeExampleModule');
$y = ModUtil::isOO('CmfcmfUsageStatisticsModule');
$z = ModUtil::isOO('ZikulaOAuthModule');
var_dump($x);
var_dump($y);
var_dump($z);
So @Guite you should send your module to @drak.
Should be fixed by https://github.com/zikula/core/pull/1096.
Works indeed :+1:
When targeting 1.3.6 then
ModUtil::isOO()
returns false for the generated module. Usually the following condition should become true:The
getModule
method includes the following check:Some debugging shew that the InvalidArgumentException happens, but this is not visible as it is caught silently.
The output of
includes
AcmeExampleModule
, but notGuiteAutoMusicModule
(example model).So obviously something is missing in the generated module - but what?