Odoo缺少依赖项:web.ControlPanelMixin

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Odoo缺少依赖项:web.ControlPanelMixin相关的知识,希望对你有一定的参考价值。

我正在尝试在Odoo 13社区中安装一些模块。缺少依赖项'web.ControlPanelMixin',我正在尝试解决此问题,到目前为止,我没有成功。javascript代码:

odoo.define('crm_dashboard.dashboard', [
  'web.core',
  'web.framework',
  'web.session',
  'web.ajax',
  'web.ActionManager',
  'web.view_registry',
  'web.Widget',
  'web.AbstractAction',
  'odoo.web.ControlPanelMixin'
], function (require) {
  "use strict";
  var core = require('web.core');
  var framework = require('web.framework');
  var session = require('web.session');
  var ajax = require('web.ajax');
  var ActionManager = require('web.ActionManager');
  var view_registry = require('web.view_registry');
  var Widget = require('web.Widget');
  var AbstractAction = require('web.AbstractAction');
  var ControlPanelMixin = require('web.ControlPanelMixin');
  var QWeb = core.qweb;
  ...
});

我尝试搜索'web.ControlPanelMixin'在哪里声明:

[odoo-13.0]$ grep -rnw ./ -e 'ControlPanelMixin'
./doc/reference/javascript_reference.rst:2221:        var ControlPanelMixin = require('web.ControlPanelMixin');
./doc/reference/javascript_reference.rst:2224:        var ClientAction = AbstractAction.extend(ControlPanelMixin, {
./doc/reference/javascript_reference.rst:2262:- add ControlPanelMixin in the widget:
./doc/reference/javascript_reference.rst:2266:        var ControlPanelMixin = require('web.ControlPanelMixin');
./doc/reference/javascript_reference.rst:2268:        var MyClientAction = AbstractAction.extend(ControlPanelMixin, {
./doc/reference/javascript_reference.rst:2277:        var SomeClientAction = Widget.extend(ControlPanelMixin, {
./mymodules/odoo_crm_dashboard/static/src/js/crm_dashboard.js:11:    'odoo.web.ControlPanelMixin'
./mymodules/odoo_crm_dashboard/static/src/js/crm_dashboard.js:25:var ControlPanelMixin = require('web.ControlPanelMixin');
./mymodules/odoo_crm_dashboard/static/src/js/crm_dashboard.js:31:var CRMDashboardView = AbstractAction.extend(ControlPanelMixin, {

谢谢!

答案

我认为有一个错误:

odoo.define('crm_dashboard.dashboard', [
    'web.core',
    'web.framework',
    'web.session',
    'web.ajax',
    'web.ActionManager',
    'web.view_registry',
    'web.Widget',
    'web.AbstractAction',
    'web.ControlPanelMixin'
]

它是web.ControlPanelMixin而不是odoo.web.ControlPanelMixin

您可以查看此documentation

以上是关于Odoo缺少依赖项:web.ControlPanelMixin的主要内容,如果未能解决你的问题,请参考以下文章

React Hook useEffect 缺少依赖项:'list'

Worldwind 缺少依赖项

React Hook useEffect 缺少依赖项

React Hook useEffect 缺少依赖项:'props'

React Hook useEffect 缺少依赖项:'History'

Eclipse 项目中缺少 Maven 依赖项