How to work with plugins in CakePHP 3.6 or 3.6.1

0

How to work with plugins in CakePHP 3.6 or 3.6.1.

Until version 3.5.13 I worked without problems, installed via composer and loaded with bin / cake plugin load Name

But in version 3.6 that was greatly changed, I install without problem with composer require user / nomeplugin

But when I load bin / cake plugin load NomePlugin

He throws me this message:

  

Your application class does not have a bootstrap () method. Please add one.

I got a hint to add the code below in src / Application.php

public function bootstrap()
{   
    parent::bootstrap();
}

So I can load. At least it does not give an error message. Says he loaded. But when I try to run the bake to generate code it tells me:

bin / cake bake

all groups -t CakeAclBr
PHP Fatal error:  Uncaught InvalidArgumentException: The plugin class 'CakeAclBr\Plugin' cannot be found. Ensure your autoloader is correct. in /backup/www/cake361/vendor/cakephp/cakephp/src/Http/BaseApplication.php:127
Stack trace:
#0 /backup/www/cake361/vendor/cakephp/cakephp/src/Http/BaseApplication.php(95): Cake\Http\BaseApplication->makePlugin('CakeAclBr\Plugi...', Array)
#1 /backup/www/cake361/src/Application.php(34): Cake\Http\BaseApplication->addPlugin('CakeAclBr', Array)
#2 /backup/www/cake361/vendor/cakephp/cakephp/src/Console/CommandRunner.php(188): App\Application->bootstrap()
#3 /backup/www/cake361/vendor/cakephp/cakephp/src/Console/CommandRunner.php(134): Cake\Console\CommandRunner->bootstrap()
#4 /backup/www/cake361/bin/cake.php(12): Cake\Console\CommandRunner->run(Array)
#5 {main}
  thrown in /backup/www/cake361/vendor/cakephp/cakephp/src/Http/BaseApplication.php on line 127

From here I could not go forward. Got any tips. Thanks!

    
asked by anonymous 25.04.2018 / 15:06

0 answers