Odoo Help

0
0
Avatar

Pinakin Nayi (pna)

--Pinakin Nayi (pna)--
1624
| 2 2 5
Ahmedabad, India
--Pinakin Nayi (pna)--

He has good skills in problem identification and implementation of effective solutions. He is working in Odoo India.

Techno-Functional
Skype: pinakinerp

LinkedIn : https://www.linkedin.com/in/pinakin-nayi-2a33103a/

 

Pinakin Nayi (pna)
On 12/6/18, 7:43 AM

You can update the code something like,

import xmlrpc.client
host='localhost'
port=8069
url = "http://localhost:8069/xmlrpc"
db = 'test_website'
username = 'admin'
password = 'a'
print ("URLL", url)
common = xmlrpc.client.ServerProxy(url +'/common')
uid = common.login(db, username, password)
print ("UIDDD", uid)
models = xmlrpc.client.ServerProxy(url +'/object')
prodid = models.execute_kw(db, uid, password, 'product.template', 'create', [{
    'categ_id': 1,
    'name': 'Yet another thing',
    'uom_id': 1,
    'uom_po_id': 1,
  }])

0
John Ashurst
On 12/6/18, 4:41 AM

Try removing the `create_uid`

I think this is auto created from the `uid` you pass with the db etc.

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

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

1 follower(s)

Stats

Asked: 2/1/18, 4:44 AM
Seen: 781 times
Last updated: 12/6/18, 7:43 AM