647556386
2025-10-18 d01658c63cd541fe4ea5cec5c4bd7f23b9408cdb
WMS/WIDESEA_WMSServer/WIDESEA_Core/Utilities/EntityProperties.cs
@@ -85,17 +85,19 @@
                }
                else
                {
                    int length = sugarColumn.Length;
                    if (length == 0) { return (true, null, null); }
                    //判断双字节与单字段
                    else if (length < 8000 &&
                        ((dbType.Substring(0, 1) != "n"
                        && Encoding.UTF8.GetBytes(val.ToCharArray()).Length > length)
                         || val.Length > length)
                         )
                    if (sugarColumn != null)
                    {
                        reslutMsg = $"最多只能【{length}】个字符。";
                        int length = sugarColumn.Length;
                        if (length == 0) { return (true, null, null); }
                        //判断双字节与单字段
                        else if (length < 8000 &&
                            ((dbType.Substring(0, 1) != "n"
                            && Encoding.UTF8.GetBytes(val.ToCharArray()).Length > length)
                             || val.Length > length)
                             )
                        {
                            reslutMsg = $"最多只能【{length}】个字符。";
                        }
                    }
                }
            }