Magento ver。 2.1.7类别主页图像不保存

时间:2017-07-03 09:35:58

标签: magento magento2 magento-2.0

我正在使用Magento ver。 2.1.7当上传主页的类别图像时,不保存或上传图像。 我正在使用Agorae magento主题,我也检查了exception.log 它说一些例外见下文。

[2017-07-03 09:49:48] main.CRITICAL: exception 'PDOException' with message 'SQLSTATE[HY000]: General error: 1449 The user specified as a definer ('pocketgr_pglvdb'@'localhost') does not exist' in D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Statement\Pdo.php:228
Stack trace:
#0 D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Statement\Pdo.php(228): PDOStatement->execute(Array)
#1 D:\wamp\www\folder\vendor\magento\framework\DB\Statement\Pdo\Mysql.php(95): Zend_Db_Statement_Pdo->_execute(Array)
#2 D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Statement.php(303): Magento\Framework\DB\Statement\Pdo\Mysql->_execute(Array)
#3 D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Adapter\Abstract.php(480): Zend_Db_Statement->execute(Array)
#4 D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Adapter\Pdo\Abstract.php(238): Zend_Db_Adapter_Abstract->query('UPDATE `pg_cata...', Array)
#5 D:\wamp\www\folder\vendor\magento\framework\DB\Adapter\Pdo\Mysql.php(465): Zend_Db_Adapter_Pdo_Abstract->query('UPDATE `pg_cata...', Array)
#6 D:\wamp\www\folder\vendor\magento\framework\DB\Adapter\Pdo\Mysql.php(520): Magento\Framework\DB\Adapter\Pdo\Mysql->_query('UPDATE `pg_cata...', Array)
#7 D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Adapter\Abstract.php(635): Magento\Framework\DB\Adapter\Pdo\Mysql->query('UPDATE `pg_cata...', Array)
#8 D:\wamp\www\folder\vendor\magento\framework\EntityManager\Db\UpdateRow.php(83): Zend_Db_Adapter_Abstract->update('pg_catalog_cate...', Array, Array)
#9 D:\wamp\www\folder\vendor\magento\framework\EntityManager\Operation\Update\UpdateMain.php(57): Magento\Framework\EntityManager\Db\UpdateRow->execute('Magento\\Catalog...', Array)
#10 D:\wamp\www\folder\vendor\magento\framework\EntityManager\Operation\Update.php(105): Magento\Framework\EntityManager\Operation\Update\UpdateMain->execute(Object(Magento\Catalog\Model\Category\Interceptor), Array)
#11 D:\wamp\www\folder\vendor\magento\framework\EntityManager\EntityManager.php(87): Magento\Framework\EntityManager\Operation\Update->execute(Object(Magento\Catalog\Model\Category\Interceptor), Array)
#12 D:\wamp\www\folder\vendor\magento\module-catalog\Model\ResourceModel\Category.php(1027): Magento\Framework\EntityManager\EntityManager->save(Object(Magento\Catalog\Model\Category\Interceptor))
#13 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(74): Magento\Catalog\Model\ResourceModel\Category->save(Object(Magento\Catalog\Model\Category\Interceptor))
#14 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(70): Magento\Catalog\Model\ResourceModel\Category\Interceptor->___callParent('save', Array)
#15 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(63): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Catalog...', 'save', Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Array, 'clean_cache')
#16 D:\wamp\www\folder\vendor\magento\framework\App\Cache\FlushCacheByTags.php(71): Magento\Framework\Interception\Chain\Chain->Magento\Framework\Interception\Chain\{closure}(Object(Magento\Catalog\Model\Category\Interceptor))
#17 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(67): Magento\Framework\App\Cache\FlushCacheByTags->aroundSave(Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Object(Closure), Object(Magento\Catalog\Model\Category\Interceptor))
#18 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(138): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Catalog...', 'save', Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Array, 'catalogsearchFu...')
#19 D:\wamp\www\folder\vendor\magento\module-catalog-search\Model\Indexer\Fulltext\Plugin\Category.php(43): Magento\Catalog\Model\ResourceModel\Category\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Catalog\Model\Category\Interceptor))
#20 D:\wamp\www\folder\vendor\magento\module-catalog-search\Model\Indexer\Fulltext\Plugin\Category.php(29): Magento\CatalogSearch\Model\Indexer\Fulltext\Plugin\Category->addCommitCallback(Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Object(Closure), Object(Magento\Catalog\Model\Category\Interceptor))
#21 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(142): Magento\CatalogSearch\Model\Indexer\Fulltext\Plugin\Category->aroundSave(Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Object(Closure), Object(Magento\Catalog\Model\Category\Interceptor))
#22 D:\wamp\www\folder\var\generation\Magento\Catalog\Model\ResourceModel\Category\Interceptor.php(52): Magento\Catalog\Model\ResourceModel\Category\Interceptor->___callPlugins('save', Array, Array)
#23 D:\wamp\www\folder\vendor\magento\framework\Model\AbstractModel.php(631): Magento\Catalog\Model\ResourceModel\Category\Interceptor->save(Object(Magento\Catalog\Model\Category\Interceptor))
#24 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(146): Magento\Framework\Model\AbstractModel->save()
#25 D:\wamp\www\folder\var\generation\Magento\Catalog\Model\Category\Interceptor.php(26): Magento\Catalog\Model\Category\Interceptor->___callPlugins('save', Array, Array)
#26 D:\wamp\www\folder\vendor\magento\module-catalog\Controller\Adminhtml\Category\Save.php(203): Magento\Catalog\Model\Category\Interceptor->save()
#27 D:\wamp\www\folder\vendor\magento\framework\App\Action\Action.php(102): Magento\Catalog\Controller\Adminhtml\Category\Save->execute()
#28 D:\wamp\www\folder\vendor\magento\module-backend\App\AbstractAction.php(226): Magento\Framework\App\Action\Action->dispatch(Object(Magento\Framework\App\Request\Http))
#29 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(74): Magento\Backend\App\AbstractAction->dispatch(Object(Magento\Framework\App\Request\Http))
#30 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(70): Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor->___callParent('dispatch', Array)
#31 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(63): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Catalog...', 'dispatch', Object(Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor), Array, 'adminAuthentica...')
#32 D:\wamp\www\folder\vendor\magento\module-backend\App\Action\Plugin\Authentication.php(143): Magento\Framework\Interception\Chain\Chain->Magento\Framework\Interception\Chain\{closure}(Object(Magento\Framework\App\Request\Http))
#33 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(67): Magento\Backend\App\Action\Plugin\Authentication->aroundDispatch(Object(Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#34 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(138): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Catalog...', 'dispatch', Object(Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor), Array, 'adminMassaction...')
#35 D:\wamp\www\folder\vendor\magento\module-backend\App\Action\Plugin\MassactionKey.php(33): Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#36 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(142): Magento\Backend\App\Action\Plugin\MassactionKey->aroundDispatch(Object(Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#37 D:\wamp\www\folder\var\generation\Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor.php(26): Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor->___callPlugins('dispatch', Array, Array)
#38 D:\wamp\www\folder\vendor\magento\framework\App\FrontController.php(55): Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))
#39 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(74): Magento\Framework\App\FrontController->dispatch(Object(Magento\Framework\App\Request\Http))
#40 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(70): Magento\Framework\App\FrontController\Interceptor->___callParent('dispatch', Array)
#41 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(138): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Framewo...', 'dispatch', Object(Magento\Framework\App\FrontController\Interceptor), Array, 'install')
#42 D:\wamp\www\folder\vendor\magento\framework\Module\Plugin\DbStatusValidator.php(69): Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#43 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(142): Magento\Framework\Module\Plugin\DbStatusValidator->aroundDispatch(Object(Magento\Framework\App\FrontController\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#44 D:\wamp\www\folder\var\generation\Magento\Framework\App\FrontController\Interceptor.php(26): Magento\Framework\App\FrontController\Interceptor->___callPlugins('dispatch', Array, Array)
#45 D:\wamp\www\folder\vendor\magento\framework\App\Http.php(135): Magento\Framework\App\FrontController\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))
#46 D:\wamp\www\folder\vendor\magento\framework\App\Bootstrap.php(258): Magento\Framework\App\Http->launch()
#47 D:\wamp\www\folder\index.php(39): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http))
#48 {main}

