Odoo Help

1

ProgrammingError: can't adapt type 'dict'

By
jean44
on 9/17/13, 9:04 AM 1,646 views

How I can resolve this problem ?

Can you please more specify ? At where or code you have done ?

Pinakin Nayi (pna)
on 9/17/13, 11:05 AM
0

Tarek Mohamed Ibrahim

--Tarek Mohamed Ibrahim--
904
| 5 3 7
Gîza, Egypt
--Tarek Mohamed Ibrahim--

I am an old VFP developer on ERP

I have moved to 2p since Nov-2014 and started developing with Python on Odoo.

https://www.linkedin.com/profile/public-profile-settings?trk=prof-edit-edit-public_profile

tibrahim@2p.com.sa

Tarek Mohamed Ibrahim
On 4/27/15, 3:22 AM

I got the same error when using the method trg_validate with the customized button 'signal_draft_depheadapr' :

wf_service.trg_validate(uid, 'purchase.order', id, 'signal_draft_depheadapr', cr)

After trace I discovered that the 'id' parameter is an object one and not an integer id, I replace the above line with the following line and it worked:

wf_service.trg_validate(uid, 'purchase.order', po_obj.id, 'signal_draft_depheadapr', cr) 

The exact line that caused this problem was the cr.execute method

So check your code, the reason of this was a wrong parameter type you passed.

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

Question tools

0 follower(s)

Stats

Asked: 9/17/13, 9:04 AM
Seen: 1646 times
Last updated: 4/27/15, 3:22 AM