记得上下班打卡 | 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
c8ac7205
Commit
c8ac7205
authored
Dec 03, 2021
by
Tice
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
107921a1
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
143 additions
and
47 deletions
+143
-47
MerchantMongoUtil.java
...ient/admin/zhengzai/merchant/utils/MerchantMongoUtil.java
+61
-10
MerchantRedisUtil.java
...ient/admin/zhengzai/merchant/utils/MerchantRedisUtil.java
+6
-0
MerchantMongoService.java
...uidnet/service/merchant/service/MerchantMongoService.java
+61
-36
MerchantRdmService.java
...iquidnet/service/merchant/service/MerchantRdmService.java
+5
-0
MerchantFieldsServiceImpl.java
...vice/merchant/service/impl/MerchantFieldsServiceImpl.java
+10
-1
No files found.
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/merchant/utils/MerchantMongoUtil.java
View file @
c8ac7205
...
@@ -23,8 +23,10 @@ public class MerchantMongoUtil {
...
@@ -23,8 +23,10 @@ public class MerchantMongoUtil {
private
MongoConverter
mongoConverter
;
private
MongoConverter
mongoConverter
;
// 【场地相关】
public
MerchantFieldsVo
getFieldsVoByFieldId
(
String
fieldId
)
{
public
MerchantFieldsVo
getFieldsVoByFieldId
(
String
fieldId
)
{
return
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"fieldId"
).
is
(
fieldId
)),
MerchantFieldsVo
.
class
,
MerchantFieldsVo
.
class
.
getSimpleName
());
Query
query
=
Query
.
query
(
Criteria
.
where
(
"fieldId"
).
is
(
fieldId
));
return
mongoTemplate
.
findOne
(
query
,
MerchantFieldsVo
.
class
,
MerchantFieldsVo
.
class
.
getSimpleName
());
}
}
public
void
setFieldsVoByFieldId
(
String
fieldId
,
MerchantFieldsVo
vo
)
{
public
void
setFieldsVoByFieldId
(
String
fieldId
,
MerchantFieldsVo
vo
)
{
...
@@ -34,8 +36,10 @@ public class MerchantMongoUtil {
...
@@ -34,8 +36,10 @@ public class MerchantMongoUtil {
mongoTemplate
.
upsert
(
query
,
update
,
MerchantFieldsVo
.
class
,
MerchantFieldsVo
.
class
.
getSimpleName
());
mongoTemplate
.
upsert
(
query
,
update
,
MerchantFieldsVo
.
class
,
MerchantFieldsVo
.
class
.
getSimpleName
());
}
}
// 【主办相关】
public
MerchantSponsorsVo
getSponsorsVoBySponsorId
(
String
sponsorId
)
{
public
MerchantSponsorsVo
getSponsorsVoBySponsorId
(
String
sponsorId
)
{
return
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"sponsorId"
).
is
(
sponsorId
)),
MerchantSponsorsVo
.
class
,
MerchantSponsorsVo
.
class
.
getSimpleName
());
Query
query
=
Query
.
query
(
Criteria
.
where
(
"sponsorId"
).
is
(
sponsorId
));
return
mongoTemplate
.
findOne
(
query
,
MerchantSponsorsVo
.
class
,
MerchantSponsorsVo
.
class
.
getSimpleName
());
}
}
public
void
setSponsorsVoBySponsorId
(
String
sponsorId
,
MerchantSponsorsVo
vo
)
{
public
void
setSponsorsVoBySponsorId
(
String
sponsorId
,
MerchantSponsorsVo
vo
)
{
...
@@ -45,9 +49,56 @@ public class MerchantMongoUtil {
...
@@ -45,9 +49,56 @@ public class MerchantMongoUtil {
mongoTemplate
.
upsert
(
query
,
update
,
MerchantSponsorsVo
.
class
,
MerchantSponsorsVo
.
class
.
getSimpleName
());
mongoTemplate
.
upsert
(
query
,
update
,
MerchantSponsorsVo
.
class
,
MerchantSponsorsVo
.
class
.
getSimpleName
());
}
}
// 【场地申请相关】
public
List
<
MerchantFieldAppliesVo
>
getFieldAppliesVosByUid
(
String
uid
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
MerchantFieldAppliesVo
.
class
,
MerchantFieldAppliesVo
.
class
.
getSimpleName
());
}
public
MerchantFieldAppliesVo
addFieldAppliesVo
(
MerchantFieldAppliesVo
vo
)
{
return
mongoTemplate
.
insert
(
vo
,
MerchantFieldAppliesVo
.
class
.
getSimpleName
());
}
public
void
delFieldAppliesVoByFieldApplyId
(
String
fieldApplyId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"fieldApplyId"
).
is
(
fieldApplyId
));
mongoTemplate
.
remove
(
query
,
MerchantFieldAppliesVo
.
class
.
getSimpleName
());
}
// 【主办申请相关】
public
List
<
MerchantSponsorAppliesVo
>
getSponsorAppliesVosByUid
(
String
uid
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
MerchantSponsorAppliesVo
.
class
,
MerchantSponsorAppliesVo
.
class
.
getSimpleName
());
}
public
MerchantSponsorAppliesVo
addSponsorAppliesVo
(
MerchantSponsorAppliesVo
vo
)
{
return
mongoTemplate
.
insert
(
vo
,
MerchantSponsorAppliesVo
.
class
.
getSimpleName
());
}
public
void
delSponsorAppliesVoBySponsorApplyId
(
String
sponsorApplyId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"sponsorApplyId"
).
is
(
sponsorApplyId
));
mongoTemplate
.
remove
(
query
,
MerchantSponsorAppliesVo
.
class
.
getSimpleName
());
}
// 【默认验票员相关】
public
List
<
MerchantFieldCheckersVo
>
getFieldCheckersVosByFieldId
(
String
fieldId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"fieldId"
).
is
(
fieldId
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
MerchantFieldCheckersVo
.
class
,
MerchantFieldCheckersVo
.
class
.
getSimpleName
());
}
public
MerchantFieldCheckersVo
addFieldCheckersVo
(
MerchantFieldCheckersVo
vo
)
{
return
mongoTemplate
.
insert
(
vo
,
MerchantFieldCheckersVo
.
class
.
getSimpleName
());
}
public
void
delFieldCheckersVoByFieldCheckerId
(
String
fieldCheckerId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"fieldCheckerId"
).
is
(
fieldCheckerId
));
mongoTemplate
.
remove
(
query
,
MerchantFieldCheckersVo
.
class
.
getSimpleName
());
}
// 【权限相关】
public
MerchantAuthorizationPerformanceVo
getAuthorizationPerformanceVo
(
String
performanceId
,
String
uid
)
{
public
MerchantAuthorizationPerformanceVo
getAuthorizationPerformanceVo
(
String
performanceId
,
String
uid
)
{
return
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"performanceId"
).
is
(
performanceId
).
and
(
"uid"
).
is
(
uid
)),
MerchantAuthorizationPerformanceVo
.
class
,
MerchantAuthorizationPerformanceVo
.
class
.
getSimpleName
());
Query
query
=
Query
.
query
(
Criteria
.
where
(
"performanceId"
).
is
(
performanceId
).
and
(
"uid"
).
is
(
uid
));
return
mongoTemplate
.
findOne
(
query
,
MerchantAuthorizationPerformanceVo
.
class
,
MerchantAuthorizationPerformanceVo
.
class
.
getSimpleName
());
}
}
public
MerchantAuthorizationPerformanceVo
getAndSyncAuthorizationPerformanceVo
(
String
performanceId
,
String
uid
)
{
public
MerchantAuthorizationPerformanceVo
getAndSyncAuthorizationPerformanceVo
(
String
performanceId
,
String
uid
)
{
...
@@ -78,15 +129,15 @@ public class MerchantMongoUtil {
...
@@ -78,15 +129,15 @@ public class MerchantMongoUtil {
return
vo
;
return
vo
;
}
}
// 【授权记录相关】
public
List
<
MerchantFieldAppliesVo
>
getFieldAppliesVosByUid
(
String
ui
d
)
{
public
MerchantAuthorizationRecordsVo
getAuthorizationRecordsVoByAuthorizationRecordId
(
String
authorizationRecordI
d
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"
uid"
).
is
(
ui
d
).
and
(
"deletedAt"
).
is
(
null
));
Query
query
=
Query
.
query
(
Criteria
.
where
(
"
authorizationRecordId"
).
is
(
authorizationRecordI
d
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
MerchantFieldAppliesVo
.
class
,
MerchantFieldApplie
sVo
.
class
.
getSimpleName
());
return
mongoTemplate
.
find
One
(
query
,
MerchantAuthorizationRecordsVo
.
class
,
MerchantAuthorizationRecord
sVo
.
class
.
getSimpleName
());
}
}
public
List
<
Merchant
SponsorAppliesVo
>
getSponsorAppliesVosByUid
(
String
ui
d
)
{
public
List
<
Merchant
AuthorizationRecordsVo
>
getAuthorizationRecordsVosByUid
(
String
uid
,
String
performanceI
d
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"deletedAt"
).
is
(
null
));
Query
query
=
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"
performanceId"
).
is
(
performanceId
).
and
(
"
deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
Merchant
SponsorAppliesVo
.
class
,
MerchantSponsorApplie
sVo
.
class
.
getSimpleName
());
return
mongoTemplate
.
find
(
query
,
Merchant
AuthorizationRecordsVo
.
class
,
MerchantAuthorizationRecord
sVo
.
class
.
getSimpleName
());
}
}
public
List
<
MerchantAuthorizationRecordsVo
>
getAuthorizationRecordsCheckersVosByCuid
(
String
cuid
,
String
performanceId
)
{
public
List
<
MerchantAuthorizationRecordsVo
>
getAuthorizationRecordsCheckersVosByCuid
(
String
cuid
,
String
performanceId
)
{
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/merchant/utils/MerchantRedisUtil.java
View file @
c8ac7205
...
@@ -104,6 +104,10 @@ public class MerchantRedisUtil {
...
@@ -104,6 +104,10 @@ public class MerchantRedisUtil {
long
s
=
System
.
currentTimeMillis
();
long
s
=
System
.
currentTimeMillis
();
List
<
MerchantFieldCheckersVo
>
vos
=
(
List
<
MerchantFieldCheckersVo
>)
redisDataSourceUtil
.
getRedisKylinUtil
().
get
(
key
);
List
<
MerchantFieldCheckersVo
>
vos
=
(
List
<
MerchantFieldCheckersVo
>)
redisDataSourceUtil
.
getRedisKylinUtil
().
get
(
key
);
log
.
debug
(
"#RDM耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
log
.
debug
(
"#RDM耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
if
(
null
==
vos
)
{
vos
=
merchantMongoUtil
.
getFieldCheckersVosByFieldId
(
fieldId
);
redisDataSourceUtil
.
getRedisKylinUtil
().
set
(
key
,
vos
);
}
return
vos
;
return
vos
;
}
}
...
@@ -125,6 +129,7 @@ public class MerchantRedisUtil {
...
@@ -125,6 +129,7 @@ public class MerchantRedisUtil {
return
redisDataSourceUtil
.
getRedisKylinUtil
().
set
(
MerchantRedisConst
.
INFO_FIELD_CHECKERS
.
concat
(
fieldId
),
vos
);
return
redisDataSourceUtil
.
getRedisKylinUtil
().
set
(
MerchantRedisConst
.
INFO_FIELD_CHECKERS
.
concat
(
fieldId
),
vos
);
}
}
// 【主办】详情
// 【主办】详情
public
MerchantSponsorsVo
getSponsorsVoBySponsorId
(
String
sponsorId
)
{
public
MerchantSponsorsVo
getSponsorsVoBySponsorId
(
String
sponsorId
)
{
if
(
null
==
sponsorId
||
sponsorId
.
isEmpty
())
{
if
(
null
==
sponsorId
||
sponsorId
.
isEmpty
())
{
...
@@ -146,6 +151,7 @@ public class MerchantRedisUtil {
...
@@ -146,6 +151,7 @@ public class MerchantRedisUtil {
return
redisDataSourceUtil
.
getRedisKylinUtil
().
set
(
MerchantRedisConst
.
INFO_SPONSOR
.
concat
(
sponsorId
),
vo
);
return
redisDataSourceUtil
.
getRedisKylinUtil
().
set
(
MerchantRedisConst
.
INFO_SPONSOR
.
concat
(
sponsorId
),
vo
);
}
}
// 【主办申请】我的列表
// 【主办申请】我的列表
public
List
<
MerchantSponsorAppliesVo
>
getSponsorAppliesVosByUid
(
String
uid
)
{
public
List
<
MerchantSponsorAppliesVo
>
getSponsorAppliesVosByUid
(
String
uid
)
{
if
(
null
==
uid
||
uid
.
isEmpty
())
{
if
(
null
==
uid
||
uid
.
isEmpty
())
{
...
...
liquidnet-bus-service/liquidnet-service-merchant/liquidnet-service-merchant-impl/src/main/java/com/liquidnet/service/merchant/service/MerchantMongoService.java
View file @
c8ac7205
...
@@ -23,8 +23,10 @@ public class MerchantMongoService {
...
@@ -23,8 +23,10 @@ public class MerchantMongoService {
MongoConverter
mongoConverter
;
MongoConverter
mongoConverter
;
// 【场地相关】
public
MerchantFieldsVo
getFieldsVoByFieldId
(
String
fieldId
)
{
public
MerchantFieldsVo
getFieldsVoByFieldId
(
String
fieldId
)
{
return
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"fieldId"
).
is
(
fieldId
)),
MerchantFieldsVo
.
class
,
MerchantFieldsVo
.
class
.
getSimpleName
());
Query
query
=
Query
.
query
(
Criteria
.
where
(
"fieldId"
).
is
(
fieldId
));
return
mongoTemplate
.
findOne
(
query
,
MerchantFieldsVo
.
class
,
MerchantFieldsVo
.
class
.
getSimpleName
());
}
}
public
void
setFieldsVoByFieldId
(
String
fieldId
,
MerchantFieldsVo
vo
)
{
public
void
setFieldsVoByFieldId
(
String
fieldId
,
MerchantFieldsVo
vo
)
{
...
@@ -34,9 +36,10 @@ public class MerchantMongoService {
...
@@ -34,9 +36,10 @@ public class MerchantMongoService {
mongoTemplate
.
upsert
(
query
,
update
,
MerchantFieldsVo
.
class
,
MerchantFieldsVo
.
class
.
getSimpleName
());
mongoTemplate
.
upsert
(
query
,
update
,
MerchantFieldsVo
.
class
,
MerchantFieldsVo
.
class
.
getSimpleName
());
}
}
// 【主办相关】
public
MerchantSponsorsVo
getSponsorsVoBySponsorId
(
String
sponsorId
)
{
public
MerchantSponsorsVo
getSponsorsVoBySponsorId
(
String
sponsorId
)
{
return
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"sponsorId"
).
is
(
sponsorId
)),
MerchantSponsorsVo
.
class
,
MerchantSponsorsVo
.
class
.
getSimpleName
());
Query
query
=
Query
.
query
(
Criteria
.
where
(
"sponsorId"
).
is
(
sponsorId
));
return
mongoTemplate
.
findOne
(
query
,
MerchantSponsorsVo
.
class
,
MerchantSponsorsVo
.
class
.
getSimpleName
());
}
}
public
void
setSponsorsVoBySponsorId
(
String
sponsorId
,
MerchantSponsorsVo
vo
)
{
public
void
setSponsorsVoBySponsorId
(
String
sponsorId
,
MerchantSponsorsVo
vo
)
{
...
@@ -46,9 +49,56 @@ public class MerchantMongoService {
...
@@ -46,9 +49,56 @@ public class MerchantMongoService {
mongoTemplate
.
upsert
(
query
,
update
,
MerchantSponsorsVo
.
class
,
MerchantSponsorsVo
.
class
.
getSimpleName
());
mongoTemplate
.
upsert
(
query
,
update
,
MerchantSponsorsVo
.
class
,
MerchantSponsorsVo
.
class
.
getSimpleName
());
}
}
// 【场地申请相关】
public
List
<
MerchantFieldAppliesVo
>
getFieldAppliesVosByUid
(
String
uid
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
MerchantFieldAppliesVo
.
class
,
MerchantFieldAppliesVo
.
class
.
getSimpleName
());
}
public
MerchantFieldAppliesVo
addFieldAppliesVo
(
MerchantFieldAppliesVo
vo
)
{
return
mongoTemplate
.
insert
(
vo
,
MerchantFieldAppliesVo
.
class
.
getSimpleName
());
}
public
void
delFieldAppliesVoByFieldApplyId
(
String
fieldApplyId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"fieldApplyId"
).
is
(
fieldApplyId
));
mongoTemplate
.
remove
(
query
,
MerchantFieldAppliesVo
.
class
.
getSimpleName
());
}
// 【主办申请相关】
public
List
<
MerchantSponsorAppliesVo
>
getSponsorAppliesVosByUid
(
String
uid
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
MerchantSponsorAppliesVo
.
class
,
MerchantSponsorAppliesVo
.
class
.
getSimpleName
());
}
public
MerchantSponsorAppliesVo
addSponsorAppliesVo
(
MerchantSponsorAppliesVo
vo
)
{
return
mongoTemplate
.
insert
(
vo
,
MerchantSponsorAppliesVo
.
class
.
getSimpleName
());
}
public
void
delSponsorAppliesVoBySponsorApplyId
(
String
sponsorApplyId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"sponsorApplyId"
).
is
(
sponsorApplyId
));
mongoTemplate
.
remove
(
query
,
MerchantSponsorAppliesVo
.
class
.
getSimpleName
());
}
// 【默认验票员相关】
public
List
<
MerchantFieldCheckersVo
>
getFieldCheckersVosByFieldId
(
String
fieldId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"fieldId"
).
is
(
fieldId
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
MerchantFieldCheckersVo
.
class
,
MerchantFieldCheckersVo
.
class
.
getSimpleName
());
}
public
MerchantFieldCheckersVo
addFieldCheckersVo
(
MerchantFieldCheckersVo
vo
)
{
return
mongoTemplate
.
insert
(
vo
,
MerchantFieldCheckersVo
.
class
.
getSimpleName
());
}
public
void
delFieldCheckersVoByFieldCheckerId
(
String
fieldCheckerId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"fieldCheckerId"
).
is
(
fieldCheckerId
));
mongoTemplate
.
remove
(
query
,
MerchantFieldCheckersVo
.
class
.
getSimpleName
());
}
// 【权限相关】
public
MerchantAuthorizationPerformanceVo
getAuthorizationPerformanceVo
(
String
performanceId
,
String
uid
)
{
public
MerchantAuthorizationPerformanceVo
getAuthorizationPerformanceVo
(
String
performanceId
,
String
uid
)
{
return
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"performanceId"
).
is
(
performanceId
).
and
(
"uid"
).
is
(
uid
)),
MerchantAuthorizationPerformanceVo
.
class
,
MerchantAuthorizationPerformanceVo
.
class
.
getSimpleName
());
Query
query
=
Query
.
query
(
Criteria
.
where
(
"performanceId"
).
is
(
performanceId
).
and
(
"uid"
).
is
(
uid
));
return
mongoTemplate
.
findOne
(
query
,
MerchantAuthorizationPerformanceVo
.
class
,
MerchantAuthorizationPerformanceVo
.
class
.
getSimpleName
());
}
}
public
MerchantAuthorizationPerformanceVo
getAndSyncAuthorizationPerformanceVo
(
String
performanceId
,
String
uid
)
{
public
MerchantAuthorizationPerformanceVo
getAndSyncAuthorizationPerformanceVo
(
String
performanceId
,
String
uid
)
{
...
@@ -79,44 +129,19 @@ public class MerchantMongoService {
...
@@ -79,44 +129,19 @@ public class MerchantMongoService {
return
vo
;
return
vo
;
}
}
// 【授权记录相关】
public
List
<
MerchantFieldAppliesVo
>
getFieldAppliesVosByUid
(
String
uid
)
{
return
mongoTemplate
.
find
(
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"deletedAt"
).
is
(
null
)),
MerchantFieldAppliesVo
.
class
,
MerchantFieldAppliesVo
.
class
.
getSimpleName
());
}
public
MerchantFieldAppliesVo
addFieldAppliesVo
(
MerchantFieldAppliesVo
vo
)
{
return
mongoTemplate
.
insert
(
vo
,
MerchantFieldAppliesVo
.
class
.
getSimpleName
());
}
public
void
delFieldAppliesVoByFieldApplyId
(
String
fieldApplyId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"fieldApplyId"
).
is
(
fieldApplyId
));
mongoTemplate
.
remove
(
query
,
MerchantFieldAppliesVo
.
class
.
getSimpleName
());
}
public
List
<
MerchantSponsorAppliesVo
>
getSponsorAppliesVosByUid
(
String
uid
)
{
return
mongoTemplate
.
find
(
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"deletedAt"
).
is
(
null
)),
MerchantSponsorAppliesVo
.
class
,
MerchantSponsorAppliesVo
.
class
.
getSimpleName
());
}
public
MerchantSponsorAppliesVo
addSponsorAppliesVo
(
MerchantSponsorAppliesVo
vo
)
{
return
mongoTemplate
.
insert
(
vo
,
MerchantSponsorAppliesVo
.
class
.
getSimpleName
());
}
public
void
delSponsorAppliesVoBySponsorApplyId
(
String
sponsorApplyId
)
{
Query
query
=
Query
.
query
(
Criteria
.
where
(
"sponsorApplyId"
).
is
(
sponsorApplyId
));
mongoTemplate
.
remove
(
query
,
MerchantSponsorAppliesVo
.
class
.
getSimpleName
());
}
public
MerchantAuthorizationRecordsVo
getAuthorizationRecordsVoByAuthorizationRecordId
(
String
authorizationRecordId
)
{
public
MerchantAuthorizationRecordsVo
getAuthorizationRecordsVoByAuthorizationRecordId
(
String
authorizationRecordId
)
{
return
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"authorizationRecordId"
).
is
(
authorizationRecordId
).
and
(
"deletedAt"
).
is
(
null
)),
MerchantAuthorizationRecordsVo
.
class
,
MerchantAuthorizationRecordsVo
.
class
.
getSimpleName
());
Query
query
=
Query
.
query
(
Criteria
.
where
(
"authorizationRecordId"
).
is
(
authorizationRecordId
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
findOne
(
query
,
MerchantAuthorizationRecordsVo
.
class
,
MerchantAuthorizationRecordsVo
.
class
.
getSimpleName
());
}
}
public
List
<
MerchantAuthorizationRecordsVo
>
getAuthorizationRecordsVosByUid
(
String
uid
,
String
performanceId
)
{
public
List
<
MerchantAuthorizationRecordsVo
>
getAuthorizationRecordsVosByUid
(
String
uid
,
String
performanceId
)
{
return
mongoTemplate
.
find
(
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"performanceId"
).
is
(
performanceId
).
and
(
"deletedAt"
).
is
(
null
)),
MerchantAuthorizationRecordsVo
.
class
,
MerchantAuthorizationRecordsVo
.
class
.
getSimpleName
());
Query
query
=
Query
.
query
(
Criteria
.
where
(
"uid"
).
is
(
uid
).
and
(
"performanceId"
).
is
(
performanceId
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
MerchantAuthorizationRecordsVo
.
class
,
MerchantAuthorizationRecordsVo
.
class
.
getSimpleName
());
}
}
public
List
<
MerchantAuthorizationRecordsVo
>
getAuthorizationRecordsCheckersVosByCuid
(
String
cuid
,
String
performanceId
)
{
public
List
<
MerchantAuthorizationRecordsVo
>
getAuthorizationRecordsCheckersVosByCuid
(
String
cuid
,
String
performanceId
)
{
return
mongoTemplate
.
find
(
Query
.
query
(
Criteria
.
where
(
"uidRole"
).
is
(
MerchantAuthorizationConst
.
PerformanceRole
.
CHECKER
.
getRole
()).
and
(
"cuid"
).
is
(
cuid
).
and
(
"performanceId"
).
is
(
performanceId
).
and
(
"deletedAt"
).
is
(
null
)),
MerchantAuthorizationRecordsVo
.
class
,
MerchantAuthorizationRecordsVo
.
class
.
getSimpleName
());
Query
query
=
Query
.
query
(
Criteria
.
where
(
"uidRole"
).
is
(
MerchantAuthorizationConst
.
PerformanceRole
.
CHECKER
.
getRole
()).
and
(
"cuid"
).
is
(
cuid
).
and
(
"performanceId"
).
is
(
performanceId
).
and
(
"deletedAt"
).
is
(
null
));
return
mongoTemplate
.
find
(
query
,
MerchantAuthorizationRecordsVo
.
class
,
MerchantAuthorizationRecordsVo
.
class
.
getSimpleName
());
}
}
}
}
liquidnet-bus-service/liquidnet-service-merchant/liquidnet-service-merchant-impl/src/main/java/com/liquidnet/service/merchant/service/MerchantRdmService.java
View file @
c8ac7205
...
@@ -84,6 +84,10 @@ public class MerchantRdmService {
...
@@ -84,6 +84,10 @@ public class MerchantRdmService {
long
s
=
System
.
currentTimeMillis
();
long
s
=
System
.
currentTimeMillis
();
List
<
MerchantFieldCheckersVo
>
vos
=
(
List
<
MerchantFieldCheckersVo
>)
redisUtil
.
get
(
key
);
List
<
MerchantFieldCheckersVo
>
vos
=
(
List
<
MerchantFieldCheckersVo
>)
redisUtil
.
get
(
key
);
log
.
debug
(
"#RDM耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
log
.
debug
(
"#RDM耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
if
(
null
==
vos
)
{
vos
=
merchantMongoService
.
getFieldCheckersVosByFieldId
(
fieldId
);
redisUtil
.
set
(
key
,
vos
);
}
return
vos
;
return
vos
;
}
}
...
@@ -126,6 +130,7 @@ public class MerchantRdmService {
...
@@ -126,6 +130,7 @@ public class MerchantRdmService {
return
redisUtil
.
set
(
MerchantRedisConst
.
INFO_SPONSOR
.
concat
(
sponsorId
),
vo
);
return
redisUtil
.
set
(
MerchantRedisConst
.
INFO_SPONSOR
.
concat
(
sponsorId
),
vo
);
}
}
// 【主办申请】我的列表
// 【主办申请】我的列表
public
List
<
MerchantSponsorAppliesVo
>
getSponsorAppliesVosByUid
(
String
uid
)
{
public
List
<
MerchantSponsorAppliesVo
>
getSponsorAppliesVosByUid
(
String
uid
)
{
if
(
null
==
uid
||
uid
.
isEmpty
())
{
if
(
null
==
uid
||
uid
.
isEmpty
())
{
...
...
liquidnet-bus-service/liquidnet-service-merchant/liquidnet-service-merchant-impl/src/main/java/com/liquidnet/service/merchant/service/impl/MerchantFieldsServiceImpl.java
View file @
c8ac7205
...
@@ -146,7 +146,6 @@ public class MerchantFieldsServiceImpl implements IMerchantFieldsService {
...
@@ -146,7 +146,6 @@ public class MerchantFieldsServiceImpl implements IMerchantFieldsService {
this
.
checkFieldAccount
(
cuid
,
fieldId
);
this
.
checkFieldAccount
(
cuid
,
fieldId
);
List
<
MerchantFieldCheckersVo
>
fieldCheckersVos
=
merchantRdmService
.
getFieldCheckersVosByFieldId
(
fieldId
);
List
<
MerchantFieldCheckersVo
>
fieldCheckersVos
=
merchantRdmService
.
getFieldCheckersVosByFieldId
(
fieldId
);
if
(!
CollectionUtil
.
isEmpty
(
fieldCheckersVos
))
{
if
(!
CollectionUtil
.
isEmpty
(
fieldCheckersVos
))
{
for
(
MerchantFieldCheckersVo
checkersVo
:
fieldCheckersVos
)
{
for
(
MerchantFieldCheckersVo
checkersVo
:
fieldCheckersVos
)
{
if
(
null
!=
checkersVo
.
getMobile
()
&&
checkersVo
.
getMobile
().
length
()
>
4
)
{
if
(
null
!=
checkersVo
.
getMobile
()
&&
checkersVo
.
getMobile
().
length
()
>
4
)
{
...
@@ -194,6 +193,11 @@ public class MerchantFieldsServiceImpl implements IMerchantFieldsService {
...
@@ -194,6 +193,11 @@ public class MerchantFieldsServiceImpl implements IMerchantFieldsService {
merchantRdmService
.
addFieldCheckersVoByFieldId
(
fieldId
,
fieldCheckersVos
,
fieldCheckersVo
);
merchantRdmService
.
addFieldCheckersVoByFieldId
(
fieldId
,
fieldCheckersVos
,
fieldCheckersVo
);
log
.
debug
(
"#RDS耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
log
.
debug
(
"#RDS耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
// 场地默认验票员 mongo
s
=
System
.
currentTimeMillis
();
merchantMongoService
.
addFieldCheckersVo
(
fieldCheckersVo
);
log
.
debug
(
"#MONGO耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
// 场地默认验票员 sql
// 场地默认验票员 sql
LinkedList
<
String
>
toMqSqls
=
CollectionUtil
.
linkedListString
();
LinkedList
<
String
>
toMqSqls
=
CollectionUtil
.
linkedListString
();
LinkedList
<
Object
[]>
fieldCheckerInsertObjs
=
CollectionUtil
.
linkedListObjectArr
();
LinkedList
<
Object
[]>
fieldCheckerInsertObjs
=
CollectionUtil
.
linkedListObjectArr
();
...
@@ -245,6 +249,11 @@ public class MerchantFieldsServiceImpl implements IMerchantFieldsService {
...
@@ -245,6 +249,11 @@ public class MerchantFieldsServiceImpl implements IMerchantFieldsService {
merchantRdmService
.
delFieldCheckersVoByFieldId
(
fieldId
,
fieldCheckersVos
,
fieldCheckersVo
);
merchantRdmService
.
delFieldCheckersVoByFieldId
(
fieldId
,
fieldCheckersVos
,
fieldCheckersVo
);
log
.
debug
(
"#RDS耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
log
.
debug
(
"#RDS耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
// 场地默认验票员 mongo
s
=
System
.
currentTimeMillis
();
merchantMongoService
.
delFieldCheckersVoByFieldCheckerId
(
fieldCheckersVo
.
getFieldCheckerId
());
log
.
debug
(
"#MONGO耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
// 场地默认验票员 sql
// 场地默认验票员 sql
LinkedList
<
String
>
toMqSqls
=
CollectionUtil
.
linkedListString
();
LinkedList
<
String
>
toMqSqls
=
CollectionUtil
.
linkedListString
();
LinkedList
<
Object
[]>
fieldCheckerUpdateObjs
=
CollectionUtil
.
linkedListObjectArr
();
LinkedList
<
Object
[]>
fieldCheckerUpdateObjs
=
CollectionUtil
.
linkedListObjectArr
();
...
...
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