|
@@ -68,8 +68,12 @@ public class FieldComparedUtils {
|
|
|
// 获取Field属性值
|
|
|
Object requestField = getRequestMethod.invoke(requestBean);
|
|
|
Object fitField = getFitMethod.invoke(fitBean);
|
|
|
+ /* if(fieldCompared.name().equals("自定义参数列表")){
|
|
|
+ System.out.println("-------requestField------------"+requestField);
|
|
|
+ System.out.println("-------fitField------------"+fitField);
|
|
|
+ }*/
|
|
|
// 返回异常信息
|
|
|
- if (!Objects.equals(requestField, fitField)) {
|
|
|
+ if (!equals(requestField, fitField)) {
|
|
|
// 当累类型为BigDecimal
|
|
|
if(requestField instanceof BigDecimal){
|
|
|
BigDecimal req = (BigDecimal)requestField;
|
|
@@ -140,9 +144,10 @@ public class FieldComparedUtils {
|
|
|
String result = compareBean(userInfo, userInfo2);
|
|
|
System.out.println(result);*/
|
|
|
|
|
|
- String info = "[<a href='https://www.yuexiang.cn/yx/borrow/1712291375973093.do' target=_blank>购车周转贷171230-04</a>]借款入账10,000元。";
|
|
|
- String ss = info.split("target=_blank>")[1].split("</a>")[0];
|
|
|
- System.out.println(ss);
|
|
|
+ Object old = null;
|
|
|
+ Object current = null;
|
|
|
+ System.out.println(equals(old,current));
|
|
|
+ System.out.println(Objects.equals(old, current));
|
|
|
}
|
|
|
|
|
|
public static String getGetMethod(String fieldName){
|
|
@@ -150,6 +155,16 @@ public class FieldComparedUtils {
|
|
|
return "get" + Character.toUpperCase(cha) + fieldName.substring(1);
|
|
|
}
|
|
|
|
|
|
+ public static boolean equals(Object old,Object current){
|
|
|
+ if(old == null || "".equals(old) || "[]".equals(old) || "null".equals(old)){
|
|
|
+ old = "";
|
|
|
+ }
|
|
|
+ if(current == null || "".equals(current) || "[]".equals(current) || "null".equals(current)){
|
|
|
+ current = "";
|
|
|
+ }
|
|
|
+ return old.equals(current);
|
|
|
+ }
|
|
|
+
|
|
|
}
|
|
|
|
|
|
|