|
@@ -4,6 +4,8 @@ package com.hrsk.cloud.eg.domain.api.func;
|
|
|
import com.alibaba.fastjson2.JSON;
|
|
|
import com.alibaba.fastjson2.JSONObject;
|
|
|
import com.hrsk.cloud.eg.domain.api.FunctionParam;
|
|
|
+import com.hrsk.cloud.eg.domain.api.common.DataVoStatusEnum;
|
|
|
+import com.hrsk.cloud.eg.domain.api.common.ThreeplatfromResultCodeEnum;
|
|
|
|
|
|
import java.security.MessageDigest;
|
|
|
import java.util.List;
|
|
@@ -49,22 +51,22 @@ public class EncryptionFunction {
|
|
|
return null;
|
|
|
}
|
|
|
}
|
|
|
- public static String outPrint(FunctionParam input) {
|
|
|
- JSONObject.toJSONString(input);
|
|
|
- System.out.println(input.getInput());
|
|
|
- return "";
|
|
|
- }
|
|
|
-
|
|
|
-
|
|
|
|
|
|
- public static String md5Sign(FunctionParam functionParam) {
|
|
|
- functionParam.setInput(JSON.toJSONString(functionParam));
|
|
|
|
|
|
- List<Object> extArg = functionParam.getExtArg();
|
|
|
- StringBuilder builder = new StringBuilder();
|
|
|
- for (Object o : extArg) {
|
|
|
- builder.append(o.toString());
|
|
|
+ /**
|
|
|
+ * @description: 第三方返回值进行配置
|
|
|
+ * @param:
|
|
|
+ * @return: Integer
|
|
|
+ * @author zhangyy
|
|
|
+ * @date: 2024/9/5 14:00
|
|
|
+ */
|
|
|
+ public static Integer resultCodeConvertStatus(FunctionParam functionParam) {
|
|
|
+ String value = functionParam.getInput().toString();
|
|
|
+ Integer result = Integer.valueOf(value);
|
|
|
+ if (ThreeplatfromResultCodeEnum.getList().contains(result)) {
|
|
|
+ return DataVoStatusEnum.SUCCESS.getCode();
|
|
|
+ }else {
|
|
|
+ return DataVoStatusEnum.FAIL.getCode();
|
|
|
}
|
|
|
- return null;
|
|
|
}
|
|
|
}
|