|
|
|
@ -1,6 +1,7 @@
|
|
|
|
|
package org.dromara.common.encrypt.interceptor;
|
|
|
|
|
|
|
|
|
|
import cn.hutool.core.collection.CollUtil;
|
|
|
|
|
import cn.hutool.core.convert.Convert;
|
|
|
|
|
import cn.hutool.core.util.ObjectUtil;
|
|
|
|
|
import lombok.AllArgsConstructor;
|
|
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
|
@ -75,7 +76,7 @@ public class MybatisDecryptInterceptor implements Interceptor {
|
|
|
|
|
Set<Field> fields = encryptorManager.getFieldCache(sourceObject.getClass());
|
|
|
|
|
try {
|
|
|
|
|
for (Field field : fields) {
|
|
|
|
|
field.set(sourceObject, this.decryptField(String.valueOf(field.get(sourceObject)), field));
|
|
|
|
|
field.set(sourceObject, this.decryptField(Convert.toStr(field.get(sourceObject)), field));
|
|
|
|
|
}
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
log.error("处理解密字段时出错", e);
|
|
|
|
|