[CHG] remove server_environment dependency
Moving this behaviour in a new module in server-env repopull/2914/head
parent
dcc804c4d7
commit
195aec52e2
|
@ -15,7 +15,7 @@
|
||||||
"application": False,
|
"application": False,
|
||||||
"installable": True,
|
"installable": True,
|
||||||
"external_dependencies": {"python": [], "bin": []},
|
"external_dependencies": {"python": [], "bin": []},
|
||||||
"depends": ["iap", "server_environment"],
|
"depends": ["iap"],
|
||||||
"data": ["views/iap_account_view.xml"],
|
"data": ["views/iap_account_view.xml"],
|
||||||
"demo": [],
|
"demo": [],
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,19 +6,12 @@ from odoo import api, fields, models
|
||||||
|
|
||||||
|
|
||||||
class IapAccount(models.Model):
|
class IapAccount(models.Model):
|
||||||
_inherit = ["iap.account", "server.env.mixin"]
|
_inherit = "iap.account"
|
||||||
_name = "iap.account"
|
_name = "iap.account"
|
||||||
|
|
||||||
name = fields.Char()
|
name = fields.Char()
|
||||||
provider = fields.Selection([("odoo", "Odoo IAP")], required=True, default="odoo")
|
provider = fields.Selection([("odoo", "Odoo IAP")], required=True, default="odoo")
|
||||||
|
|
||||||
@property
|
|
||||||
def _server_env_fields(self):
|
|
||||||
return {
|
|
||||||
"provider": {},
|
|
||||||
"account_token": {},
|
|
||||||
}
|
|
||||||
|
|
||||||
def _get_service_from_provider(self):
|
def _get_service_from_provider(self):
|
||||||
"""In case that the provider only propose one service you can
|
"""In case that the provider only propose one service you can
|
||||||
return the service_name in you module to simplify the user interface"""
|
return the service_name in you module to simplify the user interface"""
|
||||||
|
|
Loading…
Reference in New Issue