Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
There is no way of acessing the purchase.order.line date.....u can add new field in purchase order model and call onchange method on order_line and pass same field as an argument.
<field name ='order_line' onchange= "getdate(order_line)">
by this way u can specify the defnition of getdate() to fetch the date of purchase order line and insert into purchase order model...
True, you cannot access child objects field...
However with help of some work around you can acheive it, again depending on your requirement, but keep it mind, you are trying to fetch values of muliple records (One2many) and dumping it in single record's field (parent), hence you can either have first/last of child records value, or concatenation of all child's records values as single value...
So all you need to do is First create a functional field in Purchase Order object, (Note: store is False)
case 1: Assume you are trying to fetch First Child records value, say "description", then evaluate your functional field to fetch only first records' "description" value
case 2: Assume you want to fetch all Child records value, say "description", then evaluate your functional field to fetch all records' "description" value, by concatenating with a comma(,) separator...
Now the same functional field can be used in Purchase Order Tree... And you will have to write a defined search view for it, use _fnct_search..
Hope this helps you, even i had the same requirement, so i acheived it with functional field and defined search view
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 10/15/14, 3:14 AM|
|Seen: 1793 times|
|Last updated: 3/16/15, 8:10 AM|