diff --git a/CHANGELOG b/CHANGELOG index 307ad212db..9114870cf8 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,4 @@ +* Replace sha widget by password * Add Len to PYSON * Use a pool of connection * Manage client actions from button and wizard diff --git a/tryton/common/domain_parser.py b/tryton/common/domain_parser.py index bc9be0aa57..3b664c0676 100644 --- a/tryton/common/domain_parser.py +++ b/tryton/common/domain_parser.py @@ -862,7 +862,7 @@ class DomainParser(object): operator = '' formatted_value = format_value(field, value, target) if (operator in OPERATORS and - field['type'] in ('char', 'text', 'sha', 'selection') + field['type'] in ('char', 'text', 'selection') and value == ''): formatted_value = '""' return '%s: %s%s' % (quote(field['string']), operator, diff --git a/tryton/gui/window/view_form/model/field.py b/tryton/gui/window/view_form/model/field.py index c09958b592..dc13e02326 100644 --- a/tryton/gui/window/view_form/model/field.py +++ b/tryton/gui/window/view_form/model/field.py @@ -898,7 +898,6 @@ class DictField(CharField): TYPES = { 'char': CharField, - 'sha': CharField, 'float_time': FloatField, 'integer': IntegerField, 'biginteger': IntegerField, diff --git a/tryton/gui/window/view_form/view/form_gtk/char.py b/tryton/gui/window/view_form/view/form_gtk/char.py index 75c9eefcdf..ae25a916a4 100644 --- a/tryton/gui/window/view_form/view/form_gtk/char.py +++ b/tryton/gui/window/view_form/view/form_gtk/char.py @@ -150,10 +150,10 @@ class Char(WidgetInterface, TranslateMixin): self.widget.set_focus_chain([self.entry]) -class Sha(Char): +class Password(Char): def __init__(self, field_name, model_name, attrs=None): - super(Sha, self).__init__(field_name, model_name, attrs=attrs) + super(Password, self).__init__(field_name, model_name, attrs=attrs) self.entry.props.visibility = False self.visibility_checkbox = gtk.CheckButton() diff --git a/tryton/gui/window/view_form/view/form_gtk/parser.py b/tryton/gui/window/view_form/view/form_gtk/parser.py index 133a62deb4..0f3fc69d63 100644 --- a/tryton/gui/window/view_form/view/form_gtk/parser.py +++ b/tryton/gui/window/view_form/view/form_gtk/parser.py @@ -522,7 +522,7 @@ from calendar import Calendar, DateTime, Time from float import Float from integer import Integer from selection import Selection -from char import Char, Sha +from char import Char, Password from float_time import FloatTime from checkbox import CheckBox from reference import Reference @@ -549,7 +549,7 @@ WIDGETS_TYPE = { 'biginteger': (Integer, 1, False, False), 'selection': (Selection, 1, False, False), 'char': (Char, 1, False, False), - 'sha': (Sha, 1, False, False), + 'password': (Password, 1, False, False), 'float_time': (FloatTime, 1, False, False), 'boolean': (CheckBox, 1, False, False), 'reference': (Reference, 1, False, False),