跳至內容
選單
此問題已被標幟

I've got a problem when adding, data to model at database creation. After the database is created I'm trying to change the partner/user data, but sometimes the changes are added to a different database.

dispatch_rpc('db', 'create_database', [master_pwd, db_name, demo_data, lang, pwd, login, country_code, phone])
request.session.authenticate(db_name, login, pwd)
user = request.env['res.users'].search([('login', '=', login)])
user.partner_id.write(vals)

Should I use request differently when searching after authenticate? 

When I didn't use workers it worked.

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
0
5月 20
5
1
11月 23
1879
0
8月 23
1394
1
8月 20
14261
0
2月 22
11933