[FIX] core: allow translated sized char fields

in the commit 763fbb1c of #101115
an assert is added for translated sized char fields

It is too strict for some legacy customized fields, we decide to remove it

closes odoo/odoo#116538

X-original-commit: 44f09e927d0f9338a42a3f121377db00cc70f714
Signed-off-by: Raphael Collet <rco@odoo.com>
Signed-off-by: Wang Chong (cwg) <cwg@odoo.com>
This commit is contained in:
Chong Wang (cwg)
2023-03-24 19:21:40 +01:00
parent fb23cc3851
commit f03e84da21
-2
View File
@@ -1847,8 +1847,6 @@ class Char(_String):
super()._setup_attrs(model_class, name)
assert self.size is None or isinstance(self.size, int), \
"Char field %s with non-integer size %r" % (self, self.size)
assert not(self.translate and self.size), \
"Translated field %s cannot have size %r" % (self, self.size)
@property
def column_type(self):