[FIX] base_gengo: private key password field

Before this commit, the gengo private password was displayed in
plaintext in edit mode. This is due to text fields being rendered as
`textarea` in edit mode, which does not support the "password" type.

This commit fixes the issue by turning this field to `Char`, so that
it is rendered as `input` with type "password" in edit mode.

The loss of multi-line from `textarea` is not a big deal, because
gengo passwords are not that long.

Task-ID 1892058

closes odoo/odoo#32725

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit is contained in:
mgh-odoo
2019-04-16 12:33:45 +00:00
parent 1537b475b0
commit 208287385e
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -7,7 +7,7 @@ from odoo import fields, models
class res_company(models.Model):
_inherit = "res.company"
gengo_private_key = fields.Text(string="Gengo Private Key", copy=False, groups="base.group_system")
gengo_private_key = fields.Char(string="Gengo Private Key", copy=False, groups="base.group_system")
gengo_public_key = fields.Text(string="Gengo Public Key", copy=False, groups="base.group_user")
gengo_comment = fields.Text(string="Comments", groups="base.group_user",
help="This comment will be automatically be enclosed in each an every request sent to Gengo")
@@ -7,7 +7,7 @@ from odoo import api, models, fields
class ResConfigSettings(models.TransientModel):
_inherit = 'res.config.settings'
gengo_private_key = fields.Text(string="Gengo Private Key", related="company_id.gengo_private_key", readonly=False)
gengo_private_key = fields.Char(string="Gengo Private Key", related="company_id.gengo_private_key", readonly=False)
gengo_public_key = fields.Text(string="Gengo Public Key", related="company_id.gengo_public_key", readonly=False)
gengo_comment = fields.Text(string="Comments", related="company_id.gengo_comment",
help="This comment will be automatically be enclosed in each an every request sent to Gengo")