Avoid possible sql injection in bi_view_editor
parent
c16e15ed08
commit
a04ed55922
|
@ -280,9 +280,8 @@ class IrModel(models.Model):
|
||||||
# this sql update is necessary since a write method here would
|
# this sql update is necessary since a write method here would
|
||||||
# be not working (an orm constraint is restricting the modification
|
# be not working (an orm constraint is restricting the modification
|
||||||
# of the state field while updating ir.model)
|
# of the state field while updating ir.model)
|
||||||
q = ("""UPDATE ir_model SET state = 'manual'
|
q = "UPDATE ir_model SET state = 'manual' WHERE id = %s"
|
||||||
WHERE id = """ + str(res.id))
|
self.env.cr.execute(q, (res.id, ))
|
||||||
self.env.cr.execute(q)
|
|
||||||
|
|
||||||
# # update registry
|
# # update registry
|
||||||
if self._context.get('bve'):
|
if self._context.get('bve'):
|
||||||
|
|
Loading…
Reference in New Issue