parent
2a21082477
commit
54f4c8f1cc
|
@ -1404,7 +1404,10 @@ class orm(orm_template):
|
|||
for key,val in res.items():
|
||||
if f._multi:
|
||||
val = val[k]
|
||||
cr.execute("UPDATE \"%s\" SET \"%s\"='%s' where id=%d"% (self._table, k, val, key))
|
||||
if (val<>False) or (type(val)<>bool):
|
||||
cr.execute("UPDATE \"%s\" SET \"%s\"='%s' where id=%d"% (self._table, k, val, key))
|
||||
#else:
|
||||
# cr.execute("UPDATE \"%s\" SET \"%s\"=NULL where id=%d"% (self._table, k, key))
|
||||
|
||||
# and add constraints if needed
|
||||
if isinstance(f, fields.many2one):
|
||||
|
|
|
@ -396,7 +396,7 @@ def email_send_attach(email_from, email_to, subject, body, email_cc=None, email_
|
|||
msg = MIMEMultipart()
|
||||
|
||||
if not ssl:
|
||||
ssl = config['smtp_ssl']
|
||||
ssl = config.get('smtp_ssl', False)
|
||||
|
||||
msg['Subject'] = Header(subject.decode('utf8'), 'utf-8')
|
||||
msg['From'] = email_from
|
||||
|
|
Loading…
Reference in New Issue