From 0229d83d106030a07d540245c705958620ba2c66 Mon Sep 17 00:00:00 2001 From: svazquezco Date: Thu, 13 Dec 2018 14:00:34 +0100 Subject: [PATCH] [ADD] Added l10n_co_dian_resolution module --- __init__.py | 1 + __manifiest__.py => __manifest__.py | 1 + models/__init__.py | 1 + static/__init__.py | 0 tests/__init__.py | 1 + tests/test_dian_resolution.py | 28 +++++++++++ views/l10n_co_dian_resolution.xml | 75 +++++++++++++++++++++++++++++ 7 files changed, 107 insertions(+) rename __manifiest__.py => __manifest__.py (93%) delete mode 100644 static/__init__.py create mode 100644 tests/test_dian_resolution.py create mode 100644 views/l10n_co_dian_resolution.xml diff --git a/__init__.py b/__init__.py index e69de29..0650744 100644 --- a/__init__.py +++ b/__init__.py @@ -0,0 +1 @@ +from . import models diff --git a/__manifiest__.py b/__manifest__.py similarity index 93% rename from __manifiest__.py rename to __manifest__.py index 162b41a..264c9de 100644 --- a/__manifiest__.py +++ b/__manifest__.py @@ -17,6 +17,7 @@ ], 'data': [ + 'views/l10n_co_dian_resolution.xml', ], 'installable': True diff --git a/models/__init__.py b/models/__init__.py index e69de29..4cdbf55 100644 --- a/models/__init__.py +++ b/models/__init__.py @@ -0,0 +1 @@ +from . import l10n_co_dian_resolution diff --git a/static/__init__.py b/static/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/tests/__init__.py b/tests/__init__.py index e69de29..8bc2970 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -0,0 +1 @@ +from . import test_dian_resolution diff --git a/tests/test_dian_resolution.py b/tests/test_dian_resolution.py new file mode 100644 index 0000000..6ba6f85 --- /dev/null +++ b/tests/test_dian_resolution.py @@ -0,0 +1,28 @@ +from odoo import fields + +from odoo.tests.common import TransactionCase +from odoo.exceptions import UserError + + +class TestL10nCoDianResolution(TransactionCase): + + def setUp(self): + self.dian_resolution = self.env.ref('l10n.co.dian.resolution') + self.resolution_fe = self.dian_resolution.create({ + 'name': 'Resolution FE', + 'document_type': 'fe', + 'technical_key': 'abc123455', + 'prefix': 'PRE', + 'range_from': '1', + 'range_to': '100', + 'next_number': 1, + 'start_date': fields.Date.today(), + 'end_date': fields.Date.today(), + }) + + + + + + + diff --git a/views/l10n_co_dian_resolution.xml b/views/l10n_co_dian_resolution.xml new file mode 100644 index 0000000..4da6aee --- /dev/null +++ b/views/l10n_co_dian_resolution.xml @@ -0,0 +1,75 @@ + + + + + l10n.co.dian.resolution.tree + l10n.co.dian.resolution + + + + + + + + + + + + + + + + + + + + l10n.co.dian.resolution.form + l10n.co.dian.resolution + +
+ + + + + + + + + + + + + + +
+
+
+ + + l10n.co.dian.resolution.search + l10n.co.dian.resolution + + + + + + + + + + + + DIAN - Resolutions + l10n.co.dian.resolution + tree,form + form + + + + + + +