Next exception 'Zend_Db_Statement_Exception' with message 'SQLSTATE[HY000]: General error: 1449 The user specified as a definer ('pocketgr_pglvdb'@'localhost') does not exist, query was: UPDATE `pg_catalog_category_entity` SET `attribute_set_id` = ?, `parent_id` = ?, `path` = ?, `level` = ?, `children_count` = ? WHERE (entity_id = '70')' in D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Statement\Pdo.php:235
Stack trace:
#0 D:\wamp\www\folder\vendor\magento\framework\DB\Statement\Pdo\Mysql.php(95): Zend_Db_Statement_Pdo->_execute(Array)
#1 D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Statement.php(303): Magento\Framework\DB\Statement\Pdo\Mysql->_execute(Array)
#2 D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Adapter\Abstract.php(480): Zend_Db_Statement->execute(Array)
#3 D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Adapter\Pdo\Abstract.php(238): Zend_Db_Adapter_Abstract->query('UPDATE `pg_cata...', Array)
#4 D:\wamp\www\folder\vendor\magento\framework\DB\Adapter\Pdo\Mysql.php(465): Zend_Db_Adapter_Pdo_Abstract->query('UPDATE `pg_cata...', Array)
#5 D:\wamp\www\folder\vendor\magento\framework\DB\Adapter\Pdo\Mysql.php(520): Magento\Framework\DB\Adapter\Pdo\Mysql->_query('UPDATE `pg_cata...', Array)
#6 D:\wamp\www\folder\vendor\magento\zendframework1\library\Zend\Db\Adapter\Abstract.php(635): Magento\Framework\DB\Adapter\Pdo\Mysql->query('UPDATE `pg_cata...', Array)
#7 D:\wamp\www\folder\vendor\magento\framework\EntityManager\Db\UpdateRow.php(83): Zend_Db_Adapter_Abstract->update('pg_catalog_cate...', Array, Array)
#8 D:\wamp\www\folder\vendor\magento\framework\EntityManager\Operation\Update\UpdateMain.php(57): Magento\Framework\EntityManager\Db\UpdateRow->execute('Magento\\Catalog...', Array)
#9 D:\wamp\www\folder\vendor\magento\framework\EntityManager\Operation\Update.php(105): Magento\Framework\EntityManager\Operation\Update\UpdateMain->execute(Object(Magento\Catalog\Model\Category\Interceptor), Array)
#10 D:\wamp\www\folder\vendor\magento\framework\EntityManager\EntityManager.php(87): Magento\Framework\EntityManager\Operation\Update->execute(Object(Magento\Catalog\Model\Category\Interceptor), Array)
#11 D:\wamp\www\folder\vendor\magento\module-catalog\Model\ResourceModel\Category.php(1027): Magento\Framework\EntityManager\EntityManager->save(Object(Magento\Catalog\Model\Category\Interceptor))
#12 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(74): Magento\Catalog\Model\ResourceModel\Category->save(Object(Magento\Catalog\Model\Category\Interceptor))
#13 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(70): Magento\Catalog\Model\ResourceModel\Category\Interceptor->___callParent('save', Array)
#14 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(63): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Catalog...', 'save', Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Array, 'clean_cache')
#15 D:\wamp\www\folder\vendor\magento\framework\App\Cache\FlushCacheByTags.php(71): Magento\Framework\Interception\Chain\Chain->Magento\Framework\Interception\Chain\{closure}(Object(Magento\Catalog\Model\Category\Interceptor))
#16 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(67): Magento\Framework\App\Cache\FlushCacheByTags->aroundSave(Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Object(Closure), Object(Magento\Catalog\Model\Category\Interceptor))
#17 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(138): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Catalog...', 'save', Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Array, 'catalogsearchFu...')
#18 D:\wamp\www\folder\vendor\magento\module-catalog-search\Model\Indexer\Fulltext\Plugin\Category.php(43): Magento\Catalog\Model\ResourceModel\Category\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Catalog\Model\Category\Interceptor))
#19 D:\wamp\www\folder\vendor\magento\module-catalog-search\Model\Indexer\Fulltext\Plugin\Category.php(29): Magento\CatalogSearch\Model\Indexer\Fulltext\Plugin\Category->addCommitCallback(Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Object(Closure), Object(Magento\Catalog\Model\Category\Interceptor))
#20 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(142): Magento\CatalogSearch\Model\Indexer\Fulltext\Plugin\Category->aroundSave(Object(Magento\Catalog\Model\ResourceModel\Category\Interceptor), Object(Closure), Object(Magento\Catalog\Model\Category\Interceptor))
#21 D:\wamp\www\folder\var\generation\Magento\Catalog\Model\ResourceModel\Category\Interceptor.php(52): Magento\Catalog\Model\ResourceModel\Category\Interceptor->___callPlugins('save', Array, Array)
#22 D:\wamp\www\folder\vendor\magento\framework\Model\AbstractModel.php(631): Magento\Catalog\Model\ResourceModel\Category\Interceptor->save(Object(Magento\Catalog\Model\Category\Interceptor))
#23 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(146): Magento\Framework\Model\AbstractModel->save()
#24 D:\wamp\www\folder\var\generation\Magento\Catalog\Model\Category\Interceptor.php(26): Magento\Catalog\Model\Category\Interceptor->___callPlugins('save', Array, Array)
#25 D:\wamp\www\folder\vendor\magento\module-catalog\Controller\Adminhtml\Category\Save.php(203): Magento\Catalog\Model\Category\Interceptor->save()
#26 D:\wamp\www\folder\vendor\magento\framework\App\Action\Action.php(102): Magento\Catalog\Controller\Adminhtml\Category\Save->execute()
#27 D:\wamp\www\folder\vendor\magento\module-backend\App\AbstractAction.php(226): Magento\Framework\App\Action\Action->dispatch(Object(Magento\Framework\App\Request\Http))
#28 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(74): Magento\Backend\App\AbstractAction->dispatch(Object(Magento\Framework\App\Request\Http))
#29 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(70): Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor->___callParent('dispatch', Array)
#30 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(63): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Catalog...', 'dispatch', Object(Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor), Array, 'adminAuthentica...')
#31 D:\wamp\www\folder\vendor\magento\module-backend\App\Action\Plugin\Authentication.php(143): Magento\Framework\Interception\Chain\Chain->Magento\Framework\Interception\Chain\{closure}(Object(Magento\Framework\App\Request\Http))
#32 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(67): Magento\Backend\App\Action\Plugin\Authentication->aroundDispatch(Object(Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#33 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(138): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Catalog...', 'dispatch', Object(Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor), Array, 'adminMassaction...')
#34 D:\wamp\www\folder\vendor\magento\module-backend\App\Action\Plugin\MassactionKey.php(33): Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#35 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(142): Magento\Backend\App\Action\Plugin\MassactionKey->aroundDispatch(Object(Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#36 D:\wamp\www\folder\var\generation\Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor.php(26): Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor->___callPlugins('dispatch', Array, Array)
#37 D:\wamp\www\folder\vendor\magento\framework\App\FrontController.php(55): Magento\Catalog\Controller\Adminhtml\Category\Save\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))
#38 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(74): Magento\Framework\App\FrontController->dispatch(Object(Magento\Framework\App\Request\Http))
#39 D:\wamp\www\folder\vendor\magento\framework\Interception\Chain\Chain.php(70): Magento\Framework\App\FrontController\Interceptor->___callParent('dispatch', Array)
#40 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(138): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Framewo...', 'dispatch', Object(Magento\Framework\App\FrontController\Interceptor), Array, 'install')
#41 D:\wamp\www\folder\vendor\magento\framework\Module\Plugin\DbStatusValidator.php(69): Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#42 D:\wamp\www\folder\vendor\magento\framework\Interception\Interceptor.php(142): Magento\Framework\Module\Plugin\DbStatusValidator->aroundDispatch(Object(Magento\Framework\App\FrontController\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#43 D:\wamp\www\folder\var\generation\Magento\Framework\App\FrontController\Interceptor.php(26): Magento\Framework\App\FrontController\Interceptor->___callPlugins('dispatch', Array, Array)
#44 D:\wamp\www\folder\vendor\magento\framework\App\Http.php(135): Magento\Framework\App\FrontController\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))
#45 D:\wamp\www\folder\vendor\magento\framework\App\Bootstrap.php(258): Magento\Framework\App\Http->launch()
#46 D:\wamp\www\folder\index.php(39): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http))
#47 {main} [] []

2 个答案:

答案 0 :(得分:0)

  

下一个异常'Zend_Db_Statement_Exception',消息'SQLSTATE [HY000]:常规错误:1449指定为定义者的用户('pocketgr_pglvdb'@'localhost')不存在,查询为:UPDATE pg_catalog_category_entity SET { {1}} =?,attribute_set_id =?,parent_id =?,path =?,level =? D:\ wamp \ www \ folder \ vendor \ magento \ zendframework1 \ library \ Zend \ Db \ Statement \ Pdo.php中的WHERE(entity_id ='70')'

由于未正确设置数据库用户,因此生成此错误。

确保正确建立数据库连接。如果是,请检查连接到数据库的用户权限。

如果您没有通过此类异常提供对magento的完全访问权限。

希望这会对你有所帮助。

答案 1 :(得分:0)

解决方案: 这是我的老定义者('pocketgr_pglvdb'@'localhost') 我用新用户/定义器

更新了我的sql文件

( '根' @ '本地主机')

并重新导入sql文件并且工作正常!!