记得上下班打卡 | 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
1ecb29c3
Commit
1ecb29c3
authored
Apr 22, 2022
by
GaoHu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
exit
parent
7b686911
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
31 deletions
+5
-31
GoblinGoodsAnticipateServiceImpl.java
...goblin/service/impl/GoblinGoodsAnticipateServiceImpl.java
+5
-5
GoblinGoodsAnticipateMgServiceImpl.java
...rvice/impl/manage/GoblinGoodsAnticipateMgServiceImpl.java
+0
-10
GoblinRedisUtils.java
...a/com/liquidnet/service/goblin/util/GoblinRedisUtils.java
+0
-16
No files found.
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/service/impl/GoblinGoodsAnticipateServiceImpl.java
View file @
1ecb29c3
...
...
@@ -75,7 +75,6 @@ public class GoblinGoodsAnticipateServiceImpl implements IGoblinGoodsAnticipateS
if
(
sid
!=
null
)
{
Integer
people
=
goblinRedisUtils
.
getHelpSidAddHelp
(
sid
);
if
(
anticipateValueVo
.
getPeopleType
()
>
people
)
{
int
num
=
anticipateValueVo
.
getPeopleType
()
-
people
;
log
.
debug
(
" skuId:{},分享sid:{},预约uid:{},需要助力人数:{},助力人数:{}"
,
skuId
,
sid
,
uid
,
anticipateValueVo
.
getPeopleType
(),
people
);
return
ResponseDto
.
failure
(
"预约失败!"
);
}
...
...
@@ -148,9 +147,9 @@ public class GoblinGoodsAnticipateServiceImpl implements IGoblinGoodsAnticipateS
//查询sku需要助力人数
//Integer skuIdPeople = goblinRedisUtils.getSharePeopleBySkuId(skuId);
String
sI
d
=
IDGenerator
.
nextTimeId2
();
si
d
=
IDGenerator
.
nextTimeId2
();
GoblinGoodsAnticipateShareVo
goblinGoodsAnticipateShareVo
=
GoblinGoodsAnticipateShareVo
.
getNew
();
goblinGoodsAnticipateShareVo
.
setSid
(
s
I
d
);
goblinGoodsAnticipateShareVo
.
setSid
(
s
i
d
);
goblinGoodsAnticipateShareVo
.
setUid
(
uid
);
goblinGoodsAnticipateShareVo
.
setSkuId
(
skuId
);
goblinGoodsAnticipateShareVo
.
setType
(
valueBySkuId
.
getType
());
...
...
@@ -164,7 +163,7 @@ public class GoblinGoodsAnticipateServiceImpl implements IGoblinGoodsAnticipateS
//goblinMongoUtils.setGoblinGoodsAnticipateShareVo(goblinGoodsAnticipateShareVo);
//redis缓存
goblinRedisUtils
.
setShare
(
skuId
,
uid
,
s
I
d
);
goblinRedisUtils
.
setShare
(
skuId
,
uid
,
s
i
d
);
//redis存储用户分享
goblinRedisUtils
.
setShareVo
(
goblinGoodsAnticipateShareVo
);
...
...
@@ -180,7 +179,7 @@ public class GoblinGoodsAnticipateServiceImpl implements IGoblinGoodsAnticipateS
goblinGoodsAnticipateShareVo
.
getCreatedDate
()
});
sendRedis
(
"goblin_goods_anticipate_share"
,
sqlValue
);
return
ResponseDto
.
success
(
s
I
d
);
return
ResponseDto
.
success
(
s
i
d
);
}
}
...
...
@@ -243,6 +242,7 @@ public class GoblinGoodsAnticipateServiceImpl implements IGoblinGoodsAnticipateS
}
return
ResponseDto
.
success
(
true
);
}
log
.
debug
(
"help() false ------> sid:{}"
,
sid
);
return
ResponseDto
.
success
(
false
);
}
...
...
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/service/impl/manage/GoblinGoodsAnticipateMgServiceImpl.java
View file @
1ecb29c3
...
...
@@ -118,16 +118,6 @@ public class GoblinGoodsAnticipateMgServiceImpl implements IGoblinGoodsAnticipat
//redis标识存入该sku处于预约列表
goblinRedisUtils
.
setValue
(
goodsAnticipateValueVo
);
//redis缓存预约条件
/*GoblinGoodsAnticipateHelp goodsAnticipateHelp = GoblinGoodsAnticipateHelp.getNew();
goodsAnticipateHelp.setSkuId(goodsAnticipateValueVo.getSkuId());
goodsAnticipateHelp.setType(type);
goodsAnticipateHelp.setPeople(people);
goodsAnticipateHelp.setAboutStartDate(goodsAnticipateValueVo.getAboutStartDate());
goodsAnticipateHelp.setAboutEndDate(goodsAnticipateValueVo.getAboutEndDate());
goblinRedisUtils.setSharePeopleBySkuId(item.getSkuId(), goodsAnticipateHelp);*/
//保存mysql中间表
LinkedList
<
Object
[]>
sqlValue
=
CollectionUtil
.
linkedListObjectArr
();
sqlValue
.
add
(
new
Object
[]{
...
...
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/util/GoblinRedisUtils.java
View file @
1ecb29c3
...
...
@@ -173,22 +173,6 @@ public class GoblinRedisUtils {
return
(
String
)
redisUtil
.
get
(
key
);
}
/**
* 缓存sku预约助力人数
*/
public
void
setSharePeopleBySkuId
(
String
skuId
,
GoblinGoodsAnticipateHelp
goodsAnticipateHelp
){
String
key
=
GoblinRedisConst
.
ANTICIPATE_SHARE_SKUID_PEOPLE
.
concat
(
skuId
);
redisUtil
.
set
(
key
,
goodsAnticipateHelp
);
}
/**
* 缓存sku预约助力人数
*/
public
GoblinGoodsAnticipateHelp
getSharePeopleBySkuId
(
String
skuId
){
String
key
=
GoblinRedisConst
.
ANTICIPATE_SHARE_SKUID_PEOPLE
.
concat
(
skuId
);
return
(
GoblinGoodsAnticipateHelp
)
redisUtil
.
get
(
key
);
}
/**
* 缓存sku预约助力人数
*/
...
...
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