项目中需要在mybatis后台比较字符串
因为mybatis映射文件使用的是ognl表达式,所以不能使用
<if test="type == '0'">
解决:
<test="type=='0'.toString()">或者<test = 'type== "0"'>
即可