字典类型加上组织字段
This commit is contained in:
@@ -80,7 +80,15 @@ public class LogAspect
|
||||
// 请求的地址
|
||||
String ip = IpUtils.getIpAddr(ServletUtils.getRequest());
|
||||
operLog.setOperIp(ip);
|
||||
operLog.setOperLocation(StrUtil.isNotEmpty(operLog.getOperIp()) ? IpUtil.getLocationSplicing(operLog.getOperIp()) : "");
|
||||
try
|
||||
{
|
||||
operLog.setOperLocation(StrUtil.isNotEmpty(operLog.getOperIp()) ? IpUtil.getLocationSplicing(operLog.getOperIp()) : "");
|
||||
}
|
||||
catch (Throwable t)
|
||||
{
|
||||
log.warn("操作日志 IP 归属解析跳过: {}", t.getMessage());
|
||||
operLog.setOperLocation("");
|
||||
}
|
||||
operLog.setOperUrl(ServletUtils.getRequest().getRequestURI());
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null){
|
||||
|
||||
Reference in New Issue
Block a user