← Back to team overview

openerp-connector-community team mailing list archive

Re: Data passed to event subscribers.

 

On 09/30/2013 08:43 AM, sebastien beau wrote:
Hi, passing a dictionary can be an interestingg feature for us too.
My team is actually working on using job for importing data from csv
file (We use the native OpenERP wizard for importing but we overwrite
the load function in order to create one job per line. So if one line is
incorrect than only one job fail). I did a first prototype yesterday and
it's look promising ;)

If possible it will be great if we can store this dictionary in a
serialized field on the job instead of keeping it in the function.
Indeed the final aim in my case will be to edit directly the contain of
the line from the job with a json widget and them to requeue the job
when you have fixed the data. What do you think?

See you


Hi,

I think that you are diverging from the topic which is to pass the dictionary of modified values in 'on_record_write' instead of the list of fields. It doesn't concern the jobs at all.

I'm not too fund of the idea of adding a new field in the jobs for doing such a thing. In my sense, your dictionary of values should be an argument of your job function (so pickled within the job function) and not stored in a second field.

Cheers,

--
Guewen Baconnier
Business Solutions Software Developer

Camptocamp SA
PSE A, CH-1015 Lausanne
Phone: +41 21 619 10 39
Office: +41 21 619 10 10
http://www.camptocamp.com/


References