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
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
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
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
That's look more simple than expected ! Thank you very much for your fast answer.
I'm happy you solved your problem....;)
Buat akun sekarang untuk menikmati fitur eksklufi dan agar terlibat dengan komunitas kami!
Daftar| Post Terkait | Replies | Tampilan | Aktivitas | |
|---|---|---|---|---|
|
0
Nov 25
|
10 | |||
|
1
Jun 24
|
4208 | |||
|
Domain one2many field?
Diselesaikan
|
5
Jun 23
|
36928 | ||
|
[Solved] Close window on button press
Diselesaikan
|
1
Des 23
|
20600 | ||
|
2
Jun 16
|
4150 |
1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.