记得上下班打卡 | 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
d5b7dd47
Commit
d5b7dd47
authored
Jun 30, 2025
by
姜秀龙
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
doudou活动 2 期
parent
a9b4b3e0
Changes
8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
39 additions
and
33 deletions
+39
-33
SweetDouDouParam.java
...a/com/liquidnet/service/sweet/param/SweetDouDouParam.java
+7
-6
ISweetDoudouService.java
.../liquidnet/service/sweet/service/ISweetDoudouService.java
+1
-1
SweetDouDouVo.java
...in/java/com/liquidnet/service/sweet/vo/SweetDouDouVo.java
+4
-4
db_20250604_doudou.sql
...rvice/liquidnet-service-sweet/docu/db_20250604_doudou.sql
+8
-0
SweetDoudouController.java
...idnet/service/sweet/controller/SweetDoudouController.java
+1
-1
SweetDoudouServiceImpl.java
...et/service/sweet/service/impl/SweetDoudouServiceImpl.java
+14
-17
RedisDataUtils.java
...ava/com/liquidnet/service/sweet/utils/RedisDataUtils.java
+3
-3
sqlmap.properties
...uidnet-service-sweet/src/main/resources/sqlmap.properties
+1
-1
No files found.
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/param/SweetDouDouParam.java
View file @
d5b7dd47
...
@@ -21,15 +21,16 @@ public class SweetDouDouParam implements Serializable {
...
@@ -21,15 +21,16 @@ public class SweetDouDouParam implements Serializable {
@NotBlank
(
message
=
"phone不能为空"
)
@NotBlank
(
message
=
"phone不能为空"
)
private
String
phone
;
private
String
phone
;
@ApiModelProperty
(
position
=
12
,
required
=
true
,
value
=
"
购买平台"
,
example
=
"大麦
"
)
@ApiModelProperty
(
position
=
12
,
required
=
true
,
value
=
"
3442"
,
example
=
"活动 ID
"
)
@NotBlank
(
message
=
"
platform
不能为空"
)
@NotBlank
(
message
=
"
activeId
不能为空"
)
private
String
platform
;
private
String
activeId
;
@ApiModelProperty
(
position
=
13
,
required
=
true
,
value
=
"
购买订单号"
,
example
=
"23424353477473
"
)
@ApiModelProperty
(
position
=
13
,
required
=
true
,
value
=
"
img"
,
example
=
"图片地址
"
)
@NotBlank
(
message
=
"
orderCodee
不能为空"
)
@NotBlank
(
message
=
"
imgUrl
不能为空"
)
private
String
orderCode
;
private
String
imgUrl
;
@ApiModelProperty
(
position
=
14
,
required
=
true
,
value
=
"想给doudou说的话"
,
example
=
"我爱你啦啦啦"
)
@ApiModelProperty
(
position
=
14
,
required
=
true
,
value
=
"想给doudou说的话"
,
example
=
"我爱你啦啦啦"
)
private
String
mark
;
private
String
mark
;
}
}
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/service/ISweetDoudouService.java
View file @
d5b7dd47
...
@@ -22,7 +22,7 @@ import java.util.List;
...
@@ -22,7 +22,7 @@ import java.util.List;
*/
*/
public
interface
ISweetDoudouService
extends
IService
<
SweetDoudou
>
{
public
interface
ISweetDoudouService
extends
IService
<
SweetDoudou
>
{
ResponseDto
<
SweetDouDouVo
>
info
();
ResponseDto
<
SweetDouDouVo
>
info
(
String
activeId
);
ResponseDto
<
SweetDouDouVo
>
create
(
@Valid
SweetDouDouParam
param
);
ResponseDto
<
SweetDouDouVo
>
create
(
@Valid
SweetDouDouParam
param
);
...
...
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/vo/SweetDouDouVo.java
View file @
d5b7dd47
...
@@ -21,11 +21,11 @@ public class SweetDouDouVo implements Serializable, Cloneable {
...
@@ -21,11 +21,11 @@ public class SweetDouDouVo implements Serializable, Cloneable {
@ApiModelProperty
(
"观演人手机号"
)
@ApiModelProperty
(
"观演人手机号"
)
private
String
phone
;
private
String
phone
;
@ApiModelProperty
(
"
购买平台
"
)
@ApiModelProperty
(
"
图片地址
"
)
private
String
platform
;
private
String
imgUrl
;
@ApiModelProperty
(
"
购买订单号
"
)
@ApiModelProperty
(
"
活动 ID
"
)
private
String
orderCode
;
private
String
activeId
;
@ApiModelProperty
(
"想给doudou说的话"
)
@ApiModelProperty
(
"想给doudou说的话"
)
private
String
mark
;
private
String
mark
;
...
...
liquidnet-bus-service/liquidnet-service-sweet/docu/db_20250604_doudou.sql
View file @
d5b7dd47
...
@@ -20,6 +20,14 @@ CREATE TABLE `sweet_doudou`
...
@@ -20,6 +20,14 @@ CREATE TABLE `sweet_doudou`
COLLATE
utf8mb4_unicode_ci
COLLATE
utf8mb4_unicode_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
'doudou预约签名CD记录表'
;
ROW_FORMAT
=
DYNAMIC
COMMENT
'doudou预约签名CD记录表'
;
alter
table
sweet_doudou
add
active_id
varchar
(
100
)
default
''
not
null
comment
'活动id'
after
order_code
;
alter
table
sweet_doudou
add
img_url
varchar
(
255
)
default
''
not
null
comment
'订单截图 url'
after
active_id
;
-- 20250604 doudou预约签名核验权限表
-- 20250604 doudou预约签名核验权限表
drop
TABLE
if
exists
`sweet_doudou_scope`
;
drop
TABLE
if
exists
`sweet_doudou_scope`
;
CREATE
TABLE
`sweet_doudou_scope`
CREATE
TABLE
`sweet_doudou_scope`
...
...
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/controller/SweetDoudouController.java
View file @
d5b7dd47
...
@@ -46,7 +46,7 @@ public class SweetDoudouController {
...
@@ -46,7 +46,7 @@ public class SweetDoudouController {
@GetMapping
(
""
)
@GetMapping
(
""
)
@ApiOperation
(
"获取用户预约详情"
)
@ApiOperation
(
"获取用户预约详情"
)
public
ResponseDto
<
SweetDouDouVo
>
info
(
@RequestParam
(
value
=
"activeId"
)
String
activeId
)
{
public
ResponseDto
<
SweetDouDouVo
>
info
(
@RequestParam
(
value
=
"activeId"
)
String
activeId
)
{
return
iSweetDoudouService
.
info
();
return
iSweetDoudouService
.
info
(
activeId
);
}
}
@PostMapping
(
""
)
@PostMapping
(
""
)
...
...
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/service/impl/SweetDoudouServiceImpl.java
View file @
d5b7dd47
...
@@ -48,32 +48,32 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
...
@@ -48,32 +48,32 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
QueueUtils
queueUtils
;
QueueUtils
queueUtils
;
@Override
@Override
public
ResponseDto
<
SweetDouDouVo
>
info
()
{
public
ResponseDto
<
SweetDouDouVo
>
info
(
String
activeId
)
{
String
uid
=
CurrentUtil
.
getCurrentUid
();
String
uid
=
CurrentUtil
.
getCurrentUid
();
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
uid
);
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
uid
,
activeId
);
return
ResponseDto
.
success
(
vo
);
return
ResponseDto
.
success
(
vo
);
}
}
@Override
@Override
public
ResponseDto
<
SweetDouDouVo
>
create
(
SweetDouDouParam
param
)
{
public
ResponseDto
<
SweetDouDouVo
>
create
(
SweetDouDouParam
param
)
{
String
uid
=
CurrentUtil
.
getCurrentUid
();
String
uid
=
CurrentUtil
.
getCurrentUid
();
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
uid
);
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
uid
,
param
.
getActiveId
()
);
if
(
null
!=
vo
)
{
if
(
null
!=
vo
)
{
return
ResponseDto
.
failure
(
"您已经预约过啦~"
);
return
ResponseDto
.
failure
(
"您已经预约过啦~"
);
}
}
String
nextSnowId
=
IDGenerator
.
nextSnowId
();
String
nextSnowId
=
IDGenerator
.
nextSnowId
();
String
username
=
param
.
getUsername
();
String
username
=
param
.
getUsername
();
String
phone
=
param
.
getPhone
();
String
phone
=
param
.
getPhone
();
String
platform
=
param
.
getPlatform
();
String
activeId
=
param
.
getActiveId
();
String
orderCode
=
param
.
getOrderCode
();
String
imgUrl
=
param
.
getImgUrl
();
String
mark
=
param
.
getMark
();
String
mark
=
param
.
getMark
();
SweetDouDouVo
entityVo
=
SweetDouDouVo
.
getNew
();
SweetDouDouVo
entityVo
=
SweetDouDouVo
.
getNew
();
entityVo
.
setDoudouId
(
nextSnowId
);
entityVo
.
setDoudouId
(
nextSnowId
);
entityVo
.
setUsername
(
username
);
entityVo
.
setUsername
(
username
);
entityVo
.
setPhone
(
phone
);
entityVo
.
setPhone
(
phone
);
entityVo
.
set
Platform
(
platform
);
entityVo
.
set
ActiveId
(
activeId
);
entityVo
.
set
OrderCode
(
orderCode
);
entityVo
.
set
ImgUrl
(
imgUrl
);
entityVo
.
setMark
(
mark
);
entityVo
.
setMark
(
mark
);
entityVo
.
setUserId
(
uid
);
entityVo
.
setUserId
(
uid
);
entityVo
.
setStatus
(
1
);
entityVo
.
setStatus
(
1
);
...
@@ -83,7 +83,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
...
@@ -83,7 +83,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
LinkedList
<
Object
[]>
sqlsDataA
=
CollectionUtil
.
linkedListObjectArr
();
LinkedList
<
Object
[]>
sqlsDataA
=
CollectionUtil
.
linkedListObjectArr
();
sqls
.
add
(
SqlMapping
.
get
(
"sweet_doudou.insert"
));
sqls
.
add
(
SqlMapping
.
get
(
"sweet_doudou.insert"
));
sqlsDataA
.
add
(
new
Object
[]{
sqlsDataA
.
add
(
new
Object
[]{
nextSnowId
,
uid
,
username
,
phone
,
platform
,
orderCode
,
mark
nextSnowId
,
uid
,
username
,
phone
,
activeId
,
imgUrl
,
mark
});
});
queueUtils
.
sendMsgByRedis
(
MQConst
.
SweetQueue
.
SWEET_ANSWER_INSERT
.
getKey
(),
queueUtils
.
sendMsgByRedis
(
MQConst
.
SweetQueue
.
SWEET_ANSWER_INSERT
.
getKey
(),
SqlMapping
.
gets
(
sqls
,
sqlsDataA
));
SqlMapping
.
gets
(
sqls
,
sqlsDataA
));
...
@@ -100,8 +100,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
...
@@ -100,8 +100,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20003"
));
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20003"
));
}
}
// TODO
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
param
.
getUserId
(),
param
.
getActiveId
());
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
param
.
getUserId
());
if
(
null
==
vo
)
{
if
(
null
==
vo
)
{
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"90091"
));
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"90091"
));
}
}
...
@@ -140,8 +139,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
...
@@ -140,8 +139,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
log
.
info
(
"无权核验, authMoible: {}"
,
param
.
getAuthMobile
());
log
.
info
(
"无权核验, authMoible: {}"
,
param
.
getAuthMobile
());
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20003"
));
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20003"
));
}
}
//TODO
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
param
.
getDoudouId
(),
param
.
getActiveId
());
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
param
.
getUserId
());
if
(
vo
==
null
)
{
if
(
vo
==
null
)
{
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"90091"
));
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"90091"
));
}
}
...
@@ -160,7 +158,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
...
@@ -160,7 +158,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
}
}
for
(
SweetDouDouVo
fileDouDouVo
:
fileSweetDouDouVos
)
{
for
(
SweetDouDouVo
fileDouDouVo
:
fileSweetDouDouVos
)
{
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
fileDouDouVo
.
getUserId
());
SweetDouDouVo
vo
=
redisDataUtils
.
getSweetDouDou
(
fileDouDouVo
.
getUserId
()
,
fileDouDouVo
.
getActiveId
()
);
if
(
vo
!=
null
)
{
if
(
vo
!=
null
)
{
vo
.
setStatus
(
fileDouDouVo
.
getStatus
());
vo
.
setStatus
(
fileDouDouVo
.
getStatus
());
redisDataUtils
.
setSweetDouDou
(
vo
);
redisDataUtils
.
setSweetDouDou
(
vo
);
...
@@ -220,8 +218,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
...
@@ -220,8 +218,7 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
if
(
StringUtil
.
isBlank
(
uid
)){
if
(
StringUtil
.
isBlank
(
uid
)){
douDouActiveVo
.
setStatus
(
0
);
douDouActiveVo
.
setStatus
(
0
);
}
else
{
}
else
{
//TODO 添加活动ID
SweetDouDouVo
sweetDouDou
=
redisDataUtils
.
getSweetDouDou
(
uid
,
doudouActive
.
getActiveId
());
SweetDouDouVo
sweetDouDou
=
redisDataUtils
.
getSweetDouDou
(
uid
);
if
(
sweetDouDou
==
null
)
{
if
(
sweetDouDou
==
null
)
{
douDouActiveVo
.
setStatus
(
0
);
douDouActiveVo
.
setStatus
(
0
);
}
else
{
}
else
{
...
@@ -293,8 +290,8 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
...
@@ -293,8 +290,8 @@ public class SweetDoudouServiceImpl extends ServiceImpl<SweetDoudouMapper, Sweet
vo
.
setUserId
(
getStringValue
(
row
.
getCell
(
1
)));
vo
.
setUserId
(
getStringValue
(
row
.
getCell
(
1
)));
vo
.
setUsername
(
getStringValue
(
row
.
getCell
(
2
)));
vo
.
setUsername
(
getStringValue
(
row
.
getCell
(
2
)));
vo
.
setPhone
(
getStringValue
(
row
.
getCell
(
3
)));
vo
.
setPhone
(
getStringValue
(
row
.
getCell
(
3
)));
vo
.
set
Platform
(
getStringValue
(
row
.
getCell
(
4
)));
vo
.
set
ActiveId
(
getStringValue
(
row
.
getCell
(
4
)));
vo
.
set
OrderCode
(
getStringValue
(
row
.
getCell
(
5
)));
vo
.
set
ImgUrl
(
getStringValue
(
row
.
getCell
(
5
)));
vo
.
setMark
(
getStringValue
(
row
.
getCell
(
6
)));
vo
.
setMark
(
getStringValue
(
row
.
getCell
(
6
)));
String
cell7
=
getStringValue
(
row
.
getCell
(
7
));
String
cell7
=
getStringValue
(
row
.
getCell
(
7
));
vo
.
setStatus
(
cell7
.
equals
(
"1"
)
?
3
:
2
);
vo
.
setStatus
(
cell7
.
equals
(
"1"
)
?
3
:
2
);
...
...
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/utils/RedisDataUtils.java
View file @
d5b7dd47
...
@@ -465,12 +465,12 @@ public class RedisDataUtils {
...
@@ -465,12 +465,12 @@ public class RedisDataUtils {
// doudou
// doudou
public
void
setSweetDouDou
(
SweetDouDouVo
vo
)
{
public
void
setSweetDouDou
(
SweetDouDouVo
vo
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_DOUDOU_USER
.
concat
(
vo
.
getUserId
());
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_DOUDOU_USER
.
concat
(
vo
.
getUserId
())
.
concat
(
":activeId:"
+
vo
.
getActiveId
())
;
redisUtil
.
set
(
redisKey
,
vo
);
redisUtil
.
set
(
redisKey
,
vo
);
}
}
public
SweetDouDouVo
getSweetDouDou
(
String
uid
)
{
public
SweetDouDouVo
getSweetDouDou
(
String
uid
,
String
activeId
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_DOUDOU_USER
.
concat
(
uid
);
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_DOUDOU_USER
.
concat
(
uid
)
.
concat
(
":activeId:"
+
activeId
)
;
return
(
SweetDouDouVo
)
redisUtil
.
get
(
redisKey
);
return
(
SweetDouDouVo
)
redisUtil
.
get
(
redisKey
);
}
}
...
...
liquidnet-bus-service/liquidnet-service-sweet/src/main/resources/sqlmap.properties
View file @
d5b7dd47
This diff is collapsed.
Click to expand it.
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