updated condition
This commit is contained in:
parent
d459a19b09
commit
df1bb030dc
|
@ -63,8 +63,8 @@ class ProjectCreateExpense(models.TransientModel):
|
|||
def action_create_project_expense(self):
|
||||
expenses_amt = self.expenses_amt
|
||||
if self.expenses_amt > 0:
|
||||
expenses_amt = self.expense_amount * -1
|
||||
if self.expenses_amt == 0:
|
||||
expenses_amt = expenses_amount * -1
|
||||
if expenses_amt == 0:
|
||||
raise ValidationError(_("Amount shoud not be zero"))
|
||||
analytic = self.env['account.analytic.line'].create({
|
||||
'project_id': False,
|
||||
|
|
Loading…
Reference in New Issue