From ff06ca82d01d6c8b315568ea660e26c006a4007f Mon Sep 17 00:00:00 2001 From: "Pedro M. Baeza" Date: Sat, 24 Sep 2016 12:36:25 +0200 Subject: [PATCH] [FIX] mis_builder: Obsolete migration script --- .../migrations/8.0.0.2/pre-migration.py | 42 ------------------- 1 file changed, 42 deletions(-) delete mode 100644 mis_builder/migrations/8.0.0.2/pre-migration.py diff --git a/mis_builder/migrations/8.0.0.2/pre-migration.py b/mis_builder/migrations/8.0.0.2/pre-migration.py deleted file mode 100644 index 8b08c619..00000000 --- a/mis_builder/migrations/8.0.0.2/pre-migration.py +++ /dev/null @@ -1,42 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################## -# -# mis_builder module for Odoo, Management Information System Builder -# Copyright (C) 2014-2015 ACSONE SA/NV () -# -# This file is a part of mis_builder -# -# mis_builder is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License v3 or later -# as published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# mis_builder is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License v3 or later for more details. -# -# You should have received a copy of the GNU Affero General Public License -# v3 or later along with this program. -# If not, see . -# -############################################################################## - - -def migrate(cr, version): - if not version: - return - - cr.execute(""" - ALTER TABLE mis_report_instance - ADD COLUMN root_account INTEGER - """) - cr.execute(""" - UPDATE mis_report_instance - SET root_account = ( - SELECT id FROM account_account - WHERE parent_id IS NULL - AND company_id = mis_report_instance.company_id - LIMIT 1 - ) - """)