This commit is contained in:
yumoqing 2026-05-04 12:00:38 +08:00
parent f0eebd7c8a
commit bc62352d96

View File

@ -184,7 +184,8 @@ def get_code_desc(field: dict, desc: dict) -> dict:
def setup_ui_info(field:dict, confidential_fields=[]) ->dict: def setup_ui_info(field:dict, confidential_fields=[]) ->dict:
d = DictObject(**field.copy()) d = DictObject(**field.copy())
if d.length: if d.length:
d.cwidth = d.length if d.length < 18 else 18 length = int(d.length)
d.cwidth = length if length < 18 else 18
if d.cwidth < 4: if d.cwidth < 4:
d.cwidth = 4; d.cwidth = 4;
else: else: