Commit 597af8c2 authored by yanzg's avatar yanzg

不记录系统日志

parent 6bc18684
......@@ -87,6 +87,30 @@ public class ArrayHelper {
return list;
}
/**
* 将数组添加到列表中
*
* @param from
* @param <T>
*/
public static final <T extends Object> List<T> mergeList(T[]... from) {
List<T> list = new ArrayList<>();
addList(list, from);
return list;
}
/**
* 将数组添加到列表中
*
* @param from
* @param <T>
*/
public static final <T extends Object> List<T> mergeList(List<T>... from) {
List<T> list = new ArrayList<>();
addList(list, from);
return list;
}
/**
* 将数组添加到列表中
*
......
......@@ -300,37 +300,21 @@ public class BaseRequestAspect {
if (feignClient != null) {
sb.append(feignClient.value());
}
if (classRequests != null) {
for (RequestMapping item : classRequests) {
List<RequestMapping> reqList = ArrayHelper.mergeList(classRequests, requests);
List<PostMapping> postList = ArrayHelper.mergeList(classPosts, posts);
List<GetMapping> getList = ArrayHelper.mergeList(classGets, gets);
for (RequestMapping item : reqList) {
if (item.value() != null && item.value().length > 0) {
sb.append(item.value()[0]);
}
}
if (classPosts != null) {
for (PostMapping item : classPosts) {
for (PostMapping item : postList) {
if (item.value() != null && item.value().length > 0) {
sb.append(item.value()[0]);
}
}
if (classGets != null) {
for (GetMapping item : classGets) {
sb.append(item.value()[0]);
}
}
if (requests != null) {
for (RequestMapping item : requests) {
sb.append(item.value()[0]);
}
}
if (posts != null) {
for (PostMapping item : posts) {
sb.append(item.value()[0]);
}
}
if (gets != null) {
for (GetMapping item : gets) {
for (GetMapping item : getList) {
if (item.value() != null && item.value().length > 0) {
sb.append(item.value()[0]);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment