[FIX] account: reports: drop view before replacing them
bzr revid: olt@tinyerp.com-20120516065727-ghvzjttnncj8ryj0
This commit is contained in:
parent
5415104047
commit
28e4d3a286
|
@ -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:
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
Loading…
Reference in New Issue