Skip to content

Commit

Permalink
[FIX][11.0] web_environment_ribbon (#806)
Browse files Browse the repository at this point in the history
* [FIX] web_environment_ribbon: Fix to show the ribbon to every non-admin user

* [FIX] web_environment_ribbon: Version number
  • Loading branch information
xavierjimenez authored and moylop260 committed Nov 21, 2017
1 parent 2a20770 commit ae45d8f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion web_environment_ribbon/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

{
'name': "Web Environment Ribbon",
'version': '11.0.1.0.0',
'version': '11.0.1.0.1',
'category': 'Web',
'author': 'Francesco OpenCode Apruzzese, '
'Tecnativa, '
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ def _prepare_ribbon_format_vals(self):

@api.model
def _prepare_ribbon_name(self):
name_tmpl = self.env['ir.config_parameter'].get_param('ribbon.name')
name_tmpl = self.env['ir.config_parameter'].sudo().get_param(
'ribbon.name')
vals = self._prepare_ribbon_format_vals()
return name_tmpl.format(**vals)

Expand All @@ -31,7 +32,7 @@ def get_environment_ribbon(self):
name = self._prepare_ribbon_name()
return {
'name': name,
'color': ir_config_model.get_param('ribbon.color'),
'background_color': ir_config_model.get_param(
'color': ir_config_model.sudo().get_param('ribbon.color'),
'background_color': ir_config_model.sudo().get_param(
'ribbon.background.color'),
}

0 comments on commit ae45d8f

Please sign in to comment.