Skip to content

Commit

Permalink
fixup! edi: refactor model rules backward compat
Browse files Browse the repository at this point in the history
  • Loading branch information
simahawk committed Aug 21, 2023
1 parent cc66284 commit 61748bb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions edi_oca/migrations/14.0.1.20.0/post-migrate.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ def migrate(cr, version):
for item in res:
kind = "form_btn" if item.pop("form_btn", False) else "custom"
vals = dict(item, name="Default", kind=kind)
model.create(vals)
item.type_id.button_wipe_deprecated_rule_fields()
rec = model.create(vals)
rec.type_id.button_wipe_deprecated_rule_fields()

cr.execute("DROP TABLE exc_type_model_rel_bkp")
_logger.info("edi.exchange.type.rule created")

0 comments on commit 61748bb

Please sign in to comment.