Merge pull request #911 from expsa/project_test
Update project_invoice.py
This commit is contained in:
commit
9e9e02d10d
|
|
@ -236,7 +236,7 @@ class ProjectInvoice(models.Model):
|
|||
def action_set_to_draft(self):
|
||||
self.ensure_one()
|
||||
if self.invoice_id.state=='draft':
|
||||
self.invoice_id=False or [(5, 0, 0)]
|
||||
self.invoice_id=False
|
||||
self.state = 'draft'
|
||||
else:
|
||||
raise UserError(_("Kindly The invoice is not in draft state, so it cannot be unlinked."))
|
||||
|
|
|
|||
Loading…
Reference in New Issue