Skip to Content
Menu
This question has been flagged
1 Atsakyti
2716 Rodiniai

How do I accept only capitals fields before creating a record?

Portretas
Atmesti
Best Answer

You have to override method create like this:

def create(self, cr, user, vals, context=None): # do something with values of field (in 'vals' dictionary)
return super(your_class, self).create(cr, user, vals, context=context)

Portretas
Atmesti