Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
Eladmin
Commits
1c141bfc
Commit
1c141bfc
authored
Aug 11, 2022
by
Zheng Jie
Browse files
Merge branch 'master' of github.com:elunez/eladmin
parents
5cfa96e1
62fab6e7
Changes
2
Hide whitespace changes
Inline
Side-by-side
eladmin-common/src/main/java/me/zhengjie/config/RedisConfig.java
View file @
1c141bfc
...
...
@@ -106,7 +106,7 @@ public class RedisConfig extends CachingConfigurerSupport {
@Override
public
KeyGenerator
keyGenerator
()
{
return
(
target
,
method
,
params
)
->
{
Map
<
String
,
Object
>
container
=
new
HashMap
<>(
4
);
Map
<
String
,
Object
>
container
=
new
HashMap
<>(
8
);
Class
<?>
targetClassClass
=
target
.
getClass
();
// 类地址
container
.
put
(
"class"
,
targetClassClass
.
toGenericString
());
...
...
eladmin-logging/src/main/java/me/zhengjie/service/impl/LogServiceImpl.java
View file @
1c141bfc
...
...
@@ -96,9 +96,9 @@ public class LogServiceImpl implements LogService {
log
.
setUsername
(
username
);
log
.
setParams
(
getParameter
(
method
,
joinPoint
.
getArgs
()));
// 记录登录用户,隐藏密码信息
if
(
log
.
getDescription
().
equals
(
"用户登录"
)){
if
(
signature
.
getName
().
equals
(
"login"
)
&&
StringUtils
.
isNotEmpty
(
log
.
getParams
()
)){
JSONObject
obj
=
JSONUtil
.
parseObj
(
log
.
getParams
());
log
.
setUsername
(
obj
.
get
(
"username"
).
toString
(
));
log
.
setUsername
(
obj
.
get
Str
(
"username"
,
""
));
log
.
setParams
(
JSONUtil
.
toJsonStr
(
Dict
.
create
().
set
(
"username"
,
log
.
getUsername
())));
}
log
.
setBrowser
(
browser
);
...
...
@@ -120,7 +120,7 @@ public class LogServiceImpl implements LogService {
//将RequestParam注解修饰的参数作为请求参数
RequestParam
requestParam
=
parameters
[
i
].
getAnnotation
(
RequestParam
.
class
);
if
(
requestParam
!=
null
)
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>(
4
);
Map
<
String
,
Object
>
map
=
new
HashMap
<>(
2
);
String
key
=
parameters
[
i
].
getName
();
if
(!
StringUtils
.
isEmpty
(
requestParam
.
value
()))
{
key
=
requestParam
.
value
();
...
...
Write
Preview
Supports
Markdown
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