Community mailing list archives

community@mail.odoo.com

Re: null value in column "notify_email" violates not-null constraint

by
Ronald Wopereis
- 06/24/2015 02:47:05
addendum to my question:
thx, Ron


2015-06-24 8:45 GMT+02:00 Ronald Wopereis <woepwoep@gmail.com>:
I am wondering if my solution is correct?

What if there is another module that i do not know about,
that is installed and - like the mail module - extends res.partner with a non-null field ?

How do i add 'depends' for a module that i don't know about?

I was thinking perhaps i should add 'depends' for res_partner,
but then i get this error

Error

You try to upgrade a module that depends on the module: res_partner.
But this module is not available in your system.

Any insights on this matter of dependencies is truly appreciated.

Thx, Ron 


2015-06-24 7:54 GMT+02:00 Ronald Wopereis <woepwoep@gmail.com>:
Jose thank you very much.
Your tip made me think of 'mail' as the module responsible for initial values.

So i added a line to __openerp__.py saying: cwa_supplier depends on mail module.
Now all is working fine.

Best regards, Ron


2015-06-23 23:44 GMT+02:00 Jose Antonio Morales <jose@vauxoo.com>:

On Tue, Jun 23, 2015 at 4:27 PM, Ronald Wopereis <woepwoep@gmail.com> wrote:
l value in column "notify_email" violates not-null constraint" when uploading res.partner from 

Hello Ronald.

This field is a selection field, it is meant that you need to put the database value of the selection field in this case for the string 'Never' is 'none'[1]. You have an example in the demo data of the mail module[2].

e.g.

<field name="notify_email">none</field>
Best Regards.

--
Jose Morales
Senior Developer
Twitter: @joseamoralesp
Skype: joseamoralesp
Linux-Counter: 564569

_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe