From eba830a2e5fbd888ba3f5ade33bbe06188e13d80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Mon, 22 Dec 2008 19:08:29 +0100 Subject: [PATCH] Add ondelete_target CASCADE for payment_lines on invoice for issue694 --- invoice.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/invoice.py b/invoice.py index 0b5a234bc4..609cd6c7d2 100644 --- a/invoice.py +++ b/invoice.py @@ -289,7 +289,7 @@ class Invoice(OSV): relation='account.move.line', string='Lines to Pay') payment_lines = fields.Many2Many('account.move.line', 'invoice_payment_lines_rel', 'invoice', 'line', readonly=True, - string='Payment Lines') + ondelete_target='CASCADE', string='Payment Lines') amount_to_pay_today = fields.Function('get_amount_to_pay', type='numeric', digits="(16, currency_digits)", string='Amount to Pay Today')