Skip to content

Commit

Permalink
Add Migration Scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
Weltschmerz-dev committed Aug 21, 2024
1 parent 3306f7d commit 78922f2
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion frepple/__manifest__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
{
"name": "frepple",
"version": "17.0.0.0",
"version": "17.0.0.1",
"category": "Manufacturing",
"summary": "Advanced planning and scheduling",
"author": "frePPLe",
Expand Down
8 changes: 8 additions & 0 deletions frepple/migrations/17.0.0.1/pre-migrate.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
def migrate(cr, version):
if not version:
return

cr.execute("DELETE FROM frepple_quote fq WHERE fq.product_id NOT IN (SELECT id FROM product_product)")
cr.execute("delete from ir_ui_view where arch_db ->> 'en_US' like '%partner_ref_unique%'")
cr.execute("delete from ir_ui_view where arch_db ->> 'en_US' like '%frepple_write_date%'")

0 comments on commit 78922f2

Please sign in to comment.