Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
4202 มุมมอง
Hi,
I want to override the following js function in this path ("Odoo 15" Enterprise: project_enterprise/static/src/js/connector/connector.js)

i tried this code:

odoo.define(
"connector_fixed",
function (require) {
"use strict";

const components = {
Connector: require("project_enterprise/static/src/js/connector/connector.js"),
};
const { patch } = require("web.utils");

patch(
components.Connector,
"connector_fixed",
{
_getPathInfo(source, target, slackness) {
//mycode
},
}
);
}
);

but this code can't handle dependecies
i got this
console.error:

Missing dependencies:
Array [ "project_enterprise/static/src/js/connector/connector.js"]

how should I override this function?
อวตาร
ละทิ้ง

I checked the path. I don't find any connector folder under js folder in project_enterprise module...

ผู้เขียน

you should check Odoo enterprise repository

i checked all files in module project_enterprise qs you mentioned. no folder called connector.

404: Pages not found..
I hope you resolve your issue.
Best of luck

Related Posts ตอบกลับ มุมมอง กิจกรรม
1
พ.ย. 24
1541
Dependency priorities on calling super แก้ไขแล้ว
1
ต.ค. 23
2470
2
ก.ค. 24
1370
Create function problem แก้ไขแล้ว
2
มิ.ย. 23
2198
2
ก.ย. 21
4720