Uncaught Typeerror: Cannot Read Property 'bool' of Undefined
Howdy guys, I am facing this problem when i am trying to create a new client. Can you delight aid me right this bug. Thanks in advance
12 Answers
This error is because in that location is a holding field in that model, on that course that doesn't have his generic value defined, probably someone delete it.
you should be getting this same error one fourth dimension for every property with no generic value inside that course.
the model is the object, for example the partner 'res.partner'
What is a property field?
https://accounts.openerp.com/forum/Assist-ane/question/24622/
Where can I define the generic value?
get-go you need to know the property you are going define, to know that, get developer mode on that grade and check for fields that begins with 'property', properties are normally accounts, in res.partner we also have the cost-lists.
so lets say for example our property is 'property_account_receivable' from the partner object, which is a many2one field to the object account.account
at present we go to settings --> parameters --> configuration parameters
we filter for generics and search for information technology, if in that location is no lines, then thats a trouble and nosotros need one.
so we create one with the proper noun:'property_account_receivable', field: Account Receivable, type:many2one, resource:[no value], account.account, and the default account we would desire to put.
Hi.
The solution is:
In the file /addons/web/static/src/js/view_form.js
Replace the lines:
if (! no_recurse) { var dataset = new case.web.DataSetStatic(this, this.field.relation, self.build_context()); this.live(dataset.name_get([self.get("value")])).washed(function(data) { self.display_value["" + cocky.get("value")] = information[0][i]; cocky.render_value(true); }); }
By:
if (! no_recurse) { var dataset = new instance.web.DataSetStatic(this, this.field.relation, self.build_context()); this.live(dataset.name_get([self.get("value")])).done(function(data) { if(typeof information[0] != "undefined" && data[0] != null && data[0].length > 0){ self.display_value["" + self.get("value")] = data[0][ane]; self.render_value(true); } else { return false; } }); }
Unremarkably this mistake comes when yous try to pass an non existing id to a many2many/many2one field.
This mistake occurs in Chrome Browser when you read a property or call a method on an undefined object . Uncaught TypeError: Cannot read property of undefined fault is probably easiest to understand from the perspective of undefined, since undefined is not considered an object type at all (but its ain undefined blazon instead), and properties can only vest to objects within JavaScript. There are a few variations of this error depending on the belongings you are trying to access. Sometimes instead of undefined it will say null.
http://cyberspace-informations.com/js/iq/unerror.htm
You could go the real reason with a small js print to debug.
Go to \addons/web/static/src/js/view_form.js#L533 and add the following lines:
console.log("FIELDNAME " +fieldname); console.log(cocky.fields);
After reproduce the fault and so cheque on your browser programmer tools panel to see the trouble.
For chrome use correct-click and inspect pick and see the console.
Answer by @oscarolar
If using nginx, read this post >>
http://www.developpez.internet/forums/d1498867/logiciels/solutions-d-entreprise/erp/odoo-ex-openerp/v8-importation-csv-error-cannot-read-property-1-of-undefined/
I am getting this error when trying to add a customer invoice. The error appears when I try to add together an invoice line, it gives this error and does non allow me to add an invoice line.
I checked the property fields every bit suggested and all fields seems to exist there. The system is a fresh install with a custom chart of accounts. Account payable and receivable are available for the customer. Also income and expense accounts are available for the product.
Please assistance.
UPDATE: The outcome is now fixed. There was not default business relationship set for the generic backdrop of receivable, payable, expense and income accounts. Thanks so much for your help.
This is happening as well with my when I access the Products form and click on Create. Following the instructions I found 5 property values on product form: 3 for stock counter parts (property_stock_procurement, property_stock_production and property_stock_inventory) and two for accounting (property_account_income and property_account_expense). All 5 property values are defined on settings / parameters / configuration parameters. Any thought please?
I am also getting this same error when creating a new product from the point of sale bill of fare. When I create a new product from anywhere else (like purchase card) I practise not get this fault.
It happens for all users for me.
I take tried setting defaults in debug mode but that doesn't seem to find this 'undefined ' field.
The only affair I might be able to attribute this to is deleting the others category from point of sale categories (but information technology recreates it automatically).
Source: https://www.odoo.com/forum/help-1/uncaught-typeerror-cannot-read-property-1-of-undefined-28100
0 Response to "Uncaught Typeerror: Cannot Read Property 'bool' of Undefined"
Post a Comment