Skip to Content
Menu
This question has been flagged
1 Reply
2940 Views

i can't find source of this error, in my code there is no such as "not in" but this error appears :


Uncaught Error: Unknown field state in domain [["state","not in",["draft"]]]
http://localhost:8071/web/content/899-6aca18d/web.assets_backend.js:1767
Traceback:
Error: Unknown field state in domain [["state","not in",["draft"]]]
    at Object.compute_domain (http://localhost:8071/web/content/899-6aca18d/web.assets_backend.js:1767:42)
    at Class.compute_domain (http://localhost:8071/web/content/899-6aca18d/web.assets_backend.js:2189:344)
    at Class.process_modifiers (http://localhost:8071/web/content/899-6aca18d/web.assets_backend.js:2224:60)
    at Class.trigger (http://localhost:8071/web/content/252-d7ceee3/web.assets_common.js:3105:180)
    at Class.trigger (http://localhost:8071/web/content/252-d7ceee3/web.assets_common.js:3109:148)
    at Class.on_form_changed (http://localhost:8071/web/content/899-6aca18d/web.assets_backend.js:2139:98)
    at Array. (http://localhost:8071/web/content/899-6aca18d/web.assets_backend.js:2136:6)
    at Array. (http://localhost:8071/web/content/252-d7ceee3/web.assets_common.js:547:681)
    at fire (http://localhost:8071/web/content/252-d7ceee3/web.assets_common.js:541:299)
    at Object.add [as done] (http://localhost:8071/web/content/252-d7ceee3/web.assets_common.js:542:467)


thank for suggest solution

_rahman_

Avatar
Discard
Author

Thanks, Mehjabin Farsana(Metalinks IT Consulting&Solutions)

i will try to add new field 'state',

next i will inform this later

Best Answer

Hi,

The error message indicates that there is a domain filter in your Odoo code that references a field called "state" and uses the "not in" operator with a value of "draft". However, the "state" field is not recognized by Odoo or is not defined in the model or view that you are working on.

To resolve this issue, you can try the following steps:

  1. Check the model or view that you are working on and make sure that the "state" field is defined and available. You can do this by checking the model definition or the view definition in the Odoo source code.

  2. If the "state" field is defined and available, check if it has a different name or if it is defined in a different module or addon. Make sure to import the module or addon that defines the "state" field in your code.

  3. If the "state" field is not defined or available, you can define it in the model or view that you are working on. You can do this by adding a new field to the model or view definition in the Odoo source code.

Hope this will help you

Thanks

Avatar
Discard
Related Posts Replies Views Activity
3
May 21
8744
1
Jun 18
4301
0
May 25
65
2
Mar 25
2472
1
Dec 24
1943