From 28e4d3a2864b4267673c123478c36c2dfe03a904 Mon Sep 17 00:00:00 2001 From: "olt@tinyerp.com" <> Date: Wed, 16 May 2012 08:57:27 +0200 Subject: [PATCH] [FIX] account: reports: drop view before replacing them bzr revid: olt@tinyerp.com-20120516065727-ghvzjttnncj8ryj0 --- addons/account/report/account_report.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/account/report/account_report.py b/addons/account/report/account_report.py index 9f81f295d74..fce71545251 100644 --- a/addons/account/report/account_report.py +++ b/addons/account/report/account_report.py @@ -48,6 +48,7 @@ class report_account_receivable(osv.osv): _order = 'name desc' def init(self, cr): + tools.drop_view_if_exists(cr, 'report_account_receivable') cr.execute(""" create or replace view report_account_receivable as ( select @@ -182,6 +183,7 @@ class report_invoice_created(osv.osv): _order = 'create_date' def init(self, cr): + tools.drop_view_if_exists(cr, 'report_invoice_created') cr.execute("""create or replace view report_invoice_created as ( select inv.id as id, inv.name as name, inv.type as type, @@ -283,4 +285,4 @@ class report_account_sales(osv.osv): )""") report_account_sales() -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: