Le Thu, 27 Sep 2012 19:45:58 -0700 (PDT),
Miguel Tasende <miguel.tase...@gmail.com> a écrit :

> Hi!
> Maybe this question is too simple....
> 
> I am trying to make a new user with:
> 
> usr_obj = Pool().get('res.user')
> usr_obj.create({'name':'my_name','login';'my_login','password':'my_password')
> 
> I see there are 2 other required fields (in fact password isn't but I
> want to use it): "login_try" and "menu" but they have default
> functions, so in theory they should be assigned automatically...

Hi,

The default values are filled automatically ... by the client. So you
need to fill them. You can do it by yourself or you can call
default_get() on usr_obj, and add those values to the dict you pass to
create.


-- 

Bertrand Chenal

B2CK SPRL
Rue de Rotterdam, 4
4000 Liège
Belgium
Email: bertrand.che...@b2ck.com
Website: http://www.b2ck.com/

-- 
tryton-dev@googlegroups.com mailing list

Reply via email to