Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-enterprise-base
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
base_platform_enterprise
gic-enterprise-base
Commits
5326b27b
Commit
5326b27b
authored
Dec 16, 2019
by
zhiwj
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加一个重载接口
parent
bf701b47
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
41 additions
and
0 deletions
+41
-0
LogUtils.java
...ad/src/main/java/com/gic/download/utils/log/LogUtils.java
+41
-0
No files found.
gic-enterprise-download/src/main/java/com/gic/download/utils/log/LogUtils.java
View file @
5326b27b
...
...
@@ -66,4 +66,45 @@ public class LogUtils {
}
});
}
/**
* 添加日志
* @Title: createLog
* @Description:
* @author guojuxing
* @param content 操作内容
* @param operationObject 操作对象
* @return void
*/
public
static
void
createLog
(
String
content
,
String
operationObject
,
String
username
,
Integer
enterpriseId
,
String
enterpriseName
)
{
UserDetail
userDetail
=
UserDetailUtils
.
getUserDetail
();
SystemSetLogDTO
logDTO
=
new
SystemSetLogDTO
();
//操作时间
logDTO
.
setCreateTime
(
new
Date
());
//操作人
// logDTO.setUserId(Long.valueOf(userDetail.getUserInfo().getUserId()));
logDTO
.
setUserName
(
username
);
//操作内容
logDTO
.
setContent
(
content
);
//操作模块
// String moduleMenuName = (String) RequestContext.getContext().getRequest().getAttribute("moduleMenuName");
// Integer moduleMenuId = (Integer) RequestContext.getContext().getRequest().getAttribute("moduleMenuId");
// if (moduleMenuId != null) {
// logDTO.setRelationId(Long.valueOf(moduleMenuId));
// } else {
// LOGGER.info("操作模块数据有误");
// }
//操作对象
//账号(手机号)?
logDTO
.
setEnterpriesId
(
Long
.
valueOf
(
enterpriseId
));
logDTO
.
setEnterpriseName
(
enterpriseName
);
ExecutorPoolSingleton
.
getInstance
().
executeTask
(
new
Runnable
()
{
@Override
public
void
run
()
{
LOGGER
.
info
(
"添加日志了,恭喜发财。{}"
,
JSON
.
toJSONString
(
logDTO
));
logApiService
.
saveSystemSetLog
(
logDTO
);
}
});
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment