Siirry sisältöön
Menu
Sinun on rekisteröidyttävä, jotta voit olla vuorovaikutuksessa yhteisön kanssa.
Tämä kysymys on merkitty
1 Vastaa
3793 Näkymät

for example this :

def attachment_tree_view(self, cr, uid, ids, context):

For what is the self, cr, uid ,ids, context

I don't understand for what those arguments are?

Avatar
Hylkää
Paras vastaus

Hi,

Where self is reffered as this operator.

cr: is the database cursor using that you can access the database operation like (commit, rollback, etc...)

uid: current user id to check the access right

ids: it the collection of list of current object ids

context : It contains the info related to timezone, lang


cr – database cursor uid – current user id ids – list of ids fields_to_export – list of fields context – context arguments, like lang, time zone

Avatar
Hylkää
Aiheeseen liittyviä artikkeleita Vastaukset Näkymät Toimenpide
0
jouluk. 16
3142
1
huhtik. 24
1770
2
kesäk. 25
89782
1
helmik. 19
21320
0
elok. 16
4229