Browse Source

[11.0][MIG] base_tier_validation

pull/52/head
Lois Rilo 7 years ago
committed by Naglis Jonaitis
parent
commit
b665fb7629
No known key found for this signature in database GPG Key ID: 4748835F585390F5
  1. 2
      base_tier_validation/README.rst
  2. 1
      base_tier_validation/__init__.py
  3. 5
      base_tier_validation/__manifest__.py
  4. 1
      base_tier_validation/models/__init__.py
  5. 1
      base_tier_validation/models/tier_definition.py
  6. 1
      base_tier_validation/models/tier_review.py
  7. 3
      base_tier_validation/models/tier_validation.py

2
base_tier_validation/README.rst

@ -27,7 +27,7 @@ To configure this module, you need to:
.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
:alt: Try me on Runbot
:target: https://runbot.odoo-community.org/runbot/149/10.0
:target: https://runbot.odoo-community.org/runbot/250/11.0
Known issues / Roadmap
======================

1
base_tier_validation/__init__.py

@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from . import models

5
base_tier_validation/__manifest__.py

@ -1,12 +1,11 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
{
"name": "Base Tier Validation",
"summary": "Implement a validation process based on tiers.",
"version": "10.0.1.0.0",
"version": "11.0.1.0.0",
"category": "Tools",
"website": "https://github.com/OCA/server-tools",
"website": "https://github.com/OCA/server-ux",
"author": "Eficent, Odoo Community Association (OCA)",
"license": "AGPL-3",
"application": False,

1
base_tier_validation/models/__init__.py

@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from . import tier_definition

1
base_tier_validation/models/tier_definition.py

@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).

1
base_tier_validation/models/tier_review.py

@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).

3
base_tier_validation/models/tier_validation.py

@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
@ -90,7 +89,7 @@ class TierValidation(models.AbstractModel):
def evaluate_tier(self, tier):
try:
res = safe_eval(tier.python_code, globals_dict={'rec': self})
except Exception, error:
except Exception as error:
raise UserError(_(
"Error evaluating tier validation conditions.\n %s") % error)
return res

Loading…
Cancel
Save