When we work with odoo, it is important with the namecases and caps. I spent like many hours to find out an error like below
and my code is below
export class PPPProductIdFieldInSO extends Many2OneField {
setup() {
super.setup();
this.dialog = useService("dialog");
}
}
PPPProductIdFieldInSO.template = "web.Many2OneField"
export const PPPProductIdFieldInSO = {
...many2OneField,
component: PPPProductIdFieldInSO,
};
registry.category("fields").add("pppproduct_id_with_warning", PPPProductIdFieldInSO);
and the fixed code is below
export class PPPProductIdFieldInSO extends Many2OneField {
setup() {
super.setup();
this.dialog = useService("dialog");
}
}
PPPProductIdFieldInSO.template = "web.Many2OneField"
export const pPPProductIdFieldInSO = {
...many2OneField,
component: PPProductIdFieldInSO,
};
registry.category("fields").add("pppproduct_id_with_warning", pPPProductIdFieldInSO);
can you spot the issue ? if you did so fast, then you are good but it took me a while to get into that fix.