Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cust-api
Project
Project
Details
Activity
Releases
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
李伟
cust-api
Commits
65c5c529
Commit
65c5c529
authored
Apr 29, 2025
by
liwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改了bug
parent
62de1974
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
2 deletions
+4
-2
UserUtil.java
src/main/java/org/rcisoft/core/util/UserUtil.java
+3
-1
OpmArticleCommentMessageErrorMapper.xml
...ssageError/mapper/OpmArticleCommentMessageErrorMapper.xml
+1
-1
No files found.
src/main/java/org/rcisoft/core/util/UserUtil.java
View file @
65c5c529
...
@@ -107,8 +107,10 @@ public class UserUtil {
...
@@ -107,8 +107,10 @@ public class UserUtil {
}
else
if
(
redisOneHourCount
==
null
&&
redisTwoHourCount
!=
null
){
}
else
if
(
redisOneHourCount
==
null
&&
redisTwoHourCount
!=
null
){
// 2小时内被自动驳回过
// 2小时内被自动驳回过
if
((
int
)
redisTwoHourCount
>=
twoHourCount
){
if
((
int
)
redisTwoHourCount
>=
twoHourCount
){
// 2小时内被驳回数大于限制数 禁言一天
// 2小时内被驳回数大于限制数 禁言一天
设置过期时间为2天
cyRedisServiceImpl
.
hset
(
"user:forbidSpeech:"
+
date
+
":timeFlag"
,
userId
,
currentTime
+
twoHourTime
*
1000
);
cyRedisServiceImpl
.
hset
(
"user:forbidSpeech:"
+
date
+
":timeFlag"
,
userId
,
currentTime
+
twoHourTime
*
1000
);
// 设置键的过期时间为2天,单位是秒,所以2天等于172800秒
cyRedisServiceImpl
.
expire
(
"user:forbidSpeech:"
+
date
+
":timeFlag"
,
172800L
);
}
else
{
}
else
{
cyRedisServiceImpl
.
set
(
"user:forbidSpeech:"
+
date
+
":oneHourCount:"
+
userId
,
1
,
1
*
60
*
60L
);
cyRedisServiceImpl
.
set
(
"user:forbidSpeech:"
+
date
+
":oneHourCount:"
+
userId
,
1
,
1
*
60
*
60L
);
cyRedisServiceImpl
.
incr
(
"user:forbidSpeech:"
+
date
+
":twoHourCount:"
+
userId
,
1L
);
cyRedisServiceImpl
.
incr
(
"user:forbidSpeech:"
+
date
+
":twoHourCount:"
+
userId
,
1L
);
...
...
src/main/resources/mapper/business/opmArticleCommentMessageError/mapper/OpmArticleCommentMessageErrorMapper.xml
View file @
65c5c529
...
@@ -60,7 +60,7 @@
...
@@ -60,7 +60,7 @@
and oacme.article_id = #{entity.articleId}
and oacme.article_id = #{entity.articleId}
</if>
</if>
<if
test=
"entity.eventType !=null and entity.eventType != '' "
>
<if
test=
"entity.eventType !=null and entity.eventType != '' "
>
and oacme.event
T
ype = #{entity.eventType}
and oacme.event
_t
ype = #{entity.eventType}
</if>
</if>
<if
test=
"entity.content !=null and entity.content != '' "
>
<if
test=
"entity.content !=null and entity.content != '' "
>
and oacme.content like concat('%',#{entity.content},'%')
and oacme.content like concat('%',#{entity.content},'%')
...
...
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