mirror of https://gitee.com/y_project/RuoYi.git
优化Excel匹配数值型.0结尾
parent
5cbb7b9893
commit
1a5af1d8aa
|
@ -428,7 +428,7 @@ public class ExcelUtil<T>
|
|||
if (String.class == fieldType)
|
||||
{
|
||||
String s = Convert.toStr(val);
|
||||
if (StringUtils.endsWith(s, ".0"))
|
||||
if (s.matches("^\\d+\\.0$"))
|
||||
{
|
||||
val = StringUtils.substringBefore(s, ".0");
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue