Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
1 Răspunde
4715 Vizualizări

Hi

I am developing a module that display a lot of pictures. I want to create a thumbnail each time user upload a picture.

How can I trigger automatically a function when the user creates a record (= upload a picture) ?

openerp 6.1

Imagine profil
Abandonează
Cel mai bun răspuns

You must use the super on create function. This is an example how to use it:

def create(self, cr, uid, vals, context=None):
    res = super(YOUR_CLASSE, self).create(cr, uid, vals, context=context)
    YOUR CODE HERE
    return res
Imagine profil
Abandonează
Autor

That's look more simple than expected ! Thank you very much for your fast answer.

I'm happy you solved your problem....;)

Related Posts Răspunsuri Vizualizări Activitate
1
iun. 24
4208
5
iun. 23
35142
1
dec. 23
19096
2
iun. 16
3023
3
ian. 16
4340