Unverified Commit 9e16beb4 authored by 若依's avatar 若依 Committed by Gitee

!989 update ruoyi-common/src/main/java/com/ruoyi/common/core/text/Convert.java.

Merge pull request !989 from 程子/N/A
parents 193c256e 6e314dd3
......@@ -541,7 +541,7 @@ public class Convert
/**
* 转换为boolean<br>
* String支持的值为:true、false、yes、ok、no,1,0 如果给定的值为空,或者转换失败,返回默认值<br>
* String支持的值为:true、false、yes、ok、no、1、0、是、否, 如果给定的值为空,或者转换失败,返回默认值<br>
* 转换失败不会报错
*
* @param value 被转换的值
......@@ -570,10 +570,12 @@ public class Convert
case "yes":
case "ok":
case "1":
case "是":
return true;
case "false":
case "no":
case "0":
case "否":
return false;
default:
return defaultValue;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment