Odoo Help

2

2
3 Answers
8
Avatar

Andreas Brueckl Austria

--Andreas Brueckl--

5546
| 8 8 9
Vienna, Austria
--Andreas Brueckl--
OpenERP Consulting and Development
Andreas Brueckl Austria
11/22/13, 10:42 AM

Yes, it is required to specify the field again.

Another option would be to only update the function pointer:

self._columns['price_subtotal']._fnct = _amount_line
2 Comments
ARRIOUACH Mohamed Morocco
10/30/14, 6:15 AM

Thanks Andreas Brueckl, that fixed my problem.

Marie Pinto Peru
10/12/15, 7:08 PM

Hello. I'd like to know where to put this code... Thank you!

1
igor Croatia
10/8/14, 4:16 AM

i can't get this to work either... 

if i specify the field again, function is called, but then sale.order module can't acces 'price_subtotal', and i don't see why not...

( File "/opt/openerp/server/openerp/addons/sale/sale.py", line 100, in _amount_all

val1 += line.price_subtotal File "/opt/openerp/server/openerp/osv/orm.py", line 504, in __getattr__ raise AttributeError(e) AttributeError: 857)

i also can't figure out how to update function pointer...

0
Ajay India
6/6/14, 6:28 AM

Ok. thanks. I didn't know about this and I was breaking my head trying to check this.

1 Comment
Ajay India
6/6/14, 6:30 AM

Hey Andreas can you tell where to put the line you suggested in code?? I tried before & after the overridden function it gives me error.

Ask a Question
Writer
Keep Informed
1 follower(s)
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