Mybatis-使用的是ognl表达式

1、 调用类的静态方法 :@class@method(args)
SELECT * FROM USER WHERE mobile_phone = '${@net.ytoec.framework.security.EncryptionDecryption@dSecret(userName)}'

 

2、 调用类的静态字段 : @class@field
r.czmc='${@com.ytoxl.module.datahub.kernel.dataobject.EcSystemLog@THE_AUDIT}'

 

3、 mybatis的if 标签中,test 也是可以调用自定义的方法的
<if test="@org.commons.lang.StringUtils@isNotBlank(province)">andjdo.province=#{province}</if>

 

posted @ 2024-05-24 09:52  Bevis  阅读(13)  评论(0编辑  收藏  举报