diff --git a/.gitignore b/.gitignore old mode 100644 new mode 100755 diff --git a/__init__.py b/__init__.py old mode 100644 new mode 100755 diff --git a/__manifest__.py b/__manifest__.py old mode 100644 new mode 100755 index fc9b069..d55547c --- a/__manifest__.py +++ b/__manifest__.py @@ -22,7 +22,7 @@ 'author': "Suherdy Yacob", 'category': 'Accounting', - 'version': '18.0.1.0.0', + 'version': '19.0.1.0.0', # Dependencies 'depends': [ diff --git a/models/__init__.py b/models/__init__.py old mode 100644 new mode 100755 diff --git a/models/account_move_line.py b/models/account_move_line.py old mode 100644 new mode 100755 diff --git a/models/res_partner.py b/models/res_partner.py old mode 100644 new mode 100755 index 27df832..c4da43b --- a/models/res_partner.py +++ b/models/res_partner.py @@ -15,7 +15,7 @@ class ResPartner(models.Model): 'account.account', company_dependent=True, string='Customer Income Account', - domain="[('account_type', '=', 'income'), ('deprecated', '=', False)]", + domain="[('account_type', '=', 'income'), ('active', '=', True)]", help="This account will be used for revenue entries when selling to this customer. " "If not set, the income account from the product category will be used." ) @@ -24,7 +24,7 @@ class ResPartner(models.Model): 'account.account', company_dependent=True, string='Customer Expense Account (COGS)', - domain="[('account_type', '=', 'expense'), ('deprecated', '=', False)]", + domain="[('account_type', '=', 'expense'), ('active', '=', True)]", help="This account will be used for COGS entries when selling to this customer. " "If not set, the expense account from the product category will be used." ) @@ -49,7 +49,7 @@ class ResPartner(models.Model): return False # Runtime validation: Check if account is still active - if account.deprecated: + if not account.active: _logger.error( "Customer income account %s (ID: %s) for partner %s (ID: %s) is deprecated", account.code, account.id, self.name, self.id @@ -105,7 +105,7 @@ class ResPartner(models.Model): return False # Runtime validation: Check if account is still active - if account.deprecated: + if not account.active: _logger.error( "Customer expense account %s (ID: %s) for partner %s (ID: %s) is deprecated", account.code, account.id, self.name, self.id @@ -158,7 +158,7 @@ class ResPartner(models.Model): ) % account.display_name) # Check if account is deprecated - if account.deprecated: + if not account.active: raise ValidationError(_( "The selected income account '%s' is deprecated and cannot be used. " "Please select an active income account." @@ -189,7 +189,7 @@ class ResPartner(models.Model): ) % account.display_name) # Check if account is deprecated - if account.deprecated: + if not account.active: raise ValidationError(_( "The selected expense account '%s' is deprecated and cannot be used. " "Please select an active expense account." diff --git a/models/stock_move.py b/models/stock_move.py old mode 100644 new mode 100755 diff --git a/tests/__init__.py b/tests/__init__.py old mode 100644 new mode 100755 diff --git a/tests/test_account_validation.py b/tests/test_account_validation.py old mode 100644 new mode 100755 diff --git a/tests/test_audit_trail.py b/tests/test_audit_trail.py old mode 100644 new mode 100755 diff --git a/tests/test_customer_account_fields.py b/tests/test_customer_account_fields.py old mode 100644 new mode 100755 diff --git a/tests/test_error_handling.py b/tests/test_error_handling.py old mode 100644 new mode 100755 diff --git a/tests/test_expense_account_determination.py b/tests/test_expense_account_determination.py old mode 100644 new mode 100755 diff --git a/tests/test_form_view.py b/tests/test_form_view.py old mode 100644 new mode 100755 diff --git a/tests/test_income_account_determination.py b/tests/test_income_account_determination.py old mode 100644 new mode 100755 diff --git a/tests/test_sales_flow_integration.py b/tests/test_sales_flow_integration.py old mode 100644 new mode 100755 diff --git a/views/.gitkeep b/views/.gitkeep old mode 100644 new mode 100755 diff --git a/views/account_move_views.xml b/views/account_move_views.xml old mode 100644 new mode 100755 diff --git a/views/res_partner_views.xml b/views/res_partner_views.xml old mode 100644 new mode 100755