卸载drupal 8 commerce时出现意外错误

时间:2017-12-25 21:21:37

标签: drupal drupal-8 drupal-commerce

我正在尝试卸载商务模块。

我购买了一个带有商业模块的模板,并使用带有演示数据的文件。我已经联系了模板提供商,他已经澄清了问题不在于模板,而在于模块。

我正在逐个卸载模块,并且每次卸载之间都刷新了所有缓存。

在卸载模块之前,我还删除了商业中的所有视图,块和数据,例如订单,产品。

我可以卸载除Commerce,Commerce Price,Commerce Store和Commerce Product之外的所有商务模块。

每当我尝试卸载Commerce Product时,由于某种原因它都无法完成。我只得到

The website encountered an unexpected error. Please try again later.</br></br><em class="placeholder">Drupal\Component\Plugin\Exception\PluginNotFoundException</em>: The "commerce_product" entity type does not exist. in <em class="placeholder">Drupal\Core\Entity\EntityTypeManager->getDefinition()</em> (line <em class="placeholder">133</em> of <em class="placeholder">core/lib/Drupal/Core/Entity/EntityTypeManager.php</em>). <pre class="backtrace">flag_views_data_alter(Array, NULL, NULL) (Line: 501)
Drupal\Core\Extension\ModuleHandler->alter('views_data', Array) (Line: 254)
Drupal\views\ViewsData->getData() (Line: 162)
Drupal\views\ViewsData->get('block_content') (Line: 91)
Drupal\views\Plugin\Derivative\ViewsEntityRow->getDerivativeDefinitions(Array) (Line: 101)
Drupal\Component\Plugin\Discovery\DerivativeDiscoveryDecorator->getDerivatives(Array) (Line: 87)
Drupal\Component\Plugin\Discovery\DerivativeDiscoveryDecorator->getDefinitions() (Line: 283)
Drupal\Core\Plugin\DefaultPluginManager->findDefinitions() (Line: 174)
Drupal\Core\Plugin\DefaultPluginManager->getDefinitions() (Line: 22)
Drupal\Core\Plugin\DefaultPluginManager->getDefinition('entity:node') (Line: 16)
Drupal\Core\Plugin\Factory\ContainerFactory->createInstance('entity:node', Array) (Line: 84)
Drupal\Component\Plugin\PluginManagerBase->createInstance('entity:node') (Line: 818)
Drupal\views\Plugin\views\display\DisplayPluginBase->getPlugin('row') (Line: 122)
Drupal\views\Plugin\views\style\StylePluginBase->init(Object, Object, Array) (Line: 821)
Drupal\views\Plugin\views\display\DisplayPluginBase->getPlugin('style') (Line: 883)
Drupal\views\ViewExecutable->initStyle() (Line: 1840)
Drupal\views\ViewExecutable->getTitle() (Line: 132)
Drupal\views\Plugin\views\display\PathPluginBase->getRoute('blog', 'page') (Line: 220)
Drupal\views\Plugin\views\display\PathPluginBase->collectRoutes(Object) (Line: 120)
Drupal\views\EventSubscriber\RouteSubscriber->routes()
call_user_func(Array) (Line: 146)
Drupal\Core\Routing\RouteBuilder->rebuild() (Line: 83)
Drupal\Core\ProxyClass\Routing\RouteBuilder->rebuild() (Line: 477)
Drupal\Core\Extension\ModuleInstaller->uninstall(Array, 1) (Line: 91)
Drupal\Core\ProxyClass\Extension\ModuleInstaller->uninstall(Array) (Line: 160)
Drupal\system\Form\ModulesUninstallConfirmForm->submitForm(Array, Object)
call_user_func_array(Array, Array) (Line: 111)
Drupal\Core\Form\FormSubmitter->executeSubmitHandlers(Array, Object) (Line: 51)
Drupal\Core\Form\FormSubmitter->doSubmitForm(Array, Object) (Line: 585)
Drupal\Core\Form\FormBuilder->processForm('system_modules_uninstall_confirm_form', Array, Object) (Line: 314)
Drupal\Core\Form\FormBuilder->buildForm('system_modules_uninstall_confirm_form', Object) (Line: 74)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 576)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
call_user_func_array(Object, Array) (Line: 153)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 68)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 50)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 657)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
</pre>

我无法访问该网站。

有人可以向我解释错误的原因吗?

1 个答案:

答案 0 :(得分:1)

似乎主题依赖于商业模块,因此您必须检查主题,可能会有一些直接在主题中呈现的视图,现在您已删除模块,以便视图不会获取产品实体。你必须启用它。