diff --git a/disable_odoo_online/README.rst b/disable_odoo_online/README.rst new file mode 100644 index 000000000..98614f6a2 --- /dev/null +++ b/disable_odoo_online/README.rst @@ -0,0 +1,56 @@ +.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 + +======================== +Remove odoo.com Bindings +======================== + +This module deactivates all bindings to odoo.com that come with the standard +code: + +* update notifier code is deactivated and the function is overwritten +* apps and updates menu items in settings are hidden inside Tools\\Parameters +* upload thread is deactivated + +Usage +===== + +.. 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 + + +Bug Tracker +=========== + +Bugs are tracked on `GitHub Issues +`_. In case of trouble, please +check there if your issue has already been reported. If you spotted it first, +help us smashing it by providing a detailed and welcomed feedback. + +Credits +======= + +Contributors +------------ + +* Holger Brunn +* Stefan Rijnhart +* Sylvain LE GAL (https://twitter.com/legalsylvain) + +Maintainer +---------- + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +This module is maintained by the OCA. + +OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use. + +To contribute to this module, please visit https://odoo-community.org. + diff --git a/disable_odoo_online/__init__.py b/disable_odoo_online/__init__.py index 991a0f0b3..47e936c0c 100644 --- a/disable_odoo_online/__init__.py +++ b/disable_odoo_online/__init__.py @@ -1,24 +1,8 @@ # -*- coding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# This module copyright (C) 2013 Therp BV (). -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## -from . import model +# Copyright (C) 2013 Therp BV (). +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). -from openerp.tools.misc import upload_data_thread +from . import models + +from odoo.tools.misc import upload_data_thread upload_data_thread.run = lambda x: None diff --git a/disable_odoo_online/__manifest__.py b/disable_odoo_online/__manifest__.py index 484c79cb5..0fbc68acb 100644 --- a/disable_odoo_online/__manifest__.py +++ b/disable_odoo_online/__manifest__.py @@ -1,51 +1,22 @@ # -*- coding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# This module copyright (C) 2013 Therp BV (). -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## +# Copyright (C) 2013 Therp BV (). +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). { - "name": "Remove odoo.com bindings", - "version": "9.0.1.0.0", - "author": "Therp BV,Odoo Community Association (OCA)", + "name": "Remove odoo.com Bindings", + "version": "10.0.1.0.0", + "author": "Therp BV,GRAP,Odoo Community Association (OCA)", "license": "AGPL-3", - "complexity": "normal", - "description": """ -This module deactivates all bindings to openerp.com that -come with the standard code: - -* update notifier code is deactivated and the function is overwritten -* apps and updates menu items in settings are hidden inside Tools\\Parameters -* help and account menu items in user menu are removed -* prevent lookup of OPW for current database uuid and resulting - 'unsupported' warning - """, - "category": "", + "category": "base", "depends": [ 'base', 'mail', ], "data": [ - "views/disable_odoo_online.xml", 'views/ir_ui_menu.xml', 'data/ir_cron.xml', ], "qweb": [ 'static/src/xml/base.xml', ], - 'installable': False, + 'installable': True, } diff --git a/disable_odoo_online/data/ir_cron.xml b/disable_odoo_online/data/ir_cron.xml index faa58ff60..2d5aa0d35 100644 --- a/disable_odoo_online/data/ir_cron.xml +++ b/disable_odoo_online/data/ir_cron.xml @@ -1,8 +1,8 @@ - - - - - - - + + + + + + + diff --git a/disable_odoo_online/model/__init__.py b/disable_odoo_online/model/__init__.py deleted file mode 100644 index db35c95db..000000000 --- a/disable_odoo_online/model/__init__.py +++ /dev/null @@ -1,21 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# This module copyright (C) 2013 Therp BV (). -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## -from . import publisher_warranty_contract diff --git a/disable_odoo_online/model/publisher_warranty_contract.py b/disable_odoo_online/model/publisher_warranty_contract.py deleted file mode 100644 index 8830acc91..000000000 --- a/disable_odoo_online/model/publisher_warranty_contract.py +++ /dev/null @@ -1,29 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# This module copyright (C) 2013 Therp BV (). -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## -from openerp import api, models - - -class publisher_warranty_contract(models.AbstractModel): - _inherit = 'publisher_warranty.contract' - - @api.multi - def update_notification(self, cron_mode=True, context=None): - pass diff --git a/disable_odoo_online/models/__init__.py b/disable_odoo_online/models/__init__.py new file mode 100644 index 000000000..9fa3d64ff --- /dev/null +++ b/disable_odoo_online/models/__init__.py @@ -0,0 +1,2 @@ +# -*- coding: utf-8 -*- +from . import publisher_warranty_contract diff --git a/disable_odoo_online/models/publisher_warranty_contract.py b/disable_odoo_online/models/publisher_warranty_contract.py new file mode 100644 index 000000000..2b6c6232f --- /dev/null +++ b/disable_odoo_online/models/publisher_warranty_contract.py @@ -0,0 +1,16 @@ +# -*- coding: utf-8 -*- +# Copyright (C) 2013 Therp BV (). +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). + +from odoo import api, models +from odoo.release import version_info + + +class PublisherWarrantyContract(models.AbstractModel): + _inherit = 'publisher_warranty.contract' + + @api.multi + def update_notification(self, cron_mode=True): + if version_info[5] == 'e': + return super(PublisherWarrantyContract, self).update_notification( + cron_mode=cron_mode) diff --git a/disable_odoo_online/static/src/js/disable_odoo_online.js b/disable_odoo_online/static/src/js/disable_odoo_online.js deleted file mode 100644 index 7cc34d30c..000000000 --- a/disable_odoo_online/static/src/js/disable_odoo_online.js +++ /dev/null @@ -1,9 +0,0 @@ -odoo.define('disable_odoo_online.announcement', function (require) { - "use strict"; - var WebClient = require('web.WebClient'); - WebClient.include({ - show_announcement_bar: function() { - // do nothing here - } - }); -}); diff --git a/disable_odoo_online/views/disable_odoo_online.xml b/disable_odoo_online/views/disable_odoo_online.xml deleted file mode 100644 index 6c9adfabe..000000000 --- a/disable_odoo_online/views/disable_odoo_online.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - diff --git a/disable_odoo_online/views/ir_ui_menu.xml b/disable_odoo_online/views/ir_ui_menu.xml index 3fdb4e9b6..777843285 100644 --- a/disable_odoo_online/views/ir_ui_menu.xml +++ b/disable_odoo_online/views/ir_ui_menu.xml @@ -1,15 +1,13 @@ - - + - - - - + + + + - - - + + + - - +