Browse Source

Add ondelete attribute, required for Many2one fields in v9.

12.0-mig-module_prototyper_last
Jairo Llopis 8 years ago
committed by Vladislav Shepilov
parent
commit
c67fb87a4a
  1. 4
      base_multi_image/models/image.py

4
base_multi_image/models/image.py

@ -24,7 +24,9 @@ class Image(models.Model):
owner_id = fields.Integer( owner_id = fields.Integer(
"Owner", "Owner",
required=True)
required=True,
ondelete="cascade", # This Integer is really a split Many2one
)
owner_model = fields.Char( owner_model = fields.Char(
required=True) required=True)
owner_ref_id = fields.Reference( owner_ref_id = fields.Reference(

Loading…
Cancel
Save