记得上下班打卡 | git大法好,push需谨慎
Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
liquidnet-bus-v1
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
董敬伟
liquidnet-bus-v1
Commits
109f643b
Commit
109f643b
authored
May 05, 2022
by
胡佳晨
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
上传 黑白名单
parent
daab9038
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
5 deletions
+8
-5
GoblinListServiceImpl.java
...ice/goblin/service/impl/manage/GoblinListServiceImpl.java
+7
-4
sqlmap.properties
...-service-goblin-impl/src/main/resources/sqlmap.properties
+1
-1
No files found.
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/service/impl/manage/GoblinListServiceImpl.java
View file @
109f643b
...
...
@@ -114,16 +114,16 @@ public class GoblinListServiceImpl implements IGoblinListService {
// 黑名单
queueUtils
.
sendMsgByRedisXls
(
param
.
getBlackUrl
(),
null
,
"4"
,
item
.
getSkuId
());
goblinListDetails
.
add
(
new
Object
[]{
vo
.
getListId
(),
itemVo
.
getSpuId
(),
itemVo
.
getSkuId
(),
now
vo
.
getListId
(),
itemVo
.
getSpuId
(),
itemVo
.
getSkuId
(),
now
});
}
vo
.
setItemVo
(
voItemList
);
redisUtils
.
setGoblinListDetailsVo
(
vo
);
mongoUtils
.
insertGoblinListDetailsVo
(
vo
);
goblinList
.
add
(
new
Object
[]{
vo
.
getListId
(),
vo
.
getUid
(),
vo
.
getName
(),
vo
.
getWhiteType
(),
vo
.
getWhiteUrl
(),
vo
.
getAdvanceMin
(),
vo
.
getBlackUrl
(),
now
vo
.
getListId
(),
vo
.
getUid
(),
vo
.
getName
(),
vo
.
getWhiteType
(),
vo
.
getWhiteUrl
(),
vo
.
getAdvanceMin
(),
vo
.
getBlackUrl
(),
now
});
queueUtils
.
sendMsgByRedis
(
MQConst
.
GoblinQueue
.
GOBLIN_
USER_ORDER_OPERA
.
getKey
(),
SqlMapping
.
gets
(
sqls
,
goblinList
,
goblinListDetails
));
queueUtils
.
sendMsgByRedis
(
MQConst
.
GoblinQueue
.
GOBLIN_
STORE_MARKET
.
getKey
(),
SqlMapping
.
gets
(
sqls
,
goblinList
,
goblinListDetails
));
return
ResponseDto
.
success
();
}
...
...
@@ -131,6 +131,7 @@ public class GoblinListServiceImpl implements IGoblinListService {
public
ResponseDto
<
Boolean
>
update
(
GoblinListUpdateParam
param
)
{
String
whiteUrl
=
""
;
String
blackUrl
=
""
;
LocalDateTime
now
=
LocalDateTime
.
now
();
GoblinListDetailsVo
vo
=
redisUtils
.
getGoblinListDetailsVo
(
param
.
getListId
());
if
(
vo
==
null
||
!
vo
.
getUid
().
equals
(
CurrentUtil
.
getCurrentUid
()))
{
return
ResponseDto
.
failure
(
"信息错误"
);
...
...
@@ -148,7 +149,7 @@ public class GoblinListServiceImpl implements IGoblinListService {
vo
.
setWhiteUrl
(
""
);
}
vo
.
setBlackUrl
(
param
.
getBlackUrl
()
==
null
?
""
:
param
.
getBlackUrl
());
for
(
GoblinListDetailsItemVo
item
:
vo
.
getItemVo
())
{
for
(
GoblinListDetailsItemVo
item
:
vo
.
getItemVo
())
{
// 白名单
queueUtils
.
sendMsgByRedisXls
(
param
.
getWhiteUrl
(),
whiteUrl
,
"3"
,
item
.
getSkuId
());
// 黑名单
...
...
@@ -157,6 +158,8 @@ public class GoblinListServiceImpl implements IGoblinListService {
redisUtils
.
setGoblinListDetailsVo
(
vo
);
mongoUtils
.
changeGoblinListDetailsVo
(
param
.
getListId
(),
vo
);
//todo sql入库
queueUtils
.
sendMsgByRedis
(
MQConst
.
GoblinQueue
.
GOBLIN_STORE_MARKET
.
getKey
(),
SqlMapping
.
get
(
"goblin_list_update"
,
param
.
getWhiteUrl
(),
param
.
getWhiteType
(),
param
.
getBlackUrl
(),
now
,
param
.
getListId
()));
return
ResponseDto
.
success
();
}
}
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/resources/sqlmap.properties
View file @
109f643b
...
...
@@ -149,4 +149,4 @@ adam_user_busi_acct.add=INSERT INTO adam_user_busi_acct (`uid`, busi, uuid, `wor
#---- 黑白名单 ----
goblin_list_insert
=
"INSERT INTO goblin_list (`list_id`,`uid`,`name`,`white_type`,`white_url`,`advance_min``,`black_url`,`created_at`) VALUES (?,?,?,?,?,?,?,?)"
goblin_list_detail_insert
=
"INSERT INTO goblin_list_details (`list_id`,`spu_id`,`sku_id`,`created_at`) VALUES (?,?,?,?)"
goblin_list_update
=
""
\ No newline at end of file
goblin_list_update
=
"UPDATE goblin_list SET white_url = ? ,white_type = ? , black_url = ? , updated_at = ? WHERE list_id = ?"
\ No newline at end of file
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