记得上下班打卡 | 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
c0116767
Commit
c0116767
authored
May 07, 2022
by
胡佳晨
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交 名单创建bug
parent
7c952949
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
7 deletions
+8
-7
GoblinListController.java
...ervice/goblin/controller/manage/GoblinListController.java
+2
-2
GoblinListServiceImpl.java
...ice/goblin/service/impl/manage/GoblinListServiceImpl.java
+6
-5
No files found.
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/controller/manage/GoblinListController.java
View file @
c0116767
...
...
@@ -35,12 +35,12 @@ public class GoblinListController {
@ApiOperationSupport
(
order
=
1
)
@ApiOperation
(
value
=
"列表"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"form"
,
required
=
tru
e
,
dataType
=
"String"
,
name
=
"name"
,
value
=
"活动名称"
),
@ApiImplicitParam
(
type
=
"form"
,
required
=
fals
e
,
dataType
=
"String"
,
name
=
"name"
,
value
=
"活动名称"
),
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"Integer"
,
name
=
"page"
,
value
=
"页数"
),
})
@GetMapping
(
"list"
)
public
ResponseDto
<
PageInfo
<
GoblinListVo
>>
list
(
@RequestParam
String
name
,
public
ResponseDto
<
PageInfo
<
GoblinListVo
>>
list
(
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
,
@RequestParam
Integer
page
)
{
return
goblinListService
.
getList
(
name
,
page
);
}
...
...
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/service/impl/manage/GoblinListServiceImpl.java
View file @
c0116767
...
...
@@ -60,6 +60,7 @@ public class GoblinListServiceImpl implements IGoblinListService {
vo
.
setTimeEnd
(
item
.
getTimeEnd
());
vo
.
setSkuCount
(
item
.
getItemVo
().
size
());
vo
.
setHasBlack
(
item
.
getBlackUrl
().
equals
(
""
)
?
0
:
1
);
voList
.
add
(
vo
);
}
pageResult
=
new
PageInfo
(
voList
);
pageResult
.
setTotal
((
Long
)
map
.
get
(
"total"
));
...
...
@@ -127,8 +128,8 @@ public class GoblinListServiceImpl implements IGoblinListService {
}
collectVos
=
redisUtils
.
getGoblinListCollect
(
skuId
);
for
(
GoblinListCollectVo
collectItem
:
collectVos
)
{
if
(
st
.
isAfter
(
collectItem
.
getTimeStart
())
||
st
.
isBefore
(
collectItem
.
getTimeEnd
(
))
||
et
.
isAfter
(
collectItem
.
getTimeStart
())
||
et
.
isBefore
(
collectItem
.
getTimeEnd
(
)))
{
if
(
(
st
.
isAfter
(
collectItem
.
getTimeStart
().
minusSeconds
(
1
))
&&
st
.
isBefore
(
collectItem
.
getTimeEnd
().
plusSeconds
(
1
)
))
||
(
et
.
isAfter
(
collectItem
.
getTimeStart
().
minusSeconds
(
1
))
&&
et
.
isBefore
(
collectItem
.
getTimeEnd
().
plusSeconds
(
1
)
)))
{
return
ResponseDto
.
failure
(
"sku时间不能重合"
);
}
}
...
...
@@ -138,7 +139,7 @@ public class GoblinListServiceImpl implements IGoblinListService {
}
collectVos
=
redisUtils
.
getGoblinListCollect
(
skuId
);
for
(
GoblinListCollectVo
collectItem
:
collectVos
)
{
if
(
st
.
isAfter
(
collectItem
.
getTimeStart
()
)
||
st
.
isBefore
(
collectItem
.
getTimeEnd
(
)))
{
if
(
st
.
isAfter
(
collectItem
.
getTimeStart
()
.
minusSeconds
(
1
))
&&
st
.
isBefore
(
collectItem
.
getTimeEnd
().
plusSeconds
(
1
)))
{
return
ResponseDto
.
failure
(
"sku时间不能重合"
);
}
}
...
...
@@ -192,9 +193,9 @@ public class GoblinListServiceImpl implements IGoblinListService {
collectVos
.
add
(
collectVo
);
redisUtils
.
setGoblinListCollect
(
itemVo
.
getSkuId
(),
collectVos
);
// 白名单
queueUtils
.
sendMsgByRedisXls
(
param
.
getWhiteUrl
(),
""
,
"3"
,
item
.
getSkuId
());
queueUtils
.
sendMsgByRedisXls
(
vo
.
getWhiteUrl
(),
""
,
"3"
,
item
.
getSkuId
());
// 黑名单
queueUtils
.
sendMsgByRedisXls
(
param
.
getBlackUrl
(),
""
,
"4"
,
item
.
getSkuId
());
queueUtils
.
sendMsgByRedisXls
(
vo
.
getBlackUrl
(),
""
,
"4"
,
item
.
getSkuId
());
goblinListDetails
.
add
(
new
Object
[]{
vo
.
getListId
(),
itemVo
.
getSpuId
(),
itemVo
.
getSkuId
(),
now
,
itemVo
.
getSkuStock
(),
itemVo
.
getPriceV
(),
itemVo
.
getProductId
(),
itemVo
.
getPrice
()
});
...
...
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