记录解密后的data的log数据

This commit is contained in:
602090531@qq.com 2022-03-17 10:09:27 +08:00
parent e4fa95fbbc
commit b9361b8eea

View File

@ -1,5 +1,6 @@
package net.lab1024.smartadmin.module.system.royalcanin.good.service; package net.lab1024.smartadmin.module.system.royalcanin.good.service;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.ObjectMapper;
import net.lab1024.smartadmin.common.domain.ResponseDTO; import net.lab1024.smartadmin.common.domain.ResponseDTO;
@ -253,6 +254,10 @@ public class OrderService {
JSONObject jsonObject = JSONObject.parseObject(result); JSONObject jsonObject = JSONObject.parseObject(result);
String afterDecodeResult = AESUtil.decryptLinux(jsonObject.getString("data"), AESUtil.KEY); String afterDecodeResult = AESUtil.decryptLinux(jsonObject.getString("data"), AESUtil.KEY);
com.alibaba.fastjson.JSONArray jsonArray = JSONObject.parseArray(afterDecodeResult); com.alibaba.fastjson.JSONArray jsonArray = JSONObject.parseArray(afterDecodeResult);
//获取的是接收的数据
jsonObject.put("data", jsonArray);
result = JSONObject.toJSONString(jsonObject);
for (int i = 0; i < jsonArray.size();i++){ for (int i = 0; i < jsonArray.size();i++){
JSONObject jsonObjectResult = (JSONObject)jsonArray.get(i); JSONObject jsonObjectResult = (JSONObject)jsonArray.get(i);
OrderEntity orderEntity = ordersDao.findByOrderId(jsonObjectResult.getString("orderNumber")); OrderEntity orderEntity = ordersDao.findByOrderId(jsonObjectResult.getString("orderNumber"));
@ -277,6 +282,7 @@ public class OrderService {
} }
} }
//记录服务响应时间 //记录服务响应时间
addOperatreFullData(url+"orderMaster/query",queryEntity.toString(),result, startTime,elapsedTime,acceptTime); addOperatreFullData(url+"orderMaster/query",queryEntity.toString(),result, startTime,elapsedTime,acceptTime);
@ -338,4 +344,5 @@ public class OrderService {
public int updateOrder(String orderNumber){ public int updateOrder(String orderNumber){
return ordersDao.updateByOrderNumber(orderNumber); return ordersDao.updateByOrderNumber(orderNumber);
} }
} }