summaryrefslogtreecommitdiff
path: root/addons
diff options
context:
space:
mode:
authorfwi-odoo <fwi@odoo.com>2016-07-22 13:04:13 +0200
committerThibault Delavallée <tde@openerp.com>2016-08-03 13:42:06 +0200
commit271ba327b461bfbb8a5d097cd5d875b0e29d80c2 (patch)
treef30031f11769f915a12ffe872a37a34c72313761 /addons
parentd8b652d706fcd9b89eb95f70aebb16926d0c5deb (diff)
[MOV][IMP] web_diagram: reorganize files, add license and clean imports
Diffstat (limited to 'addons')
-rw-r--r--addons/web_diagram/__init__.py3
-rw-r--r--addons/web_diagram/__openerp__.py7
-rw-r--r--addons/web_diagram/controllers/__init__.py3
-rw-r--r--addons/web_diagram/controllers/main.py14
-rw-r--r--addons/web_diagram/views/web_diagram_templates.xml (renamed from addons/web_diagram/views/web_diagram.xml)4
5 files changed, 23 insertions, 8 deletions
diff --git a/addons/web_diagram/__init__.py b/addons/web_diagram/__init__.py
index e046e49fbe2..dd15b5c32e5 100644
--- a/addons/web_diagram/__init__.py
+++ b/addons/web_diagram/__init__.py
@@ -1 +1,4 @@
+# -*- coding: utf-8 -*-
+# Part of Odoo. See LICENSE file for full copyright and licensing details.
+
from . import controllers
diff --git a/addons/web_diagram/__openerp__.py b/addons/web_diagram/__openerp__.py
index 111d4731049..537e8785f85 100644
--- a/addons/web_diagram/__openerp__.py
+++ b/addons/web_diagram/__openerp__.py
@@ -1,3 +1,6 @@
+# -*- coding: utf-8 -*-
+# Part of Odoo. See LICENSE file for full copyright and licensing details.
+
{
'name': 'Odoo Web Diagram',
'category': 'Hidden',
@@ -8,8 +11,8 @@ Openerp Web Diagram view.
""",
'version': '2.0',
'depends': ['web'],
- 'data' : [
- 'views/web_diagram.xml',
+ 'data': [
+ 'views/web_diagram_templates.xml',
],
'qweb': [
'static/src/xml/*.xml',
diff --git a/addons/web_diagram/controllers/__init__.py b/addons/web_diagram/controllers/__init__.py
index 12a7e529b67..5d4b25db9c0 100644
--- a/addons/web_diagram/controllers/__init__.py
+++ b/addons/web_diagram/controllers/__init__.py
@@ -1 +1,4 @@
+# -*- coding: utf-8 -*-
+# Part of Odoo. See LICENSE file for full copyright and licensing details.
+
from . import main
diff --git a/addons/web_diagram/controllers/main.py b/addons/web_diagram/controllers/main.py
index 40f5c9a5674..0b661623e3c 100644
--- a/addons/web_diagram/controllers/main.py
+++ b/addons/web_diagram/controllers/main.py
@@ -1,9 +1,15 @@
-import openerp
-from openerp.tools.safe_eval import safe_eval as eval
+# -*- coding: utf-8 -*-
+# Part of Odoo. See LICENSE file for full copyright and licensing details.
-class DiagramView(openerp.http.Controller):
+import odoo
+import odoo.http as http
- @openerp.http.route('/web_diagram/diagram/get_diagram_info', type='json', auth='user')
+from odoo.tools.safe_eval import safe_eval as eval
+
+
+class DiagramView(http.Controller):
+
+ @http.route('/web_diagram/diagram/get_diagram_info', type='json', auth='user')
def get_diagram_info(self, req, id, model, node, connector,
src_node, des_node, label, **kw):
diff --git a/addons/web_diagram/views/web_diagram.xml b/addons/web_diagram/views/web_diagram_templates.xml
index c8606506c53..2b12b218ae6 100644
--- a/addons/web_diagram/views/web_diagram.xml
+++ b/addons/web_diagram/views/web_diagram_templates.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
-<openerp>
+<odoo>
<data>
<template id="assets_backend" name="web_diagram assets" inherit_id="web.assets_backend">
<xpath expr="." position="inside">
@@ -10,4 +10,4 @@
</xpath>
</template>
</data>
-</openerp>
+</odoo>