0
スロー$テーマプロパティ見つける:Cakephp3 - カント私は(作曲を使用)V3.3にCakephp3 v3のからアップグレードしたと、私は次のエラーを取得するエラー
Deprecated (16384): Property $theme is deprecated.
Use $this->viewBuilder()->theme() instead in beforeRender().
[CORE/src/View/ViewVarsTrait.php, line 103]
をしかし、私は、私の中で見つけることができませんがファイル$テーマが使用されます。キーワード$ themeとbeforeRenderのすべてのファイルを検索しましたが、関連する結果はありません。
このエラーはすべてのマイページに表示されるため、それぞれのファイルに含まれている必要があります。
私はすでにGoogleでこの問題について検索しましたが、関連する結果もありません。
他に誰かがこの問題を抱えていますか?
フル・エラー・スタック:
public function beforeRender(Event $event)
{
$this->viewBuilder()->theme('Orange');
}
ない:
$viewClass = null
$builder = object(Cake\View\ViewBuilder) {
\t [protected] _templatePath => 'Users'
\t [protected] _template => 'login'
\t [protected] _plugin => null
\t [protected] _theme => 'Orange'
\t [protected] _layout => null
\t [protected] _autoLayout => null
\t [protected] _layoutPath => null
\t [protected] _name => null
\t [protected] _className => null
\t [protected] _options => []
\t [protected] _helpers => []
}
$validViewOptions = [
\t (int) 0 => 'passedArgs'
]
$viewOptions = [
\t 'passedArgs' => []
]
$option = 'passedArgs'
$this = object(App\Controller\UsersController) {
\t theme => 'Orange'
\t name => 'Users'
\t helpers => []
\t request => object(Cake\Network\Request) {}
\t response => object(Cake\Network\Response) {}
\t paginate => []
\t autoRender => false
\t components => []
\t View => null
\t plugin => null
\t passedArgs => []
\t modelClass => 'Users'
\t viewClass => null
\t viewVars => []
\t Flash => object(Cake\Controller\Component\FlashComponent) {}
\t Auth => object(Cake\Controller\Component\AuthComponent) {}
\t [protected] _responseClass => 'Cake\Network\Response'
\t [protected] _components => object(Cake\Controller\ComponentRegistry) {}
\t [protected] _validViewOptions => [
\t \t (int) 0 => 'passedArgs'
\t ]
\t [protected] _eventManager => object(Cake\Event\EventManager) {}
\t [protected] _eventClass => '\Cake\Event\Event'
\t [protected] _tableLocator => object(Cake\ORM\Locator\TableLocator) {}
\t [protected] _modelFactories => [
\t \t 'Table' => [
\t \t \t [maximum depth reached]
\t \t ]
\t ]
\t [protected] _modelType => 'Table'
\t [protected] _viewBuilder => object(Cake\View\ViewBuilder) {}
}
$deprecatedOptions = [
\t 'layout' => 'layout',
\t 'view' => 'template',
\t 'theme' => 'theme',
\t 'autoLayout' => 'autoLayout',
\t 'viewPath' => 'templatePath',
\t 'layoutPath' => 'layoutPath'
]
$new = 'theme'
$old = 'theme'
Cake\Controller\Controller::createView() - CORE/src/View/ViewVarsTrait.php, line 103
Cake\Controller\Controller::render() - CORE/src/Controller/Controller.php, line 616
Cake\Http\ActionDispatcher::_invoke() - CORE/src/Http/ActionDispatcher.php, line 131
Cake\Http\ActionDispatcher::dispatch() - CORE/src/Http/ActionDispatcher.php, line 99
Cake\Routing\Dispatcher::dispatch() - CORE/src/Routing/Dispatcher.php, line 65
[main] - ROOT/webroot/index.php, line 21
は完全なエラーメッセージですか?あなたはプラグインを使用していますか?多分プラグインコンポーネントの問題です – arilia
@arilia私はプラグインを使用しません。はい、それは完全なエラーメッセージです。 – niandrei
キーワード '$ theme'を検索する必要はありません。コントローラオブジェクトの属性に使用されています。 'theme'または' - > theme'を検索してください。私は私のAppControllerまたは私のコンポーネント、IDFのいずれか – arilia