summaryrefslogtreecommitdiff
path: root/addons/auth_oauth
diff options
context:
space:
mode:
authorYannick Tivisse <yti@odoo.com>2017-08-31 12:18:09 +0200
committerYannick Tivisse <yti@odoo.com>2017-09-01 13:03:18 +0200
commit781a03b2bc33e2fba96ab85ac38696c0691e7629 (patch)
treef9d1f3f60c4c7bbe0da290e8699bb3dd1747dc12 /addons/auth_oauth
parent898224f110932addb0e976a3ca60542cda80de25 (diff)
[IMP] res_config: Update file names, xmlids, class names according to guidelines
Now that we only have one model (res.config.settings). Uniformize everything according to the guidelines.
Diffstat (limited to 'addons/auth_oauth')
-rw-r--r--addons/auth_oauth/__manifest__.py2
-rw-r--r--addons/auth_oauth/models/__init__.py2
-rw-r--r--addons/auth_oauth/models/res_config_settings.py (renamed from addons/auth_oauth/models/base_config_settings.py)6
-rw-r--r--addons/auth_oauth/views/res_config_settings_views.xml (renamed from addons/auth_oauth/views/base_config_settings_views.xml)6
4 files changed, 8 insertions, 8 deletions
diff --git a/addons/auth_oauth/__manifest__.py b/addons/auth_oauth/__manifest__.py
index d6ab043d07e..c78134cb078 100644
--- a/addons/auth_oauth/__manifest__.py
+++ b/addons/auth_oauth/__manifest__.py
@@ -15,7 +15,7 @@ Allow users to login through OAuth2 Provider.
'data/auth_oauth_data.yml',
'views/auth_oauth_views.xml',
'views/res_users_views.xml',
- 'views/base_config_settings_views.xml',
+ 'views/res_config_settings_views.xml',
'views/auth_oauth_templates.xml',
'security/ir.model.access.csv',
],
diff --git a/addons/auth_oauth/models/__init__.py b/addons/auth_oauth/models/__init__.py
index 9b02f6dc910..381d9c868b6 100644
--- a/addons/auth_oauth/models/__init__.py
+++ b/addons/auth_oauth/models/__init__.py
@@ -2,6 +2,6 @@
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from . import auth_oauth
-from . import base_config_settings
+from . import res_config_settings
from . import ir_config_parameter
from . import res_users
diff --git a/addons/auth_oauth/models/base_config_settings.py b/addons/auth_oauth/models/res_config_settings.py
index a7fe6a1b8ec..43de10ebbd6 100644
--- a/addons/auth_oauth/models/base_config_settings.py
+++ b/addons/auth_oauth/models/res_config_settings.py
@@ -8,7 +8,7 @@ from odoo import api, fields, models
_logger = logging.getLogger(__name__)
-class BaseConfigSettings(models.TransientModel):
+class ResConfigSettings(models.TransientModel):
_inherit = 'res.config.settings'
@api.model
@@ -21,7 +21,7 @@ class BaseConfigSettings(models.TransientModel):
@api.model
def get_values(self):
- res = super(BaseConfigSettings, self).get_values()
+ res = super(ResConfigSettings, self).get_values()
google_provider = self.env.ref('auth_oauth.provider_google', False)
res.update(
auth_oauth_google_enabled=google_provider.enabled,
@@ -31,7 +31,7 @@ class BaseConfigSettings(models.TransientModel):
return res
def set_values(self):
- super(BaseConfigSettings, self).set_values()
+ super(ResConfigSettings, self).set_values()
google_provider = self.env.ref('auth_oauth.provider_google', False)
google_provider.write({
'enabled': self.auth_oauth_google_enabled,
diff --git a/addons/auth_oauth/views/base_config_settings_views.xml b/addons/auth_oauth/views/res_config_settings_views.xml
index 3403904e95c..4a86ff110a5 100644
--- a/addons/auth_oauth/views/base_config_settings_views.xml
+++ b/addons/auth_oauth/views/res_config_settings_views.xml
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
- <record id="base_config_settings_view_form_inherit_auth_oauth" model="ir.ui.view">
- <field name="name">base.config.settings.form.inherit.oauth</field>
+ <record id="res_config_settings_view_form" model="ir.ui.view">
+ <field name="name">res.config.settings.view.form.inherit.auth.oauth</field>
<field name="model">res.config.settings</field>
- <field name="inherit_id" ref="base_setup.base_config_settings_view_form"/>
+ <field name="inherit_id" ref="base_setup.res_config_settings_view_form"/>
<field name="arch" type="xml">
<div id="msg_module_auth_oauth" position="replace">
<div class="content-group" attrs="{'invisible': [('module_auth_oauth','=',False)]}">