记得上下班打卡 | 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
75cd17ba
Commit
75cd17ba
authored
Aug 15, 2022
by
张国柄
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master' into ajb_dev_xuper_transfer
parents
98112071
407d0f07
Changes
126
Hide whitespace changes
Inline
Side-by-side
Showing
126 changed files
with
8980 additions
and
128 deletions
+8980
-128
GoblinMixSearchDto.java
.../com/liquidnet/service/goblin/dto/GoblinMixSearchDto.java
+29
-0
GoblinGoodsCheckVo.java
...m/liquidnet/service/goblin/dto/vo/GoblinGoodsCheckVo.java
+26
-0
GoblinMixCheckVo.java
...com/liquidnet/service/goblin/dto/vo/GoblinMixCheckVo.java
+25
-0
GoblinNftCheckVo.java
...com/liquidnet/service/goblin/dto/vo/GoblinNftCheckVo.java
+25
-0
IGoblinNftOrderService.java
...uidnet/service/goblin/service/IGoblinNftOrderService.java
+4
-0
IGoblinOrderService.java
...liquidnet/service/goblin/service/IGoblinOrderService.java
+3
-0
IMixOrderService.java
...om/liquidnet/service/goblin/service/IMixOrderService.java
+2
-1
KylinRedisConst.java
...com/liquidnet/service/kylin/constant/KylinRedisConst.java
+4
-0
KylinRecommendActiveParam.java
...et/service/kylin/dto/param/KylinRecommendActiveParam.java
+98
-0
KylinRecommendActiveRelationParam.java
...ce/kylin/dto/param/KylinRecommendActiveRelationParam.java
+67
-0
GoblinGoodsInfoVo.java
...com/liquidnet/service/kylin/dto/vo/GoblinGoodsInfoVo.java
+160
-0
GoblinMixAppDetailsVo.java
...liquidnet/service/kylin/dto/vo/GoblinMixAppDetailsVo.java
+86
-0
GoblinNftGoodsSkuInfoVo.java
...quidnet/service/kylin/dto/vo/GoblinNftGoodsSkuInfoVo.java
+168
-0
KylinRecommendActiveRelationVo.java
.../service/kylin/dto/vo/KylinRecommendActiveRelationVo.java
+100
-0
KylinRecommendActiveVo.java
...iquidnet/service/kylin/dto/vo/KylinRecommendActiveVo.java
+111
-0
IKylinOrderTicketsOrderService.java
...service/kylin/service/IKylinOrderTicketsOrderService.java
+2
-4
IKylinOrderTicketsService.java
...dnet/service/kylin/service/IKylinOrderTicketsService.java
+3
-0
IKylinRecommendActiveService.java
...t/service/kylin/service/IKylinRecommendActiveService.java
+14
-0
IKylinRecommendActiveRelationService.java
...n/service/admin/IKylinRecommendActiveRelationService.java
+16
-0
IKylinRecommendActiveService.java
...ice/kylin/service/admin/IKylinRecommendActiveService.java
+26
-0
SweetConstant.java
...a/com/liquidnet/service/sweet/constant/SweetConstant.java
+15
-7
ISweetManualArtistsFiveService.java
...ce/sweet/service/five/ISweetManualArtistsFiveService.java
+28
-0
ISweetManualFiveService.java
...t/service/sweet/service/five/ISweetManualFiveService.java
+28
-0
ISweetManualNotifyFiveService.java
...ice/sweet/service/five/ISweetManualNotifyFiveService.java
+26
-0
ISweetManualShopFiveService.java
...rvice/sweet/service/five/ISweetManualShopFiveService.java
+27
-0
ISweetManualSortFiveService.java
...rvice/sweet/service/five/ISweetManualSortFiveService.java
+19
-0
ISweetRichtextFiveService.java
...service/sweet/service/five/ISweetRichtextFiveService.java
+21
-0
ISweetUserRelationFiveService.java
...ice/sweet/service/five/ISweetUserRelationFiveService.java
+16
-0
SweetManualShopFiveAllVo.java
.../liquidnet/service/sweet/vo/SweetManualShopFiveAllVo.java
+30
-0
db_liquidnet_admin_structure.sql
...et-client-admin-web/docu/db_liquidnet_admin_structure.sql
+35
-1
LocalAdminController.java
...t/admin/web/controller/zhengzai/LocalAdminController.java
+17
-2
GoblinCommonController.java
...eb/controller/zhengzai/goblin/GoblinCommonController.java
+26
-4
GoblinSelfZhengzaiController.java
...troller/zhengzai/goblin/GoblinSelfZhengzaiController.java
+16
-5
KylinRecommendActiveController.java
...roller/zhengzai/kylin/KylinRecommendActiveController.java
+123
-0
searchSelect.js
...nt-admin-web/src/main/resources/static/js/searchSelect.js
+270
-0
info.html
...c/main/resources/templates/zhengzai/adam/member/info.html
+8
-5
gago.html
...c/main/resources/templates/zhengzai/goblin/gago/gago.html
+1
-1
addNewActivity.html
...templates/zhengzai/store/placingOrder/addNewActivity.html
+117
-15
add.html
...rces/templates/zhengzai/sweet/affiliatedActivity/add.html
+697
-0
edit.html
...ces/templates/zhengzai/sweet/affiliatedActivity/edit.html
+716
-0
list.html
...ces/templates/zhengzai/sweet/affiliatedActivity/list.html
+653
-0
IGoblinCommonService.java
...t/admin/zhengzai/goblin/service/IGoblinCommonService.java
+6
-3
IGoblinZhengzaiMarketService.java
...zhengzai/goblin/service/IGoblinZhengzaiMarketService.java
+7
-0
GoblinCommonServiceImpl.java
...zhengzai/goblin/service/impl/GoblinCommonServiceImpl.java
+41
-5
GoblinZhengzaiMarketServiceImpl.java
.../goblin/service/impl/GoblinZhengzaiMarketServiceImpl.java
+40
-1
GoblinRedisUtils.java
.../client/admin/zhengzai/goblin/utils/GoblinRedisUtils.java
+15
-0
KylinRecommendActiveRelationServiceImpl.java
...service/impl/KylinRecommendActiveRelationServiceImpl.java
+77
-0
KylinRecommendActiveServiceImpl.java
...i/kylin/service/impl/KylinRecommendActiveServiceImpl.java
+225
-0
DataUtils.java
...iquidnet/client/admin/zhengzai/kylin/utils/DataUtils.java
+27
-0
liquidnet-client-admin-web.yml
...us-config/liquidnet-config/liquidnet-client-admin-web.yml
+2
-2
liquidnet-service-kylin.yml
...t-bus-config/liquidnet-config/liquidnet-service-kylin.yml
+1
-0
GoblinMix.java
...n/java/com/liquidnet/service/goblin/entity/GoblinMix.java
+9
-5
GoblinSelfMarketing.java
.../liquidnet/service/goblin/entity/GoblinSelfMarketing.java
+5
-0
GoblinSelfMarketingMapper.xml
...idnet.service.goblin.mapper/GoblinSelfMarketingMapper.xml
+4
-5
KylinRecommendActive.java
.../liquidnet/service/kylin/entity/KylinRecommendActive.java
+96
-0
KylinRecommendActiveRelation.java
...et/service/kylin/entity/KylinRecommendActiveRelation.java
+80
-0
KylinRecommendActiveMapper.java
...dnet/service/kylin/mapper/KylinRecommendActiveMapper.java
+20
-0
KylinRecommendActiveRelationMapper.java
...vice/kylin/mapper/KylinRecommendActiveRelationMapper.java
+16
-0
kylinRecommendActiveMapper.xml
...idnet.service.kylin.mapper/kylinRecommendActiveMapper.xml
+31
-0
SweetManualAppletFiveDto.java
...liquidnet/service/sweet/dto/SweetManualAppletFiveDto.java
+50
-0
SweetManualArtistList2FiveDto.java
...dnet/service/sweet/dto/SweetManualArtistList2FiveDto.java
+23
-0
SweetManualArtistListFiveDto.java
...idnet/service/sweet/dto/SweetManualArtistListFiveDto.java
+51
-0
SweetManualArtistStageListFiveDto.java
.../service/sweet/dto/SweetManualArtistStageListFiveDto.java
+19
-0
SweetManualFiveDto.java
...a/com/liquidnet/service/sweet/dto/SweetManualFiveDto.java
+42
-0
SweetManualArtistsFive.java
...iquidnet/service/sweet/entity/SweetManualArtistsFive.java
+91
-0
SweetManualFive.java
...a/com/liquidnet/service/sweet/entity/SweetManualFive.java
+66
-0
SweetManualNotifyFive.java
...liquidnet/service/sweet/entity/SweetManualNotifyFive.java
+71
-0
SweetManualShopFive.java
...m/liquidnet/service/sweet/entity/SweetManualShopFive.java
+91
-0
SweetManualSortFive.java
...m/liquidnet/service/sweet/entity/SweetManualSortFive.java
+56
-0
SweetRichtextFive.java
...com/liquidnet/service/sweet/entity/SweetRichtextFive.java
+81
-0
SweetUserRelationFive.java
...liquidnet/service/sweet/entity/SweetUserRelationFive.java
+64
-0
SweetManualArtistsFiveMapper.java
...et/service/sweet/mapper/SweetManualArtistsFiveMapper.java
+29
-0
SweetManualFiveMapper.java
...liquidnet/service/sweet/mapper/SweetManualFiveMapper.java
+29
-0
SweetManualNotifyFiveMapper.java
...net/service/sweet/mapper/SweetManualNotifyFiveMapper.java
+17
-0
SweetManualShopFiveMapper.java
...idnet/service/sweet/mapper/SweetManualShopFiveMapper.java
+17
-0
SweetManualSortFiveMapper.java
...idnet/service/sweet/mapper/SweetManualSortFiveMapper.java
+17
-0
SweetRichtextFiveMapper.java
...quidnet/service/sweet/mapper/SweetRichtextFiveMapper.java
+17
-0
SweetUserRelationFiveMapper.java
...net/service/sweet/mapper/SweetUserRelationFiveMapper.java
+17
-0
SweetManualArtistsFiveMapper.xml
...net.service.sweet.mapper/SweetManualArtistsFiveMapper.xml
+73
-0
SweetManualFiveMapper.xml
....liquidnet.service.sweet.mapper/SweetManualFiveMapper.xml
+187
-0
SweetManualNotifyFiveMapper.xml
...dnet.service.sweet.mapper/SweetManualNotifyFiveMapper.xml
+5
-0
SweetManualShopFiveMapper.xml
...uidnet.service.sweet.mapper/SweetManualShopFiveMapper.xml
+5
-0
SweetManualSortFiveMapper.xml
...uidnet.service.sweet.mapper/SweetManualSortFiveMapper.xml
+5
-0
SweetRichtextFiveMapper.xml
...iquidnet.service.sweet.mapper/SweetRichtextFiveMapper.xml
+5
-0
SweetUserRelationFiveMapper.xml
...dnet.service.sweet.mapper/SweetUserRelationFiveMapper.xml
+5
-0
AdamUserServiceImpl.java
...uidnet/service/adam/service/impl/AdamUserServiceImpl.java
+4
-4
sqlmap.properties
...et-service-adam-impl/src/main/resources/sqlmap.properties
+1
-1
GoblinStoreMgtGoodsController.java
...blin/controller/manage/GoblinStoreMgtGoodsController.java
+22
-19
pom.xml
...uidnet-service-kylin/liquidnet-service-kylin-impl/pom.xml
+5
-0
MybatisPlusCodeGenerator.java
.../java/com/liquidnet/service/MybatisPlusCodeGenerator.java
+7
-9
KylinOrderTicketsController.java
...service/kylin/controller/KylinOrderTicketsController.java
+7
-0
KylinRecommendActiveController.java
...vice/kylin/controller/KylinRecommendActiveController.java
+77
-0
KylinOrderTicketsServiceImpl.java
...vice/kylin/service/impl/KylinOrderTicketsServiceImpl.java
+15
-5
KylinRecommendActiveServiceImpl.java
...e/kylin/service/impl/KylinRecommendActiveServiceImpl.java
+351
-0
DataUtils.java
...ain/java/com/liquidnet/service/kylin/utils/DataUtils.java
+30
-0
GoblinAnticipateUtils.java
.../liquidnet/service/kylin/utils/GoblinAnticipateUtils.java
+67
-0
GoblinOrderUtils.java
...a/com/liquidnet/service/kylin/utils/GoblinOrderUtils.java
+59
-0
KylinRedisUtils.java
...va/com/liquidnet/service/kylin/utils/KylinRedisUtils.java
+422
-0
ObjectUtil.java
...in/java/com/liquidnet/service/kylin/utils/ObjectUtil.java
+13
-2
GoblinNftOrderController.java
...et/service/order/controller/GoblinNftOrderController.java
+11
-0
GoblinOrderController.java
...idnet/service/order/controller/GoblinOrderController.java
+11
-0
KylinOrderTicketsController.java
...service/order/controller/KylinOrderTicketsController.java
+2
-9
MixOrderController.java
...iquidnet/service/order/controller/MixOrderController.java
+10
-0
GoblinNftOrderServiceImpl.java
...service/order/service/impl/GoblinNftOrderServiceImpl.java
+23
-0
GoblinOrderServiceImpl.java
...et/service/order/service/impl/GoblinOrderServiceImpl.java
+47
-5
KylinOrderTicketsServiceImpl.java
...vice/order/service/impl/KylinOrderTicketsServiceImpl.java
+7
-4
MixOrderServiceImpl.java
...idnet/service/order/service/impl/MixOrderServiceImpl.java
+42
-0
db_five_structure.sql
...ervice/liquidnet-service-sweet/docu/db_five_structure.sql
+190
-0
SweetAppletFiveController.java
...vice/sweet/controller/five/SweetAppletFiveController.java
+337
-0
SweetManualArtistsFiveController.java
...eet/controller/five/SweetManualArtistsFiveController.java
+108
-0
SweetManualFiveController.java
...vice/sweet/controller/five/SweetManualFiveController.java
+76
-0
SweetManualNotifyFiveController.java
...weet/controller/five/SweetManualNotifyFiveController.java
+92
-0
SweetManualShopFiveController.java
.../sweet/controller/five/SweetManualShopFiveController.java
+108
-0
SweetManualSortFiveController.java
.../sweet/controller/five/SweetManualSortFiveController.java
+51
-0
SweetRichtextFiveController.java
...ce/sweet/controller/five/SweetRichtextFiveController.java
+75
-0
SweetPerformanceServiceImpl.java
...rvice/sweet/service/impl/SweetPerformanceServiceImpl.java
+12
-3
SweetManualArtistsFiveServiceImpl.java
.../service/impl/five/SweetManualArtistsFiveServiceImpl.java
+127
-0
SweetManualFiveServiceImpl.java
...e/sweet/service/impl/five/SweetManualFiveServiceImpl.java
+129
-0
SweetManualNotifyFiveServiceImpl.java
...t/service/impl/five/SweetManualNotifyFiveServiceImpl.java
+121
-0
SweetManualShopFiveServiceImpl.java
...eet/service/impl/five/SweetManualShopFiveServiceImpl.java
+105
-0
SweetManualSortFiveServiceImpl.java
...eet/service/impl/five/SweetManualSortFiveServiceImpl.java
+64
-0
SweetRichtextFiveServiceImpl.java
...sweet/service/impl/five/SweetRichtextFiveServiceImpl.java
+91
-0
SweetUserRelationFiveServiceImpl.java
...t/service/impl/five/SweetUserRelationFiveServiceImpl.java
+20
-0
ObjectUtil.java
...in/java/com/liquidnet/service/sweet/utils/ObjectUtil.java
+17
-0
RedisFiveDataUtils.java
...com/liquidnet/service/sweet/utils/RedisFiveDataUtils.java
+330
-0
sqlmap.properties
...uidnet-service-sweet/src/main/resources/sqlmap.properties
+1
-1
No files found.
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/GoblinMixSearchDto.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
goblin
.
dto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
@ApiModel
(
value
=
"GoblinMixSearchDto"
,
description
=
"Mix搜素"
)
@Data
public
class
GoblinMixSearchDto
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
8425727558228094908L
;
@ApiModelProperty
(
position
=
0
,
value
=
"活动id"
)
private
String
mixId
;
@ApiModelProperty
(
position
=
1
,
value
=
"活动名称"
)
private
String
name
;
@ApiModelProperty
(
position
=
5
,
value
=
"组合名称"
)
private
String
sellName
;
private
static
final
GoblinMixSearchDto
obj
=
new
GoblinMixSearchDto
();
public
static
GoblinMixSearchDto
getNew
()
{
try
{
return
(
GoblinMixSearchDto
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
GoblinMixSearchDto
();
}
}
}
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/vo/GoblinGoodsCheckVo.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
goblin
.
dto
.
vo
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.util.List
;
@Data
public
class
GoblinGoodsCheckVo
implements
Serializable
,
Cloneable
{
@ApiModelProperty
(
value
=
"名单id"
)
private
Integer
status
;
@ApiModelProperty
(
value
=
"优先购名称"
)
private
List
<
String
>
spuId
;
private
static
final
GoblinGoodsCheckVo
obj
=
new
GoblinGoodsCheckVo
();
public
static
GoblinGoodsCheckVo
getNew
()
{
try
{
return
(
GoblinGoodsCheckVo
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
e
.
printStackTrace
();
}
return
new
GoblinGoodsCheckVo
();
}
}
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/vo/GoblinMixCheckVo.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
goblin
.
dto
.
vo
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
@Data
public
class
GoblinMixCheckVo
implements
Serializable
,
Cloneable
{
@ApiModelProperty
(
value
=
"名单id"
)
private
Integer
status
;
@ApiModelProperty
(
value
=
"优先购名称"
)
private
String
mixId
;
private
static
final
GoblinMixCheckVo
obj
=
new
GoblinMixCheckVo
();
public
static
GoblinMixCheckVo
getNew
()
{
try
{
return
(
GoblinMixCheckVo
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
e
.
printStackTrace
();
}
return
new
GoblinMixCheckVo
();
}
}
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/vo/GoblinNftCheckVo.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
goblin
.
dto
.
vo
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
@Data
public
class
GoblinNftCheckVo
implements
Serializable
,
Cloneable
{
@ApiModelProperty
(
value
=
"名单id"
)
private
Integer
status
;
@ApiModelProperty
(
value
=
"优先购名称"
)
private
String
skuId
;
private
static
final
GoblinNftCheckVo
obj
=
new
GoblinNftCheckVo
();
public
static
GoblinNftCheckVo
getNew
()
{
try
{
return
(
GoblinNftCheckVo
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
e
.
printStackTrace
();
}
return
new
GoblinNftCheckVo
();
}
}
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/service/IGoblinNftOrderService.java
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
goblin
.
service
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.goblin.dto.vo.GoblinNftCheckVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinNftPayResultVo
;
import
com.liquidnet.service.goblin.param.GoblinNftOrderPayAgainParam
;
import
com.liquidnet.service.goblin.param.GoblinNftOrderPayCallbackParam
;
...
...
@@ -22,6 +23,9 @@ public interface IGoblinNftOrderService {
ResponseDto
<
Integer
>
checkOrderResult
(
String
orderId
);
ResponseDto
<
GoblinNftCheckVo
>
checkOrderResult2
(
String
orderId
);
String
syncOrder
(
GoblinNftOrderPayCallbackParam
syncOrderParam
);
String
refundSyncOrder
(
GoblinNftOrderRefundCallbackParam
refundCallbackParam
);
...
...
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/service/IGoblinOrderService.java
View file @
75cd17ba
...
...
@@ -2,6 +2,7 @@ package com.liquidnet.service.goblin.service;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.goblin.dto.manage.GoblinOrderParam
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsCheckVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinMailVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinPayInnerResultVo
;
import
com.liquidnet.service.goblin.param.PayAgainParam
;
...
...
@@ -25,6 +26,8 @@ public interface IGoblinOrderService {
ResponseDto
<
Integer
>
checkOrderResultMaterCode
(
String
materCode
);
ResponseDto
<
GoblinGoodsCheckVo
>
checkOrderResultMaterCode2
(
String
materCode
);
String
huiFuSync
(
HttpServletRequest
request
);
...
...
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/service/IMixOrderService.java
View file @
75cd17ba
...
...
@@ -3,6 +3,7 @@ package com.liquidnet.service.goblin.service;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.goblin.dto.manage.GoblinOrderParam
;
import
com.liquidnet.service.goblin.dto.manage.MixOrderParam
;
import
com.liquidnet.service.goblin.dto.vo.GoblinMixCheckVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinPayInnerResultVo
;
import
com.liquidnet.service.goblin.param.PayAgainParam
;
import
com.liquidnet.service.goblin.param.RefundCallbackParam
;
...
...
@@ -18,5 +19,5 @@ public interface IMixOrderService {
ResponseDto
<
Integer
>
checkOrderResultMaterCode
(
String
materCode
);
ResponseDto
<
GoblinMixCheckVo
>
checkOrderResultMaterCode2
(
String
materCode
);
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/constant/KylinRedisConst.java
View file @
75cd17ba
...
...
@@ -97,6 +97,8 @@ public class KylinRedisConst {
public
static
final
String
ACTIVE_TICKET_AR_TICKET
=
"kylin:active:ar:ticket:"
;
//互动券
public
static
final
String
ACTIVE_TICKET_AR_USER
=
"kylin:active:ar:user:"
;
//互动券 绑定的用户
public
static
final
String
RECOMMEND_ACTIVE
=
"kylin:active:recommend:"
;
// 推荐活动
/**
* 巡演券
* eg:{kylin:c_rs:${couponId}, List<巡演ID>}
...
...
@@ -105,5 +107,7 @@ public class KylinRedisConst {
public
static
final
String
COUPON_COUNT
=
"kylin:coupon:count:"
;
//$key + $uid:$performance_id
public
static
final
String
MEMBER_COUNT
=
"kylin:member:count:"
;
//$key + $uid:$performance_id
//订单关联 Ar激活码
public
static
final
String
ORDER_AR_CODE
=
"kylin:ar:order:"
;
//$key + $orderId
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/param/KylinRecommendActiveParam.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
param
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
java.util.List
;
/**
* <p>
* 推荐活动表
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
KylinRecommendActiveParam
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"id"
)
private
Long
mid
;
/**
* 推荐活动id
*/
@ApiModelProperty
(
value
=
"推荐活动id"
)
private
String
recommendId
;
/**
* 开启时间
*/
@ApiModelProperty
(
value
=
"开启时间yyyy-MM-dd HH:mm:ss"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
startTime
;
/**
* 结束时间
*/
@ApiModelProperty
(
value
=
"结束时间yyyy-MM-dd HH:mm:ss"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
endTime
;
/**
* 活动名称
*/
@ApiModelProperty
(
value
=
"活动名称"
)
private
String
activeName
;
/**
* 1NFT2组合购3演出4商品
*/
@ApiModelProperty
(
value
=
"1NFT2组合购3演出4商品"
)
private
Integer
activeType
;
/**
* 活动绑定id
*/
@ApiModelProperty
(
value
=
"活动绑定id"
)
private
String
activeBindId
;
/**
* 0未删除1已删除
*/
@ApiModelProperty
(
value
=
"0未删除1已删除"
)
private
Integer
delTag
;
/**
* 创建时间
*/
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
@ApiModelProperty
(
value
=
"创建时间"
)
private
LocalDateTime
createdAt
;
/**
* 修改时间
*/
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
@ApiModelProperty
(
value
=
"修改时间"
)
private
LocalDateTime
updatedAt
;
/**
* 0开启,1未开启
*/
@ApiModelProperty
(
value
=
"0开启,1未开启"
)
private
Integer
status
;
private
List
<
KylinRecommendActiveRelationParam
>
list
;
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/param/KylinRecommendActiveRelationParam.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
param
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 推荐活动关联表
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
KylinRecommendActiveRelationParam
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"id"
)
private
Long
mid
;
/**
* 推荐活动关系id
*/
@ApiModelProperty
(
value
=
"推荐活动关系id"
)
private
String
recommendRelationId
;
/**
* 推荐商品id
*/
@ApiModelProperty
(
value
=
"推荐商品id"
)
private
String
recommendBindId
;
/**
* 1NFT2组合购3演出4商品
*/
@ApiModelProperty
(
value
=
"1NFT2组合购3演出4商品"
)
private
Integer
type
;
/**
* 推荐活动id(关联id)
*/
@ApiModelProperty
(
value
=
"推荐活动id(关联id)"
)
private
String
recommendActiveId
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 修改时间
*/
private
LocalDateTime
updatedAt
;
/**
*
*/
@ApiModelProperty
(
value
=
"排序"
)
private
Integer
indexs
;
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/vo/GoblinGoodsInfoVo.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
java.util.List
;
@ApiModel
(
value
=
"GoblinGoodsInfoVo"
,
description
=
"商品SPU详情[不包含具体SKU,SKU详情参见'GoblinGoobsSkuInfoVo']"
)
@Data
@JsonIgnoreProperties
(
ignoreUnknown
=
true
)
public
class
GoblinGoodsInfoVo
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
-
4712015317981742851L
;
@ApiModelProperty
(
position
=
10
,
value
=
"店铺ID"
)
private
String
storeId
;
@ApiModelProperty
(
position
=
11
,
value
=
"商品ID[64]"
)
private
String
spuId
;
@ApiModelProperty
(
position
=
12
,
value
=
"商品编码[默认为系统编码,也可手动输入商家自己的编码]"
)
private
String
spuNo
;
@ApiModelProperty
(
position
=
12
,
value
=
"商品类型[0-常规|1-数字藏品]"
)
private
int
spuType
;
@ApiModelProperty
(
position
=
13
,
value
=
"商品名称[100]"
)
private
String
name
;
@ApiModelProperty
(
position
=
14
,
value
=
"商品副标题[128]"
)
private
String
subtitle
;
@ApiModelProperty
(
position
=
15
,
value
=
"销售价-原价[20,2]"
)
private
BigDecimal
sellPrice
;
@ApiModelProperty
(
position
=
16
,
value
=
"价格区间MIN[20,2]"
)
private
BigDecimal
priceGe
;
@ApiModelProperty
(
position
=
17
,
value
=
"价格区间MAX[20,2]"
)
private
BigDecimal
priceLe
;
@ApiModelProperty
(
position
=
18
,
value
=
"商品简介[256]"
)
private
String
intro
;
@ApiModelProperty
(
position
=
19
,
value
=
"商品详情"
,
example
=
"商品详情..."
)
private
String
details
;
@ApiModelProperty
(
position
=
19
,
value
=
"注意事项"
,
example
=
"注意事项..."
)
private
String
attention
;
@ApiModelProperty
(
position
=
20
,
value
=
"封面图片地址[256]"
)
private
String
coverPic
;
@ApiModelProperty
(
position
=
21
,
value
=
"商品视频地址"
)
private
String
video
;
@ApiModelProperty
(
position
=
22
,
value
=
"规格展现方式[1-常规|2-组合]"
)
private
String
specMode
;
@ApiModelProperty
(
position
=
23
,
value
=
"商品一级分类ID[30]"
)
private
String
cateFid
;
@ApiModelProperty
(
position
=
24
,
value
=
"商品二级分类ID[30]"
)
private
String
cateSid
;
@ApiModelProperty
(
position
=
25
,
value
=
"商品三级分类ID[30]"
)
private
String
cateTid
;
@ApiModelProperty
(
position
=
26
,
value
=
"店铺一级分类ID[30]"
)
private
String
storeCateFid
;
@ApiModelProperty
(
position
=
27
,
value
=
"店铺二级分类ID[30]"
)
private
String
storeCateSid
;
@ApiModelProperty
(
position
=
28
,
value
=
"店铺三级分类ID[31]"
)
private
String
storeCateTid
;
@ApiModelProperty
(
position
=
29
,
value
=
"品牌ID[30]"
)
private
String
brandId
;
@ApiModelProperty
(
position
=
30
,
value
=
"上架处理方式[1-等待手动上架|2-直接上架售卖|3-预约定时上架]"
)
private
String
shelvesHandle
;
@ApiModelProperty
(
position
=
31
,
value
=
"预约上架时间[上架处理方式为3-预约定时上架时需要指定]"
)
private
String
shelvesTime
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
@ApiModelProperty
(
position
=
31
,
value
=
"开售时间"
)
private
LocalDateTime
saleStartTime
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
@ApiModelProperty
(
position
=
31
,
value
=
"停售时间"
)
private
LocalDateTime
saleStopTime
;
@ApiModelProperty
(
position
=
32
,
value
=
"商品有效期[YYYY-MM-DD]"
)
private
String
spuValidity
;
@ApiModelProperty
(
position
=
33
,
value
=
"是否虚拟商品[0-否|1-是]"
)
private
String
virtualFlg
;
@ApiModelProperty
(
position
=
34
,
value
=
"审核状态[0-编辑中|1-审核中|2-审核不通过|3-审核通过]"
)
private
String
status
;
@ApiModelProperty
(
position
=
35
,
value
=
"审核拒绝原因[256]"
)
private
String
reason
;
@ApiModelProperty
(
position
=
36
,
value
=
"商品上架状态[0-待上架|1-下架|2-违规|3-上架]"
)
private
String
shelvesStatus
;
@ApiModelProperty
(
position
=
37
,
value
=
"是否隐藏[0-默认展示|1-隐藏]"
)
private
String
spuAppear
;
@ApiModelProperty
(
position
=
37
,
value
=
"是否购买[0-否|1-是]"
)
private
String
spuCanbuy
;
@ApiModelProperty
(
position
=
37
,
value
=
"创作者"
)
private
String
author
;
@ApiModelProperty
(
position
=
37
,
value
=
"发行方"
)
private
String
publisher
;
@ApiModelProperty
(
position
=
38
,
value
=
"删除标记[0-未删除|1-删除]"
)
private
String
delFlg
;
@ApiModelProperty
(
position
=
39
,
value
=
"上架时间"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
shelvesAt
;
@ApiModelProperty
(
position
=
40
,
value
=
"商品图片列表"
)
private
List
<
String
>
imageList
;
@ApiModelProperty
(
position
=
41
,
value
=
"物流模版"
)
private
String
logisticsTemplate
;
private
String
createdBy
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
createdAt
;
private
String
updatedBy
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
updatedAt
;
private
String
deletedBy
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
deletedAt
;
/* @ApiModelProperty(position = 51, value = "规格信息")
private List<GoblinGoodsSpecVo> specVoList;
@ApiModelProperty(position = 52, value = "商品标签列表")
private List<GoblinGoodsTagVo> tagVoList;
@ApiModelProperty(position = 53, value = "商品服务支持列表")
private List<GoblinServiceSupportVo> serviceSupportVoList;
@ApiModelProperty(position = 54, value = "音乐人、艺术家、IP列表")
private List<GoblinGoodsExtagVo> extagVoList;
@ApiModelProperty(position = 55, value = "AR标签")
private List<GoblinGoodsExtagVo> artagVoList;*/
@ApiModelProperty
(
position
=
56
,
value
=
"SPU包含的SKU_ID列表"
)
private
List
<
String
>
skuIdList
;
/* ------------------------------------------------------------ */
@ApiModelProperty
(
position
=
60
,
value
=
"活动Id"
)
private
String
marketId
;
@ApiModelProperty
(
position
=
64
,
value
=
"活动类型"
)
private
String
marketType
;
@ApiModelProperty
(
position
=
63
,
value
=
"演出id"
)
private
String
performanceId
;
@ApiModelProperty
(
position
=
61
,
value
=
"销量"
)
private
Integer
count
;
@ApiModelProperty
(
position
=
62
,
value
=
"商铺名称"
)
private
String
storeName
;
/*@ApiModelProperty(position = 63, value = "skuList")
private List<GoblinGoodsSkuInfoVo> goblinOrderSkuVos;
public String getMarketType() {
if (marketId == null) {
return "";
} else if (marketId.contains("ZZ")) {
return GoblinStatusConst.MarketPreStatus.getPre(marketId);
}
return "";
}*/
private
static
final
GoblinGoodsInfoVo
obj
=
new
GoblinGoodsInfoVo
();
public
static
GoblinGoodsInfoVo
getNew
()
{
try
{
return
(
GoblinGoodsInfoVo
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
GoblinGoodsInfoVo
();
}
}
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/vo/GoblinMixAppDetailsVo.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
@Data
@EqualsAndHashCode
public
class
GoblinMixAppDetailsVo
implements
Serializable
,
Cloneable
{
@ApiModelProperty
(
position
=
0
,
value
=
"活动id"
)
private
String
mixId
;
@ApiModelProperty
(
position
=
1
,
value
=
"活动名称"
)
private
String
name
;
@ApiModelProperty
(
position
=
2
,
value
=
"开始时间"
)
private
String
timeStart
;
@ApiModelProperty
(
position
=
3
,
value
=
"结束时间"
)
private
String
timeEnd
;
@ApiModelProperty
(
position
=
5
,
value
=
"组合名称"
)
private
String
sellName
;
@ApiModelProperty
(
position
=
9
,
value
=
"商品简介/购买须知"
)
private
String
intro
;
@ApiModelProperty
(
position
=
10
,
value
=
"封面图片地址"
)
private
String
coverPic
;
@ApiModelProperty
(
position
=
11
,
value
=
"商品视频地址/数字昌平视频地址"
)
private
String
video
;
@ApiModelProperty
(
position
=
12
,
value
=
"商品详情/藏品详情"
)
private
String
details
;
@ApiModelProperty
(
position
=
13
,
value
=
"展示文件类型[1-图片|2-视频]"
)
private
Integer
watchType
;
@ApiModelProperty
(
position
=
14
,
value
=
"详情图片地址"
)
private
String
detailUrl
;
@ApiModelProperty
(
position
=
17
,
value
=
"限购数量[0-无限]"
)
private
Integer
limit
;
@ApiModelProperty
(
position
=
18
,
value
=
"白名单类型[0-会员|1-指定用户|2-全部用户]"
)
private
Integer
whiteType
;
/* @ApiModelProperty(position = 20, value = "配置详情")
private List<GoblinMixDetailsItemVo> item;*/
@ApiModelProperty
(
position
=
22
,
value
=
"状态[6-活动中|7-停用|8-售罄|9-等待开始|10-活动结束]"
)
private
Integer
status
;
@ApiModelProperty
(
position
=
24
,
value
=
"IOS支付方式[0-第三方支付|1-苹果支付]"
)
private
Integer
payType
;
@ApiModelProperty
(
position
=
25
,
value
=
"店铺名称]"
)
private
String
storeName
;
@ApiModelProperty
(
position
=
23
,
value
=
"销售价格"
)
private
BigDecimal
sellPrice
;
@ApiModelProperty
(
position
=
23
,
value
=
"原价"
)
private
BigDecimal
price
;
@ApiModelProperty
(
position
=
22
,
value
=
"上架时间"
)
private
String
shelvesTime
;
private
static
final
GoblinMixAppDetailsVo
obj
=
new
GoblinMixAppDetailsVo
();
public
static
GoblinMixAppDetailsVo
getNew
()
{
try
{
return
(
GoblinMixAppDetailsVo
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
GoblinMixAppDetailsVo
();
}
}
/* public GoblinMixAppDetailsVo copy(GoblinMixDetailsVo source,String storeName) {
if (null == source) return this;
this.setMixId(source.getMixId());
this.setName(source.getName());
this.setTimeStart(source.getTimeStart());
this.setTimeEnd(source.getTimeEnd());
this.setSellName(source.getSellName());
this.setIntro(source.getIntro());
this.setCoverPic(source.getCoverPic());
this.setVideo(source.getVideo());
this.setDetails(source.getDetails());
this.setWatchType(source.getWatchType());
this.setDetailUrl(source.getDetailUrl());
this.setLimit(source.getLimit());
this.setWhiteType(source.getWhiteType());
this.setItem(source.getItem());
this.setPayType(source.getPayType());
this.setStoreName(storeName);
this.setPrice(source.getPrice());
this.setSellPrice(source.getSellPrice());
return this;
}*/
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/vo/GoblinNftGoodsSkuInfoVo.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.math.BigInteger
;
import
java.time.LocalDateTime
;
import
java.util.List
;
@ApiModel
(
value
=
"GoblinNftGoodsSkuInfoVo"
,
description
=
"NFT商品SKU信息"
)
@Data
@JsonIgnoreProperties
(
ignoreUnknown
=
true
)
public
class
GoblinNftGoodsSkuInfoVo
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
-
519573757075729441L
;
@ApiModelProperty
(
position
=
10
,
value
=
"商品单品ID"
)
private
String
skuId
;
@ApiModelProperty
(
position
=
11
,
value
=
"商品ID[64]"
)
private
String
spuId
;
@ApiModelProperty
(
position
=
13
,
value
=
"单品的名称[100]"
)
private
String
name
;
@ApiModelProperty
(
position
=
14
,
value
=
"单品的副标题[128]"
)
private
String
subtitle
;
@ApiModelProperty
(
position
=
15
,
value
=
"单品详情展示文件URL[256]"
)
private
String
skuWatch
;
private
String
coverPic
;
@ApiModelProperty
(
position
=
16
,
value
=
"展示文件类型[1-图片|2-视频|3-模型]"
)
private
String
watchType
;
@ApiModelProperty
(
position
=
17
,
value
=
"展示预览图URL[256]"
)
private
String
skuWatchPic
;
@ApiModelProperty
(
position
=
18
,
value
=
"单品库存"
)
private
Integer
skuStock
;
@ApiModelProperty
(
position
=
21
,
value
=
"单品现价[20,2]"
)
private
BigDecimal
price
;
@ApiModelProperty
(
position
=
22
,
value
=
"IOS商品价格[20,2]"
)
private
BigDecimal
priceV
;
@ApiModelProperty
(
position
=
23
,
value
=
"单品详情"
,
example
=
"单品详情..."
)
private
String
details
;
@ApiModelProperty
(
position
=
26
,
value
=
"限量 0无限制 X限购数量"
)
private
Integer
buyLimit
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
@ApiModelProperty
(
position
=
27
,
value
=
"开售时间"
)
private
LocalDateTime
saleStartTime
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
@ApiModelProperty
(
position
=
28
,
value
=
"系统时间"
)
private
LocalDateTime
systime
;
@ApiModelProperty
(
position
=
33
,
value
=
"是否购买[0-否|1-是]"
)
private
String
skuCanbuy
;
@ApiModelProperty
(
position
=
34
,
value
=
"购买限制[0-全部用户|1-仅会员|2-指定用户 暂时没有这个选项 不用判断 只处理0和1就行]"
)
private
String
buyFactor
;
/* @ApiModelProperty(position = 54, value = "单品音乐人标签[藏品类型时使用]")
private List<GoblinGoodsExtagVo> extagVoList;
@ApiModelProperty(position = 55, value = "spu相关信息")
private GoblinNftGoodsDetailSpuInfoVo goblinNftGoodsDetailSpuInfoVo;*/
@ApiModelProperty
(
position
=
57
,
value
=
"是否还有库存 0没有库存 1有库存 即售罄"
)
private
int
isStock
;
@ApiModelProperty
(
position
=
58
,
value
=
"当前用户还可以购买数量 有限购的时候用"
)
private
int
canBuyNum
;
@ApiModelProperty
(
position
=
59
,
value
=
"预约开始时间"
)
private
String
aboutStartDate
;
@ApiModelProperty
(
position
=
60
,
value
=
"预约结束时间"
)
private
String
aboutEndDate
;
@ApiModelProperty
(
position
=
61
,
value
=
"预约状态(0:未开始,1:可预约,3:已结束)"
)
private
Integer
state
;
@ApiModelProperty
(
position
=
62
,
value
=
"预约规则"
)
private
String
rule
;
@ApiModelProperty
(
position
=
63
,
value
=
"预约人数"
)
private
BigInteger
aboutPeople
;
@ApiModelProperty
(
position
=
64
,
value
=
"前三预约头像"
)
private
List
<
String
>
aboutAvatarList
;
@ApiModelProperty
(
"预约类型(1:预约提醒,2:预约获得购买资格)"
)
private
Integer
type
;
@ApiModelProperty
(
"设置预约人数"
)
private
Integer
peopleType
;
@ApiModelProperty
(
position
=
65
,
value
=
"是否开启兑换 1未开启 2已开启"
)
private
int
isExchange
;
@ApiModelProperty
(
position
=
66
,
value
=
"待支付订单数量"
)
private
int
notPayNum
;
@ApiModelProperty
(
position
=
67
,
value
=
"单品AR文件URL-iOS版"
)
private
String
arUrlIos
;
@ApiModelProperty
(
position
=
68
,
value
=
"单品AR文件URL-Android版"
)
private
String
arUrlAndroid
;
@ApiModelProperty
(
position
=
69
,
value
=
"标签[0-提前购买|1-分段购买]"
)
private
Integer
tagType
;
@ApiModelProperty
(
position
=
70
,
value
=
"分批购活动id"
)
private
String
listId
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
@ApiModelProperty
(
position
=
71
,
value
=
"sku正常开售时间"
)
private
LocalDateTime
baseSaleStartTime
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
@ApiModelProperty
(
position
=
72
,
value
=
"下个分段购开始时间,如果为null则没有"
)
private
LocalDateTime
nextSaleStartTime
;
@ApiModelProperty
(
position
=
73
,
value
=
"创作者"
)
private
String
author
;
@ApiModelProperty
(
position
=
74
,
value
=
"发行方"
)
private
String
publisher
;
private
static
final
GoblinNftGoodsSkuInfoVo
obj
=
new
GoblinNftGoodsSkuInfoVo
();
public
static
GoblinNftGoodsSkuInfoVo
getNew
()
{
try
{
return
(
GoblinNftGoodsSkuInfoVo
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
GoblinNftGoodsSkuInfoVo
();
}
}
/*public GoblinNftGoodsSkuInfoVo copy(GoblinGoodsSkuInfoVo source, AnticipateValueVo anticipateValueVo) {
if (null == source) return this;
this.setSkuId(source.getSkuId());
this.setSpuId(source.getSpuId());
this.setName(source.getName());
this.setSubtitle(source.getSubtitle());
this.setSkuWatch(source.getSkuWatch());
this.setWatchType(source.getWatchType());
this.setSkuWatchPic(source.getSkuWatchPic());
this.setSkuStock(source.getSkuStock());
this.setPrice(source.getPrice());
this.setPriceV(source.getPriceV());
this.setDetails(source.getDetails());
this.setBuyLimit(source.getBuyLimit());
this.setSaleStartTime(source.getSaleStartTime());
this.setSkuCanbuy(source.getSkuCanbuy());
this.setBuyFactor(source.getBuyFactor());
this.setExtagVoList(source.getExtagVoList());
if (anticipateValueVo != null) {
if (anticipateValueVo.getAboutEndDate() != null) {
this.setAboutEndDate(DateUtil.Formatter.yyyyMMddHHmmss.format(anticipateValueVo.getAboutEndDate()));
}
if (anticipateValueVo.getAboutEndDate() != null) {
this.setAboutStartDate(DateUtil.Formatter.yyyyMMddHHmmss.format(anticipateValueVo.getAboutStartDate()));
}
this.setType(anticipateValueVo.getType());
this.setPeopleType(anticipateValueVo.getPeopleType());
this.setState(anticipateValueVo.getState());
this.setRule(anticipateValueVo.getRule());
this.setAboutPeople(anticipateValueVo.getAboutPeople());
this.setAboutAvatarList(anticipateValueVo.getAboutAvatarList());
}
this.setArUrlIos(source.getArUrlIos());
this.setArUrlAndroid(source.getArUrlAndroid());
return this;
}*/
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/vo/KylinRecommendActiveRelationVo.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
com.liquidnet.service.kylin.dto.vo.mongo.KylinPerformanceVo
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 推荐活动关联表
* </p>
* @since 2022-07-27
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
KylinRecommendActiveRelationVo
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"mid"
)
private
Long
mid
;
/**
* 推荐活动关系id
*/
@ApiModelProperty
(
value
=
"推荐活动关系id"
)
private
String
recommendRelationId
;
/**
* 推荐商品id
*/
@ApiModelProperty
(
value
=
"推荐商品id"
)
private
String
recommendBindId
;
/**
* 1NFT2组合购3演出4商品
*/
@ApiModelProperty
(
value
=
"1NFT2组合购3演出4商品"
)
private
Integer
type
;
/**
* 推荐活动id(关联id)
*/
@ApiModelProperty
(
value
=
"推荐活动id(关联id)"
)
private
String
recommendActiveId
;
/**
* 创建时间
*/
@ApiModelProperty
(
value
=
"推荐活动id(关联id)"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
createdAt
;
/**
* 修改时间
*/
@ApiModelProperty
(
value
=
"推荐活动id(关联id)"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
updatedAt
;
/**
* 0未删除1已删除
*/
@ApiModelProperty
(
value
=
"0未删除1已删除"
)
private
Integer
delTag
;
/**
* 排序
*/
@ApiModelProperty
(
value
=
"排序"
)
private
Integer
indexs
;
@ApiModelProperty
(
value
=
"演出的vo"
)
private
KylinPerformanceVo
kylinPerformanceVo
;
private
GoblinNftGoodsSkuInfoVo
goblinNftGoodsSkuInfoVo
;
private
GoblinGoodsInfoVo
goblinGoodsInfoVo
;
private
GoblinMixAppDetailsVo
goblinMixAppDetailsVo
;
private
boolean
isCount
;
private
static
final
KylinRecommendActiveRelationVo
obj
=
new
KylinRecommendActiveRelationVo
();
public
static
KylinRecommendActiveRelationVo
getNew
()
{
try
{
return
(
KylinRecommendActiveRelationVo
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
KylinRecommendActiveRelationVo
();
}
}
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/dto/vo/KylinRecommendActiveVo.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
com.liquidnet.service.kylin.dto.vo.mongo.KylinPerformanceVo
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
java.util.List
;
/**
* <p>
* 推荐活动表
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
KylinRecommendActiveVo
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
private
Long
mid
;
/**
* 推荐活动id
*/
@ApiModelProperty
(
value
=
"推荐活动id"
)
private
String
recommendId
;
/**
* 开启时间
*/
@ApiModelProperty
(
value
=
"开启时间"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
startTime
;
/**
* 结束时间
*/
@ApiModelProperty
(
value
=
"结束时间"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
endTime
;
/**
* 1NFT2组合购3演出4商品
*/
@ApiModelProperty
(
value
=
"1NFT2组合购3演出4商品"
)
private
Integer
activeType
;
/**
* 活动绑定id
*/
@ApiModelProperty
(
value
=
"活动绑定id"
)
private
String
activeBindId
;
/**
* 0未删除1已删除
*/
@ApiModelProperty
(
value
=
"0未删除1已删除"
)
private
Integer
delTag
;
/**
* 创建时间
*/
@ApiModelProperty
(
value
=
"0未删除1已删除"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
createdAt
;
/**
* 修改时间
*/
@ApiModelProperty
(
value
=
"0未删除1已删除"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
DateUtil
.
DATE_FULL_STR
)
private
LocalDateTime
updatedAt
;
/**
* 0开启,1未开启
*/
@ApiModelProperty
(
value
=
"0开启,1未开启"
)
private
Integer
status
;
@ApiModelProperty
(
value
=
"推荐活动"
)
private
List
<
KylinRecommendActiveRelationVo
>
list
;
@ApiModelProperty
(
value
=
"演出的vo"
)
private
KylinPerformanceVo
kylinPerformanceVo
;
@ApiModelProperty
(
value
=
"NFT的vo"
)
private
GoblinNftGoodsSkuInfoVo
goblinNftGoodsSkuInfoVo
;
@ApiModelProperty
(
value
=
"商品的vo"
)
private
GoblinGoodsInfoVo
goblinGoodsInfoVo
;
@ApiModelProperty
(
value
=
"组合购的vo"
)
private
GoblinMixAppDetailsVo
goblinMixAppDetailsVo
;
private
String
name
;
private
static
final
KylinRecommendActiveVo
obj
=
new
KylinRecommendActiveVo
();
public
static
KylinRecommendActiveVo
getNew
()
{
try
{
return
(
KylinRecommendActiveVo
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
KylinRecommendActiveVo
();
}
}
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/service/IKylinOrderTicketsOrderService.java
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
service
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.kylin.dto.param.PayAgainParam
;
import
com.liquidnet.service.kylin.dto.param.PayOrderParam
;
import
com.liquidnet.service.kylin.dto.param.SyncOrderDtoParam
;
import
com.liquidnet.service.kylin.dto.param.SyncOrderParam
;
import
com.liquidnet.service.kylin.dto.vo.returns.*
;
import
java.util.
List
;
import
java.util.
HashMap
;
/**
* <p>
...
...
@@ -30,6 +28,6 @@ public interface IKylinOrderTicketsOrderService {
String
syncOrder
(
SyncOrderParam
syncOrderParam
);
//去 PHP pay检查 订单状态
ResponseDto
<
Integer
>
checkOrderResult
(
String
orderId
);
ResponseDto
<
HashMap
<
String
,
Object
>
>
checkOrderResult
(
String
orderId
);
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/service/IKylinOrderTicketsService.java
View file @
75cd17ba
...
...
@@ -70,4 +70,7 @@ public interface IKylinOrderTicketsService {
//退款撤回
ResponseDto
<
Boolean
>
orderRefundWithdraw
(
String
orderRefundsId
);
//获取 订单Ar激活码
ResponseDto
<
List
<
String
>>
getOrderArCode
(
String
orderId
);
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/service/IKylinRecommendActiveService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
service
;
import
com.liquidnet.service.kylin.dto.vo.KylinRecommendActiveVo
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActive
;
import
java.text.ParseException
;
import
java.util.List
;
/**
* 推荐活动接口
*/
public
interface
IKylinRecommendActiveService
{
KylinRecommendActiveVo
getRecommendById
(
List
<
KylinRecommendActive
>
list
)
throws
ParseException
;
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/service/admin/IKylinRecommendActiveRelationService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
service
.
admin
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActiveRelation
;
import
java.util.List
;
/**
* <p>
* 推荐活动关联表 服务类
*/
public
interface
IKylinRecommendActiveRelationService
extends
IService
<
KylinRecommendActiveRelation
>
{
boolean
addKylinRecommendActiveRelation
(
KylinRecommendActiveRelation
kylinRecommendActiveRelation
);
boolean
addListKylinRecommendActiveRelation
(
List
<
KylinRecommendActiveRelation
>
kylinRecommendActiveRelation
);
boolean
deleteKylinRecommendActiveRelation
(
KylinRecommendActiveRelation
kylinRecommendActiveRelation
);
}
liquidnet-bus-api/liquidnet-service-kylin-api/src/main/java/com/liquidnet/service/kylin/service/admin/IKylinRecommendActiveService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
service
.
admin
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActive
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActiveRelation
;
import
java.util.List
;
/**
* <p>
* 推荐活动表 服务类
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
public
interface
IKylinRecommendActiveService
extends
IService
<
KylinRecommendActive
>
{
boolean
addKylinRecommendActive
(
KylinRecommendActive
kylinRecommendActive
,
List
<
KylinRecommendActiveRelation
>
kylinRecommendActiveRelations
);
boolean
updateKylinRecommendActive
(
KylinRecommendActive
kylinRecommendActive
);
List
<
KylinRecommendActive
>
pageKylinAcitve
(
int
pageSize
,
int
pageNumber
);
KylinRecommendActive
getKylinRecommendActiveById
(
int
mid
);
KylinRecommendActive
getByRecommendId
(
String
id
);
int
validateTime
(
KylinRecommendActive
kylinRecommendActive
);
void
updateRedis
(
KylinRecommendActive
kylinRecommendActive
);
}
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/constant/SweetConstant.java
View file @
75cd17ba
...
...
@@ -27,13 +27,21 @@ public class SweetConstant {
public
final
static
String
REDIS_KEY_SWEET_MDSK_ARTISTS_RELATION
=
"sweet:mdsk:artists:relation:uid:"
;
public
final
static
String
REDIS_KEY_SWEET_MDSK_SHOP
=
"sweet:mdsk:artists:shop:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_PUSH_LIST
=
"sweet:mdsk:manual:pushList"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_TIME_LIST
=
"sweet:mdsk:manual:timeList:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_NOTIFY_LIST
=
"sweet:mdsk:manual:notify:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_RICH_TEXT
=
"sweet:mdsk:manual:richText:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_SORT
=
"sweet:mdsk:manual:sort:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_ARTISTS_RELATION
=
"sweet:mdsk:artists:relation:uid:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_SHOP
=
"sweet:mdsk:artists:shop:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_FIVE_MANUAL_PUSH_LIST
=
"sweet:five:manual:pushList"
;
public
final
static
String
REDIS_KEY_SWEET_FIVE_MANUAL_TIME_LIST
=
"sweet:five:manual:timeList:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_FIVE_MANUAL_NOTIFY_LIST
=
"sweet:five:manual:notify:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_FIVE_MANUAL_RICH_TEXT
=
"sweet:five:manual:richText:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_FIVE_MANUAL_SORT
=
"sweet:five:manual:sort:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_FIVE_ARTISTS_RELATION
=
"sweet:five:artists:relation:uid:"
;
public
final
static
String
REDIS_KEY_SWEET_FIVE_SHOP
=
"sweet:five:artists:shop:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_PUSH_LIST
=
"sweet:tfc:manual:pushList"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_TIME_LIST
=
"sweet:tfc:manual:timeList:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_NOTIFY_LIST
=
"sweet:tfc:manual:notify:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_RICH_TEXT
=
"sweet:tfc:manual:richText:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_MANUAL_SORT
=
"sweet:tfc:manual:sort:manual:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_ARTISTS_RELATION
=
"sweet:tfc:artists:relation:uid:"
;
public
final
static
String
REDIS_KEY_SWEET_TFC_SHOP
=
"sweet:tfc:artists:shop:manual:"
;
// 积分活动
public
static
final
String
REDIS_KEY_SWEET_INTEGRAL_ACTIVITY_LIST
=
"sweet:integralActivity:list"
;
...
...
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/service/five/ISweetManualArtistsFiveService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
five
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistListFiveDto
;
import
com.liquidnet.service.sweet.entity.SweetManualArtistsFive
;
/**
* <p>
* 电子宣传手册艺人表 服务类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
ISweetManualArtistsFiveService
extends
IService
<
SweetManualArtistsFive
>
{
ResponseDto
<
PageInfo
<
SweetManualArtistListFiveDto
>>
getList
(
Integer
page
,
Integer
size
,
String
manualId
);
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
artistId
,
String
stageId
,
String
performanceStart
,
String
performanceEnd
,
String
signatureStart
,
String
signatureEnd
);
ResponseDto
<
SweetManualArtistListFiveDto
>
details
(
String
manualRelationId
);
ResponseDto
<
Boolean
>
change
(
String
manualRelationId
,
String
manualId
,
String
artistId
,
String
stageId
,
String
performanceStart
,
String
performanceEnd
,
String
signatureStart
,
String
signatureEnd
);
ResponseDto
<
Boolean
>
delete
(
String
manualRelationId
,
String
manualId
);
}
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/service/five/ISweetManualFiveService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
five
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.dto.SweetManualFiveDto
;
import
com.liquidnet.service.sweet.entity.SweetManualFive
;
/**
* <p>
* 电子宣传手册表 服务类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
ISweetManualFiveService
extends
IService
<
SweetManualFive
>
{
ResponseDto
<
PageInfo
<
SweetManualFiveDto
>>
getManualList
(
int
page
,
int
size
,
String
name
);
ResponseDto
<
SweetManualFiveDto
>
details
(
String
manualId
);
//关闭开启
ResponseDto
<
Boolean
>
changeStatus
(
String
manualId
,
String
performancesId
,
Integer
status
);
//发布与否
ResponseDto
<
Boolean
>
changeRelease
(
String
manualId
,
Integer
isRelease
);
}
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/service/five/ISweetManualNotifyFiveService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
five
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetManualNotifyFive
;
/**
* <p>
* 电子宣传手册通知表 服务类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
ISweetManualNotifyFiveService
extends
IService
<
SweetManualNotifyFive
>
{
ResponseDto
<
PageInfo
<
SweetManualNotifyFive
>>
getList
(
Integer
page
,
Integer
size
,
String
title
,
String
manualId
);
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
title
,
String
content
);
ResponseDto
<
SweetManualNotifyFive
>
details
(
String
manualId
);
ResponseDto
<
Boolean
>
change
(
String
manualId
,
String
manualNotifyId
,
String
title
,
String
content
);
ResponseDto
<
Boolean
>
delete
(
String
manualId
);
}
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/service/five/ISweetManualShopFiveService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
five
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetManualShopFive
;
import
java.util.List
;
/**
* <p>
* 电子宣传手册商铺表 服务类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
ISweetManualShopFiveService
extends
IService
<
SweetManualShopFive
>
{
ResponseDto
<
List
<
SweetManualShopFive
>>
getList
(
String
manualId
,
Integer
type
);
ResponseDto
<
SweetManualShopFive
>
details
(
String
manualShopId
);
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
title
,
String
picUrl
,
String
describe
,
Integer
type
,
Integer
isRecommend
,
Integer
sort
);
ResponseDto
<
Boolean
>
change
(
String
manualShopId
,
String
manualId
,
String
title
,
String
picUrl
,
String
describe
,
Integer
type
,
Integer
isRecommend
,
Integer
sort
);
ResponseDto
<
Boolean
>
delete
(
String
manualShopId
,
String
manualId
);
}
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/service/five/ISweetManualSortFiveService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
five
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetManualSortFive
;
/**
* <p>
* 电子宣传手册显示内容表 服务类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
ISweetManualSortFiveService
extends
IService
<
SweetManualSortFive
>
{
ResponseDto
<
SweetManualSortFive
>
get
(
String
manualId
);
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
content
);
}
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/service/five/ISweetRichtextFiveService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
five
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetRichtextFive
;
/**
* <p>
* 电子宣传手册富文本表 服务类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
ISweetRichtextFiveService
extends
IService
<
SweetRichtextFive
>
{
ResponseDto
<
SweetRichtextFive
>
get
(
String
manualId
,
Integer
type
);
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
details
,
String
local
,
String
pirUrl
,
Integer
type
);
ResponseDto
<
Boolean
>
change
(
String
manualId
,
String
details
,
String
local
,
String
pirUrl
,
Integer
type
);
}
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/service/five/ISweetUserRelationFiveService.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
five
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.liquidnet.service.sweet.entity.SweetUserRelationFive
;
/**
* <p>
* 用户 收藏/喜欢等状态 服务类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
ISweetUserRelationFiveService
extends
IService
<
SweetUserRelationFive
>
{
}
liquidnet-bus-api/liquidnet-service-sweet-api/src/main/java/com/liquidnet/service/sweet/vo/SweetManualShopFiveAllVo.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
vo
;
import
com.liquidnet.service.sweet.entity.SweetManualShopFive
;
import
com.liquidnet.service.sweet.entity.SweetManualShopMdsk
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.util.List
;
@Data
@ApiModel
public
class
SweetManualShopFiveAllVo
implements
Serializable
,
Cloneable
{
@ApiModelProperty
(
"推荐"
)
private
List
<
SweetManualShopFive
>
recommend
;
@ApiModelProperty
(
"吃喝"
)
private
List
<
SweetManualShopFive
>
eat
;
@ApiModelProperty
(
"玩乐"
)
private
List
<
SweetManualShopFive
>
play
;
private
static
final
SweetManualShopFiveAllVo
obj
=
new
SweetManualShopFiveAllVo
();
public
static
SweetManualShopFiveAllVo
getNew
()
{
try
{
return
(
SweetManualShopFiveAllVo
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualShopFiveAllVo
();
}
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/docu/db_liquidnet_admin_structure.sql
View file @
75cd17ba
...
...
@@ -709,4 +709,38 @@ create table gen_table_column (
update_by
varchar
(
64
)
default
''
comment
'更新者'
,
update_time
datetime
comment
'更新时间'
,
primary
key
(
column_id
)
)
engine
=
innodb
auto_increment
=
1
comment
=
'代码生成业务表字段'
;
\ No newline at end of file
)
engine
=
innodb
auto_increment
=
1
comment
=
'代码生成业务表字段'
;
DROP
TABLE
IF
EXISTS
`kylin_recommend_active`
;
CREATE
TABLE
`kylin_recommend_active`
(
`mid`
bigint
(
20
)
NOT
NULL
AUTO_INCREMENT
,
`recommend_id`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_unicode_ci
DEFAULT
NULL
COMMENT
'推荐活动id'
,
`start_time`
timestamp
NULL
DEFAULT
NULL
COMMENT
'开启时间'
,
`end_time`
timestamp
NULL
DEFAULT
NULL
COMMENT
'结束时间'
,
`active_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_unicode_ci
DEFAULT
NULL
COMMENT
'活动名称'
,
`active_type`
int
(
2
)
DEFAULT
NULL
COMMENT
'1NFT2组合购3演出4商品'
,
`active_bind_id`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_unicode_ci
DEFAULT
NULL
COMMENT
'活动绑定id'
,
`del_tag`
int
(
2
)
DEFAULT
NULL
COMMENT
'0未删除1已删除'
,
`created_at`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`updated_at`
datetime
DEFAULT
NULL
COMMENT
'修改时间'
,
`status`
int
(
2
)
DEFAULT
NULL
COMMENT
'0开启,1未开启'
,
PRIMARY
KEY
(
`mid`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
9
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_unicode_ci
COMMENT
=
'推荐活动表'
;
SET
FOREIGN_KEY_CHECKS
=
1
;
DROP
TABLE
IF
EXISTS
`kylin_recommend_active_relation`
;
CREATE
TABLE
`kylin_recommend_active_relation`
(
`mid`
bigint
(
20
)
NOT
NULL
AUTO_INCREMENT
,
`recommend_relation_id`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_unicode_ci
DEFAULT
NULL
COMMENT
'推荐活动关系id'
,
`recommend_bind_id`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_unicode_ci
DEFAULT
NULL
COMMENT
'推荐商品id'
,
`type`
int
(
255
)
DEFAULT
NULL
COMMENT
'1NFT2组合购3演出4商品'
,
`recommend_active_id`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_unicode_ci
DEFAULT
NULL
COMMENT
'推荐活动id(关联id)'
,
`created_at`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`updated_at`
datetime
DEFAULT
NULL
COMMENT
'修改时间'
,
`del_tag`
int
(
2
)
DEFAULT
NULL
COMMENT
'0未删除1已删除'
,
`indexs`
int
(
11
)
DEFAULT
NULL
COMMENT
'排序'
,
PRIMARY
KEY
(
`mid`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
13
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_unicode_ci
COMMENT
=
'推荐活动关联表'
;
SET
FOREIGN_KEY_CHECKS
=
1
;
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/java/com/liquidnet/client/admin/web/controller/zhengzai/LocalAdminController.java
View file @
75cd17ba
...
...
@@ -122,8 +122,8 @@ public class LocalAdminController extends BaseController
return
storePrefix
+
"/placingOrder/activityList"
;
}
@GetMapping
(
"/addNewActivity"
)
public
String
addNewActivity
(
)
{
public
String
addNewActivity
(
ModelMap
mmap
)
{
mmap
.
put
(
"platformUrl"
,
platformUrl
);
return
storePrefix
+
"/placingOrder/addNewActivity"
;
}
@GetMapping
(
"/activityStoreList"
)
...
...
@@ -206,5 +206,20 @@ public class LocalAdminController extends BaseController
{
return
candyPrefix
+
"/coupon/mgt/relevancyShow"
;
}
@GetMapping
(
"/affiliatedActivity"
)
// 关联活动
public
String
affiliatedActivity
()
{
return
activityPrefix
+
"/affiliatedActivity/list"
;
}
@GetMapping
(
"/affiliatedActivityadd"
)
// 关联活动-编辑
public
String
affiliatedActivityadd
()
{
return
activityPrefix
+
"/affiliatedActivity/add"
;
}
@GetMapping
(
"/affiliatedActivityEdit"
)
// 关联活动-编辑
public
String
affiliatedActivityEdit
()
{
return
activityPrefix
+
"/affiliatedActivity/edit"
;
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/java/com/liquidnet/client/admin/web/controller/zhengzai/goblin/GoblinCommonController.java
View file @
75cd17ba
...
...
@@ -40,10 +40,18 @@ public class GoblinCommonController extends BaseController {
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"title"
,
value
=
"商品名称[模糊]"
),
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"Integer"
,
name
=
"type"
,
value
=
"商品类型[0-常规|1-数字藏品]"
),
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"shelvesStatus"
,
value
=
"上线状态"
),
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"spuAppear"
,
value
=
"显示状态"
),
})
@ResponseBody
public
AjaxResult
goodsSearch
(
String
title
,
Integer
type
)
{
return
AjaxResult
.
success
(
goblinCommonService
.
goodsSearch
(
title
,
type
));
public
AjaxResult
goodsSearch
(
String
title
,
Integer
type
,
String
shelvesStatus
,
String
spuAppear
)
{
if
(
""
.
equals
(
shelvesStatus
)){
shelvesStatus
=
null
;
}
if
(
""
.
equals
(
spuAppear
)){
spuAppear
=
null
;
}
return
AjaxResult
.
success
(
goblinCommonService
.
goodsSearch
(
title
,
type
,
shelvesStatus
,
spuAppear
));
}
@Log
(
title
=
"商品搜索"
,
businessType
=
BusinessType
.
LIST
)
...
...
@@ -51,10 +59,24 @@ public class GoblinCommonController extends BaseController {
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"title"
,
value
=
"商品名称[模糊]"
),
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"Integer"
,
name
=
"type"
,
value
=
"商品类型[0-常规|1-数字藏品]"
),
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"shelvesStatus"
,
value
=
"上线状态"
),
})
@ResponseBody
public
AjaxResult
skuSearch
(
String
title
,
Integer
type
)
{
return
AjaxResult
.
success
(
goblinCommonService
.
skuSearch
(
title
,
type
));
public
AjaxResult
skuSearch
(
String
title
,
Integer
type
,
String
shelvesStatus
)
{
if
(
""
.
equals
(
shelvesStatus
)){
shelvesStatus
=
null
;
}
return
AjaxResult
.
success
(
goblinCommonService
.
skuSearch
(
title
,
type
,
shelvesStatus
));
}
@Log
(
title
=
"混合售搜索"
,
businessType
=
BusinessType
.
LIST
)
@GetMapping
(
"mix"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"title"
,
value
=
"混合售售卖名称[模糊]"
),
})
@ResponseBody
public
AjaxResult
mixSearch
(
String
title
)
{
return
AjaxResult
.
success
(
goblinCommonService
.
mixSearch
(
title
));
}
/** ------------------------------------------------------------------------ **/
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/java/com/liquidnet/client/admin/web/controller/zhengzai/goblin/GoblinSelfZhengzaiController.java
View file @
75cd17ba
...
...
@@ -55,7 +55,7 @@ public class GoblinSelfZhengzaiController extends BaseController {
@RequestParam
(
value
=
"createdAt"
,
required
=
false
)
String
ct
)
{
LocalDateTime
now
=
LocalDateTime
.
now
();
PageHelper
.
startPage
(
page
,
size
);
List
<
GoblinSelfMarketingDto
>
list
=
goblinZhengzaiMarketService
.
zhengzaiList
(
page
,
size
,
purchaseName
,
status
,
st
,
et
,
ct
).
getData
();
List
<
GoblinSelfMarketingDto
>
list
=
goblinZhengzaiMarketService
.
zhengzaiList
(
page
,
size
,
purchaseName
,
status
,
st
,
et
,
ct
).
getData
();
for
(
GoblinSelfMarketingDto
item
:
list
)
{
if
(
item
.
getStatus
()
!=
7
)
{
if
(
now
.
isBefore
(
item
.
getStartTime
()))
{
...
...
@@ -94,9 +94,8 @@ public class GoblinSelfZhengzaiController extends BaseController {
@ApiOperation
(
"修改活动-正在下单"
)
@ApiResponse
(
code
=
200
,
message
=
"接口返回对象参数"
)
@ResponseBody
public
ResponseDto
<
String
>
purchasingUpdate
(
GoblinStoreZhengzaiParam
goblinStoreZhengzaiParam
)
{
goblinZhengzaiMarketService
.
zhengzaiUpdate
(
goblinStoreZhengzaiParam
.
getMarketId
(),
goblinStoreZhengzaiParam
.
getName
(),
goblinStoreZhengzaiParam
.
getPerformanceId
(),
goblinStoreZhengzaiParam
.
getPerformanceImg
(),
goblinStoreZhengzaiParam
.
getStartTime
(),
goblinStoreZhengzaiParam
.
getEndTime
());
return
ResponseDto
.
success
();
public
ResponseDto
<
Boolean
>
purchasingUpdate
(
GoblinStoreZhengzaiParam
goblinStoreZhengzaiParam
)
{
return
goblinZhengzaiMarketService
.
zhengzaiUpdate
(
goblinStoreZhengzaiParam
.
getMarketId
(),
goblinStoreZhengzaiParam
.
getName
(),
goblinStoreZhengzaiParam
.
getPerformanceId
(),
goblinStoreZhengzaiParam
.
getPerformanceImg
(),
goblinStoreZhengzaiParam
.
getStartTime
(),
goblinStoreZhengzaiParam
.
getEndTime
());
}
@PostMapping
(
"zhengzai/details"
)
...
...
@@ -111,12 +110,24 @@ public class GoblinSelfZhengzaiController extends BaseController {
@PostMapping
(
"zhengzai/store"
)
@ApiOperation
(
"活动详情-正在下单-新增店铺"
)
@ApiOperation
(
"活动详情-正在下单-新增
/修改
店铺"
)
@ApiResponse
(
code
=
200
,
message
=
"接口返回对象参数"
)
public
ResponseDto
<
Boolean
>
purchasingStore
(
@RequestBody
List
<
GoblinInsertZhengzaiParam
>
params
)
{
return
goblinZhengzaiMarketService
.
zhengzaiStore
(
params
);
}
@PostMapping
(
"zhengzai/store/del"
)
@ApiOperation
(
"活动详情-正在下单-删除店铺"
)
@ApiResponse
(
code
=
200
,
message
=
"接口返回对象参数"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"marketId"
,
value
=
"活动id"
,
example
=
"1"
),
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"storeId"
,
value
=
"店铺id"
,
example
=
"0"
),
})
public
ResponseDto
<
Boolean
>
zhengzaiDelStore
(
@RequestParam
(
value
=
"marketId"
)
@Valid
String
marketId
,
@RequestParam
(
value
=
"storeId"
)
@Valid
String
storeId
)
{
return
goblinZhengzaiMarketService
.
zhengzaiDelStore
(
marketId
,
storeId
);
}
// @PostMapping("zhengzai/store/update")
// @ApiOperation("活动详情-正在下单-修改店铺")
// @ApiResponse(code = 200, message = "接口返回对象参数")
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/java/com/liquidnet/client/admin/web/controller/zhengzai/kylin/KylinRecommendActiveController.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
client
.
admin
.
web
.
controller
.
zhengzai
.
kylin
;
import
com.liquidnet.client.admin.common.core.controller.BaseController
;
import
com.liquidnet.client.admin.common.core.domain.AjaxResult
;
import
com.liquidnet.client.admin.common.core.page.TableDataInfo
;
import
com.liquidnet.client.admin.zhengzai.kylin.service.impl.KylinRecommendActiveRelationServiceImpl
;
import
com.liquidnet.client.admin.zhengzai.kylin.service.impl.KylinRecommendActiveServiceImpl
;
import
com.liquidnet.service.kylin.dto.param.KylinRecommendActiveParam
;
import
com.liquidnet.service.kylin.dto.param.KylinRecommendActiveRelationParam
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActive
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActiveRelation
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.ArrayList
;
import
java.util.List
;
/**
* <p>
* 推荐活动表 前端控制器
* </p>
*/
@Api
(
tags
=
"推荐活动controller"
)
@RestController
@RequestMapping
(
"/kylin-recommend-active"
)
public
class
KylinRecommendActiveController
extends
BaseController
{
@Autowired
private
KylinRecommendActiveServiceImpl
kylinRecommendActiveService
;
@Autowired
private
KylinRecommendActiveRelationServiceImpl
kylinRecommendActiveRelationService
;
@PostMapping
(
"addKylinRecommendActive"
)
@ApiOperation
(
value
=
"增加活动"
)
@ResponseBody
public
AjaxResult
addKylinRecommendActive
(
@RequestBody
KylinRecommendActiveParam
kylinRecommendActiveParam
)
{
KylinRecommendActive
kylinRecommendActive
=
new
KylinRecommendActive
();
BeanUtils
.
copyProperties
(
kylinRecommendActiveParam
,
kylinRecommendActive
);
if
(
kylinRecommendActiveService
.
validateTime
(
kylinRecommendActive
)
==
0
)
{
List
<
KylinRecommendActiveRelation
>
list
=
new
ArrayList
<
KylinRecommendActiveRelation
>();
if
(
kylinRecommendActiveParam
.
getList
()
!=
null
)
{
kylinRecommendActiveParam
.
getList
().
forEach
(
r
->
{
KylinRecommendActiveRelation
kylinRecommendActiveRelation
=
new
KylinRecommendActiveRelation
();
BeanUtils
.
copyProperties
(
r
,
kylinRecommendActiveRelation
);
list
.
add
(
kylinRecommendActiveRelation
);
});
}
kylinRecommendActiveService
.
addKylinRecommendActive
(
kylinRecommendActive
,
list
);
return
AjaxResult
.
success
(
"操作成功"
,
""
);
}
else
{
return
AjaxResult
.
error
(
"该时间段已经重复,请重新选择"
);
}
}
@PostMapping
(
"addKylinRecommendActiveRelation"
)
@ApiOperation
(
value
=
"增加活动推荐"
)
@ResponseBody
public
AjaxResult
addKylinRecommendActiveRelation
(
@RequestBody
KylinRecommendActiveRelationParam
kylinRecommendActiveParam
)
{
KylinRecommendActiveRelation
kylinRecommendActiveRelation
=
new
KylinRecommendActiveRelation
();
BeanUtils
.
copyProperties
(
kylinRecommendActiveParam
,
kylinRecommendActiveRelation
);
kylinRecommendActiveRelationService
.
addKylinRecommendActiveRelation
(
kylinRecommendActiveRelation
);
return
AjaxResult
.
success
(
"操作成功"
,
""
);
}
@PostMapping
(
"addOrUpdateListKylinRecommendActiveRelation"
)
@ApiOperation
(
value
=
"增加或者修改活动推荐List"
)
@ResponseBody
public
AjaxResult
addOrUpdateListKylinRecommendActiveRelation
(
@RequestBody
List
<
KylinRecommendActiveRelationParam
>
kylinRecommendActiveParam
)
{
if
(
kylinRecommendActiveParam
.
size
()>
20
){
return
AjaxResult
.
error
(
"操作失败"
,
"推荐活动不允许超过20个!!!"
);
}
List
<
KylinRecommendActiveRelation
>
list
=
new
ArrayList
<>();
for
(
KylinRecommendActiveRelationParam
ky:
kylinRecommendActiveParam
){
KylinRecommendActiveRelation
kylinRecommendActiveRelation
=
new
KylinRecommendActiveRelation
();
BeanUtils
.
copyProperties
(
ky
,
kylinRecommendActiveRelation
);
list
.
add
(
kylinRecommendActiveRelation
);
}
kylinRecommendActiveRelationService
.
addListKylinRecommendActiveRelation
(
list
);
return
AjaxResult
.
success
(
"操作成功"
,
""
);
}
@PostMapping
(
"delKylinRecommendActiveRelation"
)
@ApiOperation
(
value
=
"删除活动推荐(传入互动推荐里面的mid)"
)
@ResponseBody
public
AjaxResult
delKylinRecommendActiveRelation
(
@RequestBody
KylinRecommendActiveRelation
kylinRecommendActiveRelation
)
{
kylinRecommendActiveRelationService
.
deleteKylinRecommendActiveRelation
(
kylinRecommendActiveRelation
);
return
AjaxResult
.
success
(
"操作成功"
,
""
);
}
@PostMapping
(
"updateKylinRecommendActive"
)
@ApiOperation
(
value
=
"修改活动"
)
@ResponseBody
public
AjaxResult
updateKylinRecommendActive
(
@RequestBody
KylinRecommendActiveParam
kylinRecommendActiveParam
)
{
KylinRecommendActive
kylinRecommendActive
=
new
KylinRecommendActive
();
BeanUtils
.
copyProperties
(
kylinRecommendActiveParam
,
kylinRecommendActive
);
if
(
kylinRecommendActiveService
.
validateTime
(
kylinRecommendActive
)
==
0
)
{
kylinRecommendActiveService
.
updateKylinRecommendActive
(
kylinRecommendActive
);
return
AjaxResult
.
success
(
"操作成功"
,
""
);
}
else
{
return
AjaxResult
.
error
(
"该时间段已经重复,请重新选择"
);
}
}
@PostMapping
(
"pageActive"
)
@ApiOperation
(
value
=
"分页活动"
)
@ResponseBody
public
TableDataInfo
pageActive
(
@RequestParam
(
name
=
"pageSize"
,
required
=
true
)
int
pageSize
,
@RequestParam
(
name
=
"pageNum"
,
required
=
true
)
int
pageNum
)
{
//return AjaxResult.success(kylinAcitveService.pageKylinAcitve(pageSize,pageNum));
return
getDataTable
(
kylinRecommendActiveService
.
pageKylinAcitve
(
pageSize
,
pageNum
));
}
@PostMapping
(
"getActiveById"
)
@ApiOperation
(
value
=
"通过id获得活动"
)
@ResponseBody
public
KylinRecommendActive
getActiveById
(
@RequestParam
(
name
=
"mid"
,
required
=
true
)
int
mid
)
{
return
kylinRecommendActiveService
.
getKylinRecommendActiveById
(
mid
);
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/static/js/searchSelect.js
0 → 100644
View file @
75cd17ba
/*
一个模糊搜索组件
基于jq,还算好看,使用简单,有点有趣
用法非常简单,你甚至不需要引入css
使用方法:引入然后new一下,在标签上写placeholder和name就和在input上写这两个属性的性质一样。是你需要的效果
<div id="search" placeholder="请搜索" name="searchSelect"></div>
const search = new searchSelect('#search',[{id:1,value:'许嵩'},{id:2,value:'周杰伦'},{id:3,value:'林俊杰'}])
类似这样子,第一个值是元素名,第二个是一个模糊搜索用的数组,它还有第三个参数是个回调函数,这个是一个选填项目,
这个回调函数会在触发input事件被执行
所以这个回调你想写异步搜索也许有用
const search = new searchSelect('#search',[],function(){
$..ajax........
})
update方法,用于更新下拉列表的数据,使用方法
search.update([{id:1,value:'乌鸦'},{id:2,value:'冰柜'}])
search方法,一般配合回调函数用及update方法做异步请求用,
传入true会一直显示搜索中的字样,如果关掉它可以传入false,调用update也一样会清空搜索状态
search.search(true)
disabled方法,实现disabled效果,传入true开启传入false关闭
search.disabled(true)
empty方法,帮你清空所有内容
search.empty()
assignment方法,你也许有类似编辑页需要直接给搜索框赋值的操作,可以这样做
search.assignment({id:3,value:'苏格拉没有底'})
会帮你选中下拉框中对应的值,没有就帮你加上且自动选中
你也可以直接传个id
search.assignment(1)
这样做会帮你选中对应id的下拉框但是无法实现找不到就自动添加
大清都亡了所以抛弃ie
*/
(
function
(){
$
(
'head'
).
append
(
`
<style>
.searchSelect_box {
position: relative;
}
.searchSelect_box>.searchSelect {
background-color: #fff;
border-radius: 4px;
border: 1px solid #dcdee2;
transition: all .2s ease-in-out;
position: relative;
width: 100%;
padding:5px;
}
.searchSelect_box>.searchSelect:focus {
border-color: #57a3f3 !important;
outline: 0;
box-shadow: 0 0 0 2px rgb(45 140 240 / 20%) !important;
}
.searchSelect_box>.drawer {
width: 100%;
max-height: 200px;
overflow-x: hidden;
overflow-y: auto;
margin: 5px 0;
padding: 5px 0;
background-color: #fff;
box-sizing: border-box;
border-radius: 4px;
box-shadow: 0 1px 6px rgb(0 0 0 / 20%);
position: absolute;
z-index: 900;
left: 0;
top: 30px;
display:none;
}
.searchSelect_box>.drawer>li {
margin: 0;
line-height: normal;
padding: 7px 16px;
clear: both;
color: #515a6e;
font-size: 14px!important;
white-space: nowrap;
list-style: none;
cursor: pointer;
transition: background .2s ease-in-out;
overflow:hidden;
text-overflow:ellipsis;
white-space:nowrap;
}
.searchSelect_box>.drawer>.none {
padding: 0 16px;
text-align: center;
color: #ccc;
}
.searchSelect_box>.drawer>li:hover {
background-color: rgba(0, 0, 0, .1);
}
.searchSelect_box>.drawer>.active {
color: #57a3f3;
}
/*定义滚动条高宽及背景
高宽分别对应横竖滚动条的尺寸*/
.searchSelect_box>.drawer::-webkit-scrollbar {
width: 5px;
height: 5px;
background-color: #fff;
}
/*定义滚动条轨道
内阴影+圆角*/
.searchSelect_box>.drawer::-webkit-scrollbar-track {
-webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.3);
border-radius: 2px;
background-color: #fff;
}
/*定义滑块
内阴影+圆角*/
.searchSelect_box>.drawer::-webkit-scrollbar-thumb {
border-radius: 2px;
-webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.3);
background-color: #ccc;
}
</style>
`
)
})()
class
searchSelect
{
constructor
(
dom
,
list
,
fn
)
{
this
.
list
=
[]
this
.
dom
=
dom
this
.
params
=
{}
this
.
loading
=
false
this
.
fn
=
fn
if
(
list
instanceof
Array
)
{
this
.
list
=
list
}
$
(
this
.
dom
).
addClass
(
'searchSelect_box'
)
let
name
=
$
(
this
.
dom
).
attr
(
'name'
);
let
placeholder
=
$
(
this
.
dom
).
attr
(
'placeholder'
)
$
(
this
.
dom
).
append
(
'<input placeholder="'
+
(
placeholder
||
''
)
+
'" type="text" name="'
+
(
name
||
''
)
+
'" class="searchSelect">'
)
$
(
this
.
dom
).
append
(
'<ul class="drawer"></ul>'
)
this
.
getList
()
let
that
=
this
$
(
this
.
dom
).
children
(
'.searchSelect'
).
on
(
'input'
,
function
(){
let
val
=
$
(
that
.
dom
).
children
(
'.searchSelect'
).
val
().
trim
()
$
(
that
.
dom
).
children
(
'.searchSelect'
).
val
(
val
)
if
(
!
(
val
===
$
(
that
.
dom
).
children
(
'.drawer'
).
find
(
'.active'
).
text
()))
{
$
(
that
.
dom
).
children
(
'.searchSelect'
).
attr
(
'data-id'
,
''
)
$
(
that
.
dom
).
children
(
'.drawer'
).
find
(
'.active'
).
removeClass
(
'active'
)
that
.
params
=
{}
fn
&&
fn
(
$
(
this
).
val
())
}
$
(
that
.
dom
).
children
(
'.drawer'
).
stop
(
true
,
true
).
fadeIn
()
if
(
!
that
.
loading
)
{
that
.
getList
(
val
)
}
// that.list.filter((item)=>item.value.inc)
})
$
(
this
.
dom
).
children
(
'.searchSelect'
).
on
(
'focus'
,
function
(){
$
(
that
.
dom
).
children
(
'.drawer'
).
stop
(
true
,
true
).
fadeIn
()
})
$
(
this
.
dom
).
children
(
'.searchSelect'
).
on
(
'blur'
,
function
(){
setTimeout
(()
=>
{
if
(
!
(
$
(
that
.
dom
).
children
(
'.searchSelect'
).
attr
(
'data-id'
)))
{
$
(
that
.
dom
).
children
(
'.searchSelect'
).
val
(
''
)
}
$
(
that
.
dom
).
children
(
'.drawer'
).
stop
(
true
,
true
).
fadeOut
()
},
100
)
})
}
// 模糊搜索方法
getList
(
str
)
{
// let list = arr || JSON.parse(JSON.stringify(this.list))
if
(
this
.
list
.
length
<
1
)
{
$
(
this
.
dom
).
children
(
'.drawer'
).
html
(
'<li class="none">暂无其他数据</li>'
)
return
this
}
// let domlist = str?this.list.filter(item => item.value.includes(str)):JSON.parse(JSON.stringify(this.list))
let
domlist
=
str
?
this
.
list
:
JSON
.
parse
(
JSON
.
stringify
(
this
.
list
))
if
(
domlist
.
length
<
1
)
{
$
(
this
.
dom
).
children
(
'.drawer'
).
html
(
'<li class="none">暂无其他数据</li>'
)
return
this
}
let
listDom
=
''
$
(
this
.
dom
).
children
(
'.drawer'
).
html
(
''
)
domlist
.
forEach
(
item
=>
{
let
isActive
=
$
(
this
.
dom
).
children
(
'.searchSelect'
).
attr
(
'data-id'
)
==
item
.
id
listDom
+=
'<li class="item '
+
(
isActive
?
'active'
:
''
)
+
' " data-id="'
+
item
.
id
+
'">'
+
item
.
value
+
'</li>'
if
(
isActive
)
{
$
(
this
.
dom
).
children
(
'.searchSelect'
).
val
(
item
.
value
)
}
})
$
(
this
.
dom
).
children
(
'.drawer'
).
append
(
listDom
)
let
dom
=
this
.
dom
let
that
=
this
$
(
this
.
dom
).
children
(
'.drawer'
).
children
(
'.item'
).
on
(
'click'
,
function
(){
if
(
$
(
this
).
hasClass
(
'active'
))
return
$
(
dom
).
children
(
'.searchSelect'
).
attr
(
'data-id'
,
$
(
this
).
attr
(
'data-id'
))
$
(
dom
).
children
(
'.searchSelect'
).
val
(
$
(
this
).
text
())
that
.
params
.
id
=
$
(
this
).
attr
(
'data-id'
)
that
.
params
.
value
=
$
(
this
).
text
()
$
(
this
).
addClass
(
'active'
).
siblings
().
removeClass
(
'active'
)
setTimeout
(()
=>
{
$
(
dom
).
children
(
'.drawer'
).
stop
(
true
,
true
).
fadeOut
()
that
.
getList
(
$
(
this
).
text
())
},
300
)
})
return
this
}
// 更新数据 传入一个数组,更新下拉框内容
update
(
list
)
{
if
(
!
(
list
instanceof
Array
))
{
console
.
error
(
'请传入一个数组!'
)
return
this
}
this
.
list
=
list
this
.
getList
(
$
(
this
.
dom
).
children
(
'.searchSelect'
).
val
())
this
.
loading
=
false
return
this
}
// 搜索方法 ,传入true会显示搜索中的loading,一般在input的钩子中触发ajax请求模糊搜索数据可用
search
(
bol
)
{
bol
&&
$
(
this
.
dom
).
children
(
'.drawer'
).
html
(
'<li class="none">正在搜索....</li>'
)
bol
&&
(
this
.
loading
=
true
)
!
bol
&&
this
.
getList
()
!
bol
&&
(
this
.
loading
=
false
)
return
this
}
// 清空所有内容的方法
empty
()
{
$
(
this
.
dom
).
children
(
'.drawer'
).
html
(
'<li class="none">暂无其他数据</li>'
)
$
(
this
.
dom
).
children
(
'.searchSelect'
).
val
(
''
)
return
this
}
isFunction
(
fn
)
{
return
Object
.
prototype
.
toString
.
call
(
fn
)
===
'[object Function]'
;
}
// disabled选项
disabled
(
bol
)
{
bol
&&
$
(
this
.
dom
).
children
(
'.searchSelect'
).
prop
(
'disabled'
,
true
)
!
bol
&&
$
(
this
.
dom
).
children
(
'.searchSelect'
).
prop
(
'disabled'
,
false
)
return
this
}
// 你也许需要强行赋值,用它
assignment
(
obj
)
{
if
(
obj
instanceof
Object
&&
obj
.
id
)
{
for
(
let
i
=
0
;
i
<
this
.
list
.
length
;
i
++
)
{
if
(
this
.
list
[
i
].
id
==
obj
.
id
)
{
$
(
this
.
dom
).
children
(
'.drawer'
).
html
(
'<li class="item active" data-id="'
+
obj
.
id
+
'">'
+
obj
.
value
+
'</li>'
)
$
(
this
.
dom
).
children
(
'.searchSelect'
).
val
(
obj
.
value
)
$
(
this
.
dom
).
children
(
'.searchSelect'
).
attr
(
'data-id'
,
obj
).
id
this
.
fn
()
return
this
}
}
this
.
list
.
push
(
obj
)
$
(
this
.
dom
).
children
(
'.drawer'
).
html
(
'<li class="item active" data-id="'
+
obj
.
id
+
'">'
+
obj
.
value
+
'</li>'
)
$
(
this
.
dom
).
children
(
'.searchSelect'
).
val
(
obj
.
value
)
$
(
this
.
dom
).
children
(
'.searchSelect'
).
attr
(
'data-id'
,
obj
.
id
)
this
.
params
.
id
=
obj
.
id
this
.
params
.
value
=
obj
.
value
}
else
if
(
typeof
obj
===
'string'
||
typeof
obj
===
'number'
){
this
.
list
.
forEach
(
item
=>
{
if
(
item
.
id
==
obj
)
{
$
(
this
.
dom
+
' .item[data-id="'
+
obj
+
'"]'
).
addClass
(
'active'
)
$
(
this
.
dom
).
children
(
'.searchSelect'
).
val
(
$
(
this
.
dom
+
' .item[data-id="'
+
obj
+
'"]'
).
text
())
$
(
this
.
dom
).
children
(
'.searchSelect'
).
attr
(
'data-id'
,
obj
)
this
.
params
.
id
=
item
.
id
this
.
params
.
value
=
$
(
this
.
dom
+
' .item[data-id="'
+
obj
+
'"]'
).
text
()
}
})
}
this
.
fn
()
return
this
}
}
\ No newline at end of file
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/adam/member/info.html
View file @
75cd17ba
...
...
@@ -325,7 +325,7 @@
</div>
</ul>
</div>
<div
class=
"member-coupes"
onclick=
"addCoupes(this)"
>
+添加券
<br/>
*全场券不需要重复添加
</div>
<div
class=
"member-coupes"
onclick=
"addCoupes(this)"
>
+添加券
<br/>
*全场券不需要重复添加
,需要先保存再添加券
</div>
<div
class=
"go-member-item"
onclick=
"addColumn(this)"
>
继续添加
</div>
<div
class=
"go-member-item save_mermber"
onclick=
"saveColumn(this, 1)"
>
保存
</div>
</div>
...
...
@@ -381,7 +381,7 @@
</div>
</ul>
</div>
<div
class=
"member-coupes"
onclick=
"addCoupes(this)"
>
+添加券
<br/>
*全场券不需要重复添
加
</div>
<div
class=
"member-coupes"
onclick=
"addCoupes(this)"
>
+添加券
<br/>
*全场券不需要重复添
,需要先保存再添加券
</div>
<div
class=
"go-member-item"
onclick=
"addColumn(this)"
>
继续添加
</div>
<div
class=
"go-member-item save_mermber"
onclick=
"saveColumn(this, 1)"
>
保存
</div>
<div
class=
"go-member-item del_mermber"
onclick=
"saveColumn(this, 2)"
>
删除
</div>
...
...
@@ -707,6 +707,7 @@
$
(
'.alltrack_limit'
).
show
();
$
(
'.alltrack_radio'
).
hide
();
}
else
{
$
(
'.alltrack_radio'
).
show
();
$
(
'.alltrack'
).
show
();
$
(
'.alltrack_limit'
).
hide
();
if
(
typeRadio
==
2
)
{
...
...
@@ -836,9 +837,11 @@
function
addCoupes
(
obj
)
{
var
addItemIndex
=
$
(
'.member-coupes'
).
index
(
$
(
obj
));
console
.
log
(
addItemIndex
)
$
(
'.parentsIndex'
).
val
(
addItemIndex
);
$
(
'.pop_oper'
).
val
(
1
);
$
(
'.coupe_pop'
).
show
();
if
(
addItemIndex
<
memberRightsList
.
length
){
$
(
'.parentsIndex'
).
val
(
addItemIndex
);
$
(
'.pop_oper'
).
val
(
1
);
$
(
'.coupe_pop'
).
show
();
}
}
// 编辑券
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/goblin/gago/gago.html
View file @
75cd17ba
...
...
@@ -70,7 +70,7 @@
$
(
'#remoteSearch'
).
remoteSearchPerformance
({
ajax
:
{
url
:
"/goblin/common/sku?type=1"
,
url
:
"/goblin/common/sku?type=1
&shelvesStatus=3
"
,
type
:
"get"
},
chose
:
function
(
text
,
val
)
{
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/store/placingOrder/addNewActivity.html
View file @
75cd17ba
...
...
@@ -3,9 +3,13 @@
<head>
<th:block
th:include=
"include :: header('新增活动')"
/>
<th:block
th:include=
"include :: select2-css"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-css"
/>
<link
rel=
"stylesheet"
href=
""
>
<style>
input
{
height
:
34
PX
;
line-height
:
34
PX
;
}
.required
{
font-style
:
normal
;
color
:
red
;
...
...
@@ -56,6 +60,18 @@
line-height
:
45px
;
padding-left
:
60px
;
}
.form-control
,
.layui-input
{
height
:
34
PX
;
line-height
:
34
PX
;
}
.kv-upload-progress
{
display
:
none
!important
;
}
.ibox-content
.imgBox
{
max-width
:
350px
;
max-height
:
180px
;
}
</style>
</head>
<body>
...
...
@@ -81,6 +97,22 @@
<!-- /btn-group 11 -->
</div>
</div>
<div
class=
"basis_data ibox-content"
style=
"border: none;display: flex;"
>
<span>
<em
class=
"required"
>
*
</em>
演出图片:
</span>
<div>
<img
id=
"viewImg"
class=
"imgBox"
src=
""
alt=
""
>
<div
class=
"form-group"
>
<div
class=
"file-loading"
>
<input
id=
"fileinput"
type=
"file"
name=
"file"
data-browse-on-zone-click=
"true"
data-theme=
"fas"
>
</div>
<span
style=
"color: #ccc; font-size: 12px;"
>
适配图片尺寸:660*344
</span>
</div>
</div>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
...
...
@@ -105,7 +137,7 @@
</span>
<div
class=
"activityStore"
>
<button
class=
"btn btn-primary"
onclick=
"addItem()"
style=
"margin-bottom: 12px;"
>
新增
</button>
<div
class=
"activityStore_item
"
id=
"activityStore_item
"
data-newTag=
"1"
>
<div
class=
"activityStore_item
activityStore_item_first"
id=
"activityStore_item1
"
data-newTag=
"1"
>
<div
class=
"input-group"
style=
"margin-right: 12px;"
>
<input
type=
"text"
class=
"form-control storeList item1"
placeholder=
"搜索店铺名称"
>
<div
class=
"input-group-btn"
>
...
...
@@ -114,7 +146,7 @@
</div>
</div>
<input
type=
"text"
class=
"layui-input form-control timeSp"
id=
"startTime"
autocomplete=
"off"
placeholder=
"配置活动时间"
>
<button
type=
"button"
class=
"btn btn-danger"
onclick=
"delItem('1')"
>
删除
</button>
</div>
</div>
...
...
@@ -126,6 +158,7 @@
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-js"
/>
<th:block
th:include=
"include :: bootstrap-suggest-js"
/>
</body>
<script
th:inline=
"javascript"
>
...
...
@@ -133,7 +166,7 @@
var
prefix2
=
ctx
+
"local"
;
let
marketId
=
''
;
let
editDatas
=
0
;
let
performanceImg
=
''
;
var
platformUrl
=
[[
$
{
platformUrl
}]]
;
$
(
function
()
{
let
name
=
'id'
;
var
reg
=
new
RegExp
(
"(^|&)"
+
name
+
"=([^&]*)(&|$)"
);
...
...
@@ -153,8 +186,8 @@
common
();
if
(
r
)
{
marketId
=
unescape
(
r
[
2
]);
$
(
".editDisabled"
).
attr
(
'disabled'
,
true
);
$
(
".editshow"
).
hide
()
//
$(".editDisabled").attr('disabled', true);
//
$(".editshow").hide()
let
data
=
{
marketId
}
...
...
@@ -165,17 +198,43 @@
let
{
data
}
=
res
[
1
];
editDatas
=
data
.
length
;
$
(
"#selectShow"
).
val
(
basisData
.
data
.
name
);
$
(
"#selectShow"
).
attr
(
'data-id'
,
basisData
.
data
.
performanceId
);
$
(
"#viewImg"
).
attr
(
'src'
,
basisData
.
data
.
performanceImg
);
$
(
"#startTime"
).
val
(
basisData
.
data
.
startTime
);
$
(
"#endTime"
).
val
(
basisData
.
data
.
endTime
);
$
(
".content_item"
).
show
();
$
(
".add_footer"
).
show
();
$
(
"
#activityStore_item
"
).
remove
();
$
(
"
.activityStore_item_first
"
).
remove
();
data
.
forEach
((
item
,
index
)
=>
{
addItem
(
item
)
})
})
}
$
(
"#fileinput"
).
fileinput
({
'theme'
:
'explorer-fas'
,
// 'uploadUrl': "https://devplatform.zhengzai.tv/platform/basicServices/alOss/upload",
'uploadUrl'
:
platformUrl
+
"/platform/basicServices/alOss/upload"
,
"uploadExtraData"
:
{
"pathName"
:
"banner"
,
"buckType"
:
1
},
autoReplace
:
true
,
showCaption
:
false
,
showPreview
:
false
,
showRemove
:
false
,
showUpload
:
false
,
showCancel
:
false
,
showClose
:
false
,
autoReplace
:
true
,
dropZoneTitle
:
"请上传文件"
,
maxFileCount
:
1
}).
on
(
"filebatchselected"
,
function
(
event
,
files
)
{
//默认上传
$
(
this
).
fileinput
(
"upload"
);
})
.
on
(
"fileuploaded"
,
function
(
event
,
data
)
{
//上传回调事件
let
showPicture
=
'https://img.zhengzai.tv/'
+
data
.
response
.
data
.
ossPath
;
$
(
"#viewImg"
).
attr
(
'src'
,
showPicture
)
})
})
function
common
()
{
...
...
@@ -195,8 +254,6 @@
return
json
;
}
}).
on
(
'onSetSelectValue'
,
function
(
e
,
result
,
selectedRawData
)
{
console
.
log
(
e
,
result
,
selectedRawData
)
performanceImg
=
selectedRawData
.
imgPoster
;
});
$
(
".storeList"
).
bsSuggest
({
idField
:
'storeId'
,
...
...
@@ -221,7 +278,7 @@
count
++
;
let
body
=
''
;
if
(
item
)
{
body
+=
`<div class="activityStore_item" data-newTag="">
body
+=
`<div class="activityStore_item"
id="activityStore_item
${
count
}
"
data-newTag="">
<div class="input-group" style="margin-right: 12px;">
<input type="text" class="form-control storeList item
${
count
}
itemDisabled" data-id="
${
item
.
storeId
}
" value="
${
item
.
storeName
}
" placeholder="搜索店铺名称">
<div class="input-group-btn">
...
...
@@ -230,9 +287,11 @@
</div>
</div>
<input type="text" class="layui-input form-control timeSp startTime
${
count
}
itemDisabled" id="startTime" value="
${
item
.
showTime
}
" autocomplete="off" placeholder="配置活动时间">
<button type="button" class="btn btn-danger" onclick="delItem('
${
count
}
')">删除</button>
</div>`
}
else
{
body
+=
`<div class="activityStore_item" data-newTag="1">
body
+=
`<div class="activityStore_item"
id="activityStore_item
${
count
}
"
data-newTag="1">
<div class="input-group" style="margin-right: 12px;">
<input type="text" class="form-control storeList item
${
count
}
" placeholder="搜索店铺名称">
<div class="input-group-btn">
...
...
@@ -241,11 +300,12 @@
</div>
</div>
<input type="text" class="layui-input form-control timeSp startTime
${
count
}
" id="startTime" autocomplete="off" placeholder="配置活动时间">
<button type="button" class="btn btn-danger" onclick="delItem('
${
count
}
')">删除</button>
</div>`
}
$
(
".activityStore"
).
append
(
body
)
common
()
$
(
".itemDisabled"
).
attr
(
'disabled'
,
true
);
//
$(".itemDisabled").attr('disabled', true);
layui
.
use
(
'laydate'
,
function
(){
var
laydate
=
layui
.
laydate
;
//执行一个laydate实例
...
...
@@ -255,25 +315,63 @@
});
});
}
function
delItem
(
num
)
{
let
domData
=
$
(
".activityStore_item"
);
let
arr
=
[];
Array
.
prototype
.
forEach
.
call
(
domData
,
function
(
item
,
index
){
if
(
!
item
.
getAttribute
(
'data-id'
))
{
arr
.
push
(
item
)
}
})
if
(
arr
.
length
<
2
)
return
layer
.
msg
(
'最少保留一个店铺!'
)
$
.
modal
.
loading
(
"请稍等..."
);
// console.log(domData.length)
console
.
log
(
document
.
querySelector
(
'#activityStore_item'
+
num
+
''
).
querySelector
(
'.storeList'
).
getAttribute
(
'data-id'
),
'????'
)
let
storeId
=
document
.
querySelector
(
'#activityStore_item'
+
num
+
''
).
querySelector
(
'.storeList'
).
getAttribute
(
'data-id'
);
if
(
!
document
.
querySelector
(
'#activityStore_item'
+
num
+
''
).
getAttribute
(
'data-newTag'
))
{
let
data
=
{};
data
.
marketId
=
marketId
;
data
.
storeId
=
storeId
;
console
.
log
(
data
,
'dsasadasd'
)
promiseMethods
(
'/goblin/marketing/zhengzai/store/del'
,
'post'
,
data
).
then
(
res
=>
{
$
.
modal
.
closeLoading
();
if
(
res
.
code
==
0
)
{
$
(
'#activityStore_item'
+
num
+
''
).
remove
();
layer
.
msg
(
'修改活动成功,请配置活动对应店铺!'
)
}
else
{
layer
.
msg
(
res
.
message
)
}
})
}
else
{
$
(
'#activityStore_item'
+
num
+
''
).
remove
();
$
.
modal
.
closeLoading
();
};
}
function
nextBtn
(
params
)
{
if
(
!
$
(
"#selectShow"
).
attr
(
'data-id'
))
{
return
layer
.
msg
(
'请选择演出进行创建!'
)
}
if
(
!
$
(
"#viewImg"
).
attr
(
'src'
))
{
return
layer
.
msg
(
'请上传演出图片!'
)
}
if
(
!
$
(
"#endTime"
).
val
()
||
!
$
(
"#startTime"
).
val
())
{
return
layer
.
msg
(
'请
输入必填项
!'
)
return
layer
.
msg
(
'请
将有效期输入完整
!'
)
}
let
data
=
{
endTime
:
$
(
"#endTime"
).
val
(),
startTime
:
$
(
"#startTime"
).
val
(),
name
:
$
(
"#selectShow"
).
val
(),
performanceId
:
$
(
"#selectShow"
).
attr
(
'data-id'
),
performanceImg
performanceImg
:
$
(
"#viewImg"
).
attr
(
'src'
)
}
// endTime
if
(
marketId
)
{
data
.
marketId
=
marketId
;
promiseMethods
(
'/goblin/marketing/zhengzai/change'
,
'post'
,
data
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
layer
.
msg
(
'修改活动成功,请配置活动对应店铺!'
)
}
else
{
layer
.
msg
(
res
.
message
)
}
})
...
...
@@ -284,6 +382,8 @@
layer
.
msg
(
'添加活动成功,请配置活动对应店铺!'
)
$
(
".content_item"
).
show
();
$
(
".add_footer"
).
show
();
}
else
{
layer
.
msg
(
res
.
message
)
}
})
}
...
...
@@ -296,7 +396,9 @@
let
domData
=
$
(
".activityStore_item"
);
let
flag
=
false
;
Array
.
prototype
.
forEach
.
call
(
domData
,
function
(
item
,
index
){
console
.
log
(
item
)
obj
[
'marketId'
]
=
marketId
;
obj
[
'showTime'
]
=
item
.
querySelector
(
'.timeSp'
).
value
;
obj
[
'storeId'
]
=
item
.
querySelector
(
'.storeList'
).
getAttribute
(
'data-id'
);
if
(
!
item
.
querySelector
(
'.timeSp'
).
value
||
!
item
.
querySelector
(
'.storeList'
).
getAttribute
(
'data-id'
))
{
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/sweet/affiliatedActivity/add.html
0 → 100644
View file @
75cd17ba
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
>
<head>
<th:block
th:include=
"include :: header('增加关联活动')"
/>
<th:block
th:include=
"include :: select2-css"
/>
<link
rel=
"stylesheet"
href=
""
>
<style>
body
.layui-layer-btn
{
display
:
none
!important
;
}
#layui-layer1
{
z-index
:
1001
!important
;
}
#layui-layer-shade1
{
z-index
:
1000
!important
;
}
.required
{
font-style
:
normal
;
color
:
red
;
}
.content_item
{
padding
:
20px
;
}
/* .content_item .content_title {
display: flex;
} */
.content_item
.content_title
h3
span
{
display
:
inline-block
;
width
:
4px
;
height
:
18px
;
background
:
skyblue
;
margin-right
:
6px
;
vertical-align
:
top
;
}
.basis_data
{
display
:
flex
;
font-size
:
14px
;
padding
:
0
20px
;
margin-top
:
20px
;
/* align-items: center; */
}
.basis_data
span
{
width
:
100px
;
text-align
:
right
;
}
#startTime
,
#endTime
{
width
:
272px
;
margin-right
:
10px
;
}
.storeList
,
#selectShow
,
.dropdown-menu
,
.input-group
{
width
:
320px
!important
;
}
.activityStore_item
{
display
:
flex
;
margin-bottom
:
12px
;
}
#basis_data
{
align-items
:
flex-start
;
}
.add_footer
{
width
:
100%
;
height
:
45px
;
line-height
:
45px
;
padding-left
:
60px
;
}
/* ---------------------------------------- */
.sortable-list
{
width
:
700px
;
}
.sortable-list
li
{
width
:
100%
;
}
.sortable-list
li
.addAvatarItem
{
width
:
100%
;
display
:
flex
;
justify-content
:
flex-start
;
}
#addClassify2
,
#detailPro
{
width
:
450px
;
padding-top
:
20px
;
}
.input-group-wrapper
{
padding
:
20px
;
border-radius
:
8px
;
border
:
1px
solid
#cccccc
;
}
.addAvatarItem
.selectClassifyOne
{
width
:
100%
;
display
:
flex
;
margin-right
:
15px
;
}
.addAvatarItem
.selectClassifyOne
.span-label
{
width
:
108px
;
padding-top
:
5px
;
}
.picker
{
display
:
flex
;
justify-content
:
flex-start
;
}
#addClassify
.addAvatarItem
label
{
display
:
flex
;
margin-right
:
20px
;
align-items
:
center
;
}
#addClassify
.addAvatarItem
label
input
{
margin
:
0
;
margin-right
:
2px
;
}
#detailPro
.detail_inner
{
margin-bottom
:
20px
;
}
#detailPro
.detail_title
{
margin-top
:
50px
;
font-weight
:
bold
;
font-size
:
16px
;
}
.bottomBtn
{
text-align
:
left
;
padding
:
30px
15px
12px
;
}
.layui-layer-shade
{
opacity
:
30%
;
}
.item
div
{
display
:
flex
;
}
.item
div
a
{
margin-left
:
12px
;
}
/* 星星 */
.required-group-name
{
color
:
red
;
font-size
:
20px
;
position
:
relative
;
top
:
6px
;
}
.groupName
{
border
:
1px
solid
#dfdfdf
;
}
.required-province
{
color
:
red
;
display
:
inline-block
;
margin-right
:
3px
;
position
:
relative
;
top
:
6px
;
font-size
:
20px
;
}
/* 必填红色文字 */
.required-group-text
{
height
:
20px
;
color
:
red
;
}
.required-province-text
{
color
:
red
;
height
:
20px
;
}
.search-wrapper
{
width
:
100%
;
}
</style>
</head>
<body>
<div>
<div
class=
"content_item"
>
<div
class=
"content_title"
>
<h3><span></span>
增加关联活动
</h3>
</div>
<!-- row -->
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
活动名称:
</span>
<div
class=
"input-group"
style=
"width: 300px;"
>
<input
type=
"text"
class=
"form-control"
id=
"activeName"
placeholder=
""
>
</div>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
关联类型:
</span>
<div
class=
"input-group"
style=
"width: 300px;"
>
<select
name=
"activeType"
id=
"activeType"
class=
"form-control m-b"
>
<option
value=
"1"
>
NFT
</option>
<option
value=
"2"
>
组合购
</option>
<option
value=
"3"
>
演出
</option>
<option
value=
"4"
>
商品
</option>
</select>
</div>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
关联名称:
</span>
<div
class=
"input-group"
style=
"width: 300px;"
>
<div
class=
"search-wrapper"
style=
"margin-bottom: 15px;"
>
<!-- 关联 模糊搜索 回显的话添加id再赋值 -->
<div
id=
"search"
placeholder=
"请搜索"
name=
"seaarchSelect"
></div>
</div>
</div>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
状态:
</span>
<div
class=
"input-group"
style=
"width: 300px;"
>
<select
name=
"status"
id=
"status"
class=
"form-control m-b"
>
<option
value=
"0"
>
开启
</option>
<option
value=
"1"
>
未开启
</option>
</select>
</div>
</div>
<!-- row -->
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
时间范围:
</span>
<input
type=
"text"
class=
"layui-input form-control"
id=
"startTime"
autocomplete=
"off"
placeholder=
"开始时间选择"
>
~
<input
type=
"text"
class=
"layui-input form-control"
id=
"endTime"
style=
"margin-left: 10px;"
autocomplete=
"off"
placeholder=
"结束时间选择"
>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
推荐:
</span>
<!-- 动态 input -->
<div
class=
"input-group"
id=
"addClassify2"
>
<div
class=
"input-group-wrapper"
>
<ul
class=
"sortable-list connectList agile-list"
>
</ul>
</div>
</div>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
></em>
</span>
<a
class=
"btn btn-default btn-xs"
href=
"javascript:void(0)"
onclick=
"addDom()"
>
+ 添加推荐
</a>
</div>
<!-- -->
<div
class=
"first_footer editshow"
style=
"padding-left: 60px; margin-top: 12px;"
>
<button
class=
"btn btn-primary"
onclick=
"save()"
>
确定
</button>
</div>
</div>
<!-- 提交 -->
<div
class=
"add_footer"
style=
"display: none;"
>
<button
class=
"btn btn-success"
onclick=
"save()"
>
保存
</button>
<!-- <button class="btn" onclick="addItem()">取消</button> -->
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: bootstrap-suggest-js"
/>
</body>
<script
th:src=
"@{/js/searchSelect.js}"
></script>
<script
th:src=
"@{/js/jquery-ui-1.10.4.min.js}"
></script>
<script
th:inline=
"javascript"
>
let
prefix2
=
ctx
+
"local"
;
// let itemId = Number(getUrlParms('id'))
let
affiliatedUrl
=
[
'goblin/common/sku'
,
'goblin/common/mix'
,
'kylin/performances/roadShow/performance/status'
,
'goblin/common/goods'
]
let
listData
=
[]
let
count
=
0
// 判断是否默认一组表单
let
currentUrl
=
'goblin/common/sku'
let
activeTypeChangeVal
=
1
let
varObj
=
{}
$
(
document
).
ready
(
function
()
{
$
(
'.sortable-list'
).
sortable
({
connectWith
:
'.connectList'
}).
disableSelection
()
})
// init
$
(
function
()
{
layui
.
use
(
'laydate'
,
function
()
{
let
laydate
=
layui
.
laydate
;
// 执行一个laydate实例
laydate
.
render
({
elem
:
'#startTime'
,
//指定元素
type
:
'datetime'
});
laydate
.
render
({
elem
:
'#endTime'
,
//指定元素
type
:
'datetime'
});
});
$
(
"#status"
).
attr
(
'value'
,
0
)
$
(
"#activeType"
).
attr
(
'value'
,
1
)
// 选择select
$
(
'#activeType'
).
change
(
function
()
{
activeTypeChangeVal
=
Number
(
$
(
this
).
val
())
// 1 2 3 4
currentUrl
=
affiliatedUrl
[
activeTypeChangeVal
-
1
]
// 获取选中的,对应地址
})
// 监听 模糊搜索
let
search
=
new
searchSelect
(
'#search'
,
[],
function
(
val
)
{
let
_params
=
{}
if
(
activeTypeChangeVal
==
1
)
{
_params
[
'type'
]
=
1
_params
[
'title'
]
=
val
}
else
if
(
activeTypeChangeVal
==
2
)
{
// 组合购
_params
[
'title'
]
=
val
}
else
if
(
activeTypeChangeVal
==
3
)
{
// 演出
_params
[
'status'
]
=
'(3,6,7,8,9,10)'
_params
[
'title'
]
=
val
}
else
if
(
activeTypeChangeVal
==
4
)
{
// 商品
_params
[
'type'
]
=
0
_params
[
'title'
]
=
val
}
console
.
log
(
'searchSelect'
,
activeTypeChangeVal
,
_params
)
$
.
ajax
({
type
:
'get'
,
url
:
ctx
+
currentUrl
,
contentType
:
"application/json;charset=UTF-8"
,
data
:
_params
,
success
:
function
(
res
)
{
let
_data
=
[]
let
nft
=
res
.
data
||
[]
let
group
=
res
.
data
||
[]
let
yan
=
res
.
value
||
[]
let
sp
=
res
.
data
||
[]
if
(
activeTypeChangeVal
==
1
)
{
_data
=
nft
?.
map
(
item
=>
{
// 组装返回nft数据
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
else
if
(
activeTypeChangeVal
==
2
)
{
_data
=
group
?.
map
(
item
=>
{
return
{
id
:
item
.
mixId
,
value
:
item
.
sellName
}
})
}
else
if
(
activeTypeChangeVal
==
3
)
{
_data
=
yan
?.
map
(
item
=>
{
return
{
id
:
item
.
performancesId
,
value
:
item
.
title
}
})
}
else
if
(
activeTypeChangeVal
==
4
)
{
_data
=
sp
?.
map
(
item
=>
{
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
search
.
update
(
_data
)
}
})
})
})
// init end
getPageData
()
// 最开始加载
// 获得当前页面回显数据
function
getPageData
()
{
let
list
=
[]
list
=
[{
type
:
1
}]
assembleDom
(
list
)
// 创建监听
setTimeout
(()
=>
{
for
(
let
i
=
0
;
i
<
list
.
length
;
i
++
)
{
createListenerSearch
(
i
+
1
)
$
(
`#listActiveType
${
i
+
1
}
`
).
change
(
function
()
{
$
(
'#listRemoteSearch'
+
(
i
+
1
)
+
' input'
).
attr
(
'value'
,
''
)
})
}
},
500
)
// 回显 search
setTimeout
(()
=>
{
for
(
let
i
=
0
;
i
<
list
.
length
;
i
++
)
{
$
(
'#listRemoteSearch'
+
(
i
+
1
)
+
' input'
).
attr
(
'value'
,
''
)
$
(
'#listActiveType'
+
(
i
+
1
)).
find
(
`option[value=
${
list
[
i
].
type
}
]`
).
attr
(
'selected'
,
true
)
}
},
800
)
}
// 组装 html
function
assembleDom
(
list
)
{
list
.
forEach
((
item
,
index
)
=>
{
count
=
index
+
1
;
let
dynamicAddDom
=
`<li class="info-element" id="liItem
${
count
}
">
<div class="addAvatarItem" style="padding: 20px;">
<div class="selectClassifyOne">
<span class="span-label"><i style="color: red; position: relative; top: 3px;">*</i>推荐类型:</span>
<select id="listActiveType
${
index
+
1
}
" value="
${
item
.
type
}
" class="form-control m-b">
<option value="1">NFT</option>
<option value="2">组合购</option>
<option value="3">演出</option>
<option value="4">商品</option>
</select>
</div>
<div class="selectClassifyOne">
<span class="span-label"><i style="color: red; position: relative; top: 3px;">*</i>推荐商品:</span>
<div class="search-wrapper">
<div class="search-wrapper">
<div id="listRemoteSearch
${
index
+
1
}
" placeholder="请搜索" name="searchSelect
${
index
+
1
}
"></div>
</div>
</div>
</div>
<div><a href="#" class="pull-right btn btn-xs btn-white" style="margin-top: 5px;background: none;border: none;"><i class="fa fa-navicon"></i></a></div>
<div style="position: relative;"><i class="fa fa-remove" onclick="removeListItem('
${
count
}
')" style="margin-top: 8px; position: absolute; left: 10px;"></i></div>
</li>`
$
(
'.sortable-list'
).
append
(
dynamicAddDom
)
// 组装好,添加进去
})
}
// 添加关联推荐 html 单个添加
function
addDom
()
{
count
++
let
dynamicAddDom
=
`<li class="info-element" id="liItem
${
count
}
">
<div class="addAvatarItem" style="padding: 20px;">
<div class="selectClassifyOne">
<span class="span-label"><i style="color: red; position: relative; top: 3px;">*</i>推荐类型:</span>
<select id="listActiveType
${
count
}
" class="form-control m-b">
<option value="1">NFT</option>
<option value="2">组合购</option>
<option value="3">演出</option>
<option value="4">商品</option>
</select>
</div>
<div class="selectClassifyOne">
<span class="span-label"><i style="color: red; position: relative; top: 3px;">*</i>推荐商品:</span>
<div class="search-wrapper">
<div class="search-wrapper">
<div id="listRemoteSearch
${
count
}
" placeholder="请搜索" name="searchSelect
${
count
}
"></div>
</div>
</div>
</div>
<div><a href="#" class="pull-right btn btn-xs btn-white" style="margin-top: 5px;background: none;border: none;"><i class="fa fa-navicon"></i></a></div>
<div style="position: relative;"><i class="fa fa-remove" onclick="removeListItem('
${
count
}
')" style="margin-top: 8px; position: absolute; left: 10px;"></i></div>
</li>`
// 只有一组,可添加
if
(
count
>=
0
&&
count
<=
19
)
{
$
(
'.sortable-list'
).
append
(
dynamicAddDom
)
// 设置 实例化 一个 input search监听
setTimeout
(()
=>
{
varObj
[
'listRemoteSearch'
+
count
]
=
new
searchSelect
(
`#listRemoteSearch
${
count
}
`
,
[],
function
(
val
)
{
searchAjax
(
val
,
count
)
})
},
500
)
setTimeout
(()
=>
{
$
(
`#listActiveType
${
count
}
`
).
change
(
function
()
{
$
(
'#listRemoteSearch'
+
(
count
)
+
' input'
).
attr
(
'value'
,
''
)
})
},
800
)
}
else
{
layer
.
msg
(
'不能添加'
)
}
// const new search
}
// 删除list item
function
removeListItem
(
index
)
{
let
evryGroup
=
$
(
'#addClassify2'
).
find
(
$
(
'.addAvatarItem'
))
if
(
evryGroup
.
length
<=
1
)
return
layer
.
msg
(
'至少保留一个'
)
$
.
modal
.
loading
(
"请稍等..."
);
$
(
`#liItem
${
index
}
`
).
remove
()
setTimeout
(
function
()
{
$
.
modal
.
closeLoading
();
},
500
)
}
// 保存 list
function
saveList
()
{
listData
=
[]
let
evryGroup
=
$
(
'#addClassify2'
).
find
(
$
(
'.addAvatarItem'
))
for
(
let
i
=
0
;
i
<
evryGroup
.
length
;
i
++
)
{
listData
.
push
({
recommendBindId
:
$
(
'#listRemoteSearch'
+
(
i
+
1
)).
find
(
'input'
).
attr
(
'data-id'
),
type
:
Number
(
$
(
"#listActiveType"
+
(
i
+
1
)).
find
(
"option:selected"
).
val
()),
indexs
:
i
+
1
})
}
// 修改推荐活动
promiseMethods
(
'/kylin-recommend-active/addOrUpdateListKylinRecommendActiveRelation'
,
'post'
,
JSON
.
stringify
(
listData
),
'application/json'
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
layer
.
msg
(
'修改成功'
)
// $.operate.successTabCallback(res);
// closeItem();
}
else
{
layer
.
msg
(
res
.
msg
)
}
})
}
// 添加dom同时,添加表单监听
function
createListenerSearch
(
index
)
{
varObj
[
'listRemoteSearch'
+
index
]
=
new
searchSelect
(
`#listRemoteSearch
${
index
}
`
,
[],
function
(
val
)
{
searchAjax
(
val
,
index
)
})
}
function
searchAjax
(
val
,
index
)
{
let
_selectVal
=
$
(
"#listActiveType"
+
index
).
find
(
"option:selected"
).
val
()
// 当前子select val
if
(
_selectVal
)
{
let
_params
=
{}
if
(
_selectVal
==
1
)
{
_params
[
'type'
]
=
1
_params
[
'title'
]
=
val
}
else
if
(
_selectVal
==
2
)
{
// 组合购
_params
[
'title'
]
=
val
}
else
if
(
_selectVal
==
3
)
{
// 演出
_params
[
'status'
]
=
'(3,6,7,8,9,10)'
_params
[
'title'
]
=
val
}
else
if
(
_selectVal
==
4
)
{
// 商品
_params
[
'type'
]
=
0
_params
[
'title'
]
=
val
}
$
.
ajax
({
type
:
'get'
,
url
:
ctx
+
affiliatedUrl
[
_selectVal
-
1
],
contentType
:
"application/json;charset=UTF-8"
,
data
:
_params
,
success
:
function
(
res
)
{
let
_data
=
[]
let
nft
=
res
.
data
||
[]
let
group
=
res
.
data
||
[]
let
yan
=
res
.
value
||
[]
let
sp
=
res
.
data
||
[]
if
(
_selectVal
==
1
)
{
_data
=
nft
?.
map
(
item
=>
{
// 组装返回nft数据
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
else
if
(
_selectVal
==
2
)
{
_data
=
group
?.
map
(
item
=>
{
return
{
id
:
item
.
mixId
,
value
:
item
.
sellName
}
})
}
else
if
(
_selectVal
==
3
)
{
_data
=
yan
?.
map
(
item
=>
{
return
{
id
:
item
.
performancesId
,
value
:
item
.
title
}
})
}
else
if
(
_selectVal
==
4
)
{
_data
=
sp
?.
map
(
item
=>
{
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
varObj
[
Object
.
keys
(
varObj
)[
index
-
1
]].
update
(
_data
)
// 更新数据
}
})
}
}
// 保存/更新
function
save
()
{
listData
=
[]
// let evryGroup = $('#addClassify2').find($('.addAvatarItem'))
// 遍历所有的dom组,取值组装
// for (let i = 0; i
<
evryGroup
.
length
;
i
++
)
{
// listData.push({
// recommendBindId: $('#listRemoteSearch' + (i+1)).find('input').attr('data-id'),
// type: Number($("#listActiveType" + (i+1)).find("option:selected").val()),
// indexs: i + 1
// })
// }
$
(
'#addClassify2'
).
find
(
$
(
'.addAvatarItem'
)).
each
(
function
(
index
)
{
listData
.
push
({
recommendBindId
:
$
(
this
).
find
(
'input'
).
attr
(
'data-id'
),
type
:
Number
(
$
(
this
).
find
(
"option:selected"
).
val
()),
indexs
:
index
+
1
})
})
// recommendId: _recommendId, 更新接口需要
let
_params
=
{
activeBindId
:
$
(
'#search input'
).
attr
(
'data-id'
),
activeName
:
$
(
'#activeName'
).
val
(),
activeType
:
Number
(
$
(
"#activeType"
).
find
(
"option:selected"
).
val
()),
endTime
:
$
(
'#endTime'
).
val
(),
list
:
listData
,
startTime
:
$
(
'#startTime'
).
val
(),
status
:
Number
(
$
(
"#status"
).
find
(
"option:selected"
).
val
())
}
console
.
log
(
'_params'
,
_params
)
if
(
!
_params
.
activeName
)
{
layer
.
msg
(
'请填写活动名称'
)
return
}
if
(
!
_params
.
activeType
)
{
layer
.
msg
(
'请填写活动类型'
)
return
}
if
(
!
_params
.
activeBindId
)
{
layer
.
msg
(
'请填写关联活动名称'
)
return
}
if
(
!
_params
.
startTime
)
{
layer
.
msg
(
'请填写开始时间'
)
return
}
if
(
!
_params
.
endTime
)
{
layer
.
msg
(
'请填写结束时间'
)
return
}
let
idList
=
listData
.
filter
(
item
=>
item
.
recommendBindId
==
undefined
)
if
(
idList
.
length
>=
1
)
{
layer
.
msg
(
'推荐活动需填写完整'
)
}
else
{
// 增加接口
promiseMethods
(
'/kylin-recommend-active/addKylinRecommendActive'
,
'post'
,
JSON
.
stringify
(
_params
),
'application/json'
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
layer
.
msg
(
'新增成功'
)
$
.
operate
.
successTabCallback
(
res
);
closeItem
();
}
else
{
layer
.
msg
(
res
.
msg
)
}
})
}
}
// 请求方法封装
function
promiseMethods
(
url
,
type
,
data
,
contentType
)
{
return
new
Promise
((
resolve
,
reject
)
=>
{
$
.
ajax
({
url
,
type
,
data
,
contentType
,
success
:
function
(
res
)
{
resolve
(
res
);
}
})
})
}
function
getUrlParms
(
name
)
{
var
reg
=
new
RegExp
(
"(^|&)"
+
name
+
"=([^&]*)(&|$)"
);
var
r
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg
);
if
(
r
!=
null
)
return
unescape
(
r
[
2
]);
return
null
;
}
</script>
</html>
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/sweet/affiliatedActivity/edit.html
0 → 100644
View file @
75cd17ba
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
>
<head>
<th:block
th:include=
"include :: header('编辑关联活动')"
/>
<th:block
th:include=
"include :: select2-css"
/>
<link
rel=
"stylesheet"
href=
""
>
<style>
body
.layui-layer-btn
{
display
:
none
!important
;
}
#layui-layer1
{
z-index
:
1001
!important
;
}
#layui-layer-shade1
{
z-index
:
1000
!important
;
}
.required
{
font-style
:
normal
;
color
:
red
;
}
.content_item
{
padding
:
20px
;
}
/* .content_item .content_title {
display: flex;
} */
.content_item
.content_title
h3
span
{
display
:
inline-block
;
width
:
4px
;
height
:
18px
;
background
:
skyblue
;
margin-right
:
6px
;
vertical-align
:
top
;
}
.basis_data
{
display
:
flex
;
font-size
:
14px
;
padding
:
0
20px
;
margin-top
:
20px
;
/* align-items: center; */
}
.basis_data
span
{
width
:
100px
;
text-align
:
right
;
}
#startTime
,
#endTime
{
width
:
272px
;
margin-right
:
10px
;
}
.storeList
,
#selectShow
,
.dropdown-menu
,
.input-group
{
width
:
320px
!important
;
}
.activityStore_item
{
display
:
flex
;
margin-bottom
:
12px
;
}
#basis_data
{
align-items
:
flex-start
;
}
.add_footer
{
width
:
100%
;
height
:
45px
;
line-height
:
45px
;
padding-left
:
60px
;
}
.sortable-list
{
width
:
700px
;
}
.sortable-list
li
{
width
:
100%
;
}
.sortable-list
li
.addAvatarItem
{
width
:
100%
;
display
:
flex
;
justify-content
:
flex-start
;
}
#addClassify2
,
#detailPro
{
width
:
450px
;
padding-top
:
20px
;
}
.input-group-wrapper
{
padding
:
20px
;
border-radius
:
8px
;
border
:
1px
solid
#cccccc
;
}
.addAvatarItem
.selectClassifyOne
{
width
:
100%
;
display
:
flex
;
margin-right
:
15px
;
}
.addAvatarItem
.selectClassifyOne
.span-label
{
width
:
108px
;
padding-top
:
5px
;
}
.picker
{
display
:
flex
;
justify-content
:
flex-start
;
}
#addClassify
.addAvatarItem
label
{
display
:
flex
;
margin-right
:
20px
;
margin-left
:
5px
;
align-items
:
center
;
}
#addClassify
.addAvatarItem
label
input
{
margin
:
0
;
margin-right
:
2px
;
}
#detailPro
.detail_inner
{
margin-bottom
:
20px
;
}
#detailPro
.detail_title
{
margin-top
:
50px
;
font-weight
:
bold
;
font-size
:
16px
;
}
.bottomBtn
{
text-align
:
left
;
padding
:
30px
15px
12px
;
}
.layui-layer-shade
{
opacity
:
30%
;
}
.item
div
{
display
:
flex
;
}
.item
div
a
{
margin-left
:
12px
;
}
/* 星星 */
.required-group-name
{
color
:
red
;
font-size
:
20px
;
position
:
relative
;
top
:
6px
;
}
.groupName
{
border
:
1px
solid
#dfdfdf
;
}
.required-province
{
color
:
red
;
display
:
inline-block
;
margin-right
:
3px
;
position
:
relative
;
top
:
6px
;
font-size
:
20px
;
}
/* 必填红色文字 */
.required-group-text
{
height
:
20px
;
color
:
red
;
}
.required-province-text
{
color
:
red
;
height
:
20px
;
}
.search-wrapper
{
width
:
100%
;
}
</style>
</head>
<body>
<div>
<div
class=
"content_item"
>
<div
class=
"content_title"
>
<h3><span></span>
编辑关联活动
</h3>
</div>
<!-- row -->
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
活动名称:
</span>
<div
class=
"input-group"
style=
"width: 300px;"
>
<input
type=
"text"
class=
"form-control"
id=
"activeName"
placeholder=
""
>
</div>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
关联类型:
</span>
<div
class=
"input-group"
style=
"width: 300px;"
>
<select
name=
"activeType"
id=
"activeType"
class=
"form-control m-b"
>
<option
value=
"1"
>
NFT
</option>
<option
value=
"2"
>
组合购
</option>
<option
value=
"3"
>
演出
</option>
<option
value=
"4"
>
商品
</option>
</select>
</div>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
关联名称:
</span>
<div
class=
"input-group"
style=
"width: 300px;"
>
<div
class=
"search-wrapper"
style=
"margin-bottom: 15px;"
>
<!-- 关联 模糊搜索 回显的话添加id再赋值 -->
<div
id=
"search"
placeholder=
"请搜索"
name=
"seaarchSelect"
></div>
</div>
</div>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
状态:
</span>
<div
class=
"input-group"
style=
"width: 300px;"
>
<select
name=
"status"
id=
"status"
class=
"form-control m-b"
>
<option
value=
""
>
所有
</option>
<option
value=
"0"
>
开启
</option>
<option
value=
"1"
>
未开启
</option>
</select>
</div>
</div>
<!-- row -->
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
时间范围:
</span>
<input
type=
"text"
class=
"layui-input form-control"
id=
"startTime"
autocomplete=
"off"
placeholder=
"开始时间选择"
>
~
<input
type=
"text"
class=
"layui-input form-control"
id=
"endTime"
style=
"margin-left: 10px;"
autocomplete=
"off"
placeholder=
"结束时间选择"
>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
>
*
</em>
推荐:
</span>
<div
class=
"input-group"
id=
"addClassify2"
>
<div
class=
"input-group-wrapper"
>
<ul
class=
"sortable-list connectList agile-list"
>
</ul>
</div>
</div>
</div>
<div
class=
"basis_data"
>
<span>
<em
class=
"required"
></em>
</span>
<a
class=
"btn btn-default btn-xs"
href=
"javascript:void(0)"
style=
"margin-right: 10px;"
onclick=
"addDom()"
>
添加推荐
</a>
<a
class=
"btn btn-info btn-xs"
href=
"javascript:void(0)"
onclick=
"saveList()"
>
保存推荐
</a>
</div>
<!-- -->
<div
class=
"first_footer editshow"
style=
"padding-left: 60px; margin-top: 12px;"
>
<button
class=
"btn btn-primary"
onclick=
"save()"
>
确定
</button>
</div>
</div>
<!-- 提交 -->
<div
class=
"add_footer"
style=
"display: none;"
>
<button
class=
"btn btn-success"
onclick=
"save()"
>
保存
</button>
<!-- <button class="btn" onclick="addItem()">取消</button> -->
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: bootstrap-suggest-js"
/>
</body>
<script
th:src=
"@{/js/searchSelect.js}"
></script>
<script
th:src=
"@{/js/jquery-ui-1.10.4.min.js}"
></script>
<script
th:inline=
"javascript"
>
let
prefix2
=
ctx
+
"local"
;
let
itemId
=
Number
(
getUrlParms
(
'id'
))
// 'compilations/goodsList'
let
affiliatedUrl
=
[
'goblin/common/sku'
,
'goblin/common/mix'
,
'kylin/performances/roadShow/performance/status'
,
'goblin/common/goods'
]
let
currentUrl
=
'goblin/common/sku'
let
activeTypeChangeVal
=
1
let
listData
=
[]
let
count
=
0
// 判断是否默认一组表单
let
_recommendId
=
''
let
_recommendActiveId
=
''
let
varObj
=
{}
$
(
document
).
ready
(
function
()
{
$
(
'.sortable-list'
).
sortable
({
connectWith
:
'.connectList'
}).
disableSelection
()
})
// init
$
(
function
()
{
layui
.
use
(
'laydate'
,
function
()
{
let
laydate
=
layui
.
laydate
;
// 执行一个laydate实例
laydate
.
render
({
elem
:
'#startTime'
,
//指定元素
type
:
'datetime'
});
laydate
.
render
({
elem
:
'#endTime'
,
//指定元素
type
:
'datetime'
});
});
// 选择select
$
(
'#activeType'
).
change
(
function
()
{
activeTypeChangeVal
=
Number
(
$
(
this
).
val
())
// 1 2 3 4
currentUrl
=
affiliatedUrl
[
activeTypeChangeVal
-
1
]
// 获取选中的,对应地址
$
(
'#search input'
).
attr
(
'value'
,
''
)
})
// 监听 模糊搜索
let
search
=
new
searchSelect
(
'#search'
,
[],
function
(
val
)
{
let
_params
=
{}
if
(
activeTypeChangeVal
==
1
)
{
_params
[
'type'
]
=
1
_params
[
'title'
]
=
val
}
else
if
(
activeTypeChangeVal
==
2
)
{
// 组合购
_params
[
'title'
]
=
val
}
else
if
(
activeTypeChangeVal
==
3
)
{
// 演出
_params
[
'title'
]
=
val
_params
[
'status'
]
=
'(3,6,7,8,9,10)'
}
else
if
(
activeTypeChangeVal
==
4
)
{
// 商品
_params
[
'type'
]
=
0
_params
[
'title'
]
=
val
}
$
.
ajax
({
type
:
'get'
,
url
:
ctx
+
currentUrl
,
contentType
:
"application/json;charset=UTF-8"
,
data
:
_params
,
success
:
function
(
res
)
{
let
_data
=
[]
let
nft
=
res
.
data
||
[]
let
group
=
res
.
data
||
[]
let
yan
=
res
.
value
||
[]
let
sp
=
res
.
data
||
[]
if
(
activeTypeChangeVal
==
1
)
{
_data
=
nft
?.
map
(
item
=>
{
// 组装返回nft数据
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
else
if
(
activeTypeChangeVal
==
2
)
{
_data
=
group
?.
map
(
item
=>
{
return
{
id
:
item
.
mixId
,
value
:
item
.
sellName
}
})
}
else
if
(
activeTypeChangeVal
==
3
)
{
_data
=
yan
?.
map
(
item
=>
{
return
{
id
:
item
.
performancesId
,
value
:
item
.
title
}
})
}
else
if
(
activeTypeChangeVal
==
4
)
{
_data
=
sp
?.
map
(
item
=>
{
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
search
.
update
(
_data
)
}
})
})
search
.
search
(
true
)
})
// init end
getPageData
()
// 最开始加载
// 获得当前页面回显数据
function
getPageData
()
{
let
list
=
[]
if
(
itemId
)
{
// 请求数据
promiseMethods
(
'/kylin-recommend-active/getActiveById'
,
'post'
,
{
mid
:
itemId
}).
then
(
res
=>
{
if
(
res
)
{
list
=
res
.
list
_recommendId
=
res
.
recommendId
$
(
'#activeName'
).
attr
(
'value'
,
res
.
activeName
)
$
(
'#activeType'
).
find
(
`option[value=
${
res
.
activeType
}
]`
).
attr
(
'selected'
,
true
)
activeTypeChangeVal
=
res
.
activeType
currentUrl
=
affiliatedUrl
[
res
.
activeType
-
1
]
$
(
'#search input'
).
attr
(
'value'
,
res
.
name
)
$
(
'#search input'
).
attr
(
'data-id'
,
res
.
activeBindId
)
$
(
'#status'
).
find
(
`option[value=
${
res
.
status
}
]`
).
attr
(
'selected'
,
true
)
$
(
'#startTime'
).
attr
(
'value'
,
$
.
common
.
dateFormat
(
new
Date
(
res
.
startTime
),
'yyyy-MM-dd HH:mm:ss'
))
$
(
'#endTime'
).
attr
(
'value'
,
$
.
common
.
dateFormat
(
new
Date
(
res
.
endTime
),
'yyyy-MM-dd HH:mm:ss'
))
_recommendActiveId
=
list
[
0
]?.
recommendActiveId
assembleDom
(
list
)
// 创建监听
setTimeout
(()
=>
{
for
(
let
i
=
0
;
i
<
list
.
length
;
i
++
)
{
createListenerSearch
(
i
+
1
)
$
(
`#listActiveType
${
i
+
1
}
`
).
change
(
function
()
{
$
(
'#listRemoteSearch'
+
(
i
+
1
)
+
' input'
).
attr
(
'value'
,
''
)
})
}
},
500
)
// 回显 search
setTimeout
(()
=>
{
for
(
let
i
=
0
;
i
<
list
.
length
;
i
++
)
{
$
(
'#listRemoteSearch'
+
(
i
+
1
)
+
' input'
).
attr
(
'value'
,
list
[
i
].
name
)
$
(
'#listRemoteSearch'
+
(
i
+
1
)
+
' input'
).
attr
(
'data-id'
,
list
[
i
].
recommendBindId
)
$
(
'#listRemoteSearch'
+
(
i
+
1
)
+
' input'
).
attr
(
'data-mid'
,
list
[
i
].
mid
)
$
(
'#listRemoteSearch'
+
(
i
+
1
)
+
' input'
).
attr
(
'data-recommendActiveId'
,
list
[
i
].
recommendActiveId
)
$
(
'#listRemoteSearch'
+
(
i
+
1
)
+
' input'
).
attr
(
'data-recommendRelationId'
,
list
[
i
].
recommendRelationId
)
$
(
'#listActiveType'
+
(
i
+
1
)).
find
(
`option[value=
${
list
[
i
].
type
}
]`
).
attr
(
'selected'
,
true
)
}
},
800
)
}
else
{
layer
.
msg
(
res
.
message
)
}
})
}
}
// 组装 html
function
assembleDom
(
list
)
{
list
.
forEach
((
item
,
index
)
=>
{
count
++
let
dynamicAddDom
=
`<li class="info-element" id="liItem
${
count
}
">
<div class="addAvatarItem" style="padding: 20px;">
<div class="selectClassifyOne">
<span class="span-label"><i style="color: red; position: relative; top: 3px;">*</i>推荐类型:</span>
<select id="listActiveType
${
count
}
" value="
${
item
.
type
}
" class="form-control m-b list-active-type">
<option value="1">NFT</option>
<option value="2">组合购</option>
<option value="3">演出</option>
<option value="4">商品</option>
</select>
</div>
<div class="selectClassifyOne">
<span class="span-label"><i style="color: red; position: relative; top: 3px;">*</i>推荐商品:</span>
<div class="search-wrapper">
<div class="search-wrapper">
<div id="listRemoteSearch
${
count
}
" placeholder="请搜索" name="searchSelect
${
count
}
"></div>
</div>
</div>
</div>
<div><a href="#" class="pull-right btn btn-xs btn-white" style="margin-top: 5px;background: none;border: none;"><i class="fa fa-navicon"></i></a></div>
<div style="position: relative;"><i class="fa fa-remove" onclick="removeListItem('
${
count
}
')" style="margin-top: 8px; position: absolute; left: 10px;"></i></div>
</li>`
$
(
'.sortable-list'
).
append
(
dynamicAddDom
)
// 组装好,添加进去
})
}
// 添加关联推荐 html 单个添加
function
addDom
()
{
count
++
;
let
dynamicAddDom
=
`<li class="info-element" id="liItem
${
count
}
">
<div class="addAvatarItem" style="padding: 20px;">
<div class="selectClassifyOne">
<span class="span-label"><i style="color: red; position: relative; top: 3px;">*</i>推荐类型:</span>
<select id="listActiveType
${
count
}
" class="form-control m-b">
<option value="1">NFT</option>
<option value="2">组合购</option>
<option value="3">演出</option>
<option value="4">商品</option>
</select>
</div>
<div class="selectClassifyOne">
<span class="span-label"><i style="color: red; position: relative; top: 3px;">*</i>推荐商品:</span>
<div class="search-wrapper">
<div class="search-wrapper">
<div id="listRemoteSearch
${
count
}
" placeholder="请搜索" name="searchSelect
${
count
}
"></div>
</div>
</div>
</div>
<div><a href="#" class="pull-right btn btn-xs btn-white" style="margin-top: 5px;background: none;border: none;"><i class="fa fa-navicon"></i></a></div>
<div style="position: relative;"><i class="fa fa-remove" onclick="removeListItem('
${
count
}
')" style="margin-top: 8px; position: absolute; left: 10px;"></i></div>
</li>`
// 只有一组,可添加
if
(
count
>=
0
&&
count
<=
19
)
{
$
(
'.sortable-list'
).
append
(
dynamicAddDom
)
setTimeout
(()
=>
{
varObj
[
'listRemoteSearch'
+
count
]
=
new
searchSelect
(
`#listRemoteSearch
${
count
}
`
,
[],
function
(
val
)
{
searchAjax
(
val
,
count
)
})
},
500
)
setTimeout
(()
=>
{
$
(
`#listActiveType
${
count
}
`
).
change
(
function
()
{
$
(
'#listRemoteSearch'
+
count
+
' input'
).
attr
(
'value'
,
''
)
})
},
800
)
}
else
{
layer
.
msg
(
'不能添加'
)
}
// const new search
}
// 删除list item
function
removeListItem
(
index
)
{
let
evryGroup
=
$
(
'#addClassify2'
).
find
(
$
(
'.addAvatarItem'
))
if
(
evryGroup
.
length
<=
1
)
return
layer
.
msg
(
'至少保留一个'
);
$
(
`#liItem
${
index
}
`
).
remove
()
$
.
modal
.
loading
(
"请稍等..."
);
setTimeout
(
function
()
{
$
.
modal
.
closeLoading
();
},
500
)
}
// 保存 list
function
saveList
()
{
listData
=
[]
$
(
'#addClassify2'
).
find
(
$
(
'.addAvatarItem'
)).
each
(
function
(
index
)
{
listData
.
push
({
mid
:
$
(
this
).
find
(
'input'
).
attr
(
'data-mid'
),
recommendActiveId
:
_recommendActiveId
,
recommendRelationId
:
$
(
this
).
find
(
'input'
).
attr
(
'data-recommendRelationId'
),
recommendBindId
:
$
(
this
).
find
(
'input'
).
attr
(
'data-id'
),
type
:
Number
(
$
(
this
).
find
(
"option:selected"
).
val
()),
indexs
:
index
+
1
})
})
let
idList
=
listData
.
filter
(
item
=>
item
.
recommendBindId
==
undefined
)
if
(
idList
.
length
>=
1
)
{
layer
.
msg
(
'推荐活动需填写完整'
)
}
else
{
// 增加接口
promiseMethods
(
'/kylin-recommend-active/addOrUpdateListKylinRecommendActiveRelation'
,
'post'
,
JSON
.
stringify
(
listData
),
'application/json'
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
layer
.
msg
(
'修改成功'
)
// $.operate.successTabCallback(res);
// closeItem();
}
else
{
layer
.
msg
(
res
.
msg
)
}
})
}
}
// 添加dom同时,添加表单监听
function
createListenerSearch
(
index
)
{
varObj
[
'listRemoteSearch'
+
index
]
=
new
searchSelect
(
`#listRemoteSearch
${
index
}
`
,
[],
function
(
val
)
{
searchAjax
(
val
,
index
)
})
}
function
searchAjax
(
val
,
index
)
{
let
_selectVal
=
$
(
"#listActiveType"
+
index
).
find
(
"option:selected"
).
val
()
// 当前子select val
if
(
_selectVal
)
{
let
_params
=
{}
if
(
_selectVal
==
1
)
{
_params
[
'type'
]
=
1
_params
[
'title'
]
=
val
}
else
if
(
_selectVal
==
2
)
{
// 组合购
_params
[
'title'
]
=
val
}
else
if
(
_selectVal
==
3
)
{
// 演出
_params
[
'status'
]
=
'(3,6,7,8,9,10)'
_params
[
'title'
]
=
val
}
else
if
(
_selectVal
==
4
)
{
// 商品
_params
[
'type'
]
=
0
_params
[
'title'
]
=
val
}
$
.
ajax
({
type
:
'get'
,
url
:
ctx
+
affiliatedUrl
[
_selectVal
-
1
],
contentType
:
"application/json;charset=UTF-8"
,
data
:
_params
,
success
:
function
(
res
)
{
let
_data
=
[]
let
nft
=
res
.
data
||
[]
let
group
=
res
.
data
||
[]
let
yan
=
res
.
value
||
[]
let
sp
=
res
.
data
||
[]
console
.
log
(
'_selectVal'
,
_selectVal
)
if
(
_selectVal
==
1
)
{
_data
=
nft
.
map
(
item
=>
{
// 组装返回nft数据
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
else
if
(
_selectVal
==
2
)
{
_data
=
group
?.
map
(
item
=>
{
return
{
id
:
item
.
mixId
,
value
:
item
.
sellName
}
})
}
else
if
(
_selectVal
==
3
)
{
_data
=
yan
?.
map
(
item
=>
{
return
{
id
:
item
.
performancesId
,
value
:
item
.
title
}
})
}
else
if
(
_selectVal
==
4
)
{
_data
=
sp
?.
map
(
item
=>
{
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
varObj
[
Object
.
keys
(
varObj
)[
index
-
1
]].
update
(
_data
)
// 更新数据
}
})
}
}
// 保存/更新
function
save
()
{
// bindId - 关联 id
let
_params
=
{
activeBindId
:
$
(
'#search input'
).
attr
(
'data-id'
),
recommendActiveId
:
$
(
'#search input'
).
attr
(
'data-recommendActiveId'
),
activeName
:
$
(
'#activeName'
).
val
(),
activeType
:
Number
(
$
(
"#activeType"
).
find
(
"option:selected"
).
val
()),
endTime
:
$
.
common
.
dateFormat
(
$
(
'#endTime'
).
val
(),
'yyyy-MM-dd HH:mm:ss'
),
mid
:
itemId
,
recommendId
:
_recommendId
,
startTime
:
$
.
common
.
dateFormat
(
$
(
'#startTime'
).
val
(),
'yyyy-MM-dd HH:mm:ss'
),
status
:
Number
(
$
(
"#status"
).
find
(
"option:selected"
).
val
())
}
if
(
!
_params
.
activeName
)
{
layer
.
msg
(
'请填写活动名称'
)
return
}
if
(
!
_params
.
activeType
)
{
layer
.
msg
(
'请填写活动类型'
)
return
}
if
(
!
_params
.
activeBindId
)
{
layer
.
msg
(
'请填写关联活动名称'
)
return
}
if
(
!
_params
.
startTime
)
{
layer
.
msg
(
'请填写开始时间'
)
return
}
if
(
!
_params
.
endTime
)
{
layer
.
msg
(
'请填写结束时间'
)
return
}
// 修改活动
promiseMethods
(
'/kylin-recommend-active/updateKylinRecommendActive'
,
'post'
,
JSON
.
stringify
(
_params
),
'application/json'
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
layer
.
msg
(
'修改成功'
)
$
.
operate
.
successTabCallback
(
res
);
closeItem
();
}
else
{
layer
.
msg
(
res
.
msg
)
}
})
}
// 请求方法封装
function
promiseMethods
(
url
,
type
,
data
,
contentType
)
{
return
new
Promise
((
resolve
,
reject
)
=>
{
$
.
ajax
({
url
,
type
,
data
,
contentType
,
success
:
function
(
res
)
{
resolve
(
res
);
}
})
})
}
function
getUrlParms
(
name
)
{
var
reg
=
new
RegExp
(
"(^|&)"
+
name
+
"=([^&]*)(&|$)"
);
var
r
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg
);
if
(
r
!=
null
)
return
unescape
(
r
[
2
]);
return
null
;
}
</script>
</html>
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/resources/templates/zhengzai/sweet/affiliatedActivity/list.html
0 → 100644
View file @
75cd17ba
<!DOCTYPE html>
<html
lang=
"zh"
xmlns:th=
"http://www.thymeleaf.org"
xmlns:shiro=
"http://www.pollix.at/thymeleaf/shiro"
>
<head>
<th:block
th:include=
"include :: header('关联活动')"
/>
<th:block
th:include=
"include :: datetimepicker-css"
/>
<style>
body
.layui-layer-btn
{
display
:
none
!important
;
}
.datetimepicker
{
z-index
:
99999999
!important
;
}
/*.layui-layer {*/
/* z-index: 900 !important;*/
/*}*/
#layui-layer1
{
z-index
:
1001
!important
;
}
#layui-layer-shade1
{
z-index
:
1000
!important
;
}
#addClassify
,
#detailPro
{
display
:
none
;
width
:
650px
;
padding-top
:
20px
;
}
#addClassify2
,
#detailPro
{
display
:
none
;
width
:
450px
;
height
:
260px
;
padding-top
:
20px
;
}
#addClassify
.selectClassify
{
display
:
flex
;
align-items
:
center
;
padding
:
0
60px
;
}
.selectClassify
.addAvatarItem
.selectClassifyOne
{
display
:
flex
;
}
.selectClassify
.addAvatarItem
.selectClassifyOne
.span-label
{
width
:
85px
;
}
.picker
{
display
:
flex
;
justify-content
:
flex-start
;
}
#addClassify
.selectClassify
label
{
display
:
flex
;
margin-right
:
20px
;
align-items
:
center
;
}
#addClassify
.selectClassify
label
input
{
margin
:
0
;
margin-right
:
2px
;
}
#detailPro
.detail_inner
{
margin-bottom
:
20px
;
}
#detailPro
.detail_title
{
margin-top
:
50px
;
font-weight
:
bold
;
font-size
:
16px
;
}
.bottomBtn
{
text-align
:
left
;
padding
:
30px
15px
12px
;
}
.layui-layer-shade
{
opacity
:
30%
;
}
.item
div
{
display
:
flex
;
}
.item
div
a
{
margin-left
:
12px
;
}
/* 星星 */
.required-group-name
{
color
:
red
;
font-size
:
20px
;
position
:
relative
;
top
:
6px
;
}
.groupName
{
border
:
1px
solid
#dfdfdf
;
}
.required-province
{
color
:
red
;
display
:
inline-block
;
margin-right
:
3px
;
position
:
relative
;
top
:
6px
;
font-size
:
20px
;
}
/* 必填红色文字 */
.required-group-text
{
height
:
20px
;
color
:
red
;
}
.required-province-text
{
color
:
red
;
height
:
20px
;
}
.search-wrapper
{
width
:
100%
;
}
.date-range
{
width
:
100%
;
}
.banner_list
{
display
:
flex
;
flex-direction
:
column
;
width
:
100%
;
}
.banner_item
,
.items
{
border-radius
:
10px
;
padding
:
12px
;
margin-bottom
:
20px
;
}
.img_show
,
.set_method
,
.set_function
{
display
:
flex
;
}
.title
{
font-size
:
16px
;
font-weight
:
600
;
width
:
80px
;
text-align
:
right
;
}
.kv-upload-progress
{
display
:
none
!important
;
}
.ibox-content
.imgBox
{
width
:
350px
;
max-height
:
180px
;
}
.jump
,
.ticket_name
,
.set_function_time
{
display
:
flex
;
flex-grow
:
1
;
align-items
:
center
;
}
.iptOrSelect
{
flex
:
1
;
}
.img_box
{
display
:
flex
;
flex-direction
:
column
;
}
</style>
</head>
<body
class=
"gray-bg"
>
<div
class=
"container-div"
>
<div
class=
"row"
>
<!-- <div class="col-sm-12 search-collapse">
<form id="coupon-form">
<div class="select-list">
<ul>
<input type="hidden" name="couType" th:value="${couType}"/>
<li>
<input type="text" name="mobile" placeholder="请输入手机号码"/>
</li>
<li>
状态:
<select name="status" id="">
<option value="0">全部</option>
<option value="1">正常</option>
<option value="2">冻结</option>
</select>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
</li>
</ul>
</div>
</form>
</div> -->
<div
class=
"btn-group-sm"
id=
"toolbar"
role=
"group"
>
<a
class=
"btn btn-primary"
onclick=
"toadd()"
shiro:hasPermission=
"monitor:job:export"
>
增加活动
</a>
</div>
<div
class=
"col-sm-12 select-table table-striped"
>
<table
id=
"bootstrap-table"
></table>
</div>
</div>
<!-- modal -->
<div
id=
"addClassify"
>
<div
class=
"selectClassify"
>
<div
class=
"addAvatarItem"
>
<div
class=
"selectClassifyOne"
>
<span
class=
"span-label"
><i
style=
"color: red;"
>
*
</i>
活动名称:
</span>
<input
type=
"text"
class=
"form-control"
id=
"activeName"
style=
"margin-bottom: 15px;"
>
</div>
<div
class=
"selectClassifyOne"
>
<span
class=
"span-label"
><i
style=
"color: red;"
>
*
</i>
关联类型:
</span>
<select
name=
"activeType"
id=
"activeType"
class=
"form-control m-b"
>
<option
value=
"1"
>
NFT
</option>
<option
value=
"2"
>
组合购
</option>
<option
value=
"3"
>
演出
</option>
<option
value=
"4"
>
商品
</option>
</select>
</div>
<div
class=
"selectClassifyOne"
>
<span
class=
"span-label"
><i
style=
"color: red;"
>
*
</i>
关联ID:
</span>
<div
class=
"search-wrapper"
style=
"margin-bottom: 15px;"
>
<!-- 关联 模糊搜索 -->
<div
id=
"search"
placeholder=
"请搜索"
name=
"seaarchSelect"
></div>
</div>
</div>
<div
class=
"selectClassifyOne"
>
<span
class=
"span-label"
><i
style=
"color: red;"
>
*
</i>
状态:
</span>
<select
name=
"status"
id=
"status"
class=
"form-control m-b"
>
<option
value=
""
>
所有
</option>
<option
value=
"0"
>
开启
</option>
<option
value=
"1"
>
未开启
</option>
</select>
</div>
<div
class=
"selectClassifyOne"
>
<span
class=
"span-label"
><i
style=
"color: red;"
>
*
</i>
时间范围:
</span>
<div
class=
"date-range"
style=
"margin-bottom: 15px;"
>
<input
type=
"text"
style=
"width: 200px;float: left"
class=
"form-control"
id=
"startTime"
autocomplete=
“off”
placeholder=
"开始时间选择"
name=
"startTime"
/>
<span
class=
"control-label"
style=
"float: left;margin-left: 10px;margin-right: 10px"
>
-
</span>
<input
type=
"text"
style=
"width: 200px;float: left"
class=
"form-control"
id=
"endTime"
autocomplete=
“off”
placeholder=
"结束时间选择"
name=
"endTime"
/>
</div>
</div>
<div
class=
"selectClassifyOne"
>
<span
class=
"span-label"
><i
style=
"color: red;"
>
*
</i>
推荐:
</span>
<div
class=
"search-wrapper"
>
<a
class=
"btn btn-warning btn-xs"
href=
"javascript:void(0)"
onclick=
"clickAffiliatedList('NFT', '1')"
>
NFT
</a>
<a
class=
"btn btn-warning btn-xs"
href=
"javascript:void(0)"
onclick=
"clickAffiliatedList('组合购', '2')"
>
组合购
</a>
<a
class=
"btn btn-warning btn-xs"
href=
"javascript:void(0)"
onclick=
"clickAffiliatedList('演出', '3')"
>
演出
</a>
<a
class=
"btn btn-warning btn-xs"
href=
"javascript:void(0)"
onclick=
"clickAffiliatedList('商品', '4')"
>
商品
</a>
</div>
</div>
</div>
</div>
<input
type=
"hidden"
id=
"typeValue"
value=
"1"
>
<div
class=
"bottomBtn"
>
<a
src=
"javascript:;"
class=
"layui-layer-btn0 paddings"
onclick=
"saveActivity()"
>
确定
</a>
<a
class=
"layui-layer-btn1 layui-layer-btn1"
onclick=
"closeModal()"
>
取消
</a>
</div>
</div>
<!-- modal -->
<div
id=
"addClassify2"
>
<div
class=
"selectClassify"
>
<div
class=
"addAvatarItem"
style=
"padding: 20px;"
>
<div
class=
"selectClassifyOne"
style=
"margin-bottom: 20px;"
>
<span
class=
"span-label"
><i
style=
"color: red;"
>
*
</i>
推荐商品:
</span>
<div
class=
"search-wrapper"
>
<div
class=
"search-wrapper"
style=
"margin-bottom: 15px;"
>
<!-- 关联 模糊搜索 -->
<div
id=
"listRemoteSearch1"
placeholder=
"请搜索"
name=
"listSeaarchSelect"
></div>
</div>
</div>
</div>
<div
class=
"selectClassifyOne"
>
<span
class=
"span-label"
><i
style=
"color: red;"
>
*
</i>
推荐类型:
</span>
<select
name=
"activeType"
id=
"listActiveType1"
class=
"form-control m-b"
style=
"width: 170px;"
>
<option
value=
"1"
>
NFT
</option>
<option
value=
"2"
>
组合购
</option>
<option
value=
"3"
>
演出
</option>
<option
value=
"4"
>
商品
</option>
</select>
</div>
</div>
</div>
<div
class=
"bottomBtn"
>
<a
class=
"btn btn-primary btn-xs"
href=
"javascript:void(0)"
onclick=
"saveListAffiliated()"
>
确定
</a>
<a
class=
"btn btn-default btn-xs layui-layer-btn2"
href=
"javascript:void(0)"
onclick=
"closeModal2()"
>
取消
</a>
</div>
</div>
</div>
<th:block
th:include=
"include :: footer"
/>
<th:block
th:include=
"include :: datetimepicker-js"
/>
<th:block
th:include=
"include :: bootstrap-suggest-js"
/>
<th:block
th:include=
"include :: bootstrap-fileinput-js"
/>
<script
th:src=
"@{/js/searchSelect.js}"
></script>
<script
th:inline=
"javascript"
>
let
prefix
=
ctx
+
"stone/logs"
;
let
prefix2
=
ctx
+
"local"
;
let
couType
=
[[
$
{
couType
}]];
let
formData
=
new
FormData
()
let
listData
=
[]
// 临时暂存 嵌套活动推荐
let
activeTypeChangeVal
=
0
// 关联id select
let
activeTypeChangeValChild
=
0
// list 中 关联id select
let
affiliatedUrl
=
[
'goblin/common/sku'
,
'goblin/common/mix'
,
'kylin/performances/roadShow/performance/status'
,
'compilations/goodsList'
]
let
currentUrl
=
'goblin/common/sku'
let
currentChildUrl
=
''
let
affiliatedData
=
[]
let
affiliatedChildData
=
[]
// 下线 modal
let
addActivityModalDom
=
``
let
affiliatedChildModal
=
``
function
clickAffiliatedList
(
val
,
index
)
{
openAffiliatedModal
(
val
,
index
)
}
console
.
log
(
121212122
)
// document 加载
$
(
function
()
{
var
options
=
{
url
:
'/kylin-recommend-active/pageActive'
,
pagination
:
true
,
modalName
:
"关联"
,
columns
:
[
{
field
:
'activeName'
,
title
:
'活动名称'
},
{
field
:
'status'
,
title
:
'状态'
,
formatter
:
function
(
value
,
row
,
index
)
{
let
textArr
=
[
'开启'
,
'未启动'
];
return
textArr
[
value
]
}
},
{
field
:
'activeType'
,
title
:
'活动类型'
,
formatter
:
function
(
value
,
row
,
index
)
{
let
textArr
=
[
'NFT'
,
'组合购'
,
'演出'
,
'商品'
];
return
textArr
[
value
-
1
]
}
},
{
field
:
'name'
,
title
:
'关联名称'
},
{
field
:
'createdAt'
,
title
:
'创建时间'
,
formatter
:
function
(
value
,
row
,
index
)
{
return
$
.
common
.
dateFormat
(
new
Date
(
value
),
'yyyy-MM-dd HH:mm:ss'
)
}
},
{
title
:
'操作'
,
// align: 'center',
formatter
:
function
(
value
,
row
,
index
)
{
let
dataArr
=
[];
dataArr
.
push
(
`<span class="btn btn-primary btn-xs" href="javascript:void(0)" onclick="toEdit('
${
row
.
mid
}
')"><i class="fa fa-edit"></i>编辑</span>`
)
return
dataArr
.
join
(
' '
)
}
}]
};
$
.
table
.
init
(
options
);
$
(
"input[name='startTime']"
).
datetimepicker
({
format
:
"yyyy-mm-dd hh:ii:ss"
,
autoclose
:
true
});
$
(
"input[name='endTime']"
).
datetimepicker
({
format
:
"yyyy-mm-dd hh:ii:ss"
,
autoclose
:
true
});
// 选择select
$
(
'#activeType'
).
change
(
function
()
{
activeTypeChangeVal
=
Number
(
$
(
this
).
val
())
// 1 2 3 4
currentUrl
=
affiliatedUrl
[
activeTypeChangeVal
-
1
]
})
$
(
'#listActiveType1'
).
change
(
function
()
{
activeTypeChangeValChild
=
Number
(
$
(
this
).
val
())
// 1 2 3 4
currentChildUrl
=
affiliatedUrl
[
activeTypeChangeValChild
-
1
]
})
// 监听 模糊搜索
let
search
=
new
searchSelect
(
'#search'
,
[],
function
(
val
)
{
let
_params
=
{}
if
(
activeTypeChangeVal
===
1
)
{
_params
[
'type'
]
=
1
_params
[
'title'
]
=
val
}
else
if
(
activeTypeChangeVal
===
2
)
{
// 组合购
_params
[
'title'
]
=
val
}
else
if
(
activeTypeChangeVal
===
3
)
{
// 演出
_params
[
'status'
]
=
'(3,6,7,9,10)'
_params
[
'title'
]
=
val
}
else
{
// 商品
_params
[
'name'
]
=
val
// _params['title'] = val
}
let
_data
=
[]
$
.
ajax
({
type
:
'get'
,
url
:
ctx
+
currentUrl
,
contentType
:
"application/json;charset=UTF-8"
,
data
:
_params
,
success
:
function
(
res
)
{
let
_data
=
[]
let
nft
=
res
.
data
||
[]
let
group
=
res
.
data
||
[]
let
yan
=
res
.
value
||
[]
let
sp
=
res
.
data
||
[]
// let nft = [
// {spuId: "2219913102854826450", spuName: "测试百度链2"},
// {spuId: "2219914180134302603", spuName: "sku121"},
// {spuId: "2219914180134310692", spuName: "sku222"},
// {spuId: "2219919453537884760", spuName: "预定sku2"},
// {spuId: "2220116265978433388", spuName: "master2"},
// {spuId: "2220217443211696612", spuName: "盲盒预约2"},
// {spuId: "2220418044261869362", spuName: "测试百度2"},
// {spuId: "2221012455677371741", spuName: "万字至信链2"}
// ]
//
// let group = [
// {mixId: "222001044447601569205", name: "12", sellName: "123"},
// {mixId: "222001323109067903537", name: "GUAN花园往事数字藏品盲盒1", sellName: "GUAN 不朽之潮花园往事数字藏品+艺术微喷画(实体)"},
// {mixId: "222011421273134365656", name: "组合购1", sellName: "组合1"}
// ]
//
// let yan = [{ performancesId: "1408039332068474886513388", title: "测试热卖演出-01" }, { performancesId: "1408056987949219845840876", title: "718演出" }, { performancesId: "1408099963123548163199993", title: "719" }]
//
// let sp = [
// {
// name: "测试001",
// spuId: '22199135056404'
// },
// {
// name: "回归商品8",
// spuId: '22199200933490'
// }
// ]
if
(
activeTypeChangeVal
==
1
)
{
_data
=
nft
?.
map
(
item
=>
{
// 组装返回nft数据
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
else
if
(
activeTypeChangeVal
==
2
)
{
_data
=
group
?.
map
(
item
=>
{
return
{
id
:
item
.
mixId
,
value
:
item
.
name
}
})
}
else
if
(
activeTypeChangeVal
==
3
)
{
_data
=
yan
?.
map
(
item
=>
{
return
{
id
:
item
.
performancesId
,
value
:
item
.
title
}
})
}
else
if
(
activeTypeChangeVal
==
4
)
{
_data
=
sp
?.
map
(
item
=>
{
return
{
id
:
item
.
spuId
,
value
:
item
.
name
}
})
}
console
.
log
(
'_data -> '
,
_data
)
search
.
update
(
_data
)
// 更新数据
}
})
})
// 监听 模糊搜索 list
let
listRemoteSearch1
=
new
searchSelect
(
'#listRemoteSearch1'
,
[],
function
(
val
)
{
let
_params
=
{}
if
(
activeTypeChangeValChild
==
1
)
{
_params
[
'type'
]
=
1
_params
[
'title'
]
=
val
}
else
if
(
activeTypeChangeValChild
==
2
)
{
// 组合购
_params
[
'title'
]
=
val
}
else
if
(
activeTypeChangeValChild
==
3
)
{
// 演出
_params
[
'status'
]
=
'(3,6,7,9,10)'
_params
[
'title'
]
=
val
}
else
{
// 商品
_params
[
'name'
]
=
val
// _params['title'] = val
}
$
.
ajax
({
type
:
'get'
,
url
:
ctx
+
currentChildUrl
,
contentType
:
'application/json;charset=UTF-8'
,
data
:
_params
,
success
:
function
(
res
)
{
let
_data
=
[]
let
nft
=
res
.
data
||
[]
let
group
=
res
.
data
||
[]
let
yan
=
res
.
value
||
[]
let
sp
=
res
.
data
||
[]
if
(
activeTypeChangeValChild
==
1
)
{
_data
=
nft
?.
map
(
item
=>
{
// 组装返回nft数据
return
{
id
:
item
.
spuId
,
value
:
item
.
spuName
}
})
}
else
if
(
activeTypeChangeValChild
==
2
)
{
_data
=
group
?.
map
(
item
=>
{
return
{
id
:
item
.
mixId
,
value
:
item
.
name
}
})
}
else
if
(
activeTypeChangeValChild
==
3
)
{
_data
=
yan
?.
map
(
item
=>
{
return
{
id
:
item
.
performancesId
,
value
:
item
.
title
}
})
}
else
if
(
activeTypeChangeValChild
==
4
)
{
_data
=
sp
?.
map
(
item
=>
{
return
{
id
:
item
.
spuId
,
value
:
item
.
name
}
})
}
listRemoteSearch1
.
update
(
_data
)
}
})
})
// list 部分
});
// 保存
function
saveActivity
()
{
let
data
=
{
activeName
:
$
(
'#activeName'
).
val
(),
activeBindId
:
$
(
'#search input'
).
attr
(
'data-id'
),
startTime
:
$
(
'#startTime'
).
val
(),
endTime
:
$
(
'#endTime'
).
val
(),
activeType
:
Number
(
$
(
"#activeType"
).
find
(
"option:selected"
).
val
()),
status
:
Number
(
$
(
"#status"
).
find
(
"option:selected"
).
val
()),
list
:
listData
}
console
.
log
(
'saveActivity'
,
data
)
let
isRequired
=
data
.
startTime
&&
data
.
endTime
&&
data
.
activeType
console
.
log
(
'saveActivity-params'
,
data
)
if
(
isRequired
)
{
// 必填ok
$
.
ajax
({
url
:
`/kylin-recommend-active/addKylinRecommendActive`
,
type
:
'post'
,
headers
:
{
"Content-Type"
:
"application/json;charset=UTF-8"
},
data
:
JSON
.
stringify
(
data
),
success
:
function
(
res
)
{
if
(
res
.
code
==
200
)
{
alert
(
'新增成功'
)
layer
.
close
(
layer
.
index
)
}
else
{
layer
.
msg
(
res
.
msg
)
}
}
})
}
else
{
$
.
modal
.
msgWarning
(
"拒绝原因为必填项!"
)
}
}
// 保存关联活动内容
function
saveListAffiliated
()
{
let
_recommendBindId
=
$
(
'#listRemoteSearch1 input'
).
attr
(
'data-id'
)
console
.
log
(
'_recommendBindId'
,
_recommendBindId
)
let
_type
=
$
(
"#listActiveType1"
).
find
(
"option:selected"
).
val
()
// 已经获取
listData
.
push
({
recommendBindId
:
_recommendBindId
,
type
:
Number
(
_type
)
})
layer
.
close
(
layer
.
index
)
}
// 打开增加活动 modal
function
openAddActivityModal
()
{
layer
.
open
({
type
:
1
,
shade
:
.
3
,
title
:
'增加活动'
,
// 不显示标题
content
:
$
(
'#addClassify'
),
// 捕获的元素,注意:最好该指定的元素要存放在body最外层,否则可能被其它的相对元素所影响
cancel
:
function
(
res
){
// $("#addClassify").empty()
// layer.msg('捕获就是从页面已经存在的元素上,包裹layer的结构', {time: 5000, icon:6});
}
});
}
// 打开 list 选择 modal
function
openAffiliatedModal
(
val
,
index
)
{
layer
.
open
({
type
:
1
,
shade
:
.
3
,
title
:
'增加关联推荐'
,
// 不显示标题
content
:
$
(
'#addClassify2'
),
// 捕获的元素,注意:最好该指定的元素要存放在body最外层,否则可能被其它的相对元素所影响
cancel
:
function
(
res
)
{
// $("#addClassify2").empty()
// layer.msg('捕获就是从页面已经存在的元素上,包裹layer的结构', {time: 5000, icon:6});
}
});
// 设置 代入的 点击
$
(
'#listActiveType1'
).
find
(
`option[value=
${
index
}
]`
).
attr
(
'selected'
,
true
)
activeTypeChangeValChild
=
index
currentChildUrl
=
affiliatedUrl
[
activeTypeChangeValChild
]
}
// 跳转 增加
function
toadd
()
{
let
url
=
ctx
+
'local/affiliatedActivityadd'
;
$
.
modal
.
openTab
(
"关联活动增加"
,
url
);
}
// 跳转 编辑
function
toEdit
(
id
)
{
let
url
=
ctx
+
'local/affiliatedActivityEdit?id='
+
id
;
$
.
modal
.
openTab
(
"关联活动编辑"
,
url
);
}
// 关闭模态框
function
closeModal
()
{
layer
.
close
(
layer
.
index
)
}
// 关闭模态框2
function
closeModal2
()
{
layer
.
close
(
layer
.
index
)
}
// ------------------------------------------------------------------------------------------------------
function
opendTicketList
(
id
)
{
console
.
log
(
id
,
'121212121212activityTicketList'
)
var
url
=
prefix2
+
'/activityTicketList?id='
+
id
;
$
.
modal
.
openTab
(
"活动券列表"
,
url
);
}
// 导出数据
function
exportSelected
()
{
// console.log(userIds.toString(), 'dataParam')
$
.
modal
.
open
(
'创建活动'
,
prefix2
+
"/createActivityModal"
,
500
,
260
,
cancel
)
}
</script>
</body>
</html>
\ No newline at end of file
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/goblin/service/IGoblinCommonService.java
View file @
75cd17ba
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
goblin
.
service
;
import
com.liquidnet.service.goblin.dto.GoblinGoodsSearchDto
;
import
com.liquidnet.service.goblin.dto.GoblinMixSearchDto
;
import
com.liquidnet.service.goblin.dto.GoblinSkusSearchDto
;
import
com.liquidnet.service.goblin.dto.GoblinStoreSearchDto
;
...
...
@@ -11,9 +12,11 @@ import java.util.List;
*/
public
interface
IGoblinCommonService
{
List
<
GoblinStoreSearchDto
>
storeSearch
(
String
name
,
List
<
String
>
status
);
List
<
GoblinStoreSearchDto
>
storeSearch
(
String
name
,
List
<
String
>
status
);
List
<
GoblinGoodsSearchDto
>
goodsSearch
(
String
name
,
Integer
type
);
List
<
GoblinGoodsSearchDto
>
goodsSearch
(
String
name
,
Integer
type
,
String
shelvesStatus
,
String
spuAppear
);
List
<
GoblinSkusSearchDto
>
skuSearch
(
String
name
,
Integer
type
);
List
<
GoblinSkusSearchDto
>
skuSearch
(
String
name
,
Integer
type
,
String
shelvesStatus
);
List
<
GoblinMixSearchDto
>
mixSearch
(
String
name
);
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/goblin/service/IGoblinZhengzaiMarketService.java
View file @
75cd17ba
...
...
@@ -101,6 +101,13 @@ public interface IGoblinZhengzaiMarketService {
*/
ResponseDto
<
Boolean
>
zhengzaiStore
(
List
<
GoblinInsertZhengzaiParam
>
params
);
/**
* 删除正在下单 可参与活动店铺
*
* @return
*/
ResponseDto
<
Boolean
>
zhengzaiDelStore
(
String
marketId
,
String
storeId
);
/**
* 编辑正在下单 可参与活动店铺
*
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/goblin/service/impl/GoblinCommonServiceImpl.java
View file @
75cd17ba
...
...
@@ -5,13 +5,16 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import
com.liquidnet.client.admin.zhengzai.goblin.service.IGoblinCommonService
;
import
com.liquidnet.commons.lang.util.StringUtil
;
import
com.liquidnet.service.goblin.dto.GoblinGoodsSearchDto
;
import
com.liquidnet.service.goblin.dto.GoblinMixSearchDto
;
import
com.liquidnet.service.goblin.dto.GoblinSkusSearchDto
;
import
com.liquidnet.service.goblin.dto.GoblinStoreSearchDto
;
import
com.liquidnet.service.goblin.entity.GoblinGoods
;
import
com.liquidnet.service.goblin.entity.GoblinGoodsSku
;
import
com.liquidnet.service.goblin.entity.GoblinMix
;
import
com.liquidnet.service.goblin.entity.GoblinStoreInfo
;
import
com.liquidnet.service.goblin.mapper.GoblinGoodsMapper
;
import
com.liquidnet.service.goblin.mapper.GoblinGoodsSkuMapper
;
import
com.liquidnet.service.goblin.mapper.GoblinMixMapper
;
import
com.liquidnet.service.goblin.mapper.GoblinStoreInfoMapper
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -38,6 +41,8 @@ public class GoblinCommonServiceImpl implements IGoblinCommonService {
GoblinGoodsMapper
goblinGoodsMapper
;
@Autowired
GoblinGoodsSkuMapper
goblinGoodsSkuMapper
;
@Autowired
GoblinMixMapper
goblinMixMapper
;
@Override
public
List
<
GoblinStoreSearchDto
>
storeSearch
(
String
name
,
List
<
String
>
status
)
{
...
...
@@ -57,14 +62,22 @@ public class GoblinCommonServiceImpl implements IGoblinCommonService {
}
@Override
public
List
<
GoblinGoodsSearchDto
>
goodsSearch
(
String
name
,
Integer
type
)
{
public
List
<
GoblinGoodsSearchDto
>
goodsSearch
(
String
name
,
Integer
type
,
String
shelvesStatus
,
String
spuAppear
)
{
if
(
type
==
null
)
{
//普通商品
type
=
1
;
}
LambdaQueryWrapper
<
GoblinGoods
>
queryWrapper
=
Wrappers
.
lambdaQuery
(
GoblinGoods
.
class
);
queryWrapper
.
ne
(
GoblinGoods:
:
getDelFlg
,
"1"
);
queryWrapper
.
eq
(
GoblinGoods:
:
getShelvesStatus
,
"3"
);
queryWrapper
.
eq
(
GoblinGoods:
:
getSpuAppear
,
"0"
);
if
(
shelvesStatus
!=
null
)
{
queryWrapper
.
eq
(
GoblinGoods:
:
getShelvesStatus
,
shelvesStatus
);
}
else
{
// queryWrapper.eq(GoblinGoods::getShelvesStatus, "3");
}
if
(
spuAppear
!=
null
)
{
queryWrapper
.
eq
(
GoblinGoods:
:
getSpuAppear
,
spuAppear
);
}
else
{
/* queryWrapper.eq(GoblinGoods::getSpuAppear, "1");*/
}
queryWrapper
.
eq
(
GoblinGoods:
:
getSpuType
,
type
);
if
(
StringUtil
.
isNotBlank
(
name
))
{
queryWrapper
.
like
(
GoblinGoods:
:
getName
,
name
);
...
...
@@ -81,13 +94,17 @@ public class GoblinCommonServiceImpl implements IGoblinCommonService {
}
@Override
public
List
<
GoblinSkusSearchDto
>
skuSearch
(
String
name
,
Integer
type
)
{
public
List
<
GoblinSkusSearchDto
>
skuSearch
(
String
name
,
Integer
type
,
String
shelvesStatus
)
{
if
(
type
==
null
)
{
//普通商品
type
=
1
;
}
LambdaQueryWrapper
<
GoblinGoodsSku
>
queryWrapper
=
Wrappers
.
lambdaQuery
(
GoblinGoodsSku
.
class
);
queryWrapper
.
ne
(
GoblinGoodsSku:
:
getDelFlg
,
"1"
);
queryWrapper
.
eq
(
GoblinGoodsSku:
:
getShelvesStatus
,
"3"
);
if
(
shelvesStatus
!=
null
)
{
queryWrapper
.
eq
(
GoblinGoodsSku:
:
getShelvesStatus
,
shelvesStatus
);
}
else
{
// queryWrapper.eq(GoblinGoodsSku::getShelvesStatus, "3");
}
// queryWrapper.eq(GoblinGoodsSku::getSpuAppear, "0");
queryWrapper
.
eq
(
GoblinGoodsSku:
:
getSkuType
,
type
);
if
(
StringUtil
.
isNotBlank
(
name
))
{
...
...
@@ -103,4 +120,23 @@ public class GoblinCommonServiceImpl implements IGoblinCommonService {
}
return
dtoList
;
}
@Override
public
List
<
GoblinMixSearchDto
>
mixSearch
(
String
name
)
{
LambdaQueryWrapper
<
GoblinMix
>
queryWrapper
=
Wrappers
.
lambdaQuery
(
GoblinMix
.
class
);
queryWrapper
.
ne
(
GoblinMix:
:
getDelTag
,
"1"
);
if
(
StringUtil
.
isNotBlank
(
name
))
{
queryWrapper
.
like
(
GoblinMix:
:
getSellName
,
name
);
}
List
<
GoblinMix
>
list
=
goblinMixMapper
.
selectList
(
queryWrapper
.
last
(
"limit 20"
));
List
<
GoblinMixSearchDto
>
dtoList
=
new
ArrayList
<>();
for
(
GoblinMix
item
:
list
)
{
GoblinMixSearchDto
dto
=
GoblinMixSearchDto
.
getNew
();
dto
.
setMixId
(
item
.
getMixId
());
dto
.
setName
(
item
.
getName
());
dto
.
setSellName
(
item
.
getSellName
());
dtoList
.
add
(
dto
);
}
return
dtoList
;
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/goblin/service/impl/GoblinZhengzaiMarketServiceImpl.java
View file @
75cd17ba
...
...
@@ -119,11 +119,17 @@ public class GoblinZhengzaiMarketServiceImpl implements IGoblinZhengzaiMarketSer
@Override
public
ResponseDto
<
String
>
zhengzaiInsert
(
String
purchaseName
,
String
performanceId
,
String
img
,
String
st
,
String
et
)
{
int
count
=
goblinSelfMarketingMapper
.
selectCount
(
Wrappers
.
lambdaUpdate
(
GoblinSelfMarketing
.
class
).
eq
(
GoblinSelfMarketing:
:
getPerformanceId
,
performanceId
).
eq
(
GoblinSelfMarketing:
:
getDelFlag
,
0
));
if
(
count
>
0
)
{
return
ResponseDto
.
failure
(
"该演出已关联活动"
);
}
GoblinSelfMarketing
selfMarketing
=
GoblinSelfMarketing
.
getNew
();
String
SelfMarketId
=
IDGenerator
.
nextTimeId2
();
selfMarketing
.
setSelfMarketId
(
SelfMarketId
);
selfMarketing
.
setName
(
purchaseName
);
selfMarketing
.
setPerformanceId
(
performanceId
);
selfMarketing
.
setPerformanceImg
(
img
);
selfMarketing
.
setType
(
GoblinStatusConst
.
MarketingStatus
.
SELF_TYPE_ZHENGZAI
.
getValue
());
selfMarketing
.
setStartTime
(
LocalDateTime
.
parse
(
st
,
DTF_YMD_HMS
));
selfMarketing
.
setEndTime
(
LocalDateTime
.
parse
(
et
,
DTF_YMD_HMS
));
...
...
@@ -147,9 +153,19 @@ public class GoblinZhengzaiMarketServiceImpl implements IGoblinZhengzaiMarketSer
@Override
public
ResponseDto
<
Boolean
>
zhengzaiUpdate
(
String
marketId
,
String
purchaseName
,
String
performanceId
,
String
img
,
String
st
,
String
et
)
{
// GoblinSelfMarketingVo data =goblinRedisUtils.getSelfMarket(marketId);
// if(data.getPerformanceId().equals(performanceId)){
//
// }else {
int
count
=
goblinSelfMarketingMapper
.
selectCount
(
Wrappers
.
lambdaUpdate
(
GoblinSelfMarketing
.
class
).
eq
(
GoblinSelfMarketing:
:
getPerformanceId
,
performanceId
).
ne
(
GoblinSelfMarketing:
:
getSelfMarketId
,
marketId
).
eq
(
GoblinSelfMarketing:
:
getDelFlag
,
0
));
if
(
count
>
0
)
{
return
ResponseDto
.
failure
(
"该演出已关联活动"
);
}
// }
GoblinSelfMarketing
selfMarketing
=
GoblinSelfMarketing
.
getNew
();
selfMarketing
.
setSelfMarketId
(
marketId
);
selfMarketing
.
setName
(
purchaseName
);
selfMarketing
.
setPerformanceImg
(
img
);
selfMarketing
.
setType
(
GoblinStatusConst
.
MarketingStatus
.
SELF_TYPE_ZHENGZAI
.
getValue
());
selfMarketing
.
setStartTime
(
LocalDateTime
.
parse
(
st
,
DTF_YMD_HMS
));
selfMarketing
.
setEndTime
(
LocalDateTime
.
parse
(
et
,
DTF_YMD_HMS
));
...
...
@@ -173,7 +189,7 @@ public class GoblinZhengzaiMarketServiceImpl implements IGoblinZhengzaiMarketSer
@Override
public
ResponseDto
<
GoblinSelfMarketingVo
>
zhengzaiDetails
(
String
marketId
)
{
GoblinSelfMarketing
bean
=
goblinSelfMarketingMapper
.
selectOne
(
Wrappers
.
lambdaUpdate
(
GoblinSelfMarketing
.
getNew
()).
eq
(
GoblinSelfMarketing:
:
getSelfMarketId
,
marketId
));
GoblinSelfMarketing
bean
=
goblinSelfMarketingMapper
.
selectOne
(
Wrappers
.
lambdaUpdate
(
GoblinSelfMarketing
.
getNew
()).
eq
(
GoblinSelfMarketing:
:
getSelfMarketId
,
marketId
)
.
eq
(
GoblinSelfMarketing:
:
getDelFlag
,
0
)
);
GoblinSelfMarketingVo
vo
=
GoblinSelfMarketingVo
.
getNew
();
BeanUtils
.
copyProperties
(
bean
,
vo
);
vo
.
setStartTime
(
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
format
(
bean
.
getStartTime
()));
...
...
@@ -209,6 +225,7 @@ public class GoblinZhengzaiMarketServiceImpl implements IGoblinZhengzaiMarketSer
entity
.
setSelfMarketId
(
marketId
);
entity
.
setStoreId
(
storeId
);
entity
.
setShowTime
(
LocalDateTime
.
parse
(
showTime
,
DTF_YMD_HMS
));
entity
.
setCreatedAt
(
LocalDateTime
.
now
());
if
(
goblinRedisUtils
.
getZhengzaiRelation
(
storeId
).
contains
(
marketId
))
{
return
ResponseDto
.
failure
(
"禁止重复添加"
);
}
...
...
@@ -264,6 +281,28 @@ public class GoblinZhengzaiMarketServiceImpl implements IGoblinZhengzaiMarketSer
return
ResponseDto
.
success
();
}
@Override
public
ResponseDto
<
Boolean
>
zhengzaiDelStore
(
String
marketId
,
String
storeId
)
{
try
{
GoblinMarketingZhengzaiRelation
entity
=
GoblinMarketingZhengzaiRelation
.
getNew
();
entity
.
setDelTag
(
1
);
entity
.
setUpdatedAt
(
LocalDateTime
.
now
());
entity
.
setStoreId
(
storeId
);
entity
.
setSelfMarketId
(
marketId
);
//mysql
goblinMarketingZhengzaiRelationMapper
.
update
(
entity
,
Wrappers
.
lambdaUpdate
(
GoblinMarketingZhengzaiRelation
.
getNew
()).
eq
(
GoblinMarketingZhengzaiRelation:
:
getSelfMarketId
,
marketId
).
eq
(
GoblinMarketingZhengzaiRelation:
:
getStoreId
,
storeId
));
//mongo
goblinMongoUtils
.
delZhengzaiRelation
(
marketId
,
storeId
);
//redis
goblinRedisUtils
.
delZhengzaiRelation
(
marketId
,
storeId
);
goblinRedisUtils
.
delStoreSelfRelation
(
marketId
,
storeId
);
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResponseDto
.
failure
(
"删除失败"
);
}
}
@Override
public
ResponseDto
<
Boolean
>
zhengzaiStoreUpdate
(
List
<
GoblinInsertZhengzaiParam
>
params
)
{
for
(
GoblinInsertZhengzaiParam
item
:
params
)
{
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/goblin/utils/GoblinRedisUtils.java
View file @
75cd17ba
...
...
@@ -45,6 +45,21 @@ public class GoblinRedisUtils {
redisDataSourceUtil
.
getRedisGoblinUtil
().
del
(
redisKey
);
}
/**
* 删除店铺活动
*
* @param selfMarketId
*/
public
GoblinSelfMarketingVo
getSelfMarket
(
String
selfMarketId
)
{
String
redisKey
=
GoblinRedisConst
.
REDIS_GOBLIN_SELF_MARKET
.
concat
(
selfMarketId
);
Object
obj
=
redisDataSourceUtil
.
getRedisGoblinUtil
().
get
(
redisKey
);
if
(
obj
==
null
){
return
GoblinSelfMarketingVo
.
getNew
();
}
else
{
return
(
GoblinSelfMarketingVo
)
obj
;
}
}
/**
* 正在下单 可参加商户
*
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinRecommendActiveRelationServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActive
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActiveRelation
;
import
com.liquidnet.service.kylin.mapper.KylinRecommendActiveRelationMapper
;
import
com.liquidnet.service.kylin.service.admin.IKylinRecommendActiveRelationService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.beans.Transient
;
import
java.time.LocalDateTime
;
import
java.util.List
;
/**
* <p>
* 推荐活动关联表 服务实现类
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
@Service
public
class
KylinRecommendActiveRelationServiceImpl
extends
ServiceImpl
<
KylinRecommendActiveRelationMapper
,
KylinRecommendActiveRelation
>
implements
IKylinRecommendActiveRelationService
{
@Autowired
private
KylinRecommendActiveServiceImpl
kylinRecommendActiveService
;
@Autowired
private
KylinRecommendActiveRelationMapper
kylinRecommendActiveRelationMapper
;
@Override
public
boolean
addKylinRecommendActiveRelation
(
KylinRecommendActiveRelation
kylinRecommendActiveRelation
)
{
kylinRecommendActiveRelation
.
setDelTag
(
0
);
kylinRecommendActiveRelation
.
setUpdatedAt
(
LocalDateTime
.
now
());
kylinRecommendActiveRelation
.
setCreatedAt
(
LocalDateTime
.
now
());
kylinRecommendActiveRelation
.
setRecommendRelationId
(
IDGenerator
.
nextSnowId
());
kylinRecommendActiveRelationMapper
.
insert
(
kylinRecommendActiveRelation
);
//更新 redis
KylinRecommendActive
byRecommendId
=
kylinRecommendActiveService
.
getByRecommendId
(
kylinRecommendActiveRelation
.
getRecommendActiveId
());
kylinRecommendActiveService
.
updateRedis
(
byRecommendId
);
return
true
;
}
@Override
@Transient
public
boolean
addListKylinRecommendActiveRelation
(
List
<
KylinRecommendActiveRelation
>
list
)
{
//先删除 这个活动的 推荐活动
LambdaQueryWrapper
<
KylinRecommendActiveRelation
>
lambdaQueryWrapper
=
new
LambdaQueryWrapper
();
lambdaQueryWrapper
.
eq
(
KylinRecommendActiveRelation:
:
getRecommendActiveId
,
list
.
get
(
0
).
getRecommendActiveId
());
kylinRecommendActiveRelationMapper
.
delete
(
lambdaQueryWrapper
);
//然后插入
for
(
KylinRecommendActiveRelation
ky:
list
){
ky
.
setDelTag
(
0
);
ky
.
setCreatedAt
(
LocalDateTime
.
now
());
ky
.
setUpdatedAt
(
LocalDateTime
.
now
());
//recommendRelationId
ky
.
setRecommendRelationId
(
IDGenerator
.
nextSnowId
());
ky
.
setRecommendRelationId
(
list
.
get
(
0
).
getRecommendActiveId
());
kylinRecommendActiveRelationMapper
.
insert
(
ky
);
}
//更新 redis
KylinRecommendActive
byRecommendId
=
kylinRecommendActiveService
.
getByRecommendId
(
list
.
get
(
0
).
getRecommendActiveId
());
kylinRecommendActiveService
.
updateRedis
(
byRecommendId
);
return
true
;
}
@Override
public
boolean
deleteKylinRecommendActiveRelation
(
KylinRecommendActiveRelation
kylinRecommendActiveRelation
)
{
kylinRecommendActiveRelation
.
setDelTag
(
1
);
kylinRecommendActiveRelationMapper
.
updateById
(
kylinRecommendActiveRelation
);
//更新 redis
KylinRecommendActive
byRecommendId
=
kylinRecommendActiveService
.
getByRecommendId
(
kylinRecommendActiveRelation
.
getRecommendActiveId
());
kylinRecommendActiveService
.
updateRedis
(
byRecommendId
);
return
true
;
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinRecommendActiveServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.github.pagehelper.PageHelper
;
import
com.liquidnet.common.cache.redis.util.RedisDataSourceUtil
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.goblin.entity.GoblinGoods
;
import
com.liquidnet.service.goblin.entity.GoblinGoodsSku
;
import
com.liquidnet.service.goblin.entity.GoblinMix
;
import
com.liquidnet.service.goblin.mapper.GoblinGoodsMapper
;
import
com.liquidnet.service.goblin.mapper.GoblinGoodsSkuMapper
;
import
com.liquidnet.service.goblin.mapper.GoblinMixMapper
;
import
com.liquidnet.service.kylin.constant.KylinRedisConst
;
import
com.liquidnet.service.kylin.entity.KylinPerformances
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActive
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActiveRelation
;
import
com.liquidnet.service.kylin.mapper.KylinPerformancesMapper
;
import
com.liquidnet.service.kylin.mapper.KylinRecommendActiveMapper
;
import
com.liquidnet.service.kylin.mapper.KylinRecommendActiveRelationMapper
;
import
com.liquidnet.service.kylin.service.admin.IKylinRecommendActiveService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.time.LocalDateTime
;
import
java.util.ArrayList
;
import
java.util.List
;
/**
* <p>
* 推荐活动表 服务实现类
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
@Service
public
class
KylinRecommendActiveServiceImpl
extends
ServiceImpl
<
KylinRecommendActiveMapper
,
KylinRecommendActive
>
implements
IKylinRecommendActiveService
{
@Autowired
private
KylinRecommendActiveMapper
kylinRecommendActiveMapper
;
@Autowired
private
KylinRecommendActiveRelationMapper
kylinRecommendActiveRelationMapper
;
@Autowired
RedisDataSourceUtil
redisDataSourceUtil
;
@Autowired
private
KylinPerformancesMapper
performancesMapper
;
@Autowired
GoblinGoodsMapper
goblinGoodsMapper
;
@Autowired
GoblinGoodsSkuMapper
goblinGoodsSkuMapper
;
@Autowired
GoblinMixMapper
goblinMixMapper
;
@Override
public
boolean
addKylinRecommendActive
(
KylinRecommendActive
kylinRecommendActive
,
List
<
KylinRecommendActiveRelation
>
kylinRecommendActiveRelations
)
{
//生成id
kylinRecommendActive
.
setRecommendId
(
IDGenerator
.
nextSnowId
());
kylinRecommendActive
.
setCreatedAt
(
LocalDateTime
.
now
());
kylinRecommendActive
.
setUpdatedAt
(
LocalDateTime
.
now
());
kylinRecommendActive
.
setDelTag
(
0
);
kylinRecommendActiveMapper
.
insert
(
kylinRecommendActive
);
//保存推荐活动关系
kylinRecommendActiveRelations
.
forEach
(
r
->
{
r
.
setCreatedAt
(
LocalDateTime
.
now
());
r
.
setUpdatedAt
(
LocalDateTime
.
now
());
r
.
setDelTag
(
0
);
r
.
setRecommendActiveId
(
kylinRecommendActive
.
getRecommendId
());
r
.
setRecommendRelationId
(
IDGenerator
.
nextSnowId
());
kylinRecommendActiveRelationMapper
.
insert
(
r
);
});
//更新redis数据
this
.
updateRedis
(
kylinRecommendActive
);
return
true
;
}
@Override
public
boolean
updateKylinRecommendActive
(
KylinRecommendActive
kylinRecommendActive
)
{
KylinRecommendActive
kylinRecommendActive1
=
kylinRecommendActiveMapper
.
selectById
(
kylinRecommendActive
.
getMid
());
redisDataSourceUtil
.
getRedisKylinUtil
().
del
(
KylinRedisConst
.
RECOMMEND_ACTIVE
+
kylinRecommendActive1
.
getActiveBindId
());
kylinRecommendActiveMapper
.
updateById
(
kylinRecommendActive
);
//更新redis数据
this
.
updateRedis
(
kylinRecommendActive
);
return
true
;
}
@Override
public
List
<
KylinRecommendActive
>
pageKylinAcitve
(
int
pageSize
,
int
pageNumber
)
{
PageHelper
.
startPage
(
pageNumber
,
pageSize
,
"created_at desc"
);
LambdaQueryWrapper
<
KylinRecommendActive
>
queryWrapper
=
Wrappers
.
lambdaQuery
(
KylinRecommendActive
.
class
);
queryWrapper
.
eq
(
KylinRecommendActive:
:
getDelTag
,
0
);
List
<
KylinRecommendActive
>
list
=
kylinRecommendActiveMapper
.
selectList
(
queryWrapper
);
list
.
forEach
(
r
->
{
//1NFT2组合购3演出4商品
if
(
r
.
getActiveType
()
==
1
)
{
LambdaQueryWrapper
<
GoblinGoodsSku
>
queryWrapperg
=
Wrappers
.
lambdaQuery
(
GoblinGoodsSku
.
class
);
queryWrapperg
.
eq
(
GoblinGoodsSku:
:
getSkuId
,
r
.
getActiveBindId
());
GoblinGoodsSku
goblinGoodsSku
=
goblinGoodsSkuMapper
.
selectOne
(
queryWrapperg
);
if
(
null
!=
goblinGoodsSku
)
{
r
.
setName
(
goblinGoodsSku
.
getName
());
}
}
else
if
(
r
.
getActiveType
()
==
2
)
{
LambdaQueryWrapper
<
GoblinMix
>
queryWrapperm
=
Wrappers
.
lambdaQuery
(
GoblinMix
.
class
);
queryWrapperm
.
eq
(
GoblinMix:
:
getMixId
,
r
.
getActiveBindId
());
GoblinMix
goblinMix
=
goblinMixMapper
.
selectOne
(
queryWrapperm
);
if
(
null
!=
goblinMix
)
{
r
.
setName
(
goblinMix
.
getSellName
());
}
}
else
if
(
r
.
getActiveType
()
==
3
)
{
LambdaQueryWrapper
<
KylinPerformances
>
queryWrapperp
=
Wrappers
.
lambdaQuery
(
KylinPerformances
.
class
);
queryWrapperp
.
eq
(
KylinPerformances:
:
getPerformancesId
,
r
.
getActiveBindId
());
KylinPerformances
kylinPerformances
=
performancesMapper
.
selectOne
(
queryWrapperp
);
if
(
null
!=
kylinPerformances
)
{
r
.
setName
(
kylinPerformances
.
getTitle
());
}
}
else
if
(
r
.
getActiveType
()
==
4
)
{
LambdaQueryWrapper
<
GoblinGoods
>
queryWrapperg
=
Wrappers
.
lambdaQuery
(
GoblinGoods
.
class
);
queryWrapperg
.
eq
(
GoblinGoods:
:
getSpuId
,
r
.
getActiveBindId
());
GoblinGoods
goblinGoods
=
goblinGoodsMapper
.
selectOne
(
queryWrapperg
);
if
(
null
!=
goblinGoods
)
{
r
.
setName
(
goblinGoods
.
getName
());
}
}
});
return
list
;
}
@Override
public
KylinRecommendActive
getKylinRecommendActiveById
(
int
mid
)
{
//获得推荐活动
KylinRecommendActive
kylinRecommendActive
=
kylinRecommendActiveMapper
.
selectById
(
mid
);
if
(
kylinRecommendActive
.
getActiveType
()
==
1
)
{
LambdaQueryWrapper
<
GoblinGoodsSku
>
queryWrapperg
=
Wrappers
.
lambdaQuery
(
GoblinGoodsSku
.
class
);
queryWrapperg
.
eq
(
GoblinGoodsSku:
:
getSkuId
,
kylinRecommendActive
.
getActiveBindId
());
GoblinGoodsSku
goblinGoodsSku
=
goblinGoodsSkuMapper
.
selectOne
(
queryWrapperg
);
if
(
null
!=
goblinGoodsSku
)
{
kylinRecommendActive
.
setName
(
goblinGoodsSku
.
getName
());
}
}
else
if
(
kylinRecommendActive
.
getActiveType
()
==
2
)
{
LambdaQueryWrapper
<
GoblinMix
>
queryWrapperm
=
Wrappers
.
lambdaQuery
(
GoblinMix
.
class
);
queryWrapperm
.
eq
(
GoblinMix:
:
getMixId
,
kylinRecommendActive
.
getActiveBindId
());
GoblinMix
goblinMix
=
goblinMixMapper
.
selectOne
(
queryWrapperm
);
if
(
null
!=
goblinMix
)
{
kylinRecommendActive
.
setName
(
goblinMix
.
getSellName
());
}
}
else
if
(
kylinRecommendActive
.
getActiveType
()
==
3
)
{
LambdaQueryWrapper
<
KylinPerformances
>
queryWrapperp
=
Wrappers
.
lambdaQuery
(
KylinPerformances
.
class
);
queryWrapperp
.
eq
(
KylinPerformances:
:
getPerformancesId
,
kylinRecommendActive
.
getActiveBindId
());
KylinPerformances
kylinPerformances
=
performancesMapper
.
selectOne
(
queryWrapperp
);
if
(
null
!=
kylinPerformances
)
{
kylinRecommendActive
.
setName
(
kylinPerformances
.
getTitle
());
}
}
else
if
(
kylinRecommendActive
.
getActiveType
()
==
4
)
{
LambdaQueryWrapper
<
GoblinGoods
>
queryWrapperg
=
Wrappers
.
lambdaQuery
(
GoblinGoods
.
class
);
queryWrapperg
.
eq
(
GoblinGoods:
:
getSpuId
,
kylinRecommendActive
.
getActiveBindId
());
GoblinGoods
goblinGoods
=
goblinGoodsMapper
.
selectOne
(
queryWrapperg
);
if
(
null
!=
goblinGoods
)
{
kylinRecommendActive
.
setName
(
goblinGoods
.
getName
());
}
}
//获得推荐商品
LambdaQueryWrapper
<
KylinRecommendActiveRelation
>
queryWrapper
=
Wrappers
.
lambdaQuery
(
KylinRecommendActiveRelation
.
class
);
queryWrapper
.
eq
(
KylinRecommendActiveRelation:
:
getRecommendActiveId
,
kylinRecommendActive
.
getRecommendId
());
queryWrapper
.
eq
(
KylinRecommendActiveRelation:
:
getDelTag
,
0
);
List
<
KylinRecommendActiveRelation
>
kylinRecommendActiveRelations
=
kylinRecommendActiveRelationMapper
.
selectList
(
queryWrapper
);
for
(
KylinRecommendActiveRelation
r
:
kylinRecommendActiveRelations
)
{
//1NFT2组合购3演出4商品
if
(
r
.
getType
()
==
1
)
{
LambdaQueryWrapper
<
GoblinGoodsSku
>
queryWrapperg
=
Wrappers
.
lambdaQuery
(
GoblinGoodsSku
.
class
);
queryWrapperg
.
eq
(
GoblinGoodsSku:
:
getSkuId
,
r
.
getRecommendBindId
());
GoblinGoodsSku
goblinGoodsSku
=
goblinGoodsSkuMapper
.
selectOne
(
queryWrapperg
);
if
(
null
!=
goblinGoodsSku
)
{
r
.
setName
(
goblinGoodsSku
.
getName
());
}
}
else
if
(
r
.
getType
()
==
2
)
{
LambdaQueryWrapper
<
GoblinMix
>
queryWrapperm
=
Wrappers
.
lambdaQuery
(
GoblinMix
.
class
);
queryWrapperm
.
eq
(
GoblinMix:
:
getMixId
,
r
.
getRecommendBindId
());
GoblinMix
goblinMix
=
goblinMixMapper
.
selectOne
(
queryWrapperm
);
if
(
null
!=
goblinMix
)
{
r
.
setName
(
goblinMix
.
getSellName
());
}
}
else
if
(
r
.
getType
()
==
3
)
{
LambdaQueryWrapper
<
KylinPerformances
>
queryWrapperp
=
Wrappers
.
lambdaQuery
(
KylinPerformances
.
class
);
queryWrapperp
.
eq
(
KylinPerformances:
:
getPerformancesId
,
r
.
getRecommendBindId
());
KylinPerformances
kylinPerformances
=
performancesMapper
.
selectOne
(
queryWrapperp
);
if
(
null
!=
kylinPerformances
)
{
r
.
setName
(
kylinPerformances
.
getTitle
());
}
}
else
if
(
r
.
getType
()
==
4
)
{
LambdaQueryWrapper
<
GoblinGoods
>
queryWrapperg
=
Wrappers
.
lambdaQuery
(
GoblinGoods
.
class
);
queryWrapperg
.
eq
(
GoblinGoods:
:
getSpuId
,
r
.
getRecommendBindId
());
GoblinGoods
goblinGoods
=
goblinGoodsMapper
.
selectOne
(
queryWrapperg
);
if
(
null
!=
goblinGoods
)
{
r
.
setName
(
goblinGoods
.
getName
());
}
}
}
kylinRecommendActive
.
setList
(
kylinRecommendActiveRelations
);
return
kylinRecommendActive
;
}
@Override
public
KylinRecommendActive
getByRecommendId
(
String
id
)
{
LambdaQueryWrapper
<
KylinRecommendActive
>
queryWrapper
=
Wrappers
.
lambdaQuery
(
KylinRecommendActive
.
class
);
queryWrapper
.
eq
(
KylinRecommendActive:
:
getRecommendId
,
id
);
return
kylinRecommendActiveMapper
.
selectOne
(
queryWrapper
);
}
@Override
public
int
validateTime
(
KylinRecommendActive
kylinRecommendActive
)
{
return
kylinRecommendActiveMapper
.
validateTime
(
kylinRecommendActive
);
}
@Override
public
void
updateRedis
(
KylinRecommendActive
kylinRecommendActive
)
{
//查出这个类型, 这个演出 对应配置的数据
List
<
KylinRecommendActive
>
list
=
kylinRecommendActiveMapper
.
getBybindId
(
kylinRecommendActive
.
getActiveType
(),
kylinRecommendActive
.
getActiveBindId
());
List
<
KylinRecommendActive
>
redisList
=
new
ArrayList
<>();
list
.
forEach
(
r
->
{
//查推荐商品
redisList
.
add
(
this
.
getKylinRecommendActiveById
(
r
.
getMid
().
intValue
()));
});
redisDataSourceUtil
.
getRedisKylinUtil
().
set
(
KylinRedisConst
.
RECOMMEND_ACTIVE
+
kylinRecommendActive
.
getActiveBindId
(),
redisList
);
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/utils/DataUtils.java
View file @
75cd17ba
...
...
@@ -3,6 +3,7 @@ package com.liquidnet.client.admin.zhengzai.kylin.utils;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.client.admin.zhengzai.kylin.dto.OrderOutLineVo
;
import
com.liquidnet.common.cache.redis.util.RedisDataSourceUtil
;
import
com.liquidnet.commons.lang.util.CollectionUtil
;
import
com.liquidnet.service.kylin.constant.KylinRedisConst
;
import
com.liquidnet.service.kylin.dto.vo.KylinExpressModuleVo
;
import
com.liquidnet.service.kylin.dto.vo.admin.OrderRefundAddress
;
...
...
@@ -504,4 +505,30 @@ public class DataUtils {
return
(
String
)
obj
;
}
}
//删除 订单Ar激活码
public
void
delOrderArCode
(
String
orderId
){
String
rdk
=
KylinRedisConst
.
ORDER_AR_CODE
.
concat
(
orderId
);
redisDataSourceUtil
.
getRedisKylinUtil
().
del
(
rdk
);
}
//添加 订单Ar激活码
public
void
addOrderArCode
(
String
orderId
,
String
arCode
){
String
rdk
=
KylinRedisConst
.
ORDER_AR_CODE
.
concat
(
orderId
);
List
<
String
>
data
=
getOrderArCode
(
orderId
);
data
.
add
(
arCode
);
redisDataSourceUtil
.
getRedisKylinUtil
().
set
(
rdk
,
data
);
}
//获取 订单Ar激活码
public
List
<
String
>
getOrderArCode
(
String
orderId
){
String
rdk
=
KylinRedisConst
.
ORDER_AR_CODE
.
concat
(
orderId
);
Object
obj
=
redisDataSourceUtil
.
getRedisKylinUtil
().
get
(
rdk
);
if
(
obj
==
null
){
return
CollectionUtil
.
arrayListString
();
}
else
{
return
(
List
<
String
>)
obj
;
}
}
}
liquidnet-bus-config/liquidnet-config/liquidnet-client-admin-web.yml
View file @
75cd17ba
...
...
@@ -17,8 +17,8 @@ ruoyi:
liquidnet
:
url-banner
:
url6
:
"
/kylin/performances/recommend/performance/status?pageNum=1&pageSize=50&status=(3,6,7,8,9,10)"
#票务
url7
:
"
/goblin/common/goods?type=0"
#商品
url9
:
"
/goblin/common/sku?type=1"
#NFT
url7
:
"
/goblin/common/goods?type=0
&shelvesStatus=3&spuAppear=1
"
#商品
url9
:
"
/goblin/common/sku?type=1
&shelvesStatus=3
"
#NFT
url14
:
"
${liquidnet.client.admin.phpMallUrl}/admin/good/collective/quick?page=1&per_page=50"
#商品集合
# 开发环境配置
...
...
liquidnet-bus-config/liquidnet-config/liquidnet-service-kylin.yml
View file @
75cd17ba
...
...
@@ -138,6 +138,7 @@ global-auth:
-
${liquidnet.info.context}/performance/calendarPerformances
-
${liquidnet.info.context}/performance/*
-
${liquidnet.info.context}/myPerformance/*
-
${liquidnet.info.context}/recommendActive/*
# 场地摄像头列表
-
${liquidnet.info.context}/camera/list
-
${liquidnet.info.context}/inner/**
...
...
liquidnet-bus-do/liquidnet-service-goblin-do/src/main/java/com/liquidnet/service/goblin/entity/GoblinMix.java
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
goblin
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
java.io.Serializable
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
/**
* <p>
...
...
@@ -40,6 +40,7 @@ public class GoblinMix implements Serializable {
/**
* 混合名称
*/
@TableField
(
value
=
"`name`"
)
private
String
name
;
/**
...
...
@@ -55,6 +56,7 @@ public class GoblinMix implements Serializable {
/**
* 状态[6-启用|7-停用]
*/
@TableField
(
value
=
"`status`"
)
private
Integer
status
;
/**
...
...
@@ -120,6 +122,7 @@ public class GoblinMix implements Serializable {
/**
* 限购数量[0-不限购]
*/
@TableField
(
value
=
"`limit`"
)
private
Integer
limit
;
/**
...
...
@@ -145,11 +148,12 @@ public class GoblinMix implements Serializable {
/**
* 店铺id
*/
private
Integer
storeId
;
private
String
storeId
;
/**
* 补充字段
*/
@TableField
(
value
=
"`comment`"
)
private
String
comment
;
/**
...
...
liquidnet-bus-do/liquidnet-service-goblin-do/src/main/java/com/liquidnet/service/goblin/entity/GoblinSelfMarketing.java
View file @
75cd17ba
...
...
@@ -36,6 +36,11 @@ public class GoblinSelfMarketing implements Serializable, Cloneable {
*/
private
String
performanceId
;
/**
* 演出id
*/
private
String
performanceImg
;
/**
* 营销名称
*/
...
...
liquidnet-bus-do/liquidnet-service-goblin-do/src/main/resources/com.liquidnet.service.goblin.mapper/GoblinSelfMarketingMapper.xml
View file @
75cd17ba
...
...
@@ -50,8 +50,8 @@ from goblin_self_marketing as a
inner join goblin_marketing_zhengzai_relation as b on a.self_market_id = b.self_market_id
inner join goblin_store_info as c on c.store_id = b.store_id
left join goblin_marketing_zhengzai as d on d.store_id = b.store_id and d.self_market_id = b.self_market_id
where a.self_market_id = #{marketId}
GROUP BY b.store_id
where a.self_market_id = #{marketId}
and b.del_tag = 0
GROUP BY b.store_id
ORDER BY b.created_at asc
</select>
<select
id=
"getZhengzaiStoreDetails"
resultMap=
"goblinZhengzaiStoreDetailsDtoResult"
>
...
...
@@ -69,10 +69,9 @@ GROUP BY b.store_id
select
gsm.mid,gsm.name,gsm.performance_id,gsm.performance_img,gsm.created_at,gsm.updated_at,gsm.type,gsm.status,gsm.start_time,gsm.end_time,gsm.self_market_id,gsm.describes,count(gmzr.store_id)
as 'store_count'
from goblin_self_marketing as gsm left join goblin_marketing_zhengzai_relation gmzr on gsm.self_market_id =
gmzr.self_market_id
from goblin_self_marketing as gsm left join goblin_marketing_zhengzai_relation gmzr on gsm.self_market_id = gmzr.self_market_id and gmzr.del_tag !=1
<where>
del_flag = 0
gsm.
del_flag = 0
<if
test=
"purchaseName != null and purchaseName!=''"
>
and gsm.name like concat('%', #{purchaseName}, '%')
'%'
</if>
...
...
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/java/com/liquidnet/service/kylin/entity/KylinRecommendActive.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
import
java.util.List
;
/**
* <p>
* 推荐活动表
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
KylinRecommendActive
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"mid"
,
type
=
IdType
.
AUTO
)
private
Long
mid
;
/**
* 推荐活动id
*/
private
String
recommendId
;
/**
* 活动名称
*/
private
String
activeName
;
/**
* 开启时间
*/
private
LocalDateTime
startTime
;
/**
* 结束时间
*/
private
LocalDateTime
endTime
;
/**
* 1NFT2组合购3演出4商品
*/
private
Integer
activeType
;
/**
* 活动绑定id
*/
private
String
activeBindId
;
/**
* 0未删除1已删除
*/
private
Integer
delTag
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 修改时间
*/
private
LocalDateTime
updatedAt
;
/**
* 0开启,1未开启
*/
private
Integer
status
;
@TableField
(
exist
=
false
)
private
List
<
KylinRecommendActiveRelation
>
list
;
@TableField
(
exist
=
false
)
private
String
name
;
private
static
final
KylinRecommendActive
obj
=
new
KylinRecommendActive
();
public
static
KylinRecommendActive
getNew
()
{
try
{
return
(
KylinRecommendActive
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
KylinRecommendActive
();
}
}
}
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/java/com/liquidnet/service/kylin/entity/KylinRecommendActiveRelation.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 推荐活动关联表
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
KylinRecommendActiveRelation
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"mid"
,
type
=
IdType
.
AUTO
)
private
Long
mid
;
/**
* 推荐活动关系id
*/
private
String
recommendRelationId
;
/**
* 推荐商品id
*/
private
String
recommendBindId
;
/**
* 1NFT2组合购3演出4商品
*/
private
Integer
type
;
/**
* 推荐活动id(关联id)
*/
private
String
recommendActiveId
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 修改时间
*/
private
LocalDateTime
updatedAt
;
/**
* 0未删除1已删除
*/
private
Integer
delTag
;
/**
* 排序
*/
private
Integer
indexs
;
@TableField
(
exist
=
false
)
private
String
name
;
private
static
final
KylinRecommendActiveRelation
obj
=
new
KylinRecommendActiveRelation
();
public
static
KylinRecommendActiveRelation
getNew
()
{
try
{
return
(
KylinRecommendActiveRelation
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
KylinRecommendActiveRelation
();
}
}
}
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/java/com/liquidnet/service/kylin/mapper/KylinRecommendActiveMapper.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActive
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
/**
* <p>
* 推荐活动表 Mapper 接口
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
public
interface
KylinRecommendActiveMapper
extends
BaseMapper
<
KylinRecommendActive
>
{
int
validateTime
(
KylinRecommendActive
kylinRecommendActive
);
List
<
KylinRecommendActive
>
getBybindId
(
@Param
(
"type"
)
int
type
,
@Param
(
"bindId"
)
String
bindId
);
}
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/java/com/liquidnet/service/kylin/mapper/KylinRecommendActiveRelationMapper.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActiveRelation
;
/**
* <p>
* 推荐活动关联表 Mapper 接口
* </p>
*
* @author liquidnet
* @since 2022-07-27
*/
public
interface
KylinRecommendActiveRelationMapper
extends
BaseMapper
<
KylinRecommendActiveRelation
>
{
}
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/resources/com.liquidnet.service.kylin.mapper/kylinRecommendActiveMapper.xml
0 → 100644
View file @
75cd17ba
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.liquidnet.service.kylin.mapper.KylinRecommendActiveMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.liquidnet.service.kylin.entity.KylinRecommendActive"
>
<id
column=
"mid"
jdbcType=
"BIGINT"
property=
"mid"
/>
<result
column=
"recommend_id"
jdbcType=
"VARCHAR"
property=
"recommendId"
/>
<result
column=
"start_time"
jdbcType=
"TIMESTAMP"
property=
"startTime"
/>
<result
column=
"end_time"
jdbcType=
"TIMESTAMP"
property=
"endTime"
/>
<result
column=
"active_type"
jdbcType=
"INTEGER"
property=
"activeType"
/>
<result
column=
"active_bind_id"
jdbcType=
"VARCHAR"
property=
"activeBindId"
/>
<result
column=
"del_tag"
jdbcType=
"INTEGER"
property=
"delTag"
/>
<result
column=
"created_at"
jdbcType=
"TIMESTAMP"
property=
"createdAt"
/>
<result
column=
"updated_at"
jdbcType=
"TIMESTAMP"
property=
"updatedAt"
/>
<result
column=
"status"
jdbcType=
"INTEGER"
property=
"status"
/>
</resultMap>
<!-- getBannersRelationsId -->
<select
id=
"validateTime"
parameterType=
"com.liquidnet.service.kylin.entity.KylinRecommendActive"
resultType=
"int"
>
select count(1) from kylin_recommend_active
where (#{startTime} BETWEEN start_time and end_time
or #{endTime} BETWEEN start_time and end_time) and active_type=#{activeType} and active_bind_id=#{activeBindId}
<if
test=
"recommendId !=null"
>
and recommend_id != #{recommendId}
</if>
</select>
<select
id=
"getBybindId"
resultMap=
"BaseResultMap"
>
select * from kylin_recommend_active where active_type=#{type} and active_bind_id=#{bindId} and del_tag=0 and `status`=0 and end_time>=NOW()
ORDER BY start_time asc
</select>
</mapper>
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/dto/SweetManualAppletFiveDto.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
dto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
@Data
@ApiModel
public
class
SweetManualAppletFiveDto
implements
Serializable
,
Cloneable
{
@ApiModelProperty
(
"电子手册id"
)
private
String
manualId
;
@ApiModelProperty
(
"演出id"
)
private
String
performancesId
;
@ApiModelProperty
(
"演出标题"
)
private
String
title
;
@ApiModelProperty
(
"场地id"
)
private
String
fieldId
;
@ApiModelProperty
(
"场地名称"
)
private
String
fieldName
;
@ApiModelProperty
(
"城市名称"
)
private
String
cityName
;
@ApiModelProperty
(
"演出开始时间"
)
private
String
timeStart
;
@ApiModelProperty
(
"演出结束时间"
)
private
String
timeEnd
;
@ApiModelProperty
(
"演出开售时间"
)
private
String
timeSell
;
@ApiModelProperty
(
"是否会员"
)
private
Integer
isMember
;
@ApiModelProperty
(
"提前时间"
)
private
Integer
payCountdownMinute
;
@ApiModelProperty
(
"经度"
)
private
String
longitude
;
@ApiModelProperty
(
"纬度"
)
private
String
latitude
;
private
static
final
SweetManualAppletFiveDto
obj
=
new
SweetManualAppletFiveDto
();
public
static
SweetManualAppletFiveDto
getNew
()
{
try
{
return
(
SweetManualAppletFiveDto
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualAppletFiveDto
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/dto/SweetManualArtistList2FiveDto.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
dto
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.util.List
;
@Data
public
class
SweetManualArtistList2FiveDto
implements
Serializable
,
Cloneable
{
private
List
<
SweetManualArtistListFiveDto
>
data
;
private
List
<
String
>
date
;
private
List
<
SweetManualArtistStageListFiveDto
>
stage
;
private
Integer
total
;
private
static
final
SweetManualArtistList2FiveDto
obj
=
new
SweetManualArtistList2FiveDto
();
public
static
SweetManualArtistList2FiveDto
getNew
()
{
try
{
return
(
SweetManualArtistList2FiveDto
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualArtistList2FiveDto
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/dto/SweetManualArtistListFiveDto.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
dto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
@Data
@ApiModel
public
class
SweetManualArtistListFiveDto
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
8382714055996962257L
;
@ApiModelProperty
(
"电子手册关联id"
)
private
String
manualRelationId
;
@ApiModelProperty
(
"艺人id"
)
private
String
artistId
;
@ApiModelProperty
(
"艺人名称"
)
private
String
name
;
@ApiModelProperty
(
"拼音"
)
private
String
pinyin
;
@ApiModelProperty
(
"简介"
)
private
String
describes
;
@ApiModelProperty
(
"头像图片"
)
private
String
picUrl
;
@ApiModelProperty
(
"舞台id"
)
private
String
stageId
;
@ApiModelProperty
(
"舞台名称"
)
private
String
title
;
@ApiModelProperty
(
"演出开始"
)
private
String
performanceStart
;
@ApiModelProperty
(
"演出结束"
)
private
String
performanceEnd
;
@ApiModelProperty
(
"签售开始"
)
private
String
signatureStart
;
@ApiModelProperty
(
"签售结束"
)
private
String
signatureEnd
;
@ApiModelProperty
(
"是否观看"
)
private
Integer
isWatch
;
@ApiModelProperty
(
"是否登记"
)
private
Integer
isSign
;
private
static
final
SweetManualArtistListFiveDto
obj
=
new
SweetManualArtistListFiveDto
();
public
static
SweetManualArtistListFiveDto
getNew
()
{
try
{
return
(
SweetManualArtistListFiveDto
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualArtistListFiveDto
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/dto/SweetManualArtistStageListFiveDto.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
dto
;
import
lombok.Data
;
import
java.io.Serializable
;
@Data
public
class
SweetManualArtistStageListFiveDto
implements
Serializable
,
Cloneable
{
private
String
title
;
private
static
final
SweetManualArtistStageListFiveDto
obj
=
new
SweetManualArtistStageListFiveDto
();
public
static
SweetManualArtistStageListFiveDto
getNew
()
{
try
{
return
(
SweetManualArtistStageListFiveDto
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualArtistStageListFiveDto
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/dto/SweetManualFiveDto.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
dto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
@Data
@ApiModel
public
class
SweetManualFiveDto
implements
Serializable
,
Cloneable
{
@ApiModelProperty
(
"电子手册id"
)
private
String
manualId
;
@ApiModelProperty
(
"演出id"
)
private
String
performancesId
;
@ApiModelProperty
(
"演出名称"
)
private
String
title
;
@ApiModelProperty
(
"演出开始时间"
)
private
String
timeStart
;
@ApiModelProperty
(
"演出结束时间"
)
private
String
timeEnd
;
@ApiModelProperty
(
"售卖时间"
)
private
String
timeSell
;
@ApiModelProperty
(
"停售时间"
)
private
String
timeStop
;
@ApiModelProperty
(
"状态"
)
private
Integer
status
;
@ApiModelProperty
(
"手册状态"
)
private
Integer
manualStatus
;
@ApiModelProperty
(
"是否发布"
)
private
Integer
isRelease
;
private
static
final
SweetManualFiveDto
obj
=
new
SweetManualFiveDto
();
public
static
SweetManualFiveDto
getNew
()
{
try
{
return
(
SweetManualFiveDto
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualFiveDto
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/entity/SweetManualArtistsFive.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 电子宣传手册艺人表
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
SweetManualArtistsFive
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"mid"
,
type
=
IdType
.
AUTO
)
private
Long
mid
;
/**
* manual_relation_id
*/
private
String
manualRelationId
;
/**
* 电子宣传手册id
*/
private
String
manualId
;
/**
* 关联id
*/
private
String
stageId
;
/**
* 关联id
*/
private
String
artistsId
;
/**
* 演出开始时间
*/
private
LocalDateTime
performanceStart
;
/**
* 演出结束时间
*/
private
LocalDateTime
performanceEnd
;
/**
* 签收开始时间
*/
private
LocalDateTime
signatureStart
;
/**
* 签收结束时间
*/
private
LocalDateTime
signatureEnd
;
/**
* 0关闭 1开启
*/
private
Integer
status
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 更新时间
*/
private
LocalDateTime
updatedAt
;
private
static
final
SweetManualArtistsFive
obj
=
new
SweetManualArtistsFive
();
public
static
SweetManualArtistsFive
getNew
()
{
try
{
return
(
SweetManualArtistsFive
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualArtistsFive
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/entity/SweetManualFive.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 电子宣传手册表
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
SweetManualFive
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"mid"
,
type
=
IdType
.
AUTO
)
private
Long
mid
;
/**
* manual_id
*/
private
String
manualId
;
/**
* 演出id
*/
private
String
performanceId
;
/**
* 0关闭 1开启
*/
private
Integer
status
;
/**
* 0取消 1发布
*/
private
Integer
isRelease
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 更新时间
*/
private
LocalDateTime
updatedAt
;
private
static
final
SweetManualFive
obj
=
new
SweetManualFive
();
public
static
SweetManualFive
getNew
()
{
try
{
return
(
SweetManualFive
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualFive
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/entity/SweetManualNotifyFive.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 电子宣传手册通知表
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
SweetManualNotifyFive
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"mid"
,
type
=
IdType
.
AUTO
)
private
Long
mid
;
/**
* manual_notify_id
*/
private
String
manualNotifyId
;
/**
* 电子宣传手册id
*/
private
String
manualId
;
/**
* 标题
*/
private
String
title
;
/**
* 内容
*/
private
String
content
;
/**
* 0关闭 1开启
*/
private
Integer
status
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 更新时间
*/
private
LocalDateTime
updatedAt
;
private
static
final
SweetManualNotifyFive
obj
=
new
SweetManualNotifyFive
();
public
static
SweetManualNotifyFive
getNew
()
{
try
{
return
(
SweetManualNotifyFive
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualNotifyFive
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/entity/SweetManualShopFive.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 电子宣传手册商铺表
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
SweetManualShopFive
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"mid"
,
type
=
IdType
.
AUTO
)
private
Long
mid
;
/**
* manual_shop_id
*/
private
String
manualShopId
;
/**
* 电子宣传手册id
*/
private
String
manualId
;
/**
* 商家名称
*/
private
String
title
;
/**
* 商家图片
*/
private
String
picUrl
;
/**
* 商家介绍
*/
private
String
describes
;
/**
* 1吃喝 2玩乐
*/
private
Integer
type
;
/**
* 0不推荐 1推荐
*/
private
Integer
isRecommend
;
/**
* 排序字段 数字越大越靠前
*/
private
Integer
sort
;
/**
* 0关闭 1开启
*/
private
Integer
status
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 更新时间
*/
private
LocalDateTime
updatedAt
;
private
static
final
SweetManualShopFive
obj
=
new
SweetManualShopFive
();
public
static
SweetManualShopFive
getNew
()
{
try
{
return
(
SweetManualShopFive
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualShopFive
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/entity/SweetManualSortFive.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 电子宣传手册显示内容表
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
SweetManualSortFive
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"mid"
,
type
=
IdType
.
AUTO
)
private
Long
mid
;
/**
* manual_id
*/
private
String
manualId
;
/**
* 显示哪个,号隔开
*/
private
String
showPosition
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 更新时间
*/
private
LocalDateTime
updatedAt
;
private
static
final
SweetManualSortFive
obj
=
new
SweetManualSortFive
();
public
static
SweetManualSortFive
getNew
()
{
try
{
return
(
SweetManualSortFive
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetManualSortFive
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/entity/SweetRichtextFive.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 电子宣传手册富文本表
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
SweetRichtextFive
implements
Serializable
,
Cloneable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"mid"
,
type
=
IdType
.
AUTO
)
private
Long
mid
;
/**
* order_refund_id
*/
private
String
richtextId
;
/**
* manual_id
*/
private
String
manualId
;
/**
* 富文本详情
*/
private
String
details
;
/**
* 经纬度 5需要
*/
private
String
local
;
/**
* 地图图片地址 2需要
*/
private
String
picUrl
;
/**
* 类型 1签售时间 2现场地图 3官方大巴 4公共交通 5自驾导航坐标 6官方支持 7观众须知 8防疫指南 9观演攻略
*/
private
Integer
type
;
/**
* 0关闭 1开启
*/
private
Integer
status
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 更新时间
*/
private
LocalDateTime
updatedAt
;
private
static
final
SweetRichtextFive
obj
=
new
SweetRichtextFive
();
public
static
SweetRichtextFive
getNew
()
{
try
{
return
(
SweetRichtextFive
)
obj
.
clone
();
}
catch
(
CloneNotSupportedException
e
)
{
return
new
SweetRichtextFive
();
}
}
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/entity/SweetUserRelationFive.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
entity
;
import
com.baomidou.mybatisplus.annotation.IdType
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.io.Serializable
;
import
java.time.LocalDateTime
;
/**
* <p>
* 用户 收藏/喜欢等状态
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Data
@EqualsAndHashCode
(
callSuper
=
false
)
public
class
SweetUserRelationFive
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"mid"
,
type
=
IdType
.
AUTO
)
private
Long
mid
;
/**
* 用户id
*/
private
String
userId
;
/**
* 类型 1喜欢艺人 2签售艺人
*/
private
Integer
type
;
/**
* 目标id
*/
private
String
targetId
;
/**
* 电子手册
*/
private
String
manualId
;
/**
* 1是 0否
*/
private
Integer
status
;
/**
* 创建时间
*/
private
LocalDateTime
createdAt
;
/**
* 更新时间
*/
private
LocalDateTime
updatedAt
;
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/mapper/SweetManualArtistsFiveMapper.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistListFiveDto
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistListFiveDto
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistStageListFiveDto
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistStageListFiveDto
;
import
com.liquidnet.service.sweet.entity.SweetManualArtistsFive
;
import
java.util.List
;
import
java.util.Map
;
/**
* <p>
* 电子宣传手册艺人表 Mapper 接口
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
SweetManualArtistsFiveMapper
extends
BaseMapper
<
SweetManualArtistsFive
>
{
List
<
SweetManualArtistListFiveDto
>
getManualList
(
Map
<
String
,
Object
>
map
);
SweetManualArtistListFiveDto
getManualDetails
(
Map
<
String
,
Object
>
map
);
List
<
SweetManualArtistStageListFiveDto
>
getStageNameList
(
Map
<
String
,
Object
>
map
);
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/mapper/SweetManualFiveMapper.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.liquidnet.service.sweet.dto.SweetManualAppletFiveDto
;
import
com.liquidnet.service.sweet.dto.SweetManualAppletFiveDto
;
import
com.liquidnet.service.sweet.dto.SweetManualFiveDto
;
import
com.liquidnet.service.sweet.dto.SweetManualFiveDto
;
import
com.liquidnet.service.sweet.entity.SweetManualFive
;
import
java.util.List
;
import
java.util.Map
;
/**
* <p>
* 电子宣传手册表 Mapper 接口
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
SweetManualFiveMapper
extends
BaseMapper
<
SweetManualFive
>
{
List
<
SweetManualFiveDto
>
getManualList
(
Map
<
String
,
Object
>
map
);
SweetManualFiveDto
getManualDetails
(
Map
<
String
,
Object
>
map
);
List
<
SweetManualAppletFiveDto
>
getManualAppletDto
();
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/mapper/SweetManualNotifyFiveMapper.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.liquidnet.service.sweet.entity.SweetManualNotifyFive
;
import
com.liquidnet.service.sweet.entity.SweetManualNotifyFive
;
/**
* <p>
* 电子宣传手册通知表 Mapper 接口
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
SweetManualNotifyFiveMapper
extends
BaseMapper
<
SweetManualNotifyFive
>
{
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/mapper/SweetManualShopFiveMapper.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.liquidnet.service.sweet.entity.SweetManualShopFive
;
import
com.liquidnet.service.sweet.entity.SweetManualShopFive
;
/**
* <p>
* 电子宣传手册商铺表 Mapper 接口
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
SweetManualShopFiveMapper
extends
BaseMapper
<
SweetManualShopFive
>
{
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/mapper/SweetManualSortFiveMapper.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.liquidnet.service.sweet.entity.SweetManualSortFive
;
import
com.liquidnet.service.sweet.entity.SweetManualSortFive
;
/**
* <p>
* 电子宣传手册显示内容表 Mapper 接口
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
SweetManualSortFiveMapper
extends
BaseMapper
<
SweetManualSortFive
>
{
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/mapper/SweetRichtextFiveMapper.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.liquidnet.service.sweet.entity.SweetRichtextFive
;
import
com.liquidnet.service.sweet.entity.SweetRichtextFive
;
/**
* <p>
* 电子宣传手册富文本表 Mapper 接口
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
SweetRichtextFiveMapper
extends
BaseMapper
<
SweetRichtextFive
>
{
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/java/com/liquidnet/service/sweet/mapper/SweetUserRelationFiveMapper.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.liquidnet.service.sweet.entity.SweetUserRelationFive
;
import
com.liquidnet.service.sweet.entity.SweetUserRelationFive
;
/**
* <p>
* 用户 收藏/喜欢等状态 Mapper 接口
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
public
interface
SweetUserRelationFiveMapper
extends
BaseMapper
<
SweetUserRelationFive
>
{
}
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/resources/com.liquidnet.service.sweet.mapper/SweetManualArtistsFiveMapper.xml
0 → 100644
View file @
75cd17ba
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.liquidnet.service.sweet.mapper.SweetManualArtistsFiveMapper"
>
<resultMap
id=
"getManualListResult"
type=
"com.liquidnet.service.sweet.dto.SweetManualArtistListFiveDto"
>
<result
column=
"manual_relation_id"
property=
"manualRelationId"
/>
<result
column=
"artists_id"
property=
"artistId"
/>
<result
column=
"name"
property=
"name"
/>
<result
column=
"pinyin"
property=
"pinyin"
/>
<result
column=
"describes"
property=
"describes"
/>
<result
column=
"pic_url"
property=
"picUrl"
/>
<result
column=
"stage_id"
property=
"stageId"
/>
<result
column=
"title"
property=
"title"
/>
<result
column=
"performance_start"
property=
"performanceStart"
/>
<result
column=
"performance_end"
property=
"performanceEnd"
/>
<result
column=
"signature_start"
property=
"signatureStart"
/>
<result
column=
"signature_end"
property=
"signatureEnd"
/>
</resultMap>
<resultMap
id=
"getStageNameListResult"
type=
"com.liquidnet.service.sweet.dto.SweetManualArtistStageListFiveDto"
>
<result
column=
"title"
property=
"title"
/>
</resultMap>
<select
id=
"getManualList"
parameterType=
"java.util.Map"
resultMap=
"getManualListResult"
>
select manual_relation_id,
sa.`artists_id`,
sa.`name`,
sa.pinyin,
sa.describes,
sa.pic_url,
ss.stage_id,
ss.title,
performance_start,
performance_end,
signature_start,
signature_end
from sweet_manual_artists_Five as sma
left join sweet_artists as sa on sa.artists_id = sma.artists_id
left join sweet_stage as ss on ss.stage_id = sma.stage_id
<where>
sma.status = 1 and manual_id = #{manualId}
</where>
ORDER BY sma.updated_at DESC
</select>
<select
id=
"getManualDetails"
parameterType=
"java.util.Map"
resultMap=
"getManualListResult"
>
select manual_relation_id,
sa.`name`,
sa.`artists_id`,
ss.title,
ss.stage_id,
performance_start,
performance_end,
signature_start,
signature_end
from sweet_manual_artists_Five as sma
left join sweet_artists as sa on sa.artists_id = sma.artists_id
left join sweet_stage as ss on ss.stage_id = sma.stage_id
where manual_relation_id = #{manualRelationId}
</select>
<select
id=
"getStageNameList"
parameterType=
"java.util.Map"
resultMap=
"getStageNameListResult"
>
select ss.title
from sweet_manual_artists_Five as sma
left join sweet_artists as sa on sa.artists_id = sma.artists_id
left join sweet_stage as ss on ss.stage_id = sma.stage_id
where sma.status = 1
and manual_id = #{manualId}
group by ss.title;
</select>
</mapper>
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/resources/com.liquidnet.service.sweet.mapper/SweetManualFiveMapper.xml
0 → 100644
View file @
75cd17ba
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.liquidnet.service.sweet.mapper.SweetManualFiveMapper"
>
<resultMap
id=
"partnerPerformanceListResult"
type=
"com.liquidnet.service.sweet.dto.SweetManualFiveDto"
>
<result
column=
"manual_id"
property=
"manualId"
/>
<result
column=
"performances_id"
property=
"performancesId"
/>
<result
column=
"title"
property=
"title"
/>
<result
column=
"time_start"
property=
"timeStart"
/>
<result
column=
"time_end"
property=
"timeEnd"
/>
<result
column=
"time_sell"
property=
"timeSell"
/>
<result
column=
"time_stop"
property=
"timeStop"
/>
<result
column=
"status"
property=
"status"
/>
<result
column=
"manualStatus"
property=
"manualStatus"
/>
<result
column=
"is_release"
property=
"isRelease"
/>
</resultMap>
<resultMap
id=
"getManualAppletListResult"
type=
"com.liquidnet.service.sweet.dto.SweetManualAppletFiveDto"
>
<result
column=
"manual_id"
property=
"manualId"
/>
<result
column=
"performances_id"
property=
"performancesId"
/>
<result
column=
"title"
property=
"title"
/>
<result
column=
"field_id"
property=
"fieldId"
/>
<result
column=
"city_name"
property=
"cityName"
/>
<result
column=
"time_start"
property=
"timeStart"
/>
<result
column=
"time_end"
property=
"timeEnd"
/>
</resultMap>
<resultMap
id=
"getManualAppletDtoResult"
type=
"com.liquidnet.service.sweet.dto.SweetManualAppletFiveDto"
>
<result
column=
"manual_id"
property=
"manualId"
/>
<result
column=
"performances_id"
property=
"performancesId"
/>
<result
column=
"title"
property=
"title"
/>
<result
column=
"field_id"
property=
"fieldId"
/>
<result
column=
"time_start"
property=
"timeStart"
/>
<result
column=
"time_end"
property=
"timeEnd"
/>
<result
column=
"time_sell"
property=
"timeSell"
/>
<result
column=
"pay_countdown_minute"
property=
"payCountdownMinute"
/>
<result
column=
"is_member"
property=
"isMember"
/>
</resultMap>
<!-- 电子手册列表 -->
<select
id=
"getManualList"
parameterType=
"java.util.Map"
resultMap=
"partnerPerformanceListResult"
>
SELECT
IFNULL(sm.manual_id,0) as 'manual_id',
p.performances_id ,
p.title ,
p.time_start ,
p.time_end ,
ps.status ,
t.time_sell ,
t.time_stop,
IFNULL(sm.status ,0) as 'manualStatus',
IFNULL(sm.is_release,0) as 'is_release'
FROM
kylin_performances AS p
LEFT JOIN kylin_performance_status AS ps ON p.performances_id = ps.performance_id
LEFT JOIN kylin_performance_relations AS pr ON p.performances_id = pr.performance_id
LEFT JOIN sweet_manual_Five AS sm ON p.performances_id = sm.performance_id
LEFT JOIN(
SELECT
ttr.performance_id ,
MIN(
DATE_SUB(
t.time_start ,
INTERVAL pay_countdown_minute MINUTE
)
) AS 'time_sell' ,
MAX(t.time_end) AS 'time_stop'
FROM
kylin_ticket_status AS ts
LEFT JOIN kylin_ticket_relations AS tr ON tr.ticket_id = ts.ticket_id
LEFT JOIN kylin_tickets AS t ON t.tickets_id = ts.ticket_id
LEFT JOIN kylin_ticket_time_relation AS ttr ON tr.times_id = ttr.times_id
GROUP BY
ttr.performance_id
) AS t ON p.performances_id = t.performance_id
<where>
<if
test=
"title!='' and title != null"
>
AND (title LIKE concat('%', #{title}, '%'))
</if>
</where>
ORDER BY p.created_at desc
</select>
<!-- 电子手册详情 -->
<select
id=
"getManualDetails"
parameterType=
"java.util.Map"
resultMap=
"partnerPerformanceListResult"
>
SELECT IFNULL(sm.manual_id, 0) as 'manual_id',
p.performances_id,
p.title,
p.time_start,
p.time_end,
ps.status,
t.time_sell,
t.time_stop,
IFNULL(sm.status, 0) as 'manualStatus',
IFNULL(sm.is_release, 0) as 'is_release'
FROM kylin_performances AS p
LEFT JOIN kylin_performance_status AS ps ON p.performances_id = ps.performance_id
LEFT JOIN kylin_performance_relations AS pr ON p.performances_id = pr.performance_id
LEFT JOIN sweet_manual_Five AS sm ON p.performances_id = sm.performance_id
LEFT JOIN(
SELECT ttr.performance_id,
MIN(
DATE_SUB(
t.time_start,
INTERVAL pay_countdown_minute MINUTE
)
) AS 'time_sell',
MAX(t.time_end) AS 'time_stop'
FROM kylin_ticket_status AS ts
LEFT JOIN kylin_ticket_relations AS tr ON tr.ticket_id = ts.ticket_id
LEFT JOIN kylin_tickets AS t ON t.tickets_id = ts.ticket_id
LEFT JOIN kylin_ticket_time_relation AS ttr ON tr.times_id = ttr.times_id
GROUP BY ttr.performance_id
) AS t ON p.performances_id = t.performance_id
where sm.manual_id = #{manualId}
ORDER BY p.created_at desc
</select>
<select
id=
"getManualAppletList"
resultMap=
"getManualAppletListResult"
>
select manual_id, performances_id, title, field_id, city_name, time_start, time_end
from kylin_performances as kp
left join sweet_manual_Five as sw on sw.performance_id = kp.performances_id
left join kylin_performance_relations as kpr on kpr.performance_id = kp.performances_id
where sw.`status` = 1
and sw.is_release = 1
</select>
<select
id=
"getManualAppletDto"
resultMap=
"getManualAppletDtoResult"
>
SELECT
IFNULL(sm.manual_id , 0) AS 'manual_id' ,
p.performances_id ,
p.title ,
pr.field_id ,
p.time_start ,
p.time_end,
t1.time_sell,
t1.pay_countdown_minute,
t1.is_member
FROM
kylin_performances AS p
LEFT JOIN kylin_performance_status AS ps ON p.performances_id = ps.performance_id
LEFT JOIN kylin_performance_relations AS pr ON p.performances_id = pr.performance_id
LEFT JOIN sweet_manual_Five AS sm ON p.performances_id = sm.performance_id
LEFT JOIN(
SELECT
ttr.performance_id ,
MIN(
DATE_SUB(
t.time_start ,
INTERVAL pay_countdown_minute MINUTE
)
) AS 'time_sell' ,
MAX(t.time_end) AS 'time_stop'
FROM
kylin_ticket_status AS ts
LEFT JOIN kylin_ticket_relations AS tr ON tr.ticket_id = ts.ticket_id
LEFT JOIN kylin_tickets AS t ON t.tickets_id = ts.ticket_id
LEFT JOIN kylin_ticket_time_relation AS ttr ON tr.times_id = ttr.times_id
GROUP BY
ttr.performance_id
) AS t ON p.performances_id = t.performance_id
LEFT JOIN(
SELECT
ttr.performance_id ,
pay_countdown_minute,
ts.is_member,
sum(ts.total_general) AS 'total_general' ,
MIN(
DATE_SUB(
t.time_start ,
INTERVAL pay_countdown_minute MINUTE
)
) AS 'time_sell' ,
MAX(t.time_end) AS 'time_stop'
FROM
kylin_ticket_status AS ts
LEFT JOIN kylin_ticket_relations AS tr ON tr.ticket_id = ts.ticket_id
LEFT JOIN kylin_tickets AS t ON t.tickets_id = ts.ticket_id
LEFT JOIN kylin_ticket_time_relation AS ttr ON tr.times_id = ttr.times_id
GROUP BY
ttr.performance_id
) AS t1 ON p.performances_id = t1.performance_id
where sm.`status` = 1 and sm.is_release = 1
</select>
</mapper>
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/resources/com.liquidnet.service.sweet.mapper/SweetManualNotifyFiveMapper.xml
0 → 100644
View file @
75cd17ba
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.liquidnet.service.sweet.mapper.SweetManualNotifyFiveMapper"
>
</mapper>
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/resources/com.liquidnet.service.sweet.mapper/SweetManualShopFiveMapper.xml
0 → 100644
View file @
75cd17ba
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.liquidnet.service.sweet.mapper.SweetManualShopFiveMapper"
>
</mapper>
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/resources/com.liquidnet.service.sweet.mapper/SweetManualSortFiveMapper.xml
0 → 100644
View file @
75cd17ba
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.liquidnet.service.sweet.mapper.SweetManualSortFiveMapper"
>
</mapper>
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/resources/com.liquidnet.service.sweet.mapper/SweetRichtextFiveMapper.xml
0 → 100644
View file @
75cd17ba
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.liquidnet.service.sweet.mapper.SweetRichtextFiveMapper"
>
</mapper>
liquidnet-bus-do/liquidnet-service-sweet-do/src/main/resources/com.liquidnet.service.sweet.mapper/SweetUserRelationFiveMapper.xml
0 → 100644
View file @
75cd17ba
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.liquidnet.service.sweet.mapper.SweetUserRelationFiveMapper"
>
</mapper>
liquidnet-bus-service/liquidnet-service-adam/liquidnet-service-adam-impl/src/main/java/com/liquidnet/service/adam/service/impl/AdamUserServiceImpl.java
View file @
75cd17ba
...
...
@@ -98,9 +98,9 @@ public class AdamUserServiceImpl implements IAdamUserService {
log
.
debug
(
"#RDS耗时:{}ms"
,
System
.
currentTimeMillis
()
-
s
);
toMqSqls
.
add
(
SqlMapping
.
get
(
"adam_user.add"
));
initUserObjs
.
add
(
new
Object
[]{
userInfoVo
.
getUid
(),
userInfoVo
.
getMobile
(),
userInfoVo
.
getState
(),
0
,
now
});
initUserObjs
.
add
(
new
Object
[]{
userInfoVo
.
getUid
(),
userInfoVo
.
getMobile
(),
userInfoVo
.
getState
(),
userInfoVo
.
getIsComplete
()
,
now
});
toMqSqls
.
add
(
SqlMapping
.
get
(
"adam_user_info.add"
));
initUserInfoObjs
.
add
(
new
Object
[]{
userInfoVo
.
getUid
(),
userInfoVo
.
getNickname
(),
null
,
userInfoVo
.
getQrCode
()});
initUserInfoObjs
.
add
(
new
Object
[]{
userInfoVo
.
getUid
(),
userInfoVo
.
getNickname
(),
userInfoVo
.
getAvatar
(),
userInfoVo
.
getBackground
()
,
userInfoVo
.
getQrCode
()});
s
=
System
.
currentTimeMillis
();
queueUtils
.
sendMsgByRedis
(
MQConst
.
AdamQueue
.
SQL_UREGISTER
.
getKey
(),
...
...
@@ -154,9 +154,9 @@ public class AdamUserServiceImpl implements IAdamUserService {
adamRdmService
.
setUserInfoVoByUid
(
registerUid
,
userInfoVo
);
toMqSqls
.
add
(
SqlMapping
.
get
(
"adam_user.add"
));
initUserObjs
.
add
(
new
Object
[]{
registerUid
,
userInfoVo
.
getMobile
(),
userInfoVo
.
getState
(),
0
,
now
});
initUserObjs
.
add
(
new
Object
[]{
registerUid
,
userInfoVo
.
getMobile
(),
userInfoVo
.
getState
(),
userInfoVo
.
getIsComplete
()
,
now
});
toMqSqls
.
add
(
SqlMapping
.
get
(
"adam_user_info.add"
));
initUserInfoObjs
.
add
(
new
Object
[]{
registerUid
,
userInfoVo
.
getNickname
(),
userInfoVo
.
getAvatar
(),
userInfoVo
.
getQrCode
()});
initUserInfoObjs
.
add
(
new
Object
[]{
registerUid
,
userInfoVo
.
getNickname
(),
userInfoVo
.
getAvatar
(),
userInfoVo
.
get
Background
(),
userInfoVo
.
get
QrCode
()});
AdamThirdPartInfoVo
thirdPartInfoVo
=
AdamThirdPartInfoVo
.
getNew
();
BeanUtils
.
copyProperties
(
param
,
thirdPartInfoVo
);
...
...
liquidnet-bus-service/liquidnet-service-adam/liquidnet-service-adam-impl/src/main/resources/sqlmap.properties
View file @
75cd17ba
...
...
@@ -5,7 +5,7 @@ adam_user.edit.mobile=UPDATE adam_user SET mobile=?, updated_at=? WHERE `uid`=?
adam_user.close
=
UPDATE adam_user SET `state`=2, updated_at=?, closed_at=? WHERE `uid`=?
# ----------------------------------------------------
adam_user_info.add
=
INSERT INTO adam_user_info (`uid`, nickname, avatar,
qr_code) VALUES (
?,?,?,?)
adam_user_info.add
=
INSERT INTO adam_user_info (`uid`, nickname, avatar,
background, qr_code) VALUES (?,
?,?,?,?)
adam_user_info.edit
=
UPDATE adam_user_info SET nickname=?, sex=?, birthday=?, area=?, signature=?, avatar=?, background=?, tag_me=? WHERE uid=?
adam_user_info.update_by_member
=
UPDATE adam_user_info SET birthday=?, area=? WHERE uid=?
adam_user_info.update_qr_code
=
UPDATE adam_user_info SET qr_code=? WHERE uid=?
...
...
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/controller/manage/GoblinStoreMgtGoodsController.java
View file @
75cd17ba
...
...
@@ -1087,25 +1087,7 @@ public class GoblinStoreMgtGoodsController {
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"149010"
));
}
if
(
goodsInfoVo
.
getSpuType
()
==
0
)
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"无效操作,该商品非数字藏品"
);
}
if
(
"23"
.
contains
(
mgtDigitalGoodsAddSkuParam
.
getWatchType
()))
{
if
(
StringUtils
.
isBlank
(
mgtDigitalGoodsAddSkuParam
.
getSkuWatchPic
()))
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"展示预览图不能为空"
);
}
}
else
{
mgtDigitalGoodsAddSkuParam
.
setSkuWatchPic
(
null
);
}
BigDecimal
hitRatio
=
mgtDigitalGoodsAddSkuParam
.
getHitRatio
();
if
(
null
!=
hitRatio
&&
hitRatio
.
scale
()
>
2
)
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"概率值只支持小数点后两位"
);
}
if
(
goblinMongoUtils
.
countMgtGoodsSkuInfoVo
(
mgtDigitalGoodsAddSkuParam
.
getName
(),
1
)
>
0
)
{
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"149018"
));
}
JsonNode
priceVNode
=
goblinRedisUtils
.
getIosProducts
().
get
(
mgtDigitalGoodsAddSkuParam
.
getProductId
());
if
(
null
==
priceVNode
)
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"无效的IOS商品ID"
);
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"该商品非数字藏品"
);
}
String
unbox
=
mgtDigitalGoodsAddSkuParam
.
getUnbox
();
boolean
notUnboxFlg
=
StringUtils
.
isEmpty
(
unbox
)
||
unbox
.
equals
(
"0"
);
...
...
@@ -1132,10 +1114,31 @@ public class GoblinStoreMgtGoodsController {
// }
// }
}
else
{
// 盲盒校验
if
(
CollectionUtils
.
isEmpty
(
goodsInfoVo
.
getSkuIdList
()))
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"请先添加SKU"
);
}
if
(
StringUtils
.
isEmpty
(
mgtDigitalGoodsAddSkuParam
.
getOpeningTime
()))
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"盲盒开启时间不能为空"
);
}
}
if
(
"23"
.
contains
(
mgtDigitalGoodsAddSkuParam
.
getWatchType
()))
{
if
(
StringUtils
.
isBlank
(
mgtDigitalGoodsAddSkuParam
.
getSkuWatchPic
()))
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"展示预览图不能为空"
);
}
}
else
{
mgtDigitalGoodsAddSkuParam
.
setSkuWatchPic
(
null
);
}
BigDecimal
hitRatio
=
mgtDigitalGoodsAddSkuParam
.
getHitRatio
();
if
(
null
!=
hitRatio
&&
hitRatio
.
scale
()
>
2
)
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"概率值只支持小数点后两位"
);
}
if
(
goblinMongoUtils
.
countMgtGoodsSkuInfoVo
(
mgtDigitalGoodsAddSkuParam
.
getName
(),
1
)
>
0
)
{
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"149018"
));
}
JsonNode
priceVNode
=
goblinRedisUtils
.
getIosProducts
().
get
(
mgtDigitalGoodsAddSkuParam
.
getProductId
());
if
(
null
==
priceVNode
)
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"无效的IOS商品ID"
);
}
if
(
"3"
.
equals
(
mgtDigitalGoodsAddSkuParam
.
getShelvesHandle
())
&&
StringUtils
.
isEmpty
(
mgtDigitalGoodsAddSkuParam
.
getShelvesTime
()))
{
return
ResponseDto
.
failure
(
ErrorCode
.
HTTP_PARAM_ERROR
.
getCode
(),
"请指定预约上架时间"
);
}
...
...
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/pom.xml
View file @
75cd17ba
...
...
@@ -44,6 +44,11 @@
<version>
1.0-SNAPSHOT
</version>
<scope>
compile
</scope>
</dependency>
<dependency>
<groupId>
com.liquidnet
</groupId>
<artifactId>
liquidnet-service-goblin-api
</artifactId>
<version>
1.0-SNAPSHOT
</version>
</dependency>
</dependencies>
<build>
...
...
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/MybatisPlusCodeGenerator.java
View file @
75cd17ba
...
...
@@ -88,18 +88,16 @@ public class MybatisPlusCodeGenerator {
DataSourceConfig
dsc
=
new
DataSourceConfig
();
dsc
.
setDriverName
(
"com.mysql.cj.jdbc.Driver"
);
dsc
.
setUrl
(
"jdbc:mysql://39.106.122.201:3308/dev_ln_scene?useUnicode=true&useSSL=false&characterEncoding=utf8&serverTimezone=CST"
);
dsc
.
setUsername
(
"testmall"
);
dsc
.
setPassword
(
"zhengzai!mYT"
);
String
resourcePath
=
"/Users/hujiachen/Downloads/tmp"
;
dsc
.
setUrl
(
"jdbc:mysql://java-test.mysql.polardb.rds.aliyuncs.com:3306/dev_ln_scene?useUnicode=true&useSSL=false&characterEncoding=utf8&serverTimezone=CST"
);
dsc
.
setUsername
(
"zhengzai"
);
dsc
.
setPassword
(
"Zhengzai@rd2U#"
);
String
resourcePath
=
"/Users/test/Desktop/test"
;
String
directory
=
"com.liquidnet.service.candy"
;
String
[]
dbTableArray
=
new
String
[]{
"candy_coupon"
,
"candy_coupon_code"
,
"candy_coupon_rule"
,
"candy_mgt_coupon"
,
"candy_user_coupon"
"kylin_recommend_active"
,
"kylin_recommend_active_relation"
};
doGenerator
(
resourcePath
,
dsc
,
directory
,
dbTableArray
);
...
...
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/kylin/controller/KylinOrderTicketsController.java
View file @
75cd17ba
...
...
@@ -160,6 +160,13 @@ public class KylinOrderTicketsController {
return
orderTicketsService
.
orderTransferBack
(
orderId
);
}
@GetMapping
(
"orderArCode"
)
@ApiOperation
(
"获取订单Ar激活码"
)
@ApiResponse
(
code
=
200
,
message
=
"接口返回对象参数"
)
public
ResponseDto
<
List
<
String
>>
orderArCode
(
@RequestParam
(
value
=
"orderId"
)
String
orderId
)
{
return
orderTicketsService
.
getOrderArCode
(
orderId
);
}
/*@GetMapping("toOrderRefundDetails")
@ApiOperation("想要退款订单详情")
@ApiResponse(code = 200, message = "接口返回对象参数")
...
...
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/kylin/controller/KylinRecommendActiveController.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
controller
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.kylin.dto.vo.KylinRecommendActiveRelationVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinRecommendActiveVo
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActive
;
import
com.liquidnet.service.kylin.service.impl.KylinRecommendActiveServiceImpl
;
import
com.liquidnet.service.kylin.utils.DataUtils
;
import
com.liquidnet.service.kylin.utils.ObjectUtil
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.text.ParseException
;
import
java.util.ArrayList
;
import
java.util.List
;
/**
* <p>
* 推荐活动
* </p>
*
*/
@Api
(
tags
=
"推荐活动有关接口"
)
@RestController
@RequestMapping
(
"recommendActive"
)
@Slf4j
public
class
KylinRecommendActiveController
{
@Autowired
private
KylinRecommendActiveServiceImpl
kylinRecommendActiveService
;
@Autowired
private
DataUtils
dataUtils
;
@PostMapping
(
"getRecommendById"
)
@ApiOperation
(
"获取推荐活动详情"
)
public
ResponseDto
<
KylinRecommendActiveVo
>
getRecommendById
(
@RequestParam
(
value
=
"bindId"
)
String
bindId
)
throws
ParseException
{
List
<
KylinRecommendActive
>
list
=
dataUtils
.
getRecommendActive
(
bindId
);
if
(
null
==
list
){
return
ResponseDto
.
success
(
null
);
}
else
{
//循环遍历,查到绑定的详情
return
ResponseDto
.
success
(
kylinRecommendActiveService
.
getRecommendById
(
list
));
}
}
@PostMapping
(
"getRecommendByIds"
)
@ApiOperation
(
"获取推荐活动详情,多id的"
)
public
ResponseDto
<
List
<
KylinRecommendActiveRelationVo
>>
getRecommendByIds
(
@RequestParam
(
value
=
"ids"
)
List
<
String
>
ids
)
throws
ParseException
{
ArrayList
<
KylinRecommendActiveRelationVo
>
resultList
=
ObjectUtil
.
getKylinRecommendActiveRelationVo
();
for
(
String
id:
ids
){
List
<
KylinRecommendActive
>
list
=
dataUtils
.
getRecommendActive
(
id
);
if
(
null
!=
list
&&
list
.
size
()>
0
){
KylinRecommendActiveVo
kylinRecommendActiveVo
=
kylinRecommendActiveService
.
getRecommendById
(
list
);
List
<
KylinRecommendActiveRelationVo
>
list1
=
kylinRecommendActiveVo
.
getList
();
for
(
KylinRecommendActiveRelationVo
ky:
list1
){
if
(
ky
.
isCount
()){
resultList
.
add
(
ky
);
//只搜索20个
if
(
resultList
.
size
()==
20
){
return
ResponseDto
.
success
(
resultList
)
;
}
}
}
}
}
return
ResponseDto
.
success
(
resultList
);
}
}
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/kylin/service/impl/KylinOrderTicketsServiceImpl.java
View file @
75cd17ba
...
...
@@ -198,7 +198,7 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsService {
orderTicketVo
=
dataUtils
.
getTransferOrder
(
uid
);
}
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
return
null
;
}
// if (uid.equals("809406") || uid.equals("773650")) {
...
...
@@ -404,7 +404,7 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsService {
public
ResponseDto
<
Boolean
>
supplementEnter
(
String
orderId
,
String
enterList
)
{
String
uid
=
CurrentUtil
.
getCurrentUid
();
KylinOrderTicketVo
orderTicketVo
=
dataUtils
.
getOrderTicketVo
(
orderId
);
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20003"
));
}
// if (uid.equals("809406") || uid.equals("773650")) {
...
...
@@ -1018,7 +1018,7 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsService {
KylinPerformanceVo
performanceVo
=
dataUtils
.
getPerformanceVo
(
orderTicketVo
.
getPerformanceId
());
List
<
KylinOrderRefundsVo
>
kylinOrderRefundsVoBaseList
=
dataUtils
.
getOrderRefundVoByOrderId
(
orderTicketVo
.
getOrderTicketsId
());
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20003"
));
}
...
...
@@ -1066,7 +1066,7 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsService {
KylinOrderTicketVo
orderTicketVo
=
dataUtils
.
getOrderTicketVo
(
orderId
);
KylinPerformanceVo
performanceVo
=
dataUtils
.
getPerformanceVo
(
orderTicketVo
.
getPerformanceId
());
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20003"
));
}
...
...
@@ -1101,7 +1101,7 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsService {
KylinOrderTicketVo
orderTicketVo
=
dataUtils
.
getOrderTicketVo
(
orderId
);
List
<
KylinOrderRefundsVo
>
kylinOrderRefundsVoBaseList
=
dataUtils
.
getOrderRefundVoByOrderId
(
orderTicketVo
.
getOrderTicketsId
());
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
return
"无权查看"
;
}
...
...
@@ -1341,4 +1341,14 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsService {
}
}
@Override
public
ResponseDto
<
List
<
String
>>
getOrderArCode
(
String
orderId
)
{
KylinOrderTicketVo
orderTicketVo
=
dataUtils
.
getOrderTicketVo
(
orderId
);
String
uid
=
CurrentUtil
.
getCurrentUid
();
if
(!
SuperAccountUtils
.
isSuperAccount
(
uid
,
orderTicketVo
.
getUserId
()))
{
return
ResponseDto
.
failure
(
"无权查看"
);
}
return
ResponseDto
.
success
(
dataUtils
.
getOrderArCode
(
orderId
));
}
}
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/kylin/service/impl/KylinRecommendActiveServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
service
.
impl
;
import
com.liquidnet.commons.lang.util.CollectionUtil
;
import
com.liquidnet.commons.lang.util.CurrentUtil
;
import
com.liquidnet.commons.lang.util.StringUtil
;
import
com.liquidnet.service.goblin.dto.manage.vo.AnticipateValueVo
;
import
com.liquidnet.service.goblin.dto.manage.vo.GoblinGoodsAnticipateValueVo
;
import
com.liquidnet.service.goblin.dto.vo.*
;
import
com.liquidnet.service.kylin.dto.vo.KylinRecommendActiveRelationVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinRecommendActiveVo
;
import
com.liquidnet.service.kylin.dto.vo.mongo.KylinPerformanceVo
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActive
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActiveRelation
;
import
com.liquidnet.service.kylin.service.IKylinRecommendActiveService
;
import
com.liquidnet.service.kylin.utils.*
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.math.BigInteger
;
import
java.text.ParseException
;
import
java.time.LocalDateTime
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.ListIterator
;
import
static
com
.
liquidnet
.
commons
.
lang
.
util
.
DateUtil
.
DTF_YMD_HMS
;
/**
*
*/
@Service
public
class
KylinRecommendActiveServiceImpl
implements
IKylinRecommendActiveService
{
@Autowired
private
DataUtils
dataUtils
;
@Autowired
private
KylinRedisUtils
kylinRedisUtils
;
@Autowired
private
GoblinOrderUtils
goblinOrderUtils
;
@Autowired
private
KylinPerformancesServiceImpl
kylinPerformancesService
;
@Override
public
KylinRecommendActiveVo
getRecommendById
(
List
<
KylinRecommendActive
>
list
)
throws
ParseException
{
for
(
KylinRecommendActive
kylinRecommendActive
:
list
)
{
//查看时间是否在当前范围内
if
(
LocalDateTime
.
now
().
isAfter
(
kylinRecommendActive
.
getStartTime
())
&&
LocalDateTime
.
now
().
isBefore
(
kylinRecommendActive
.
getEndTime
()))
{
KylinRecommendActiveVo
kylinRecommendActiveVo
=
KylinRecommendActiveVo
.
getNew
();
BeanUtils
.
copyProperties
(
kylinRecommendActive
,
kylinRecommendActiveVo
);
ArrayList
<
KylinRecommendActiveRelationVo
>
kylinRecommendActiveRelationVoList
=
ObjectUtil
.
getKylinRecommendActiveRelationVo
();
for
(
KylinRecommendActiveRelation
ky
:
kylinRecommendActive
.
getList
())
{
KylinRecommendActiveRelationVo
aNew
=
KylinRecommendActiveRelationVo
.
getNew
();
BeanUtils
.
copyProperties
(
ky
,
aNew
);
kylinRecommendActiveRelationVoList
.
add
(
aNew
);
}
kylinRecommendActiveVo
.
setList
(
kylinRecommendActiveRelationVoList
);
/* if(StringUtil.isNotBlank(kylinRecommendActiveVo.getActiveBindId())&&null !=kylinRecommendActiveVo.getActiveType()){
//找到绑定的详情
if(kylinRecommendActiveVo.getActiveType()==3){
//演出
KylinPerformanceVo performancesInfo = dataUtils.getPerformanceVo(kylinRecommendActiveVo.getActiveBindId());
kylinRecommendActiveVo.setKylinPerformanceVo(performancesInfo);
}else if(kylinRecommendActiveVo.getActiveType()==1){
//NFT
GoblinNftGoodsSkuInfoVo goblinNftGoodsSkuInfoVo=goodsDetail(kylinRecommendActiveVo.getActiveBindId());
com.liquidnet.service.kylin.dto.vo.GoblinNftGoodsSkuInfoVo aNew = com.liquidnet.service.kylin.dto.vo.GoblinNftGoodsSkuInfoVo.getNew();
BeanUtils.copyProperties(goblinNftGoodsSkuInfoVo,aNew);
kylinRecommendActiveVo.setGoblinNftGoodsSkuInfoVo(aNew);
}else if(kylinRecommendActiveVo.getActiveType()==4){
//商品
GoblinGoodsInfoVo goblinGoodsInfoVo = kylinRedisUtils.getGoodsInfoVo(kylinRecommendActiveVo.getActiveBindId());
com.liquidnet.service.kylin.dto.vo.GoblinGoodsInfoVo aNew = com.liquidnet.service.kylin.dto.vo.GoblinGoodsInfoVo.getNew();
BeanUtils.copyProperties(goblinGoodsInfoVo,aNew);
kylinRecommendActiveVo.setGoblinGoodsInfoVo(aNew);
}else if(kylinRecommendActiveVo.getActiveType()==2){
//组合购
GoblinMixAppDetailsVo goblinMixAppDetailsVo = mixDetails(kylinRecommendActiveVo.getActiveBindId());
com.liquidnet.service.kylin.dto.vo.GoblinMixAppDetailsVo aNew = com.liquidnet.service.kylin.dto.vo.GoblinMixAppDetailsVo.getNew();
BeanUtils.copyProperties(goblinMixAppDetailsVo,aNew);
kylinRecommendActiveVo.setGoblinMixAppDetailsVo(aNew);
}
}*/
//遍历list
List
<
KylinRecommendActiveRelationVo
>
kylinRecommendActiveVoList
=
kylinRecommendActiveVo
.
getList
();
ListIterator
<
KylinRecommendActiveRelationVo
>
iterator
=
kylinRecommendActiveVoList
.
listIterator
();
while
(
iterator
.
hasNext
())
{
KylinRecommendActiveRelationVo
kylinRecommendActiveRelationVo
=
iterator
.
next
();
if
(
kylinRecommendActiveRelationVo
.
getType
()
==
1
)
{
//NFT
GoblinNftGoodsSkuInfoVo
goblinNftGoodsSkuInfoVo
=
goodsDetail
(
kylinRecommendActiveRelationVo
.
getRecommendBindId
());
GoblinGoodsSkuInfoVo
goodsSkuInfoVo
=
kylinRedisUtils
.
getGoodsSkuInfoVo
(
goblinNftGoodsSkuInfoVo
.
getSkuId
());
if
(
null
!=
goblinNftGoodsSkuInfoVo
)
{
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
.
GoblinNftGoodsSkuInfoVo
aNew
=
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
.
GoblinNftGoodsSkuInfoVo
.
getNew
();
GoblinGoodsInfoVo
goodsInfoVo
=
kylinRedisUtils
.
getGoodsInfoVo
(
goblinNftGoodsSkuInfoVo
.
getSpuId
());
BeanUtils
.
copyProperties
(
goblinNftGoodsSkuInfoVo
,
aNew
);
aNew
.
setAuthor
(
goodsInfoVo
.
getAuthor
());
aNew
.
setPublisher
(
goodsInfoVo
.
getPublisher
());
if
(
null
!=
goodsSkuInfoVo
)
aNew
.
setCoverPic
(
goodsSkuInfoVo
.
getSkuPic
());
kylinRecommendActiveRelationVo
.
setGoblinNftGoodsSkuInfoVo
(
aNew
);
kylinRecommendActiveRelationVo
.
setCount
(
true
);
}
else
{
kylinRecommendActiveRelationVo
.
setCount
(
false
);
iterator
.
remove
();
}
}
else
if
(
kylinRecommendActiveRelationVo
.
getType
()
==
2
)
{
//组合购
GoblinMixAppDetailsVo
goblinMixAppDetailsVo
=
mixDetails
(
kylinRecommendActiveRelationVo
.
getRecommendBindId
());
if
(
null
!=
goblinMixAppDetailsVo
)
{
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
.
GoblinMixAppDetailsVo
aNew
=
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
.
GoblinMixAppDetailsVo
.
getNew
();
BeanUtils
.
copyProperties
(
goblinMixAppDetailsVo
,
aNew
);
if
(
StringUtil
.
isBlank
(
aNew
.
getShelvesTime
()))
aNew
.
setShelvesTime
(
aNew
.
getTimeStart
());
if
(
goblinMixAppDetailsVo
.
getStatus
()!=
7
&&
comparTime
(
aNew
.
getShelvesTime
(),
aNew
.
getTimeEnd
())){
kylinRecommendActiveRelationVo
.
setGoblinMixAppDetailsVo
(
aNew
);
kylinRecommendActiveRelationVo
.
setCount
(
true
);
}
else
{
kylinRecommendActiveRelationVo
.
setCount
(
false
);
iterator
.
remove
();
}
}
else
{
kylinRecommendActiveRelationVo
.
setCount
(
false
);
iterator
.
remove
();
}
}
else
if
(
kylinRecommendActiveRelationVo
.
getType
()
==
3
)
{
//演出
KylinPerformanceVo
performancesInfo
=
dataUtils
.
getPerformanceVo
(
kylinRecommendActiveRelationVo
.
getRecommendBindId
());
if
(
null
!=
performancesInfo
){
List
<
KylinPerformanceVo
>
newList
=
ObjectUtil
.
getKylinPerformanceVoArrayList
();
newList
.
add
(
performancesInfo
);
List
<
KylinPerformanceVo
>
kylinPerformanceVos
=
kylinPerformancesService
.
checkAppStatus
(
newList
);
if
(
null
!=
performancesInfo
.
getIsShow
()&&
performancesInfo
.
getIsShow
()==
0
){
kylinPerformanceVos
=
null
;
}
if
(
null
!=
kylinPerformanceVos
&&
kylinPerformanceVos
.
size
()>
0
){
performancesInfo
=
kylinPerformanceVos
.
get
(
0
);
kylinRecommendActiveRelationVo
.
setKylinPerformanceVo
(
performancesInfo
);
kylinRecommendActiveRelationVo
.
setCount
(
true
);
}
else
{
kylinRecommendActiveRelationVo
.
setCount
(
false
);
iterator
.
remove
();
}
}
else
{
kylinRecommendActiveRelationVo
.
setCount
(
false
);
iterator
.
remove
();
}
/* if(null!=performancesInfo){
if(performancesInfo.getAppStatus()!=7&&performancesInfo.getAppStatus()!=10){
kylinRecommendActiveRelationVo.setKylinPerformanceVo(performancesInfo);
kylinRecommendActiveRelationVo.setCount(true);
}else{
kylinRecommendActiveRelationVo.setCount(false);
iterator.remove();
}
}else{
kylinRecommendActiveRelationVo.setCount(false);
iterator.remove();
}*/
}
else
if
(
kylinRecommendActiveRelationVo
.
getType
()
==
4
)
{
//商品 //商品
GoblinGoodsInfoVo
goblinGoodsInfoVo
=
kylinRedisUtils
.
getGoodsInfoVo
(
kylinRecommendActiveRelationVo
.
getRecommendBindId
());
if
(
null
!=
goblinGoodsInfoVo
)
{
if
(
goblinGoodsInfoVo
.
getShelvesStatus
().
equals
(
"3"
)&&
goblinGoodsInfoVo
.
getSpuAppear
().
equals
(
"0"
)){
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
.
GoblinGoodsInfoVo
aNew
=
com
.
liquidnet
.
service
.
kylin
.
dto
.
vo
.
GoblinGoodsInfoVo
.
getNew
();
BeanUtils
.
copyProperties
(
goblinGoodsInfoVo
,
aNew
);
kylinRecommendActiveRelationVo
.
setGoblinGoodsInfoVo
(
aNew
);
kylinRecommendActiveRelationVo
.
setCount
(
true
);
}
else
{
kylinRecommendActiveRelationVo
.
setCount
(
false
);
iterator
.
remove
();
}
}
else
{
kylinRecommendActiveRelationVo
.
setCount
(
false
);
iterator
.
remove
();
}
}
/* for (KylinRecommendActiveRelationVo kylinRecommendActiveRelationVo : kylinRecommendActiveVoList) {
}*/
}
return
kylinRecommendActiveVo
;
}
}
return
null
;
}
public
boolean
comparTime
(
String
startTime
,
String
endTime
)
throws
ParseException
{
if
(
StringUtil
.
isNotBlank
(
startTime
)&&
StringUtil
.
isNotBlank
(
endTime
)){
LocalDateTime
nt
=
LocalDateTime
.
now
();
LocalDateTime
st
=
LocalDateTime
.
parse
(
startTime
,
DTF_YMD_HMS
);
LocalDateTime
et
=
LocalDateTime
.
parse
(
endTime
,
DTF_YMD_HMS
);
/* SimpleDateFormat sdf = DateUtil.SDF_YMD_HMS;*/
// LocalDateTime d = LocalDateTime.now();
/* Date d= new Date();*/
if
(
nt
.
isAfter
(
st
)&&
nt
.
isBefore
(
et
)){
return
true
;
}
/* if(d.compareTo(sdf.parse(startTime))>0&&d.compareTo(sdf.parse(endTime))<0){
return true;
}*/
}
return
false
;
}
// 各种状态下判断藏品是否可以展示
public
boolean
getSkuAllStatusShow
(
GoblinGoodsSkuInfoVo
info
)
{
if
(
info
!=
null
&&
info
.
getSkuType
()
==
1
&&
info
.
getStatus
().
equals
(
"3"
)
&&
info
.
getShelvesStatus
().
equals
(
"3"
)
&&
(
info
.
getSkuAppear
()
==
null
||
info
.
getSkuAppear
().
equals
(
"0"
))
&&
info
.
getDelFlg
().
equals
(
"0"
)
&&
((
info
.
getUnbox
().
equals
(
"0"
)
&&
info
.
getUpchain
()
==
1
)
||
info
.
getUnbox
().
equals
(
"1"
))
// && (info.getUnbox().equals("1") || info.getUpchain() == 1)
)
{
return
true
;
}
else
{
return
false
;
}
}
public
static
void
main
(
String
[]
args
)
throws
ParseException
{
KylinRecommendActiveServiceImpl
a
=
new
KylinRecommendActiveServiceImpl
();
boolean
b
=
a
.
comparTime
(
"2020-12-01 00:00:00"
,
"2022-12-01 00:00:00"
);
System
.
out
.
println
(
b
);
/* //LocalDate a=new LocalDate("2009-12-31 12:00:00");
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
Date date1 = sdf.parse("2009-12-31 12:00:00");
Date date2 = sdf.parse("2023-01-31 12:00:00");
Date date = new Date();
System.out.println(date.compareTo(date1));
System.out.println(date.compareTo(date2));*/
}
public
AnticipateValueVo
getAnticipateValueBySkuId
(
String
skuId
,
int
hasHead
)
{
GoblinGoodsAnticipateValueVo
anticipateValueVo
=
kylinRedisUtils
.
getValueBySkuId
(
skuId
);
AnticipateValueVo
valueVo
=
AnticipateValueVo
.
getNew
();
if
(
anticipateValueVo
!=
null
)
{
valueVo
=
valueVo
.
copy
(
anticipateValueVo
);
valueVo
.
setState
(
GoblinAnticipateUtils
.
setState
(
valueVo
.
getAboutStartDate
(),
valueVo
.
getAboutEndDate
()));
}
else
{
valueVo
.
setState
(
null
);
valueVo
.
setAboutEndDate
(
null
);
valueVo
.
setAboutStartDate
(
null
);
valueVo
.
setAboutPeople
(
BigInteger
.
ZERO
);
valueVo
.
setType
(
null
);
valueVo
.
setPeopleType
(
null
);
valueVo
.
setRule
(
""
);
}
if
(
hasHead
==
1
)
{
valueVo
.
setAboutAvatarList
(
kylinRedisUtils
.
getUserAvatar
(
skuId
));
}
else
{
valueVo
.
setAboutAvatarList
(
CollectionUtil
.
linkedListString
());
}
return
valueVo
;
}
/**
* NFT 获取详情
*/
public
GoblinNftGoodsSkuInfoVo
goodsDetail
(
String
skuId
)
{
// 1
LocalDateTime
now
=
LocalDateTime
.
now
();
HashMap
<
String
,
Object
>
map
=
kylinRedisUtils
.
getGoodsSkuInfoVo
(
now
,
skuId
);
if
(
null
==
map
)
{
return
null
;
}
GoblinGoodsSkuInfoVo
skuInfoVo
=
(
GoblinGoodsSkuInfoVo
)
map
.
get
(
"vo"
);
Integer
tagType
=
(
Integer
)
map
.
get
(
"tagType"
);
String
listId
=
(
String
)
map
.
get
(
"listId"
);
LocalDateTime
baseSaleStartTime
=
(
LocalDateTime
)
map
.
get
(
"baseSaleStartTime"
);
LocalDateTime
nextSaleStartTime
=
(
LocalDateTime
)
map
.
get
(
"nextSaleStartTime"
);
if
(
kylinRedisUtils
.
getSkuAllStatusShow
(
skuInfoVo
))
{
//获取预约相关
AnticipateValueVo
anticipateValueVo
=
getAnticipateValueBySkuId
(
skuId
,
1
);
GoblinNftGoodsSkuInfoVo
nftGoodsSkuInfoVo
=
GoblinNftGoodsSkuInfoVo
.
getNew
().
copy
(
skuInfoVo
,
anticipateValueVo
);
// 限购数量
Integer
buyCount
=
0
;
String
userId
=
CurrentUtil
.
getCurrentUid
();
if
(
StringUtils
.
isNotBlank
(
userId
))
{
buyCount
=
kylinRedisUtils
.
getSkuCountByUid
(
userId
,
skuId
);
}
if
(
null
!=
skuInfoVo
.
getBuyLimit
()
&&
0
!=
skuInfoVo
.
getBuyLimit
())
{
nftGoodsSkuInfoVo
.
setCanBuyNum
(
skuInfoVo
.
getBuyLimit
()
-
buyCount
);
}
// spu信息
GoblinGoodsInfoVo
goodsInfoVo
=
kylinRedisUtils
.
getGoodsInfoVo
(
skuInfoVo
.
getSpuId
());
GoblinNftGoodsDetailSpuInfoVo
nftGoodsDetailSpuInfoVo
=
GoblinNftGoodsDetailSpuInfoVo
.
getNew
().
copy
(
goodsInfoVo
);
nftGoodsSkuInfoVo
.
setGoblinNftGoodsDetailSpuInfoVo
(
nftGoodsDetailSpuInfoVo
);
// 库存
HashMap
<
String
,
Integer
>
stockHashMap
=
goblinOrderUtils
.
getIsStock
(
listId
,
skuId
,
skuInfoVo
.
getUnbox
(),
skuInfoVo
.
getSoldoutStatus
(),
goodsInfoVo
.
getSkuIdList
());
nftGoodsSkuInfoVo
.
setIsStock
(
stockHashMap
.
get
(
"isStock"
));
// 总库存
if
(
skuInfoVo
.
getUnbox
().
equals
(
"1"
))
{
nftGoodsSkuInfoVo
.
setSkuStock
(
stockHashMap
.
get
(
"totalStock"
));
}
// 系统时间
nftGoodsSkuInfoVo
.
setSystime
(
LocalDateTime
.
now
());
nftGoodsSkuInfoVo
.
setTagType
(
tagType
);
nftGoodsSkuInfoVo
.
setListId
(
listId
);
nftGoodsSkuInfoVo
.
setBaseSaleStartTime
(
baseSaleStartTime
);
nftGoodsSkuInfoVo
.
setNextSaleStartTime
(
nextSaleStartTime
);
// 是否开启兑换
nftGoodsSkuInfoVo
.
setIsExchange
(
kylinRedisUtils
.
getIsExchange
(
skuId
));
// 待支付订单数量
nftGoodsSkuInfoVo
.
setNotPayNum
(
kylinRedisUtils
.
getNotPayNum
(
skuId
,
listId
));
return
nftGoodsSkuInfoVo
;
}
else
{
return
null
;
}
}
public
GoblinMixAppDetailsVo
mixDetails
(
String
mixId
)
{
GoblinMixDetailsVo
baseVo
=
kylinRedisUtils
.
getMixDetails
(
mixId
);
//GoblinStoreInfoVo storeInfoVo = redisUtils.getStoreInfoVo(baseVo.getStoreId());
GoblinMixAppDetailsVo
vo
=
GoblinMixAppDetailsVo
.
getNew
().
copy
(
baseVo
,
""
);
int
stock
=
0
;
for
(
GoblinMixDetailsItemVo
item
:
vo
.
getItem
())
{
GoblinGoodsSkuInfoVo
skuInfoVo
=
kylinRedisUtils
.
getGoodsSkuInfoVo
(
item
.
getSkuId
());
GoblinGoodsInfoVo
spuInfoVo
=
kylinRedisUtils
.
getGoodsInfoVo
(
skuInfoVo
.
getSpuId
());
item
.
setSkuPic
(
skuInfoVo
.
getSkuPic
());
item
.
setStock
(
0
);
item
.
setSkuName
(
skuInfoVo
.
getName
());
item
.
setSpuName
(
spuInfoVo
.
getName
());
if
(
skuInfoVo
.
getUnbox
().
equals
(
"1"
))
{
List
<
String
>
relationIds
=
kylinRedisUtils
.
getGoblinMixRelationBox
(
item
.
getSkuId
(),
vo
.
getMixId
());
for
(
String
skuId
:
relationIds
)
{
stock
+=
kylinRedisUtils
.
getSkuStock
(
vo
.
getMixId
(),
skuId
);
}
}
else
{
stock
+=
kylinRedisUtils
.
getSkuStock
(
vo
.
getMixId
(),
item
.
getSkuId
());
}
}
if
(
stock
==
0
)
{
vo
.
setStatus
(
8
);
}
else
{
LocalDateTime
nt
=
LocalDateTime
.
now
();
LocalDateTime
st
=
LocalDateTime
.
parse
(
vo
.
getTimeStart
(),
DTF_YMD_HMS
);
LocalDateTime
et
=
LocalDateTime
.
parse
(
vo
.
getTimeEnd
(),
DTF_YMD_HMS
);
if
(
baseVo
.
getStatus
()
==
7
)
{
vo
.
setStatus
(
7
);
}
else
{
if
(
nt
.
isBefore
(
st
))
{
vo
.
setStatus
(
9
);
}
else
if
(
nt
.
isAfter
(
et
))
{
vo
.
setStatus
(
10
);
}
else
{
vo
.
setStatus
(
6
);
}
}
}
return
vo
;
}
}
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/kylin/utils/DataUtils.java
View file @
75cd17ba
...
...
@@ -22,6 +22,7 @@ import com.liquidnet.service.kylin.dto.vo.returns.KylinOrderListVo;
import
com.liquidnet.service.kylin.dto.vo.returns.KylinOrderRefundsVo
;
import
com.liquidnet.service.kylin.dto.vo.returns.NoticeKylinPerformanceVo
;
import
com.liquidnet.service.kylin.entity.KylinOrderCoupons
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActive
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.domain.PageRequest
;
...
...
@@ -1365,6 +1366,10 @@ public class DataUtils {
return
(
List
<
String
>)
obj
;
}
}
//获得 admin配置的推荐活动
public
List
<
KylinRecommendActive
>
getRecommendActive
(
String
id
)
{
return
(
List
<
KylinRecommendActive
>)
redisUtil
.
get
(
KylinRedisConst
.
RECOMMEND_ACTIVE
+
id
);
}
/**
* @param userId 用户id
...
...
@@ -1425,4 +1430,29 @@ public class DataUtils {
return
false
;
}
}
//删除 订单Ar激活码
public
void
delOrderArCode
(
String
orderId
){
String
rdk
=
KylinRedisConst
.
ORDER_AR_CODE
.
concat
(
orderId
);
redisUtil
.
del
(
rdk
);
}
//添加 订单Ar激活码
public
void
addOrderArCode
(
String
orderId
,
String
arCode
){
String
rdk
=
KylinRedisConst
.
ORDER_AR_CODE
.
concat
(
orderId
);
List
<
String
>
data
=
getOrderArCode
(
orderId
);
data
.
add
(
arCode
);
redisUtil
.
set
(
rdk
,
data
);
}
//获取 订单Ar激活码
public
List
<
String
>
getOrderArCode
(
String
orderId
){
String
rdk
=
KylinRedisConst
.
ORDER_AR_CODE
.
concat
(
orderId
);
Object
obj
=
redisUtil
.
get
(
rdk
);
if
(
obj
==
null
){
return
CollectionUtil
.
arrayListString
();
}
else
{
return
(
List
<
String
>)
obj
;
}
}
}
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/kylin/utils/GoblinAnticipateUtils.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
utils
;
import
com.fasterxml.jackson.core.type.TypeReference
;
import
com.liquidnet.commons.lang.util.CollectionUtil
;
import
com.liquidnet.commons.lang.util.CurrentUtil
;
import
com.liquidnet.commons.lang.util.HttpUtil
;
import
com.liquidnet.commons.lang.util.JsonUtils
;
import
com.liquidnet.service.adam.dto.vo.AdamUserInfoVo
;
import
com.liquidnet.service.adam.dto.vo.AdamUserProfileVo
;
import
com.liquidnet.service.base.ResponseDto
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.stereotype.Component
;
import
org.springframework.util.MultiValueMap
;
import
java.time.LocalDateTime
;
/**
* @author TT
*/
@Component
@Slf4j
public
class
GoblinAnticipateUtils
{
@Value
(
"${liquidnet.service.adam.url}"
)
private
String
adamUrl
;
public
AdamUserInfoVo
getUserInfo
()
{
try
{
MultiValueMap
<
String
,
String
>
header
=
CollectionUtil
.
linkedMultiValueMapStringString
();
header
.
add
(
"Authorization"
,
"Bearer "
+
CurrentUtil
.
getToken
());
header
.
add
(
"Accept"
,
"application/json;charset=UTF-8"
);
String
returnData
=
HttpUtil
.
post
(
adamUrl
+
"/adam/user/info"
,
null
,
header
);
ResponseDto
<
AdamUserProfileVo
>
innerReturnVo
=
JsonUtils
.
fromJson
(
returnData
,
new
TypeReference
<
ResponseDto
<
AdamUserProfileVo
>>()
{
});
if
(
innerReturnVo
.
getData
()
!=
null
)
{
return
innerReturnVo
.
getData
().
getUserInfo
();
}
log
.
info
(
"post url:{}<----->Authorization:{}"
,
adamUrl
+
" /adam/user/info"
,
CurrentUtil
.
getToken
());
return
null
;
}
catch
(
Exception
e
)
{
log
.
info
(
"post url:{}<----->Authorization:{}"
,
adamUrl
+
" /adam/user/info"
,
CurrentUtil
.
getToken
());
log
.
error
(
"获取用户头像失败"
,
e
);
return
null
;
}
}
public
static
Integer
setState
(
LocalDateTime
startDate
,
LocalDateTime
endDate
)
{
LocalDateTime
now
=
LocalDateTime
.
now
();
if
(
startDate
.
isAfter
(
now
))
{
//未开始 0
return
0
;
}
if
(
startDate
.
isBefore
(
now
)
&&
endDate
.
isAfter
(
now
))
{
//预约中 1
return
1
;
}
if
(
endDate
.
isBefore
(
now
))
{
//已结束 2
return
2
;
}
//其他
return
null
;
}
}
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/kylin/utils/GoblinOrderUtils.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
utils
;
import
com.liquidnet.commons.lang.util.CollectionUtil
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsSkuInfoVo
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.stereotype.Component
;
import
java.time.LocalDateTime
;
import
java.util.HashMap
;
import
java.util.List
;
@Component
@Slf4j
public
class
GoblinOrderUtils
{
@Value
(
"${liquidnet.service.candy.url}"
)
private
String
candyUrl
;
/* @Autowired
GoblinRedisUtils redisUtils;*/
@Autowired
private
KylinRedisUtils
kylinRedisUtils
;
@Autowired
QueueUtils
queueUtils
;
// NFT判断是否售罄
public
HashMap
<
String
,
Integer
>
getIsStock
(
String
listId
,
String
skuId
,
String
unbox
,
String
soldoutStatus
,
List
<
String
>
skuIdList
)
{
HashMap
<
String
,
Integer
>
returnMap
=
CollectionUtil
.
mapStringInteger
();
Integer
isStock
=
0
;
Integer
totalStock
=
0
;
if
(
null
==
soldoutStatus
||
soldoutStatus
.
equals
(
"0"
))
{
// 未设置售罄 查询库存
int
surplusStock
=
0
;
if
(
unbox
.
equals
(
"0"
))
{
// 不是盲盒
surplusStock
=
kylinRedisUtils
.
getSkuStock
(
listId
,
skuId
);
}
else
{
for
(
String
skuIdItem
:
skuIdList
)
{
// 盲盒计算所有sku库存总数
if
(
skuIdItem
.
equals
(
skuId
))
{
// 过滤自己
continue
;
}
HashMap
<
String
,
Object
>
map
=
kylinRedisUtils
.
getGoodsSkuInfoVo
(
LocalDateTime
.
now
(),
skuIdItem
);
GoblinGoodsSkuInfoVo
itemVo
=
(
GoblinGoodsSkuInfoVo
)
map
.
get
(
"vo"
);
// String listId2 = (String) map.get("listId");
// surplusStock += redisUtils.getSkuAllStatusStock(itemVo, listId2);
surplusStock
+=
kylinRedisUtils
.
getSkuAllStatusStock
(
itemVo
,
listId
);
totalStock
+=
kylinRedisUtils
.
getSkuTotalStock
(
itemVo
);
}
}
if
(
surplusStock
>
0
)
{
isStock
=
1
;
}
}
returnMap
.
put
(
"isStock"
,
isStock
);
returnMap
.
put
(
"totalStock"
,
totalStock
);
return
returnMap
;
}
}
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/kylin/utils/KylinRedisUtils.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
kylin
.
utils
;
import
com.liquidnet.common.cache.redis.util.RedisUtil
;
import
com.liquidnet.commons.lang.util.CollectionUtil
;
import
com.liquidnet.service.goblin.constant.GoblinRedisConst
;
import
com.liquidnet.service.goblin.constant.GoblinStatusConst
;
import
com.liquidnet.service.goblin.dto.manage.vo.GoblinGoodsAnticipateValueVo
;
import
com.liquidnet.service.goblin.dto.vo.*
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
java.util.ArrayList
;
import
java.util.Comparator
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.stream.Collectors
;
@Slf4j
@Component
public
class
KylinRedisUtils
{
@Autowired
RedisUtil
redisUtil
;
@Autowired
GoblinMongodbUtils
goblinMongoUtils
;
private
int
randomMax
=
10
;
public
void
del
(
String
...
keys
)
{
redisUtil
.
del
(
keys
);
}
/**
* 商品基础信息
*
* @param spuId 商品ID
* @return GoblinGoodsInfoVo
*/
public
GoblinGoodsInfoVo
getGoodsInfoVo
(
String
spuId
)
{
String
pre
=
GoblinStatusConst
.
MarketPreStatus
.
getPre
(
spuId
);
if
(
pre
!=
null
&&
pre
.
equals
(
GoblinStatusConst
.
MarketPreStatus
.
MARKET_PRE_ZHENGZAI
.
getValue
()))
{
String
[]
spuSplitArr
=
spuId
.
split
(
GoblinStatusConst
.
MarketPreStatus
.
MARKET_PRE_ZHENGZAI
.
getValue
());
String
rk
=
GoblinRedisConst
.
BASIC_GOODS
.
concat
(
spuSplitArr
[
0
]);
GoblinGoodsInfoVo
vo
=
(
GoblinGoodsInfoVo
)
redisUtil
.
get
(
rk
);
if
(
null
==
vo
&&
null
!=
(
vo
=
goblinMongoUtils
.
getGoodsInfoVo
(
spuId
)))
{
redisUtil
.
set
(
rk
,
vo
);
}
if
(
vo
==
null
)
{
return
vo
;
}
String
marketrk
=
GoblinRedisConst
.
BASIC_GOODS
.
concat
(
spuId
);
GoblinGoodsInfoVo
marketVo
=
(
GoblinGoodsInfoVo
)
redisUtil
.
get
(
marketrk
);
if
(
null
==
marketVo
&&
null
!=
(
marketVo
=
goblinMongoUtils
.
getGoodsInfoVo
(
spuId
)))
{
redisUtil
.
set
(
marketrk
,
marketVo
);
}
if
(
marketVo
==
null
)
{
return
marketVo
;
}
vo
.
setSpuId
(
marketVo
.
getSpuId
());
List
<
String
>
skuIdList
=
CollectionUtil
.
linkedListString
();
for
(
String
skuIds
:
vo
.
getSkuIdList
())
{
skuIdList
.
add
(
skuIds
.
concat
(
pre
).
concat
(
spuSplitArr
[
1
]));
}
vo
.
setSkuIdList
(
skuIdList
);
vo
.
setPriceGe
(
marketVo
.
getPriceGe
());
vo
.
setPriceLe
(
marketVo
.
getPriceLe
());
vo
.
setMarketId
(
marketVo
.
getMarketId
());
vo
.
setDelFlg
(
marketVo
.
getDelFlg
().
equals
(
"1"
)
?
marketVo
.
getDelFlg
()
:
vo
.
getDelFlg
());
return
vo
;
}
else
{
String
rk
=
GoblinRedisConst
.
BASIC_GOODS
.
concat
(
spuId
);
GoblinGoodsInfoVo
vo
=
(
GoblinGoodsInfoVo
)
redisUtil
.
get
(
rk
);
if
(
null
==
vo
&&
null
!=
(
vo
=
goblinMongoUtils
.
getGoodsInfoVo
(
spuId
)))
{
redisUtil
.
set
(
rk
,
vo
);
}
return
vo
;
}
}
/**
* 获取 包含分段购的sku详情 HASHMAP
*
* @param now 当前时间
* @param skuId skuId
* @return
*/
public
HashMap
<
String
,
Object
>
getGoodsSkuInfoVo
(
LocalDateTime
now
,
String
skuId
)
{
GoblinGoodsSkuInfoVo
vo
=
getGoodsSkuInfoVo
(
skuId
);
if
(
null
==
vo
)
{
return
null
;
}
HashMap
<
String
,
Object
>
map
=
CollectionUtil
.
mapStringObject
();
LocalDateTime
nextSaleStartTime
=
null
;
if
(
null
==
vo
.
getSaleStartTime
()
||
now
.
isAfter
(
vo
.
getSaleStartTime
()))
{
//普通商品已开售
map
.
put
(
"vo"
,
vo
);
map
.
put
(
"tagType"
,
null
);
map
.
put
(
"listId"
,
null
);
map
.
put
(
"whiteType"
,
null
);
map
.
put
(
"baseSaleStartTime"
,
vo
.
getSaleStartTime
());
map
.
put
(
"nextSaleStartTime"
,
null
);
}
else
{
//未开售
GoblinListCollectVo
collectVo
=
getCollectByNow
(
now
,
skuId
);
Integer
tagType
=
null
;
Integer
whiteType
=
null
;
String
listId
=
null
;
LocalDateTime
baseSaleStartTime
=
vo
.
getSaleStartTime
();
if
(
collectVo
!=
null
)
{
vo
.
setPrice
(
collectVo
.
getPrice
());
vo
.
setPriceV
(
collectVo
.
getPriceV
());
vo
.
setProductId
(
collectVo
.
getProductId
());
vo
.
setSaleStartTime
(
collectVo
.
getTimeStart
());
vo
.
setSaleStopTime
(
collectVo
.
getTimeEnd
());
listId
=
collectVo
.
getListId
();
whiteType
=
collectVo
.
getWhiteType
();
tagType
=
collectVo
.
getTagType
();
}
GoblinListCollectVo
collectNext
=
getCollectByNowNext
(
now
,
skuId
);
if
(
collectNext
!=
null
)
{
if
(
tagType
==
null
)
{
tagType
=
collectNext
.
getTagType
();
}
//todo 逻辑修改 开售时间
if
(
collectVo
==
null
)
{
vo
.
setSaleStartTime
(
collectNext
.
getTimeStart
());
vo
.
setSaleStopTime
(
collectNext
.
getTimeEnd
());
}
nextSaleStartTime
=
collectNext
.
getTimeStart
();
}
map
.
put
(
"vo"
,
vo
);
map
.
put
(
"tagType"
,
tagType
);
map
.
put
(
"listId"
,
listId
);
map
.
put
(
"whiteType"
,
whiteType
);
map
.
put
(
"baseSaleStartTime"
,
baseSaleStartTime
);
map
.
put
(
"nextSaleStartTime"
,
nextSaleStartTime
);
}
return
map
;
}
/**
* 单品信息
*
* @param skuId 单品ID
* @return GoblinGoodsSkuInfoVo
*/
public
GoblinGoodsSkuInfoVo
getGoodsSkuInfoVo
(
String
skuId
)
{
String
pre
=
GoblinStatusConst
.
MarketPreStatus
.
getPre
(
skuId
);
if
(
pre
!=
null
&&
pre
.
equals
(
GoblinStatusConst
.
MarketPreStatus
.
MARKET_PRE_ZHENGZAI
.
getValue
()))
{
String
rk
=
GoblinRedisConst
.
BASIC_GOODS_SKU
.
concat
(
skuId
.
split
(
GoblinStatusConst
.
MarketPreStatus
.
MARKET_PRE_ZHENGZAI
.
getValue
())[
0
]);
GoblinGoodsSkuInfoVo
vo
=
(
GoblinGoodsSkuInfoVo
)
redisUtil
.
get
(
rk
);
if
(
null
==
vo
&&
null
!=
(
vo
=
goblinMongoUtils
.
getGoodsSkuInfoVo
(
skuId
)))
{
redisUtil
.
set
(
rk
,
vo
);
}
if
(
vo
==
null
)
{
return
vo
;
}
String
marketrk
=
GoblinRedisConst
.
BASIC_GOODS_SKU
.
concat
(
skuId
);
GoblinGoodsSkuInfoVo
marketVo
=
(
GoblinGoodsSkuInfoVo
)
redisUtil
.
get
(
marketrk
);
if
(
null
==
marketVo
&&
null
!=
(
marketVo
=
goblinMongoUtils
.
getGoodsSkuInfoVo
(
skuId
)))
{
redisUtil
.
set
(
marketrk
,
marketVo
);
}
if
(
marketVo
==
null
)
{
return
marketVo
;
}
vo
.
setSpuId
(
marketVo
.
getSpuId
());
vo
.
setSkuId
(
marketVo
.
getSkuId
());
vo
.
setPrice
(
marketVo
.
getPrice
());
vo
.
setPriceMember
(
marketVo
.
getPriceMember
());
vo
.
setSkuStock
(
marketVo
.
getSkuStock
());
vo
.
setBuyLimit
(
marketVo
.
getBuyLimit
());
vo
.
setBuyRoster
(
marketVo
.
getBuyRoster
());
vo
.
setBuyFactor
(
marketVo
.
getBuyFactor
());
// vo.setDelFlg("0");
vo
.
setDelFlg
(
marketVo
.
getDelFlg
().
equals
(
"1"
)
?
marketVo
.
getDelFlg
()
:
vo
.
getDelFlg
());
vo
.
setMarketId
(
marketVo
.
getMarketId
());
vo
.
setCreatedAt
(
LocalDateTime
.
now
());
return
vo
;
}
else
{
String
rk
=
GoblinRedisConst
.
BASIC_GOODS_SKU
.
concat
(
skuId
);
GoblinGoodsSkuInfoVo
vo
=
(
GoblinGoodsSkuInfoVo
)
redisUtil
.
get
(
rk
);
if
(
null
==
vo
&&
null
!=
(
vo
=
goblinMongoUtils
.
getGoodsSkuInfoVo
(
skuId
)))
{
redisUtil
.
set
(
rk
,
vo
);
}
return
vo
;
}
}
/**
* 根据时间获取当前分段购vo
*
* @param now
* @param skuId
* @return
*/
public
GoblinListCollectVo
getCollectByNow
(
LocalDateTime
now
,
String
skuId
)
{
GoblinListCollectVo
collectVo
=
null
;
GoblinListCollectVo
collectTemp
=
null
;
List
<
GoblinListCollectVo
>
collectVos
=
getGoblinListCollect
(
skuId
);
for
(
int
i
=
0
;
i
<
collectVos
.
size
();
i
++)
{
GoblinListCollectVo
collectVoItem
=
collectVos
.
get
(
i
);
if
(
now
.
isAfter
(
collectVoItem
.
getTimeStart
())
&&
collectVoItem
.
getTimeEnd
()
==
null
)
{
if
(
collectTemp
==
null
||
collectTemp
.
getTimeStart
().
isBefore
(
collectVoItem
.
getTimeStart
()))
{
collectTemp
=
collectVoItem
;
}
}
else
if
(
now
.
isAfter
(
collectVoItem
.
getTimeStart
())
&&
now
.
isBefore
(
collectVoItem
.
getTimeEnd
()))
{
collectVo
=
collectVoItem
;
break
;
}
else
if
(
collectVoItem
.
getTimeEnd
()
!=
null
&&
now
.
isAfter
(
collectVoItem
.
getTimeEnd
()))
{
collectTemp
=
null
;
}
}
if
(
collectVo
==
null
)
{
collectVo
=
collectTemp
;
}
return
collectVo
;
}
public
List
<
GoblinListCollectVo
>
getGoblinListCollect
(
String
skuId
)
{
Object
obj
=
redisUtil
.
get
(
GoblinRedisConst
.
LIST_COLLECT
.
concat
(
skuId
));
if
(
obj
==
null
)
{
return
ObjectUtil
.
getGoblinListCollectVo
();
}
else
{
List
<
GoblinListCollectVo
>
list
=
(
List
<
GoblinListCollectVo
>)
obj
;
list
=
list
.
stream
().
sorted
(
Comparator
.
comparing
(
GoblinListCollectVo:
:
getTimeStart
)).
collect
(
Collectors
.
toList
());
return
list
;
}
}
/**
* 根据时间获取当前分段购vo 如果当前没有返回下一个
*
* @param now
* @param skuId
* @return
*/
public
GoblinListCollectVo
getCollectByNowNext
(
LocalDateTime
now
,
String
skuId
)
{
GoblinListCollectVo
collectVo
=
null
;
GoblinListCollectVo
collectTemp
=
null
;
GoblinListCollectVo
collectNext
=
null
;
List
<
GoblinListCollectVo
>
collectVos
=
getGoblinListCollect
(
skuId
);
for
(
int
i
=
0
;
i
<
collectVos
.
size
();
i
++)
{
GoblinListCollectVo
collectVoItem
=
collectVos
.
get
(
i
);
if
(
now
.
isAfter
(
collectVoItem
.
getTimeStart
())
&&
collectVoItem
.
getTimeEnd
()
==
null
)
{
if
(
collectTemp
==
null
||
collectTemp
.
getTimeStart
().
isBefore
(
collectVoItem
.
getTimeStart
()))
{
collectTemp
=
collectVoItem
;
}
}
else
if
(
now
.
isAfter
(
collectVoItem
.
getTimeStart
())
&&
now
.
isBefore
(
collectVoItem
.
getTimeEnd
()))
{
collectVo
=
collectVoItem
;
}
else
if
(
now
.
isBefore
(
collectVoItem
.
getTimeStart
()))
{
if
(
collectNext
==
null
||
collectNext
.
getTimeStart
().
isAfter
(
collectNext
.
getTimeStart
()))
{
collectNext
=
collectVoItem
;
}
}
else
if
(
collectVoItem
.
getTimeEnd
()
!=
null
&&
now
.
isAfter
(
collectVoItem
.
getTimeEnd
()))
{
collectTemp
=
null
;
}
}
// if (collectVo == null && collectTemp != null) {
// collectVo = collectTemp;
// } else
// if (collectVo == null) {
// collectVo = collectNext;
// }
// return collectVo;
return
collectNext
;
}
// 各种状态下判断藏品是否可以展示
public
boolean
getSkuAllStatusShow
(
GoblinGoodsSkuInfoVo
info
)
{
if
(
info
!=
null
&&
info
.
getSkuType
()
==
1
&&
info
.
getStatus
().
equals
(
"3"
)
&&
info
.
getShelvesStatus
().
equals
(
"3"
)
&&
(
info
.
getSkuAppear
()
==
null
||
info
.
getSkuAppear
().
equals
(
"0"
))
&&
info
.
getDelFlg
().
equals
(
"0"
)
&&
((
info
.
getUnbox
().
equals
(
"0"
)
&&
info
.
getUpchain
()
==
1
)
||
info
.
getUnbox
().
equals
(
"1"
))
// && (info.getUnbox().equals("1") || info.getUpchain() == 1)
)
{
return
true
;
}
else
{
return
false
;
}
}
/**
* 根据skuId获取valueVo
*/
public
GoblinGoodsAnticipateValueVo
getValueBySkuId
(
String
skuId
)
{
return
(
GoblinGoodsAnticipateValueVo
)
redisUtil
.
get
(
GoblinRedisConst
.
ANTICIPATE_VALUE_SKUID
.
concat
(
skuId
));
}
//获取 用户sku购买个数
public
Integer
getSkuCountByUid
(
String
uid
,
String
skuId
)
{
String
redisKey
=
GoblinRedisConst
.
REDIS_GOBLIN_BUY_COUNT
.
concat
(
uid
+
":skuId:"
+
skuId
);
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
0
;
}
else
{
return
(
Integer
)
obj
;
}
}
public
int
getIsExchange
(
String
skuId
)
{
String
redisKey
=
GoblinRedisConst
.
ACTIVITY_SKU_TIME
.
concat
(
skuId
);
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
1
;
}
else
{
GoblinNftExSkuVo
exSkuVo
=
(
GoblinNftExSkuVo
)
obj
;
if
((
null
==
exSkuVo
.
getExStartTime
()
||
LocalDateTime
.
now
().
isAfter
(
exSkuVo
.
getExStartTime
()))
&&
(
null
==
exSkuVo
.
getExStopTime
()
||
LocalDateTime
.
now
().
isBefore
(
exSkuVo
.
getExStopTime
())))
{
return
2
;
}
else
{
return
1
;
}
}
}
public
int
getNotPayNum
(
String
skuId
,
String
listId
)
{
String
redisKey
=
GoblinRedisConst
.
REDIS_GOBLIN_NFT_NOT_PAY_NUM
.
concat
(
skuId
);
if
(
null
!=
listId
)
{
redisKey
=
redisKey
.
concat
(
":"
).
concat
(
listId
);
}
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
1
;
}
else
{
return
(
int
)
obj
;
}
}
// 获取盲盒下藏品的库存 各种状态下不能算库存的排除掉
public
int
getSkuAllStatusStock
(
GoblinGoodsSkuInfoVo
info
,
String
listId
)
{
if
(
info
!=
null
// && LocalDateTime.now().isAfter(info.getSaleStartTime())
&&
(
null
==
info
.
getSoldoutStatus
()
||
info
.
getSoldoutStatus
().
equals
(
"0"
))
&&
(
null
==
info
.
getHitRatio
()
||
info
.
getHitRatio
().
compareTo
(
BigDecimal
.
ZERO
)
>
0
)
&&
(
null
==
info
.
getSkuCanbuy
()
||
info
.
getSkuCanbuy
().
equals
(
"1"
))
)
{
// 可以返回库存
// 外面只有盲盒才能请求进来 里面只有不是分批购才判断盲盒里藏品的开售时间
if
(
null
==
listId
)
{
// if (LocalDateTime.now().isAfter(info.getSaleStartTime())) {
return
getSkuStock
(
listId
,
info
.
getSkuId
());
// } else {
// return 0;
// }
}
else
{
return
getSkuStock
(
listId
,
info
.
getSkuId
());
}
}
else
{
// 不计入库存
return
0
;
}
}
// 各种状态下判断藏品总库存
public
Integer
getSkuTotalStock
(
GoblinGoodsSkuInfoVo
info
)
{
if
(
info
!=
null
// && LocalDateTime.now().isAfter(info.getSaleStartTime())
// && (null == info.getSoldoutStatus() || info.getSoldoutStatus().equals("0"))
// && (null == info.getHitRatio() || info.getHitRatio().compareTo(BigDecimal.ZERO) > 0)
)
{
// 可以返回库存
return
info
.
getSkuStock
();
}
else
{
// 不计入库存
return
0
;
}
}
/**
* 获取用户预约头像
*/
public
List
<
String
>
getUserAvatar
(
String
skuId
)
{
String
rdk
=
GoblinRedisConst
.
ANTICIPATE_SKUID_AVATAR
.
concat
(
skuId
);
Object
obj
=
redisUtil
.
get
(
rdk
);
if
(
obj
==
null
)
{
return
CollectionUtil
.
arrayListString
();
}
else
{
return
(
List
<
String
>)
obj
;
}
}
// 获取 组合售数据
public
GoblinMixDetailsVo
getMixDetails
(
String
mixId
)
{
String
rdk
=
GoblinRedisConst
.
GOBLIN_MIX_DETAILS
.
concat
(
mixId
);
Object
obj
=
redisUtil
.
get
(
rdk
);
if
(
obj
==
null
)
{
return
GoblinMixDetailsVo
.
getNew
();
}
else
{
return
(
GoblinMixDetailsVo
)
obj
;
}
}
//根据用户uid和混合mixId查询用户预约
public
GoblinMixReserveVo
getReserveMixByUid
(
String
uid
,
String
mixId
)
{
Object
obj
=
redisUtil
.
get
(
GoblinRedisConst
.
GOBLIN_MIX_RESERVE_UID
.
concat
(
mixId
).
concat
(
":"
).
concat
(
uid
));
if
(
obj
==
null
)
{
return
null
;
}
else
{
return
(
GoblinMixReserveVo
)
obj
;
}
}
/**
* 获取 盲盒skuId 关联 的skuId
*/
public
ArrayList
<
String
>
getGoblinMixRelationBox
(
String
skuId
,
String
mixId
)
{
String
rdk
=
GoblinRedisConst
.
GOBLIN_MIX_RELATION_BOX
.
concat
(
skuId
).
concat
(
":"
+
mixId
);
Object
obj
=
redisUtil
.
get
(
rdk
);
if
(
obj
==
null
)
{
return
CollectionUtil
.
arrayListString
();
}
else
{
return
(
ArrayList
<
String
>)
obj
;
}
}
public
int
getSkuStock
(
String
marketPre
,
String
skuId
)
{
String
rk
=
GoblinRedisConst
.
REAL_STOCK_SKU
;
if
(
marketPre
!=
null
&&
!
marketPre
.
equals
(
"null"
))
{
rk
=
rk
.
concat
(
marketPre
+
":"
);
}
rk
=
rk
.
concat
(
skuId
);
Object
obj
=
redisUtil
.
get
(
rk
);
if
(
obj
==
null
)
{
return
0
;
}
else
{
return
(
int
)
obj
;
}
}
}
liquidnet-bus-service/liquidnet-service-kylin/liquidnet-service-kylin-impl/src/main/java/com/liquidnet/service/kylin/utils/ObjectUtil.java
View file @
75cd17ba
...
...
@@ -4,6 +4,7 @@ import com.liquidnet.service.adam.dto.vo.AdamEntersVo;
import
com.liquidnet.service.base.PagedResult
;
import
com.liquidnet.service.goblin.dto.vo.*
;
import
com.liquidnet.service.kylin.dto.vo.KylinApiCameraDevicesVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinRecommendActiveRelationVo
;
import
com.liquidnet.service.kylin.dto.vo.admin.OrderRefundPoundage
;
import
com.liquidnet.service.kylin.dto.vo.middle.KylinTicketTimesVo
;
import
com.liquidnet.service.kylin.dto.vo.middle.KylinTicketVo
;
...
...
@@ -12,6 +13,7 @@ import com.liquidnet.service.kylin.dto.vo.mongo.KylinPerformanceVo;
import
com.liquidnet.service.kylin.dto.vo.returns.*
;
import
com.liquidnet.service.kylin.entity.KylinBanners
;
import
com.liquidnet.service.kylin.entity.KylinOrderCoupons
;
import
com.liquidnet.service.kylin.entity.KylinRecommendActiveRelation
;
import
com.mongodb.client.model.WriteModel
;
import
org.bson.Document
;
...
...
@@ -35,18 +37,25 @@ public class ObjectUtil {
private
static
final
ArrayList
<
KylinOrderCoupons
>
kylinOrderCouponsArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
KylinApiCameraDevicesVo
>
kylinApiCameraDevicesVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
KylinCandyVo
>
kylinCandyVos
=
new
ArrayList
<>();
/*正在热卖*/
private
static
final
ArrayList
<
GoblinListCollectVo
>
goblinListCollectVo
=
new
ArrayList
<>();
private
static
final
ArrayList
<
KylinRecommendActiveRelationVo
>
kylinRecommendActiveRelationVos
=
new
ArrayList
<>();
private
static
final
ArrayList
<
KylinRecommendActiveRelation
>
kylinRecommendActiveRelationList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
NoticeGoblinGoodsSkuInfoVo
>
noticeGoblinGoodsSkuInfoVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
NoticeGoblinMixDetailsVo
>
noticeGoblinMixDetailsVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinMixDetailsVo
>
goblinMixDetailsVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinGoodsSkuInfoVo
>
goblinGoodsSkuInfoVoArrayList
=
new
ArrayList
<>();
public
static
ArrayList
<
KylinRecommendActiveRelation
>
getKylinRecommendActiveRelation
()
{
return
(
ArrayList
<
KylinRecommendActiveRelation
>)
kylinRecommendActiveRelationList
.
clone
();
}
public
static
ArrayList
<
KylinCandyVo
>
kylinCandyVos
()
{
return
(
ArrayList
<
KylinCandyVo
>)
kylinCandyVos
.
clone
();
}
public
static
ArrayList
<
KylinRecommendActiveRelationVo
>
getKylinRecommendActiveRelationVo
(){
return
(
ArrayList
<
KylinRecommendActiveRelationVo
>)
kylinRecommendActiveRelationVos
.
clone
();
}
public
static
ArrayList
<
KylinStationPerformanceVo
>
getKylinStationPerformanceVoArrayList
()
{
return
(
ArrayList
<
KylinStationPerformanceVo
>)
kylinStationPerformanceVoArrayList
.
clone
();
}
...
...
@@ -127,6 +136,8 @@ public class ObjectUtil {
return
(
ArrayList
<
KylinApiCameraDevicesVo
>)
kylinApiCameraDevicesVoArrayList
.
clone
();
}
/* kylinRecommendActiveRelationVos*/
/*正在热卖*/
public
static
ArrayList
<
GoblinListCollectVo
>
getGoblinListCollectVo
()
{
...
...
liquidnet-bus-service/liquidnet-service-order/liquidnet-service-order-impl/src/main/java/com/liquidnet/service/order/controller/GoblinNftOrderController.java
View file @
75cd17ba
...
...
@@ -3,6 +3,7 @@ package com.liquidnet.service.order.controller;
import
com.liquidnet.commons.lang.constant.LnsRegex
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.base.codec.vo.EncryptedReq
;
import
com.liquidnet.service.goblin.dto.vo.GoblinNftCheckVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinNftPayResultVo
;
import
com.liquidnet.service.goblin.param.GoblinNftOrderPayAgainParam
;
import
com.liquidnet.service.goblin.param.GoblinNftOrderPayCallbackParam
;
...
...
@@ -58,6 +59,16 @@ public class GoblinNftOrderController {
return
iGoblinNftOrderService
.
checkOrderResult
(
orderId
);
}
@PostMapping
(
"checkPayment2"
)
@ApiOperation
(
"查询订单状态2"
)
@ApiResponse
(
code
=
200
,
message
=
"接口返回对象参数"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"orderId"
,
value
=
"订单ID"
,
example
=
"1"
),
})
public
ResponseDto
<
GoblinNftCheckVo
>
checkOrderResult2
(
@RequestParam
(
"orderId"
)
@NotBlank
(
message
=
"订单ID不能为空"
)
String
orderId
)
{
return
iGoblinNftOrderService
.
checkOrderResult2
(
orderId
);
}
@PostMapping
(
"syncOrder"
)
@ApiOperation
(
"支付回调"
)
@ApiResponse
(
code
=
200
,
message
=
"接口返回对象参数"
)
...
...
liquidnet-bus-service/liquidnet-service-order/liquidnet-service-order-impl/src/main/java/com/liquidnet/service/order/controller/GoblinOrderController.java
View file @
75cd17ba
...
...
@@ -4,6 +4,7 @@ import com.liquidnet.commons.lang.util.CurrentUtil;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.base.codec.vo.EncryptedReq
;
import
com.liquidnet.service.goblin.dto.manage.GoblinOrderParam
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsCheckVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinPayInnerResultVo
;
import
com.liquidnet.service.goblin.param.PayAgainParam
;
import
com.liquidnet.service.goblin.param.RefundCallbackParam
;
...
...
@@ -88,6 +89,16 @@ public class GoblinOrderController {
return
goblinAppOrderService
.
checkOrderResultMaterCode
(
masterCode
);
}
@PostMapping
(
"checkPaymentMaster2"
)
@ApiOperation
(
"订单状态[主订单号]2"
)
@ApiResponse
(
code
=
200
,
message
=
"接口返回对象参数"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"masterCode"
,
value
=
"masterCode"
,
example
=
"1"
),
})
public
ResponseDto
<
GoblinGoodsCheckVo
>
checkOrderResultMasterCode2
(
@RequestParam
(
"masterCode"
)
@Valid
String
masterCode
)
{
return
goblinAppOrderService
.
checkOrderResultMaterCode2
(
masterCode
);
}
@PostMapping
(
"zhengzai/fc7bce6d6c2213b866f76493f92224b7"
)
@ApiOperation
(
"正在下单-下单"
)
...
...
liquidnet-bus-service/liquidnet-service-order/liquidnet-service-order-impl/src/main/java/com/liquidnet/service/order/controller/KylinOrderTicketsController.java
View file @
75cd17ba
...
...
@@ -81,14 +81,7 @@ public class KylinOrderTicketsController {
@GetMapping
(
"checkPayment"
)
@ApiOperation
(
"订单状态"
)
@ApiResponse
(
code
=
200
,
message
=
"接口返回对象参数"
)
public
ResponseDto
<
HashMap
>
checkOrderResult
(
@RequestParam
(
"orderId"
)
@NotNull
(
message
=
"订单ID不能为空"
)
String
orderId
)
{
Integer
status
=
orderTicketsOrderService
.
checkOrderResult
(
orderId
).
getData
();
if
(
null
==
status
)
{
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20003"
));
}
else
{
HashMap
<
String
,
Integer
>
map
=
ObjectUtil
.
cloneHashMapStringAndInteger
();
map
.
put
(
"status"
,
status
);
return
ResponseDto
.
success
(
map
);
}
public
ResponseDto
<
HashMap
<
String
,
Object
>>
checkOrderResult
(
@RequestParam
(
"orderId"
)
@NotNull
(
message
=
"订单ID不能为空"
)
String
orderId
)
{
return
orderTicketsOrderService
.
checkOrderResult
(
orderId
);
}
}
liquidnet-bus-service/liquidnet-service-order/liquidnet-service-order-impl/src/main/java/com/liquidnet/service/order/controller/MixOrderController.java
View file @
75cd17ba
...
...
@@ -5,6 +5,7 @@ import com.liquidnet.service.base.ResponseDto;
import
com.liquidnet.service.base.codec.vo.EncryptedReq
;
import
com.liquidnet.service.goblin.dto.manage.GoblinOrderParam
;
import
com.liquidnet.service.goblin.dto.manage.MixOrderParam
;
import
com.liquidnet.service.goblin.dto.vo.GoblinMixCheckVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinPayInnerResultVo
;
import
com.liquidnet.service.goblin.param.PayAgainParam
;
import
com.liquidnet.service.goblin.param.RefundCallbackParam
;
...
...
@@ -77,4 +78,13 @@ public class MixOrderController {
}
@PostMapping
(
"checkPaymentMaster2"
)
@ApiOperation
(
"订单状态[主订单号]2"
)
@ApiResponse
(
code
=
200
,
message
=
"接口返回对象参数"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"form"
,
required
=
true
,
dataType
=
"String"
,
name
=
"masterCode"
,
value
=
"masterCode"
,
example
=
"1"
),
})
public
ResponseDto
<
GoblinMixCheckVo
>
checkOrderResultMasterCode2
(
@RequestParam
(
"masterCode"
)
@Valid
String
masterCode
)
{
return
mixOrderService
.
checkOrderResultMaterCode2
(
masterCode
);
}
}
liquidnet-bus-service/liquidnet-service-order/liquidnet-service-order-impl/src/main/java/com/liquidnet/service/order/service/impl/GoblinNftOrderServiceImpl.java
View file @
75cd17ba
...
...
@@ -677,6 +677,29 @@ public class GoblinNftOrderServiceImpl implements IGoblinNftOrderService {
}
}
@Override
public
ResponseDto
<
GoblinNftCheckVo
>
checkOrderResult2
(
String
orderId
)
{
String
uid
=
CurrentUtil
.
getCurrentUid
();
GoblinNftCheckVo
vo
=
GoblinNftCheckVo
.
getNew
();
GoblinNftOrderVo
nftOrder
=
nftOrderUtils
.
getNftOrder
(
orderId
);
if
(
null
==
nftOrder
||
!
nftOrder
.
getUserId
().
equals
(
uid
))
{
return
ResponseDto
.
failure
(
"订单不存在"
);
}
else
{
vo
.
setSkuId
(
nftOrder
.
getSkuId
());
DragonPayOrderQueryRespDto
respDto
=
dragonOrdersService
.
checkOrderStatusByCode
(
nftOrder
.
getPayCode
());
if
(
respDto
.
getStatus
()
==
1
)
{
//处理订单
GoblinNftOrderPayCallbackParam
goblinNftOrderPayCallbackParam
=
GoblinNftOrderPayCallbackParam
.
getNew
().
copy
(
respDto
);
syncOrder
(
goblinNftOrderPayCallbackParam
);
vo
.
setStatus
(
1
);
return
ResponseDto
.
success
(
vo
);
}
else
{
vo
.
setStatus
(
0
);
return
ResponseDto
.
success
(
vo
);
}
}
}
@Override
public
String
syncOrder
(
GoblinNftOrderPayCallbackParam
syncOrderParam
)
{
log
.
info
(
"NFT支付回调 参数: "
+
syncOrderParam
.
toString
());
...
...
liquidnet-bus-service/liquidnet-service-order/liquidnet-service-order-impl/src/main/java/com/liquidnet/service/order/service/impl/GoblinOrderServiceImpl.java
View file @
75cd17ba
...
...
@@ -579,7 +579,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
sqlDataOrder
.
add
(
new
Object
[]{
storeOrder
.
getMasterOrderCode
(),
storeOrder
.
getOrderId
(),
storeOrder
.
getStoreId
(),
storeOrder
.
getStoreName
(),
storeOrder
.
getOrderCode
(),
storeOrder
.
getUserId
(),
storeOrder
.
getUserName
(),
storeOrder
.
getUserMobile
(),
storeOrder
.
getPriceTotal
(),
storeOrder
.
getPayCode
(),
storeOrder
.
getPriceActual
(),
storeOrder
.
getPriceRefund
(),
storeOrder
.
getPriceExpress
(),
storeOrder
.
getPriceCoupon
(),
storeOrder
.
getStorePriceCoupon
(),
storeOrder
.
getPriceVoucher
(),
storeOrder
.
getStatus
(),
storeOrder
.
getUcouponId
(),
storeOrder
.
getStoreCouponId
(),
storeOrder
.
getPayType
(),
storeOrder
.
getDeviceFrom
(),
storeOrder
.
getSource
(),
storeOrder
.
getVersion
(),
storeOrder
.
getIsMember
(),
storeOrder
.
getOrderType
(),
storeOrder
.
getWriteOffCode
(),
storeOrder
.
getPayCountdownMinute
(),
storeOrder
.
getIpAddress
(),
storeOrder
.
getMarketId
(),
storeOrder
.
getMarketType
(),
storeOrder
.
getCreatedAt
(),
""
,
""
storeOrder
.
getSource
(),
storeOrder
.
getVersion
(),
storeOrder
.
getIsMember
(),
storeOrder
.
getOrderType
(),
storeOrder
.
getWriteOffCode
(),
storeOrder
.
getPayCountdownMinute
(),
storeOrder
.
getIpAddress
(),
storeOrder
.
getMarketId
(),
storeOrder
.
getMarketType
(),
storeOrder
.
getCreatedAt
(),
""
,
""
});
GoblinOrderAttr
orderAttr
=
item
.
getOrderAttr
();
sqlDataAttr
.
add
(
new
Object
[]{
...
...
@@ -806,7 +806,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
storeOrder
.
setUpdatedAt
(
now
);
sqls
.
add
(
SqlMapping
.
get
(
"goblin_order.pay.order"
));
sqlDataOrder
.
add
(
new
Object
[]{
storeOrder
.
getPaymentType
(),
storeOrder
.
getPaymentId
(),
storeOrder
.
getPayCode
(),
storeOrder
.
getPayTime
(),
storeOrder
.
getWriteOffCode
(),
storeOrder
.
getZhengzaiStatus
(),
storeOrder
.
getStatus
(),
storeOrder
.
getUpdatedAt
(),
storeOrder
.
getPushTime
(),
storeOrder
.
getPaymentType
(),
storeOrder
.
getPaymentId
(),
storeOrder
.
getPayCode
(),
storeOrder
.
getPayTime
(),
storeOrder
.
getWriteOffCode
(),
storeOrder
.
getZhengzaiStatus
(),
storeOrder
.
getStatus
(),
storeOrder
.
getUpdatedAt
(),
storeOrder
.
getPushTime
(),
orderId
,
now
,
now
});
sqls
.
add
(
SqlMapping
.
get
(
"goblin_order.pay.sku"
));
...
...
@@ -848,7 +848,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
mongoUtils
.
insertGoblinOrderLogVo
(
logVo
);
//mysql
sqlDataSku
.
add
(
new
Object
[]{
orderSkuVo
.
getStatus
(),
now
,
orderSkuVo
.
getStatus
()==
4
?
now:
null
,
orderSkuVo
.
getStatus
(),
now
,
orderSkuVo
.
getStatus
()
==
4
?
now
:
null
,
orderSkuVo
.
getOrderSkuId
(),
now
,
now
});
}
...
...
@@ -958,6 +958,48 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
}
}
@Override
public
ResponseDto
<
GoblinGoodsCheckVo
>
checkOrderResultMaterCode2
(
String
masterCode
)
{
String
[]
orderIds
=
redisUtils
.
getMasterCode
(
masterCode
);
GoblinGoodsCheckVo
vo
=
GoblinGoodsCheckVo
.
getNew
();
if
(
orderIds
==
null
)
{
return
ResponseDto
.
failure
(
"订单不存在"
);
}
else
{
for
(
String
orderId
:
orderIds
)
{
GoblinStoreOrderVo
storeOrderVo
=
redisUtils
.
getGoblinOrder
(
orderId
);
List
<
String
>
list
=
CollectionUtil
.
linkedListString
();
for
(
String
orderSkuId
:
storeOrderVo
.
getOrderSkuVoIds
())
{
list
.
add
(
redisUtils
.
getGoblinOrderSkuVo
(
orderSkuId
).
getSpuId
());
}
vo
.
setSpuId
(
list
);
DragonPayOrderQueryRespDto
data
=
dragonOrdersService
.
checkOrderStatusByCode
(
storeOrderVo
.
getPayCode
());
SyncOrderParam
syncOrderDtoParam
=
SyncOrderParam
.
getNew
();
syncOrderDtoParam
.
setCode
(
data
.
getCode
());
syncOrderDtoParam
.
setOrderCode
(
data
.
getOrderCode
());
syncOrderDtoParam
.
setOrderCodeId
(
data
.
getOrderCodeId
());
syncOrderDtoParam
.
setOrderId
(
data
.
getOrderCodeId
());
syncOrderDtoParam
.
setPaymentAt
(
data
.
getPaymentAt
());
syncOrderDtoParam
.
setPaymentId
(
data
.
getPaymentId
());
syncOrderDtoParam
.
setPaymentType
(
data
.
getPaymentType
());
syncOrderDtoParam
.
setPrice
(
data
.
getPrice
());
syncOrderDtoParam
.
setStatus
(
data
.
getStatus
());
syncOrderDtoParam
.
setType
(
data
.
getType
());
if
(
syncOrderDtoParam
.
getStatus
()
==
1
)
{
//处理订单
syncOrder
(
syncOrderDtoParam
);
vo
.
setStatus
(
1
);
return
ResponseDto
.
success
(
vo
);
}
else
{
vo
.
setStatus
(
0
);
return
ResponseDto
.
success
(
vo
);
}
}
vo
.
setSpuId
(
CollectionUtil
.
linkedListString
());
vo
.
setStatus
(
1
);
return
ResponseDto
.
success
(
vo
);
}
}
@Override
public
String
refundSyncOrder
(
RefundCallbackParam
refundCallbackParam
)
{
LocalDateTime
now
=
LocalDateTime
.
now
();
...
...
@@ -1134,7 +1176,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
storeOrder
.
setPushTime
(
now
);
sqls
.
add
(
SqlMapping
.
get
(
"goblin_order.pay.order"
));
sqlDataOrder
.
add
(
new
Object
[]{
storeOrder
.
getPaymentType
(),
storeOrder
.
getPaymentId
(),
storeOrder
.
getPayCode
(),
storeOrder
.
getPayTime
(),
storeOrder
.
getWriteOffCode
(),
storeOrder
.
getZhengzaiStatus
(),
storeOrder
.
getStatus
(),
storeOrder
.
getUpdatedAt
(),
storeOrder
.
getPushTime
(),
storeOrder
.
getPaymentType
(),
storeOrder
.
getPaymentId
(),
storeOrder
.
getPayCode
(),
storeOrder
.
getPayTime
(),
storeOrder
.
getWriteOffCode
(),
storeOrder
.
getZhengzaiStatus
(),
storeOrder
.
getStatus
(),
storeOrder
.
getUpdatedAt
(),
storeOrder
.
getPushTime
(),
orderId
,
now
,
now
});
sqls
.
add
(
SqlMapping
.
get
(
"goblin_order.pay.sku"
));
...
...
@@ -1171,7 +1213,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
mongoUtils
.
insertGoblinOrderLogVo
(
logVo
);
//mysql
sqlDataSku
.
add
(
new
Object
[]{
orderSkuVo
.
getStatus
(),
now
,
now
,
orderSkuVo
.
getStatus
(),
now
,
now
,
orderSkuVo
.
getOrderSkuId
(),
now
,
now
});
}
...
...
liquidnet-bus-service/liquidnet-service-order/liquidnet-service-order-impl/src/main/java/com/liquidnet/service/order/service/impl/KylinOrderTicketsServiceImpl.java
View file @
75cd17ba
...
...
@@ -1094,14 +1094,14 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsOrderServ
}
@Override
public
ResponseDto
<
Integer
>
checkOrderResult
(
String
orderId
)
{
public
ResponseDto
<
HashMap
<
String
,
Object
>
>
checkOrderResult
(
String
orderId
)
{
String
uid
=
CurrentUtil
.
getCurrentUid
();
KylinOrderTicketVo
orderTicketData
=
dataUtils
.
getOrderTicketVo
(
orderId
);
if
(
orderTicketData
==
null
)
{
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20024"
));
}
else
{
if
(!
orderTicketData
.
getUserId
().
equals
(
uid
))
{
return
null
;
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20003"
))
;
}
DragonPayOrderQueryRespDto
data
=
dragonOrdersService
.
checkOrderStatusByCode
(
orderTicketData
.
getPayCode
());
SyncOrderParam
syncOrderDtoParam
=
SyncOrderParam
.
getNew
();
...
...
@@ -1113,13 +1113,16 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsOrderServ
syncOrderDtoParam
.
setPrice
(
data
.
getPrice
());
syncOrderDtoParam
.
setStatus
(
data
.
getStatus
());
syncOrderDtoParam
.
setType
(
data
.
getType
());
HashMap
<
String
,
Object
>
map
=
CollectionUtil
.
mapStringObject
();
map
.
put
(
"performanceId"
,
orderTicketData
.
getPerformanceId
());
if
(
syncOrderDtoParam
.
getStatus
()
==
1
)
{
//处理订单
syncOrder
(
syncOrderDtoParam
);
return
ResponseDto
.
success
(
1
);
map
.
put
(
"status"
,
1
);
}
else
{
return
ResponseDto
.
success
(
0
);
map
.
put
(
"status"
,
0
);
}
return
ResponseDto
.
success
(
map
);
}
}
...
...
liquidnet-bus-service/liquidnet-service-order/liquidnet-service-order-impl/src/main/java/com/liquidnet/service/order/service/impl/MixOrderServiceImpl.java
View file @
75cd17ba
...
...
@@ -800,6 +800,48 @@ public class MixOrderServiceImpl implements IMixOrderService {
return
ResponseDto
.
success
(
1
);
}
@Override
public
ResponseDto
<
GoblinMixCheckVo
>
checkOrderResultMaterCode2
(
String
materCode
)
{
String
uid
=
CurrentUtil
.
getCurrentUid
();
GoblinMixCheckVo
vo
=
GoblinMixCheckVo
.
getNew
();
HashMap
<
String
,
String
[]>
map
=
redisUtils
.
getMixMasterCode
(
materCode
);
String
[]
nft
=
map
.
get
(
"nft"
);
String
[]
goblin
=
map
.
get
(
"goblin"
);
for
(
String
orderId
:
nft
)
{
if
(
""
.
equals
(
orderId
))
{
break
;
}
String
nftR
=
nftCheck
(
uid
,
orderId
);
if
(
vo
.
getMixId
()==
null
){
vo
.
setMixId
(
nftOrderUtils
.
getNftOrder
(
orderId
).
getMixId
());
}
if
(
"订单不存在"
.
equals
(
nftR
))
{
return
ResponseDto
.
failure
(
"订单不存在"
);
}
else
if
(
"0"
.
equals
(
nftR
))
{
vo
.
setStatus
(
0
);
return
ResponseDto
.
success
(
vo
);
}
}
for
(
String
orderId
:
goblin
)
{
if
(
""
.
equals
(
orderId
))
{
break
;
}
String
goblinR
=
goblinCheck
(
uid
,
orderId
);
if
(
vo
.
getMixId
()==
null
){
vo
.
setMixId
(
redisUtils
.
getGoblinOrder
(
orderId
).
getMixId
());
}
if
(
"订单不存在"
.
equals
(
goblinR
))
{
return
ResponseDto
.
failure
(
"订单不存在"
);
}
else
if
(
"0"
.
equals
(
goblinR
))
{
vo
.
setStatus
(
0
);
return
ResponseDto
.
success
(
vo
);
}
}
vo
.
setStatus
(
1
);
return
ResponseDto
.
success
(
vo
);
}
private
String
nftCheck
(
String
uid
,
String
orderId
)
{
GoblinNftOrderVo
nftOrder
=
nftOrderUtils
.
getNftOrder
(
orderId
);
...
...
liquidnet-bus-service/liquidnet-service-sweet/docu/db_five_structure.sql
0 → 100644
View file @
75cd17ba
create
database
if
not
exists
ln_scene
character
set
utf8mb4
collate
utf8mb4_unicode_ci
;
-- >>------------------------------------------------------------------------------------
use
ln_scene
;
-- 电子宣传手册表
drop
TABLE
if
exists
`sweet_manual_five`
;
CREATE
TABLE
`sweet_manual_five`
(
`mid`
bigint
unsigned
NOT
NULL
AUTO_INCREMENT
,
`manual_id`
varchar
(
200
)
NOT
NULL
DEFAULT
'0'
COMMENT
'manual_id'
,
`performance_id`
varchar
(
200
)
NULL
COMMENT
'演出id'
,
`status`
tinyint
NOT
NULL
DEFAULT
1
COMMENT
'0关闭 1开启'
,
`is_release`
tinyint
NOT
NULL
DEFAULT
1
COMMENT
'0取消 1发布'
,
`created_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建时间'
,
`updated_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'更新时间'
,
PRIMARY
KEY
(
`mid`
),
KEY
`manual_id_index`
(
`manual_id`
),
KEY
`performance_id_index`
(
`performance_id`
),
KEY
`is_release_index`
(
`is_release`
),
KEY
`status_index`
(
`status`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8
COLLATE
=
utf8_unicode_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
'电子宣传手册表'
;
-- 电子宣传手册显示内容表
drop
TABLE
if
exists
`sweet_manual_sort_five`
;
CREATE
TABLE
`sweet_manual_sort_five`
(
`mid`
bigint
unsigned
NOT
NULL
AUTO_INCREMENT
,
`manual_id`
varchar
(
200
)
NOT
NULL
DEFAULT
'0'
COMMENT
'manual_id'
,
`show_position`
varchar
(
200
)
NULL
COMMENT
'显示哪个,号隔开'
,
`created_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建时间'
,
`updated_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'更新时间'
,
PRIMARY
KEY
(
`mid`
),
KEY
`manual_id_index`
(
`manual_id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8
COLLATE
=
utf8_unicode_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
'电子宣传手册显示内容表'
;
-- 电子宣传手册富文本表
drop
TABLE
if
exists
`sweet_richtext_five`
;
CREATE
TABLE
`sweet_richtext_five`
(
`mid`
bigint
unsigned
NOT
NULL
AUTO_INCREMENT
,
`richtext_id`
varchar
(
200
)
NOT
NULL
DEFAULT
'0'
COMMENT
'order_refund_id'
,
`manual_id`
varchar
(
200
)
NOT
NULL
DEFAULT
'0'
COMMENT
'manual_id'
,
`details`
longtext
NULL
COMMENT
'富文本详情'
,
`local`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'经纬度 5需要'
,
`pic_url`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'地图图片地址 2需要'
,
`type`
tinyint
NOT
NULL
DEFAULT
0
COMMENT
'类型 1签售时间 2现场地图 3官方大巴 4公共交通 5自驾导航坐标 6官方支持 7观众须知 8防疫指南 9观演攻略'
,
`status`
tinyint
NOT
NULL
DEFAULT
1
COMMENT
'0关闭 1开启'
,
`created_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建时间'
,
`updated_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'更新时间'
,
PRIMARY
KEY
(
`mid`
),
KEY
`richtext_id_index`
(
`richtext_id`
),
KEY
`manual_id_index`
(
`manual_id`
),
KEY
`type_index`
(
`type`
),
KEY
`status_index`
(
`status`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8
COLLATE
=
utf8_unicode_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
'电子宣传手册富文本表'
;
-- 电子宣传手册艺人表
drop
TABLE
if
exists
`sweet_manual_artists_five`
;
CREATE
TABLE
`sweet_manual_artists_five`
(
`mid`
bigint
unsigned
NOT
NULL
AUTO_INCREMENT
,
`manual_relation_id`
varchar
(
200
)
NOT
NULL
DEFAULT
'0'
COMMENT
'manual_relation_id'
,
`manual_id`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'电子宣传手册id'
,
`stage_id`
varchar
(
200
)
NULL
COMMENT
'关联id'
,
`artists_id`
varchar
(
200
)
NULL
COMMENT
'关联id'
,
`performance_start`
datetime
NULL
COMMENT
'演出开始时间'
,
`performance_end`
datetime
NULL
COMMENT
'演出结束时间'
,
`signature_start`
datetime
NULL
COMMENT
'签收开始时间'
,
`signature_end`
datetime
NULL
COMMENT
'签收结束时间'
,
`status`
tinyint
NOT
NULL
DEFAULT
1
COMMENT
'0关闭 1开启'
,
`created_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建时间'
,
`updated_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'更新时间'
,
PRIMARY
KEY
(
`mid`
),
KEY
`manual_relation_id_index`
(
`manual_relation_id`
),
KEY
`manual_id_index`
(
`manual_id`
),
KEY
`stage_id_index`
(
`stage_id`
),
KEY
`artists_id_index`
(
`artists_id`
),
KEY
`status_index`
(
`status`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8
COLLATE
=
utf8_unicode_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
'电子宣传手册艺人表'
;
-- 电子宣传手册通知表
drop
TABLE
if
exists
`sweet_manual_notify_five`
;
CREATE
TABLE
`sweet_manual_notify_five`
(
`mid`
bigint
unsigned
NOT
NULL
AUTO_INCREMENT
,
`manual_notify_id`
varchar
(
200
)
NOT
NULL
DEFAULT
'0'
COMMENT
'manual_notify_id'
,
`manual_id`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'电子宣传手册id'
,
`title`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'标题'
,
`content`
longtext
NULL
COMMENT
'内容'
,
`status`
tinyint
NOT
NULL
DEFAULT
1
COMMENT
'0关闭 1开启'
,
`created_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建时间'
,
`updated_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'更新时间'
,
PRIMARY
KEY
(
`mid`
),
KEY
`manual_notify_id_index`
(
`manual_notify_id`
),
KEY
`manual_id_index`
(
`manual_id`
),
KEY
`status_index`
(
`status`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8
COLLATE
=
utf8_unicode_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
'电子宣传手册通知表'
;
-- 电子宣传手册商铺表
drop
TABLE
if
exists
`sweet_manual_shop_five`
;
CREATE
TABLE
`sweet_manual_shop_five`
(
`mid`
bigint
unsigned
NOT
NULL
AUTO_INCREMENT
,
`manual_shop_id`
varchar
(
200
)
NOT
NULL
DEFAULT
'0'
COMMENT
'manual_shop_id'
,
`manual_id`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'电子宣传手册id'
,
`title`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'商家名称'
,
`pic_url`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'商家图片'
,
`describes`
longtext
NULL
COMMENT
'商家介绍'
,
`type`
tinyint
NOT
NULL
DEFAULT
1
COMMENT
'1吃喝 2玩乐'
,
`is_recommend`
tinyint
NOT
NULL
DEFAULT
1
COMMENT
'0不推荐 1推荐'
,
`sort`
tinyint
NOT
NULL
DEFAULT
0
COMMENT
'排序字段 数字越大越靠前'
,
`status`
tinyint
NOT
NULL
DEFAULT
1
COMMENT
'0关闭 1开启'
,
`created_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建时间'
,
`updated_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'更新时间'
,
PRIMARY
KEY
(
`mid`
),
KEY
`manual_shop_index`
(
`manual_shop_id`
),
KEY
`manual_id_index`
(
`manual_id`
),
KEY
`status_index`
(
`status`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8
COLLATE
=
utf8_unicode_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
'电子宣传手册商铺表'
;
-- 正在现场服务号关注事件储存用户信息表
drop
TABLE
if
exists
`sweet_wechat_user_five`
;
CREATE
TABLE
`sweet_wechat_user_five`
(
`mid`
bigint
unsigned
NOT
NULL
AUTO_INCREMENT
,
`user_id`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'user_id'
,
`openId`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'openId'
,
`unionId`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'unionId'
,
`nickname`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'昵称'
,
`sexDesc`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'性别'
,
`sex`
tinyint
NOT
NULL
DEFAULT
0
COMMENT
'性别 男1'
,
`headImgUrl`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'头像'
,
`language`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'zh_CN'
,
`country`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'国家'
,
`province`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'省'
,
`city`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'市'
,
`subscribeTime`
datetime
NULL
DEFAULT
null
COMMENT
'关注时间'
,
`subscribeScene`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'ADD_SCENE_SEARCH 关注方式'
,
`created_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建时间'
,
`updated_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'更新时间'
,
PRIMARY
KEY
(
`mid`
),
KEY
`sweet_wechat_user_user_id`
(
`user_id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
utf8mb4
COLLATE
utf8mb4_unicode_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
'正在现场服务号关注事件储存用户信息表'
;
-- 用户 收藏/喜欢等状态
drop
TABLE
if
exists
`sweet_user_relation_five`
;
CREATE
TABLE
`sweet_user_relation_five`
(
`mid`
bigint
unsigned
NOT
NULL
AUTO_INCREMENT
,
`user_id`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'用户id'
,
`type`
tinyint
NOT
NULL
DEFAULT
0
COMMENT
'类型 1喜欢艺人 2签售艺人'
,
`target_id`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'目标id'
,
`manual_id`
varchar
(
200
)
NOT
NULL
DEFAULT
''
COMMENT
'电子手册'
,
`status`
tinyint
NOT
NULL
DEFAULT
0
COMMENT
'1是 0否'
,
`created_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建时间'
,
`updated_at`
datetime
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'更新时间'
,
PRIMARY
KEY
(
`mid`
),
KEY
`sweet_wechat_user_user_id`
(
`user_id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
utf8mb4
COLLATE
utf8mb4_unicode_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
'用户 收藏/喜欢等状态'
;
\ No newline at end of file
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/controller/five/SweetAppletFiveController.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
controller
.
five
;
import
com.liquidnet.commons.lang.util.CollectionUtil
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.dto.*
;
import
com.liquidnet.service.sweet.entity.*
;
import
com.liquidnet.service.sweet.utils.ObjectUtil
;
import
com.liquidnet.service.sweet.utils.RedisFiveDataUtils
;
import
com.liquidnet.service.sweet.utils.RedisMDSKDataUtils
;
import
com.liquidnet.service.sweet.vo.SweetArtistsRelationVo
;
import
com.liquidnet.service.sweet.vo.SweetManualShopFiveAllVo
;
import
com.liquidnet.service.sweet.vo.SweetManualShopMdskAllVo
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiImplicitParam
;
import
io.swagger.annotations.ApiImplicitParams
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
@Api
(
tags
=
"小程序_five"
)
@RestController
@RequestMapping
(
"/five/sweet-applet"
)
public
class
SweetAppletFiveController
{
@Autowired
private
RedisFiveDataUtils
redisDataUtils
;
@GetMapping
(
"timeSelect"
)
@ApiOperation
(
"场次选择"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"name"
,
value
=
"名称"
,
required
=
true
),
})
public
ResponseDto
<
List
<
SweetManualAppletFiveDto
>>
timeSelect
(
@RequestParam
String
name
)
{
List
<
SweetManualAppletFiveDto
>
dto
=
redisDataUtils
.
getPushList
();
List
<
SweetManualAppletFiveDto
>
vo
=
ObjectUtil
.
getSweetManualAppletFiveDtoList
();
for
(
SweetManualAppletFiveDto
item
:
dto
)
{
if
(
item
.
getTitle
().
contains
(
name
)
||
item
.
getTitle
().
contains
(
"M_DSK"
))
{
vo
.
add
(
item
);
}
}
return
ResponseDto
.
success
(
vo
);
}
@GetMapping
(
"details"
)
@ApiOperation
(
"详情"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"电子手册id"
,
required
=
true
),
})
public
ResponseDto
<
SweetManualAppletFiveDto
>
details
(
@RequestParam
()
String
manualId
)
{
return
ResponseDto
.
success
(
redisDataUtils
.
getAppletPerformance
(
manualId
));
}
@GetMapping
(
"notify"
)
@ApiOperation
(
"通知"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"电子手册id"
,
required
=
true
),
})
public
ResponseDto
<
List
<
SweetManualNotifyFive
>>
notify
(
@RequestParam
()
String
manualId
)
{
return
ResponseDto
.
success
(
redisDataUtils
.
getNotifyRedisData
(
manualId
));
}
@GetMapping
(
"tags"
)
@ApiOperation
(
"标签"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"电子手册id"
,
required
=
true
),
})
public
ResponseDto
<
List
<
String
>>
tag
(
@RequestParam
()
String
manualId
)
{
return
ResponseDto
.
success
(
redisDataUtils
.
getTagRedisData
(
manualId
));
}
@GetMapping
(
"timeList"
)
@ApiOperation
(
"时间表"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"电子手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"dateTime"
,
value
=
"时间 全部不传"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"stage"
,
value
=
"舞台 全部不传"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"isSign"
,
value
=
"是否签名(1是0否)"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"page"
,
value
=
"页数"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"size"
,
value
=
"数量"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"uid"
,
value
=
"用户id"
,
required
=
true
),
})
public
ResponseDto
<
SweetManualArtistList2FiveDto
>
timeList
(
@RequestParam
String
manualId
,
@RequestParam
(
required
=
false
)
String
dateTime
,
@RequestParam
(
required
=
false
)
String
stage
,
@RequestParam
Integer
isSign
,
@RequestParam
(
required
=
false
)
Integer
page
,
@RequestParam
(
required
=
false
)
Integer
size
,
@RequestParam
String
uid
)
{
try
{
List
<
SweetManualArtistListFiveDto
>
allReturnArtist
=
ObjectUtil
.
getSweetManualArtistListFiveDtoList
();
List
<
SweetManualArtistListFiveDto
>
returnArtist
=
ObjectUtil
.
getSweetManualArtistListFiveDtoList
();
SweetManualArtistList2FiveDto
data
=
redisDataUtils
.
getTimeList
(
manualId
);
SweetArtistsRelationVo
relationData
=
redisDataUtils
.
getArtistsRelationRedisVo
(
uid
,
manualId
);
List
<
SweetManualArtistListFiveDto
>
artistData
=
data
.
getData
();
int
startPosition
=
0
;
int
endPosition
=
0
;
if
(
page
!=
null
)
{
startPosition
=
(
page
-
1
)
*
size
;
endPosition
=
(
page
)
*
size
;
}
if
(
page
==
null
&&
dateTime
==
null
)
{
try
{
dateTime
=
data
.
getDate
().
get
(
0
);
}
catch
(
Exception
e
)
{
}
}
for
(
SweetManualArtistListFiveDto
item
:
artistData
)
{
boolean
isSave
=
true
;
if
(
isSign
==
1
)
{
if
(
item
.
getSignatureStart
()
==
null
)
{
//不保留
isSave
=
false
;
}
}
if
(
dateTime
!=
null
)
{
if
(!
item
.
getPerformanceStart
().
contains
(
dateTime
))
{
//不保留
isSave
=
false
;
}
}
if
(
stage
!=
null
)
{
if
(!
item
.
getTitle
().
equalsIgnoreCase
(
stage
))
{
//保留
isSave
=
false
;
}
}
if
(
isSave
)
{
allReturnArtist
.
add
(
item
);
}
}
for
(
int
i
=
0
;
i
<
allReturnArtist
.
size
();
i
++)
{
SweetManualArtistListFiveDto
item
=
allReturnArtist
.
get
(
i
);
if
(
page
!=
null
&&
i
>=
startPosition
&&
i
<
endPosition
)
{
item
.
setIsWatch
(
0
);
item
.
setIsSign
(
0
);
if
(
relationData
.
getWatchList
()
!=
null
)
{
for
(
String
artistsId
:
relationData
.
getWatchList
())
{
if
(
artistsId
.
equalsIgnoreCase
(
item
.
getArtistId
()))
{
item
.
setIsWatch
(
1
);
break
;
}
}
}
if
(
relationData
.
getSignList
()
!=
null
)
{
for
(
String
artistsId
:
relationData
.
getSignList
())
{
if
(
artistsId
.
equalsIgnoreCase
(
item
.
getArtistId
()))
{
item
.
setIsSign
(
1
);
break
;
}
}
}
if
(
item
.
getTitle
().
contains
(
"&"
)){
item
.
setTitle
(
item
.
getTitle
().
split
(
"&"
)[
0
]);
}
returnArtist
.
add
(
item
);
}
}
data
.
getStage
().
forEach
(
t
->{
if
(
t
.
getTitle
().
contains
(
"&"
)){
t
.
setTitle
(
t
.
getTitle
().
split
(
"&"
)[
0
]);
}
});
data
.
setData
(
returnArtist
);
data
.
setTotal
(
allReturnArtist
.
size
());
return
ResponseDto
.
success
(
data
);
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@GetMapping
(
"richText"
)
@ApiOperation
(
"富文本"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"电子手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"type"
,
value
=
"类型 (1签售时间 2现场地图 3官方大巴 4公共交通 5自驾导航坐标 6官方支持 7观众须知 8防疫指南 9观演攻略)"
,
required
=
true
),
})
public
ResponseDto
<
SweetRichtextFive
>
richText
(
@RequestParam
()
String
manualId
,
@RequestParam
()
String
type
)
{
return
ResponseDto
.
success
(
redisDataUtils
.
getRichTextRedisData
(
manualId
,
type
));
}
@PostMapping
(
"artistsWatch"
)
@ApiOperation
(
"艺人-想看"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"uid"
,
value
=
"用户id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"artistsId"
,
value
=
"艺人id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
watch
(
@RequestParam
()
String
uid
,
@RequestParam
()
String
artistsId
,
@RequestParam
()
String
manualId
)
{
if
(
uid
.
equalsIgnoreCase
(
"0"
))
{
return
ResponseDto
.
failure
();
}
redisDataUtils
.
setArtistsRelationRedisVo
(
uid
,
artistsId
,
manualId
,
"watch"
);
return
ResponseDto
.
success
();
}
@PostMapping
(
"artistsSign"
)
@ApiOperation
(
"艺人-签售"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"uid"
,
value
=
"用户id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"artistsId"
,
value
=
"艺人id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
sign
(
@RequestParam
()
String
uid
,
@RequestParam
()
String
artistsId
,
@RequestParam
()
String
manualId
)
{
if
(
uid
.
equalsIgnoreCase
(
"0"
))
{
return
ResponseDto
.
failure
();
}
redisDataUtils
.
setArtistsRelationRedisVo
(
uid
,
artistsId
,
manualId
,
"sign"
);
return
ResponseDto
.
success
();
}
@PostMapping
(
"manualASC"
)
@ApiOperation
(
"该手册艺人收藏数"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"uid"
,
value
=
"用户id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
})
public
ResponseDto
<
Map
>
manualArtistsSaveCount
(
@RequestParam
()
String
uid
,
@RequestParam
()
String
manualId
)
{
if
(
uid
.
equalsIgnoreCase
(
"0"
))
{
return
ResponseDto
.
failure
();
}
SweetArtistsRelationVo
vo
=
redisDataUtils
.
getArtistsRelationRedisVo
(
uid
,
manualId
);
int
signSize
=
0
;
int
watchSize
=
0
;
if
(
vo
.
getSignList
()
!=
null
)
{
signSize
=
vo
.
getSignList
().
size
();
}
if
(
vo
.
getWatchList
()
!=
null
)
{
watchSize
=
vo
.
getWatchList
().
size
();
}
HashMap
<
String
,
Object
>
map
=
CollectionUtil
.
mapStringObject
();
map
.
put
(
"signSize"
,
signSize
);
map
.
put
(
"watchSize"
,
watchSize
);
return
ResponseDto
.
success
(
map
);
}
@GetMapping
(
"artistsDetails"
)
@ApiOperation
(
"艺人-详情"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"artistsId"
,
value
=
"艺人id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"uid"
,
value
=
"用户id"
,
required
=
true
)
})
public
ResponseDto
<
SweetManualArtistListFiveDto
>
artistsDetails
(
@RequestParam
String
artistsId
,
@RequestParam
String
manualId
,
@RequestParam
String
uid
)
{
SweetManualArtistList2FiveDto
data
=
redisDataUtils
.
getTimeList
(
manualId
);
List
<
SweetManualArtistListFiveDto
>
dataList
=
data
.
getData
();
SweetArtistsRelationVo
relationData
=
redisDataUtils
.
getArtistsRelationRedisVo
(
uid
,
manualId
);
SweetManualArtistListFiveDto
vo
=
SweetManualArtistListFiveDto
.
getNew
();
for
(
SweetManualArtistListFiveDto
item
:
dataList
)
{
if
(
item
.
getArtistId
().
equalsIgnoreCase
(
artistsId
))
{
item
.
setIsWatch
(
0
);
item
.
setIsSign
(
0
);
if
(
relationData
.
getWatchList
()
!=
null
)
{
for
(
String
artistsIds
:
relationData
.
getWatchList
())
{
if
(
artistsId
.
equalsIgnoreCase
(
artistsIds
))
{
item
.
setIsWatch
(
1
);
break
;
}
}
}
if
(
relationData
.
getSignList
()
!=
null
)
{
for
(
String
artistsIds
:
relationData
.
getSignList
())
{
if
(
artistsId
.
equalsIgnoreCase
(
artistsIds
))
{
item
.
setIsSign
(
1
);
break
;
}
}
}
if
(
item
.
getTitle
().
contains
(
"&"
)){
item
.
setTitle
(
item
.
getTitle
().
split
(
"&"
)[
0
]);
}
vo
=
item
;
break
;
}
}
return
ResponseDto
.
success
(
vo
);
}
@GetMapping
(
"manualShop"
)
@ApiOperation
(
"吃喝玩乐"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"uid"
,
value
=
"用户id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"artistsId"
,
value
=
"艺人id"
,
required
=
true
)
})
public
ResponseDto
<
SweetManualShopFiveAllVo
>
manualShop
(
@RequestParam
String
manualId
)
{
List
<
SweetManualShopFive
>
shopList
=
redisDataUtils
.
getManualShopRedisData
(
manualId
);
List
<
SweetManualShopFive
>
recommend
=
ObjectUtil
.
getSweetManualShopFiveList
();
List
<
SweetManualShopFive
>
eat
=
ObjectUtil
.
getSweetManualShopFiveList
();
List
<
SweetManualShopFive
>
play
=
ObjectUtil
.
getSweetManualShopFiveList
();
SweetManualShopFiveAllVo
vo
=
SweetManualShopFiveAllVo
.
getNew
();
for
(
SweetManualShopFive
item
:
shopList
)
{
if
(
item
.
getIsRecommend
().
equals
(
1
))
{
recommend
.
add
(
item
);
}
if
(
item
.
getType
().
equals
(
1
))
{
eat
.
add
(
item
);
}
if
(
item
.
getType
().
equals
(
2
))
{
play
.
add
(
item
);
}
}
vo
.
setRecommend
(
recommend
);
vo
.
setEat
(
eat
);
vo
.
setPlay
(
play
);
return
ResponseDto
.
success
(
vo
);
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/controller/five/SweetManualArtistsFiveController.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
controller
.
five
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistListFiveDto
;
import
com.liquidnet.service.sweet.service.five.ISweetManualArtistsFiveService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiImplicitParam
;
import
io.swagger.annotations.ApiImplicitParams
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
/**
* <p>
* 电子宣传手册艺人表 前端控制器
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Api
(
tags
=
"电子手册艺人_five"
)
@RestController
@RequestMapping
(
"/five/sweet-manual-artists"
)
public
class
SweetManualArtistsFiveController
{
@Autowired
private
ISweetManualArtistsFiveService
sweetManualArtistsFiveService
;
@GetMapping
(
"getList"
)
@ApiOperation
(
"宣传手册艺人列表"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"page"
,
value
=
"页数"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"size"
,
value
=
"数量"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manaulId"
,
value
=
"手册id"
,
required
=
true
),
})
public
ResponseDto
<
PageInfo
<
SweetManualArtistListFiveDto
>>
getList
(
@RequestParam
()
Integer
page
,
@RequestParam
()
Integer
size
,
@RequestParam
()
String
manualId
)
{
return
sweetManualArtistsFiveService
.
getList
(
page
,
size
,
manualId
);
}
@GetMapping
(
"details"
)
@ApiOperation
(
"宣传手册艺人详情"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualRelationId"
,
value
=
"手册艺人id"
,
required
=
true
),
})
public
ResponseDto
<
SweetManualArtistListFiveDto
>
details
(
@RequestParam
()
String
manualRelationId
)
{
return
sweetManualArtistsFiveService
.
details
(
manualRelationId
);
}
@PostMapping
(
"add"
)
@ApiOperation
(
"宣传手册艺人添加"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"artistId"
,
value
=
"艺人id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"stageId"
,
value
=
"场地id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"performanceStart"
,
value
=
"演出开始时间"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"performanceEnd"
,
value
=
"演出结束时间"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"signatureStart"
,
value
=
"签售开始时间"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"signatureEnd"
,
value
=
"签售结束时间"
,
required
=
false
),
})
public
ResponseDto
<
Boolean
>
add
(
@RequestParam
()
String
manualId
,
@RequestParam
()
String
artistId
,
@RequestParam
()
String
stageId
,
@RequestParam
(
required
=
false
)
String
performanceStart
,
@RequestParam
(
required
=
false
)
String
performanceEnd
,
@RequestParam
(
required
=
false
)
String
signatureStart
,
@RequestParam
(
required
=
false
)
String
signatureEnd
)
{
return
sweetManualArtistsFiveService
.
add
(
manualId
,
artistId
,
stageId
,
performanceStart
,
performanceEnd
,
signatureStart
,
signatureEnd
);
}
@PostMapping
(
"change"
)
@ApiOperation
(
"宣传手册艺人修改"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualRelationId"
,
value
=
"手册艺人id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"artistId"
,
value
=
"艺人id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"stageId"
,
value
=
"场地id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"performanceStart"
,
value
=
"演出开始时间"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"performanceEnd"
,
value
=
"演出结束时间"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"signatureStart"
,
value
=
"签售开始时间"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"signatureEnd"
,
value
=
"签售结束时间"
,
required
=
false
),
})
public
ResponseDto
<
Boolean
>
change
(
@RequestParam
()
String
manualRelationId
,
@RequestParam
()
String
manualId
,
@RequestParam
()
String
artistId
,
@RequestParam
()
String
stageId
,
@RequestParam
(
required
=
false
)
String
performanceStart
,
@RequestParam
(
required
=
false
)
String
performanceEnd
,
@RequestParam
(
required
=
false
)
String
signatureStart
,
@RequestParam
(
required
=
false
)
String
signatureEnd
)
{
return
sweetManualArtistsFiveService
.
change
(
manualRelationId
,
manualId
,
artistId
,
stageId
,
performanceStart
,
performanceEnd
,
signatureStart
,
signatureEnd
);
}
@DeleteMapping
(
"delete"
)
@ApiOperation
(
"宣传手册艺人删除"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualRelationId"
,
value
=
"手册艺人id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
)
})
public
ResponseDto
<
Boolean
>
delete
(
@RequestParam
()
String
manualRelationId
,
@RequestParam
()
String
manualId
)
{
return
sweetManualArtistsFiveService
.
delete
(
manualRelationId
,
manualId
);
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/controller/five/SweetManualFiveController.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
controller
.
five
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.dto.SweetManualFiveDto
;
import
com.liquidnet.service.sweet.service.five.ISweetManualFiveService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiImplicitParam
;
import
io.swagger.annotations.ApiImplicitParams
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
/**
* <p>
* 电子宣传手册表 前端控制器
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Api
(
tags
=
"电子手册_five"
)
@RestController
@RequestMapping
(
"/five/sweet-manual"
)
public
class
SweetManualFiveController
{
@Autowired
private
ISweetManualFiveService
sweetManualFiveService
;
@GetMapping
(
"list"
)
@ApiOperation
(
"宣传手册列表"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"page"
,
value
=
"页数"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"size"
,
value
=
"数量"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"name"
,
value
=
"姓名"
,
required
=
false
),
})
public
ResponseDto
<
PageInfo
<
SweetManualFiveDto
>>
getList
(
@RequestParam
()
Integer
page
,
@RequestParam
()
Integer
size
,
@RequestParam
(
required
=
false
)
String
name
)
{
return
sweetManualFiveService
.
getManualList
(
page
,
size
,
name
);
}
@GetMapping
(
"details"
)
@ApiOperation
(
"宣传手册详情"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
),
})
public
ResponseDto
<
SweetManualFiveDto
>
details
(
@RequestParam
(
required
=
false
)
String
manualId
)
{
return
sweetManualFiveService
.
details
(
manualId
);
}
@PostMapping
(
"changeRelease"
)
@ApiOperation
(
"修改是否发布"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"page"
,
value
=
"页数"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"size"
,
value
=
"数量"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
changeRelease
(
@RequestParam
()
String
manualId
,
@RequestParam
()
Integer
isRelease
)
{
return
sweetManualFiveService
.
changeRelease
(
manualId
,
isRelease
);
}
@PostMapping
(
"changeStatus"
)
@ApiOperation
(
"修改是否开启"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"电子手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"performancesId"
,
value
=
"演出id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"status"
,
value
=
"开启状态"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
changeStatus
(
@RequestParam
()
String
manualId
,
@RequestParam
()
String
performancesId
,
@RequestParam
()
Integer
status
)
{
return
sweetManualFiveService
.
changeStatus
(
manualId
,
performancesId
,
status
);
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/controller/five/SweetManualNotifyFiveController.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
controller
.
five
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetManualNotifyFive
;
import
com.liquidnet.service.sweet.service.five.ISweetManualNotifyFiveService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiImplicitParam
;
import
io.swagger.annotations.ApiImplicitParams
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
/**
* <p>
* 电子宣传手册通知表 前端控制器
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Api
(
tags
=
"电子手册通知_five"
)
@RestController
@RequestMapping
(
"/five/sweet-manual-notify"
)
public
class
SweetManualNotifyFiveController
{
@Autowired
ISweetManualNotifyFiveService
sweetManualNotifyFiveService
;
@GetMapping
(
"list"
)
@ApiOperation
(
"通知列表"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"page"
,
value
=
"页数"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"size"
,
value
=
"数量"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"name"
,
value
=
"通知标题 不查询从传递null"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
})
public
ResponseDto
<
PageInfo
<
SweetManualNotifyFive
>>
getList
(
@RequestParam
()
Integer
page
,
@RequestParam
()
Integer
size
,
@RequestParam
(
required
=
false
)
String
name
,
@RequestParam
()
String
manualId
)
{
return
sweetManualNotifyFiveService
.
getList
(
page
,
size
,
name
,
manualId
);
}
@PostMapping
(
"add"
)
@ApiOperation
(
"添加通知"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"title"
,
value
=
"标题"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"content"
,
value
=
"内容"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
add
(
@RequestParam
()
String
manualId
,
@RequestParam
()
String
title
,
@RequestParam
()
String
content
)
{
return
sweetManualNotifyFiveService
.
add
(
manualId
,
title
,
content
);
}
@GetMapping
(
"detail"
)
@ApiOperation
(
"通知详情"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualNotifyId"
,
value
=
"通知id"
,
required
=
true
),
})
public
ResponseDto
<
SweetManualNotifyFive
>
detail
(
@RequestParam
()
String
manualNotifyId
)
{
return
sweetManualNotifyFiveService
.
details
(
manualNotifyId
);
}
@PostMapping
(
"change"
)
@ApiOperation
(
"修改通知"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualNotifyId"
,
value
=
"通知id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"title"
,
value
=
"标题"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"content"
,
value
=
"内容"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
change
(
@RequestParam
()
String
manualId
,
@RequestParam
()
String
manualNotifyId
,
@RequestParam
()
String
title
,
@RequestParam
()
String
content
)
{
return
sweetManualNotifyFiveService
.
change
(
manualId
,
manualNotifyId
,
title
,
content
);
}
@DeleteMapping
(
"delete"
)
@ApiOperation
(
"删除通知"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualNotifyId"
,
value
=
"手册通知id"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
delete
(
@RequestParam
()
String
manualNotifyId
)
{
return
sweetManualNotifyFiveService
.
delete
(
manualNotifyId
);
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/controller/five/SweetManualShopFiveController.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
controller
.
five
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetManualShopFive
;
import
com.liquidnet.service.sweet.service.five.ISweetManualShopFiveService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiImplicitParam
;
import
io.swagger.annotations.ApiImplicitParams
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.List
;
/**
* <p>
* 电子宣传手册商铺表 前端控制器
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Api
(
tags
=
"电子手册吃喝玩乐_five"
)
@RestController
@RequestMapping
(
"/five/sweet-manual-shop"
)
public
class
SweetManualShopFiveController
{
@Autowired
ISweetManualShopFiveService
sweetManualShopFiveService
;
@GetMapping
(
"list"
)
@ApiOperation
(
"列表"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"type"
,
value
=
"类型 1吃喝 2玩乐"
,
required
=
true
),
})
public
ResponseDto
<
List
<
SweetManualShopFive
>>
getList
(
@RequestParam
String
manualId
,
@RequestParam
Integer
type
)
{
return
sweetManualShopFiveService
.
getList
(
manualId
,
type
);
}
@GetMapping
(
"details"
)
@ApiOperation
(
"详情"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualShopId"
,
value
=
"商铺id"
,
required
=
true
),
})
public
ResponseDto
<
SweetManualShopFive
>
details
(
@RequestParam
String
manualShopId
)
{
return
sweetManualShopFiveService
.
details
(
manualShopId
);
}
@PostMapping
(
"add"
)
@ApiOperation
(
"添加"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册iid"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"title"
,
value
=
"标题"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"picUrl"
,
value
=
"图片地址"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"describes"
,
value
=
"描述"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"type"
,
value
=
"类型 1吃喝 2玩乐"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"isRecommend"
,
value
=
"是否推荐"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"sort"
,
value
=
"排序"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
add
(
@RequestParam
String
manualId
,
@RequestParam
String
title
,
@RequestParam
String
picUrl
,
@RequestParam
String
describes
,
@RequestParam
Integer
type
,
@RequestParam
Integer
isRecommend
,
@RequestParam
Integer
sort
)
{
return
sweetManualShopFiveService
.
add
(
manualId
,
title
,
picUrl
,
describes
,
type
,
isRecommend
,
sort
);
}
@PostMapping
(
"change"
)
@ApiOperation
(
"修改"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualShopId"
,
value
=
"商铺id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"title"
,
value
=
"标题"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"picUrl"
,
value
=
"图片地址"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"describes"
,
value
=
"描述"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"type"
,
value
=
"类型 1吃喝 2玩乐"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"isRecommend"
,
value
=
"是否推荐"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"sort"
,
value
=
"排序"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
change
(
@RequestParam
String
manualShopId
,
@RequestParam
String
manualId
,
@RequestParam
String
title
,
@RequestParam
String
picUrl
,
@RequestParam
String
describes
,
@RequestParam
Integer
type
,
@RequestParam
Integer
isRecommend
,
@RequestParam
Integer
sort
)
{
return
sweetManualShopFiveService
.
change
(
manualShopId
,
manualId
,
title
,
picUrl
,
describes
,
type
,
isRecommend
,
sort
);
}
@DeleteMapping
(
"delete"
)
@ApiOperation
(
"删除"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualShopId"
,
value
=
"商铺id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"手册id"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
delete
(
@RequestParam
()
String
manualShopId
,
@RequestParam
String
manualId
)
{
return
sweetManualShopFiveService
.
delete
(
manualShopId
,
manualId
);
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/controller/five/SweetManualSortFiveController.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
controller
.
five
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetManualSortFive
;
import
com.liquidnet.service.sweet.service.five.ISweetManualSortFiveService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiImplicitParam
;
import
io.swagger.annotations.ApiImplicitParams
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
/**
* <p>
* 电子宣传手册显示内容表 前端控制器
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Api
(
tags
=
"电子手册显示tag_five"
)
@RestController
@RequestMapping
(
"/five/sweet-manual-sort"
)
public
class
SweetManualSortFiveController
{
@Autowired
private
ISweetManualSortFiveService
sweetManualSortFiveService
;
@PostMapping
(
"add"
)
@ApiOperation
(
"操作 电子手册tag"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"电子手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"content"
,
value
=
"内容 例子(POSITION_1,POSITION_2)"
,
required
=
true
)
})
public
ResponseDto
<
Boolean
>
changeStatus
(
@RequestParam
()
String
manualId
,
@RequestParam
()
String
content
)
{
return
sweetManualSortFiveService
.
add
(
manualId
,
content
);
}
@GetMapping
(
"get"
)
@ApiOperation
(
"获取 电子手册tag"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"电子手册id"
,
required
=
true
)
})
public
ResponseDto
<
SweetManualSortFive
>
changeStatus
(
@RequestParam
()
String
manualId
)
{
return
sweetManualSortFiveService
.
get
(
manualId
);
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/controller/five/SweetRichtextFiveController.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
controller
.
five
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetRichtextFive
;
import
com.liquidnet.service.sweet.service.five.ISweetRichtextFiveService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiImplicitParam
;
import
io.swagger.annotations.ApiImplicitParams
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
/**
* <p>
* 电子宣传手册富文本表 前端控制器
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Api
(
tags
=
"电子手册 富文本_five"
)
@RestController
@RequestMapping
(
"/five/sweet-richtext"
)
public
class
SweetRichtextFiveController
{
@Autowired
ISweetRichtextFiveService
sweetRichtextFiveService
;
@GetMapping
(
"get"
)
@ApiOperation
(
"富文本详情"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"String"
,
name
=
"manualId"
,
value
=
"电子手册id"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"type"
,
value
=
"类型 (1签售时间 2现场地图 3官方大巴 4公共交通 5自驾导航坐标 6官方支持 7观众须知 8防疫指南 9观演攻略)"
,
required
=
true
),
})
public
ResponseDto
<
SweetRichtextFive
>
get
(
@RequestParam
()
String
manualId
,
@RequestParam
()
Integer
type
)
{
return
sweetRichtextFiveService
.
get
(
manualId
,
type
);
}
@PostMapping
(
"add"
)
@ApiOperation
(
"添加富文本"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"manualId"
,
value
=
"页数"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"details"
,
value
=
"数量"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"local"
,
value
=
"经纬度 经度,维度,"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"picUrl"
,
value
=
"图片地址"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"type"
,
value
=
"类型 (1签售时间 2现场地图 3官方大巴 4公共交通 5自驾导航坐标 6官方支持 7观众须知 8防疫指南 9观演攻略)"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
add
(
@RequestParam
()
String
manualId
,
@RequestParam
(
required
=
false
)
String
details
,
@RequestParam
(
required
=
false
)
String
local
,
@RequestParam
(
required
=
false
)
String
picUrl
,
@RequestParam
()
Integer
type
)
{
return
sweetRichtextFiveService
.
add
(
manualId
,
details
,
local
,
picUrl
,
type
);
}
@PostMapping
(
"change"
)
@ApiOperation
(
"修改富文本"
)
@ApiImplicitParams
({
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"manualId"
,
value
=
"页数"
,
required
=
true
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"details"
,
value
=
"数量"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"local"
,
value
=
"经纬度 经度,维度,"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"picUrl"
,
value
=
"图片地址"
,
required
=
false
),
@ApiImplicitParam
(
type
=
"query"
,
dataType
=
"Integer"
,
name
=
"type"
,
value
=
"类型 (1签售时间 2现场地图 3官方大巴 4公共交通 5自驾导航坐标 6官方支持 7观众须知 8防疫指南 9观演攻略)"
,
required
=
true
),
})
public
ResponseDto
<
Boolean
>
change
(
@RequestParam
()
String
manualId
,
@RequestParam
(
required
=
false
)
String
details
,
@RequestParam
(
required
=
false
)
String
local
,
@RequestParam
(
required
=
false
)
String
picUrl
,
@RequestParam
()
Integer
type
)
{
return
sweetRichtextFiveService
.
change
(
manualId
,
details
,
local
,
picUrl
,
type
);
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/service/impl/SweetPerformanceServiceImpl.java
View file @
75cd17ba
...
...
@@ -49,8 +49,12 @@ public class SweetPerformanceServiceImpl extends ServiceImpl<SweetPerformanceMap
Environment
environment
;
@Override
public
ResponseDto
<
Boolean
>
add
(
String
performanceId
,
String
performanceName
,
String
arName
,
String
picOne
,
String
picTwo
,
String
arUrl
,
String
timeStart
,
String
timeEnd
,
String
fileSize
)
{
public
ResponseDto
<
Boolean
>
add
(
String
performanceId
,
String
performanceName
,
String
arName
,
String
picOne
,
String
picTwo
,
String
arUrl
,
String
timeStart
,
String
timeEnd
,
String
fileSize
)
{
try
{
int
count
=
sweetPerformanceMapper
.
selectCount
(
Wrappers
.
lambdaUpdate
(
SweetPerformanceShow
.
class
).
eq
(
SweetPerformanceShow:
:
getPerformanceId
,
performanceId
));
if
(
count
>
0
)
{
return
ResponseDto
.
failure
(
"该演出已关联活动"
);
}
String
offlineUrl
=
goblinUrl
+
"/goblin/inner/ar/data"
;
//离线地址
SweetPerformanceShow
show
=
SweetPerformanceShow
.
getNew
();
show
.
setArId
(
IDGenerator
.
nextTimeId2
());
...
...
@@ -63,8 +67,8 @@ public class SweetPerformanceServiceImpl extends ServiceImpl<SweetPerformanceMap
show
.
setStatus
(
0
);
show
.
setOfflineUrl
(
offlineUrl
);
show
.
setFileSize
(
fileSize
);
show
.
setTimeStart
(
LocalDateTime
.
parse
(
timeStart
,
DTF_YMD_HMS
));
show
.
setTimeEnd
(
LocalDateTime
.
parse
(
timeEnd
,
DTF_YMD_HMS
));
show
.
setTimeStart
(
LocalDateTime
.
parse
(
timeStart
,
DTF_YMD_HMS
));
show
.
setTimeEnd
(
LocalDateTime
.
parse
(
timeEnd
,
DTF_YMD_HMS
));
//redis
List
<
SweetPerformanceShow
>
performanceARList
=
redisUtils
.
getPerformanceAR
();
performanceARList
.
add
(
show
);
...
...
@@ -82,6 +86,11 @@ public class SweetPerformanceServiceImpl extends ServiceImpl<SweetPerformanceMap
@Override
public
ResponseDto
<
Boolean
>
change
(
SweetPerformanceShowParam
show
)
{
try
{
int
count
=
sweetPerformanceMapper
.
selectCount
(
Wrappers
.
lambdaUpdate
(
SweetPerformanceShow
.
class
).
eq
(
SweetPerformanceShow:
:
getPerformanceId
,
show
.
getPerformanceId
()).
ne
(
SweetPerformanceShow:
:
getArId
,
show
.
getArId
()));
if
(
count
>
0
)
{
return
ResponseDto
.
failure
(
"该演出已关联活动"
);
}
String
id
=
show
.
getArId
();
//修改redis
List
<
SweetPerformanceShow
>
performanceARList
=
redisUtils
.
getPerformanceAR
();
...
...
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/service/impl/five/SweetManualArtistsFiveServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
impl
.
five
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.commons.lang.util.CollectionUtil
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistListFiveDto
;
import
com.liquidnet.service.sweet.entity.SweetManualArtistsFive
;
import
com.liquidnet.service.sweet.mapper.SweetManualArtistsFiveMapper
;
import
com.liquidnet.service.sweet.mapper.SweetManualArtistsFiveMapper
;
import
com.liquidnet.service.sweet.service.five.ISweetManualArtistsFiveService
;
import
com.liquidnet.service.sweet.service.ISweetManualArtistsTFCService
;
import
com.liquidnet.service.sweet.utils.RedisFiveDataUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.time.LocalDateTime
;
import
java.util.HashMap
;
import
java.util.List
;
/**
* <p>
* 电子宣传手册艺人表 服务实现类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Service
public
class
SweetManualArtistsFiveServiceImpl
extends
ServiceImpl
<
SweetManualArtistsFiveMapper
,
SweetManualArtistsFive
>
implements
ISweetManualArtistsFiveService
{
@Autowired
private
SweetManualArtistsFiveMapper
sweetManualArtistsFiveMapper
;
@Autowired
private
RedisFiveDataUtils
redisDataUtils
;
@Override
public
ResponseDto
<
PageInfo
<
SweetManualArtistListFiveDto
>>
getList
(
Integer
page
,
Integer
size
,
String
manualId
)
{
PageInfo
<
SweetManualArtistListFiveDto
>
pageInfoTmp
;
try
{
PageHelper
.
startPage
(
page
,
size
);
HashMap
<
String
,
Object
>
map
=
CollectionUtil
.
mapStringObject
();
map
.
put
(
"manualId"
,
manualId
);
List
<
SweetManualArtistListFiveDto
>
voList
=
sweetManualArtistsFiveMapper
.
getManualList
(
map
);
pageInfoTmp
=
new
PageInfo
(
voList
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResponseDto
.
failure
();
}
return
ResponseDto
.
success
(
pageInfoTmp
);
}
@Override
public
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
artistId
,
String
stageId
,
String
performanceStart
,
String
performanceEnd
,
String
signatureStart
,
String
signatureEnd
)
{
try
{
SweetManualArtistsFive
sweetManualNotify
=
SweetManualArtistsFive
.
getNew
();
sweetManualNotify
.
setManualRelationId
(
IDGenerator
.
nextSnowId
());
sweetManualNotify
.
setManualId
(
manualId
);
sweetManualNotify
.
setStageId
(
stageId
);
sweetManualNotify
.
setArtistsId
(
artistId
);
sweetManualNotify
.
setPerformanceEnd
(
performanceEnd
!=
null
?
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
parse
(
performanceEnd
)
:
null
);
sweetManualNotify
.
setPerformanceStart
(
performanceStart
!=
null
?
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
parse
(
performanceStart
)
:
null
);
sweetManualNotify
.
setSignatureStart
(
signatureStart
!=
null
?
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
parse
(
signatureStart
)
:
null
);
sweetManualNotify
.
setSignatureEnd
(
signatureEnd
!=
null
?
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
parse
(
signatureEnd
)
:
null
);
sweetManualNotify
.
setCreatedAt
(
LocalDateTime
.
now
());
sweetManualArtistsFiveMapper
.
insert
(
sweetManualNotify
);
redisDataUtils
.
deleteTimeListRedisData
(
manualId
);
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
SweetManualArtistListFiveDto
>
details
(
String
manualRelationId
)
{
try
{
HashMap
<
String
,
Object
>
map
=
CollectionUtil
.
mapStringObject
();
map
.
put
(
"manualRelationId"
,
manualRelationId
);
SweetManualArtistListFiveDto
dto
=
sweetManualArtistsFiveMapper
.
getManualDetails
(
map
);
return
ResponseDto
.
success
(
dto
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
Boolean
>
change
(
String
manualRelationId
,
String
manualId
,
String
artistId
,
String
stageId
,
String
performanceStart
,
String
performanceEnd
,
String
signatureStart
,
String
signatureEnd
)
{
try
{
SweetManualArtistsFive
sweetManualNotify
=
SweetManualArtistsFive
.
getNew
();
sweetManualNotify
.
setStageId
(
stageId
);
sweetManualNotify
.
setArtistsId
(
artistId
);
sweetManualNotify
.
setPerformanceEnd
(
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
parse
(
performanceEnd
));
sweetManualNotify
.
setPerformanceStart
(
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
parse
(
performanceStart
));
sweetManualNotify
.
setSignatureStart
(
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
parse
(
signatureStart
));
sweetManualNotify
.
setSignatureEnd
(
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
parse
(
signatureEnd
));
sweetManualNotify
.
setUpdatedAt
(
LocalDateTime
.
now
());
sweetManualArtistsFiveMapper
.
update
(
sweetManualNotify
,
Wrappers
.
lambdaUpdate
(
SweetManualArtistsFive
.
class
).
eq
(
SweetManualArtistsFive:
:
getManualRelationId
,
manualRelationId
));
redisDataUtils
.
deleteTimeListRedisData
(
manualId
);
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
Boolean
>
delete
(
String
manualRelationId
,
String
manualId
)
{
try
{
SweetManualArtistsFive
sweetManualNotify
=
SweetManualArtistsFive
.
getNew
();
sweetManualNotify
.
setManualRelationId
(
IDGenerator
.
nextSnowId
());
sweetManualNotify
.
setStatus
(
0
);
sweetManualNotify
.
setUpdatedAt
(
LocalDateTime
.
now
());
sweetManualArtistsFiveMapper
.
update
(
sweetManualNotify
,
Wrappers
.
lambdaUpdate
(
SweetManualArtistsFive
.
class
).
eq
(
SweetManualArtistsFive:
:
getManualRelationId
,
manualRelationId
));
redisDataUtils
.
deleteTimeListRedisData
(
manualId
);
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/service/impl/five/SweetManualFiveServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
impl
.
five
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.commons.lang.util.CollectionUtil
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.base.ErrorMapping
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.dto.SweetManualFiveDto
;
import
com.liquidnet.service.sweet.entity.SweetManualFive
;
import
com.liquidnet.service.sweet.mapper.SweetManualFiveMapper
;
import
com.liquidnet.service.sweet.service.five.ISweetManualFiveService
;
import
com.liquidnet.service.sweet.utils.RedisFiveDataUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.time.LocalDateTime
;
import
java.util.HashMap
;
import
java.util.List
;
/**
* <p>
* 电子宣传手册表 服务实现类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Service
public
class
SweetManualFiveServiceImpl
extends
ServiceImpl
<
SweetManualFiveMapper
,
SweetManualFive
>
implements
ISweetManualFiveService
{
@Autowired
private
SweetManualFiveMapper
sweetManualFiveMapper
;
@Autowired
private
RedisFiveDataUtils
redisDataUtils
;
@Override
public
ResponseDto
<
PageInfo
<
SweetManualFiveDto
>>
getManualList
(
int
page
,
int
size
,
String
name
)
{
PageInfo
<
SweetManualFiveDto
>
pageInfoTmp
;
try
{
PageHelper
.
startPage
(
page
,
size
);
HashMap
<
String
,
Object
>
map
=
CollectionUtil
.
mapStringObject
();
map
.
put
(
"title"
,
name
);
List
<
SweetManualFiveDto
>
voList
=
sweetManualFiveMapper
.
getManualList
(
map
);
for
(
int
i
=
0
;
i
<
voList
.
size
();
i
++)
{
SweetManualFiveDto
vo
=
voList
.
get
(
i
);
if
(
vo
.
getStatus
()
>=
6
&&
vo
.
getStatus
()
!=
7
)
{
if
(
DateUtil
.
compareStrDay
(
vo
.
getTimeSell
(),
DateUtil
.
getNowTime
())
>
0
)
{
//未开始
vo
.
setStatus
(
9
);
}
else
if
(
DateUtil
.
compareStrDay
(
vo
.
getTimeStop
(),
DateUtil
.
getNowTime
())
<
0
)
{
//已结束
vo
.
setStatus
(
10
);
}
else
{
vo
.
setStatus
(
6
);
}
}
}
pageInfoTmp
=
new
PageInfo
(
voList
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
20104
));
}
return
ResponseDto
.
success
(
pageInfoTmp
);
}
@Override
public
ResponseDto
<
SweetManualFiveDto
>
details
(
String
manualId
)
{
SweetManualFiveDto
vo
;
try
{
HashMap
<
String
,
Object
>
map
=
CollectionUtil
.
mapStringObject
();
map
.
put
(
"manualId"
,
manualId
);
vo
=
sweetManualFiveMapper
.
getManualDetails
(
map
);
if
(
vo
.
getStatus
()
>=
6
&&
vo
.
getStatus
()
!=
7
)
{
if
(
DateUtil
.
compareStrDay
(
vo
.
getTimeSell
(),
DateUtil
.
getNowTime
())
>
0
)
{
//未开始
vo
.
setStatus
(
9
);
}
else
if
(
DateUtil
.
compareStrDay
(
vo
.
getTimeStop
(),
DateUtil
.
getNowTime
())
<
0
)
{
//已结束
vo
.
setStatus
(
10
);
}
else
{
vo
.
setStatus
(
6
);
}
}
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
20104
));
}
return
ResponseDto
.
success
(
vo
);
}
@Override
public
ResponseDto
<
Boolean
>
changeStatus
(
String
manualId
,
String
performancesId
,
Integer
status
)
{
try
{
int
count
=
sweetManualFiveMapper
.
selectCount
(
Wrappers
.
lambdaUpdate
(
SweetManualFive
.
class
).
eq
(
SweetManualFive:
:
getManualId
,
manualId
));
SweetManualFive
sweetManual
=
SweetManualFive
.
getNew
();
if
(
count
>
0
)
{
//修改
sweetManual
.
setStatus
(
status
);
sweetManual
.
setUpdatedAt
(
LocalDateTime
.
now
());
sweetManualFiveMapper
.
update
(
sweetManual
,
Wrappers
.
lambdaUpdate
(
SweetManualFive
.
class
).
eq
(
SweetManualFive:
:
getManualId
,
manualId
));
}
else
{
//创建
sweetManual
.
setManualId
(
IDGenerator
.
nextSnowId
());
sweetManual
.
setPerformanceId
(
performancesId
);
sweetManual
.
setStatus
(
status
);
sweetManual
.
setIsRelease
(
0
);
sweetManual
.
setCreatedAt
(
LocalDateTime
.
now
());
sweetManualFiveMapper
.
insert
(
sweetManual
);
}
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
redisDataUtils
.
deletePushListRedisData
();
return
ResponseDto
.
success
();
}
@Override
public
ResponseDto
<
Boolean
>
changeRelease
(
String
manualId
,
Integer
isRelease
)
{
try
{
SweetManualFive
sweetManual
=
SweetManualFive
.
getNew
();
sweetManual
.
setIsRelease
(
isRelease
);
sweetManual
.
setUpdatedAt
(
LocalDateTime
.
now
());
sweetManualFiveMapper
.
update
(
sweetManual
,
Wrappers
.
lambdaUpdate
(
SweetManualFive
.
class
).
eq
(
SweetManualFive:
:
getManualId
,
manualId
));
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
redisDataUtils
.
deletePushListRedisData
();
return
ResponseDto
.
success
();
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/service/impl/five/SweetManualNotifyFiveServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
impl
.
five
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetManualNotifyFive
;
import
com.liquidnet.service.sweet.mapper.SweetManualNotifyFiveMapper
;
import
com.liquidnet.service.sweet.service.five.ISweetManualNotifyFiveService
;
import
com.liquidnet.service.sweet.utils.RedisFiveDataUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.time.LocalDateTime
;
import
java.util.List
;
/**
* <p>
* 电子宣传手册通知表 服务实现类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Service
public
class
SweetManualNotifyFiveServiceImpl
extends
ServiceImpl
<
SweetManualNotifyFiveMapper
,
SweetManualNotifyFive
>
implements
ISweetManualNotifyFiveService
{
@Autowired
private
SweetManualNotifyFiveMapper
sweetManualNotifyFiveMapper
;
@Autowired
private
RedisFiveDataUtils
redisDataUtils
;
@Override
public
ResponseDto
<
PageInfo
<
SweetManualNotifyFive
>>
getList
(
Integer
page
,
Integer
size
,
String
title
,
String
manualId
)
{
PageInfo
<
SweetManualNotifyFive
>
pageInfo
=
null
;
try
{
PageHelper
.
startPage
(
page
,
size
);
List
<
SweetManualNotifyFive
>
data
;
if
(
title
!=
null
)
{
data
=
sweetManualNotifyFiveMapper
.
selectList
(
Wrappers
.
lambdaQuery
(
SweetManualNotifyFive
.
class
).
like
(
SweetManualNotifyFive:
:
getTitle
,
title
).
eq
(
SweetManualNotifyFive:
:
getManualId
,
manualId
).
eq
(
SweetManualNotifyFive:
:
getStatus
,
1
));
}
else
{
data
=
sweetManualNotifyFiveMapper
.
selectList
(
Wrappers
.
lambdaQuery
(
SweetManualNotifyFive
.
class
).
eq
(
SweetManualNotifyFive:
:
getManualId
,
manualId
).
eq
(
SweetManualNotifyFive:
:
getStatus
,
1
));
}
pageInfo
=
new
PageInfo
(
data
);
return
ResponseDto
.
success
(
pageInfo
);
}
catch
(
Exception
e
)
{
return
ResponseDto
.
success
(
pageInfo
);
}
}
@Override
public
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
title
,
String
content
)
{
try
{
SweetManualNotifyFive
sweetManualNotify
=
SweetManualNotifyFive
.
getNew
();
sweetManualNotify
.
setManualNotifyId
(
IDGenerator
.
nextSnowId
());
sweetManualNotify
.
setManualId
(
manualId
);
sweetManualNotify
.
setTitle
(
title
);
sweetManualNotify
.
setContent
(
content
);
sweetManualNotify
.
setCreatedAt
(
LocalDateTime
.
now
());
sweetManualNotifyFiveMapper
.
insert
(
sweetManualNotify
);
List
<
SweetManualNotifyFive
>
oldData
=
redisDataUtils
.
getNotifyRedisData
(
manualId
);
oldData
.
add
(
sweetManualNotify
);
redisDataUtils
.
setNotifyRedisData
(
manualId
,
oldData
);
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
SweetManualNotifyFive
>
details
(
String
manualNotifyId
)
{
try
{
return
ResponseDto
.
success
(
sweetManualNotifyFiveMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
SweetManualNotifyFive
.
class
).
eq
(
SweetManualNotifyFive:
:
getManualNotifyId
,
manualNotifyId
).
eq
(
SweetManualNotifyFive:
:
getStatus
,
1
)));
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
Boolean
>
change
(
String
manualId
,
String
manualNotifyId
,
String
title
,
String
content
)
{
try
{
SweetManualNotifyFive
sweetManualNotify
=
SweetManualNotifyFive
.
getNew
();
sweetManualNotify
.
setTitle
(
title
);
sweetManualNotify
.
setContent
(
content
);
sweetManualNotify
.
setUpdatedAt
(
LocalDateTime
.
now
());
sweetManualNotifyFiveMapper
.
update
(
sweetManualNotify
,
Wrappers
.
lambdaUpdate
(
SweetManualNotifyFive
.
class
).
eq
(
SweetManualNotifyFive:
:
getManualNotifyId
,
manualNotifyId
));
List
<
SweetManualNotifyFive
>
oldData
=
redisDataUtils
.
getNotifyRedisData
(
manualId
);
for
(
SweetManualNotifyFive
item
:
oldData
)
{
if
(
item
.
getManualNotifyId
().
equalsIgnoreCase
(
manualNotifyId
))
{
item
.
setTitle
(
title
);
item
.
setContent
(
content
);
item
.
setUpdatedAt
(
LocalDateTime
.
now
());
}
}
redisDataUtils
.
setNotifyRedisData
(
manualId
,
oldData
);
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
Boolean
>
delete
(
String
manualNotifyId
)
{
try
{
SweetManualNotifyFive
sweetManualNotify
=
SweetManualNotifyFive
.
getNew
();
sweetManualNotify
.
setStatus
(
0
);
sweetManualNotify
.
setUpdatedAt
(
LocalDateTime
.
now
());
sweetManualNotifyFiveMapper
.
update
(
sweetManualNotify
,
Wrappers
.
lambdaUpdate
(
SweetManualNotifyFive
.
class
).
eq
(
SweetManualNotifyFive:
:
getManualNotifyId
,
manualNotifyId
));
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/service/impl/five/SweetManualShopFiveServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
impl
.
five
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetManualShopFive
;
import
com.liquidnet.service.sweet.mapper.SweetManualShopFiveMapper
;
import
com.liquidnet.service.sweet.service.five.ISweetManualShopFiveService
;
import
com.liquidnet.service.sweet.utils.RedisFiveDataUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
/**
* <p>
* 电子宣传手册商铺表 服务实现类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Service
public
class
SweetManualShopFiveServiceImpl
extends
ServiceImpl
<
SweetManualShopFiveMapper
,
SweetManualShopFive
>
implements
ISweetManualShopFiveService
{
@Autowired
private
SweetManualShopFiveMapper
sweetManualShopFiveMapper
;
@Autowired
private
RedisFiveDataUtils
redisDataUtils
;
@Override
public
ResponseDto
<
List
<
SweetManualShopFive
>>
getList
(
String
manualId
,
Integer
type
)
{
try
{
List
<
SweetManualShopFive
>
data
=
sweetManualShopFiveMapper
.
selectList
(
Wrappers
.
lambdaQuery
(
SweetManualShopFive
.
class
).
eq
(
SweetManualShopFive:
:
getManualId
,
manualId
).
eq
(
SweetManualShopFive:
:
getType
,
type
).
eq
(
SweetManualShopFive:
:
getStatus
,
1
));
return
ResponseDto
.
success
(
data
);
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
SweetManualShopFive
>
details
(
String
manualShopId
)
{
try
{
SweetManualShopFive
data
=
sweetManualShopFiveMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
SweetManualShopFive
.
class
).
eq
(
SweetManualShopFive:
:
getManualShopId
,
manualShopId
).
eq
(
SweetManualShopFive:
:
getStatus
,
1
));
return
ResponseDto
.
success
(
data
);
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
title
,
String
picUrl
,
String
describe
,
Integer
type
,
Integer
isRecommend
,
Integer
sort
)
{
try
{
SweetManualShopFive
sweetManualShop
=
SweetManualShopFive
.
getNew
();
sweetManualShop
.
setManualShopId
(
IDGenerator
.
nextSnowId
());
sweetManualShop
.
setManualId
(
manualId
);
sweetManualShop
.
setTitle
(
title
);
sweetManualShop
.
setPicUrl
(
picUrl
);
sweetManualShop
.
setDescribes
(
describe
);
sweetManualShop
.
setType
(
type
);
sweetManualShop
.
setIsRecommend
(
isRecommend
);
sweetManualShop
.
setSort
(
sort
);
sweetManualShop
.
setStatus
(
1
);
sweetManualShopFiveMapper
.
insert
(
sweetManualShop
);
redisDataUtils
.
setManualShopRedisData
(
manualId
);
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
Boolean
>
change
(
String
manualShopId
,
String
manualId
,
String
title
,
String
picUrl
,
String
describe
,
Integer
type
,
Integer
isRecommend
,
Integer
sort
)
{
try
{
SweetManualShopFive
sweetManualShop
=
SweetManualShopFive
.
getNew
();
sweetManualShop
.
setTitle
(
title
);
sweetManualShop
.
setPicUrl
(
picUrl
);
sweetManualShop
.
setDescribes
(
describe
);
sweetManualShop
.
setType
(
type
);
sweetManualShop
.
setIsRecommend
(
isRecommend
);
sweetManualShop
.
setSort
(
sort
);
sweetManualShopFiveMapper
.
update
(
sweetManualShop
,
Wrappers
.
lambdaUpdate
(
SweetManualShopFive
.
class
).
eq
(
SweetManualShopFive:
:
getManualShopId
,
manualShopId
));
redisDataUtils
.
setManualShopRedisData
(
manualId
);
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
Boolean
>
delete
(
String
manualShopId
,
String
manualId
)
{
try
{
SweetManualShopFive
sweetManualShop
=
SweetManualShopFive
.
getNew
();
sweetManualShop
.
setStatus
(
0
);
sweetManualShopFiveMapper
.
update
(
sweetManualShop
,
Wrappers
.
lambdaUpdate
(
SweetManualShopFive
.
class
).
eq
(
SweetManualShopFive:
:
getManualShopId
,
manualShopId
));
redisDataUtils
.
setManualShopRedisData
(
manualId
);
return
ResponseDto
.
success
();
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/service/impl/five/SweetManualSortFiveServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
impl
.
five
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetManualSortFive
;
import
com.liquidnet.service.sweet.mapper.SweetManualSortFiveMapper
;
import
com.liquidnet.service.sweet.service.five.ISweetManualSortFiveService
;
import
com.liquidnet.service.sweet.utils.RedisFiveDataUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.time.LocalDateTime
;
/**
* <p>
* 电子宣传手册显示内容表 服务实现类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Service
public
class
SweetManualSortFiveServiceImpl
extends
ServiceImpl
<
SweetManualSortFiveMapper
,
SweetManualSortFive
>
implements
ISweetManualSortFiveService
{
@Autowired
private
SweetManualSortFiveMapper
sweetManualSortFiveMapper
;
@Autowired
private
RedisFiveDataUtils
redisDataUtils
;
@Override
public
ResponseDto
<
SweetManualSortFive
>
get
(
String
manualId
)
{
try
{
return
ResponseDto
.
success
(
sweetManualSortFiveMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
SweetManualSortFive
.
class
).
eq
(
SweetManualSortFive:
:
getManualId
,
manualId
)));
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
content
)
{
try
{
int
count
=
sweetManualSortFiveMapper
.
selectCount
(
Wrappers
.
lambdaUpdate
(
SweetManualSortFive
.
class
).
eq
(
SweetManualSortFive:
:
getManualId
,
manualId
));
if
(
count
>
0
)
{
SweetManualSortFive
sweetManualSort
=
SweetManualSortFive
.
getNew
();
sweetManualSort
.
setManualId
(
manualId
);
sweetManualSort
.
setShowPosition
(
content
);
sweetManualSort
.
setUpdatedAt
(
LocalDateTime
.
now
());
sweetManualSortFiveMapper
.
update
(
sweetManualSort
,
Wrappers
.
lambdaUpdate
(
SweetManualSortFive
.
class
).
eq
(
SweetManualSortFive:
:
getManualId
,
manualId
));
}
else
{
SweetManualSortFive
sweetManualSort
=
SweetManualSortFive
.
getNew
();
sweetManualSort
.
setManualId
(
manualId
);
sweetManualSort
.
setShowPosition
(
content
);
sweetManualSort
.
setCreatedAt
(
LocalDateTime
.
now
());
sweetManualSortFiveMapper
.
insert
(
sweetManualSort
);
}
redisDataUtils
.
deleteSortRedisData
(
manualId
);
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
return
ResponseDto
.
success
();
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/service/impl/five/SweetRichtextFiveServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
impl
.
five
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.sweet.entity.SweetRichtextFive
;
import
com.liquidnet.service.sweet.mapper.SweetRichtextFiveMapper
;
import
com.liquidnet.service.sweet.service.five.ISweetRichtextFiveService
;
import
com.liquidnet.service.sweet.utils.RedisFiveDataUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.time.LocalDateTime
;
/**
* <p>
* 电子宣传手册富文本表 服务实现类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Service
public
class
SweetRichtextFiveServiceImpl
extends
ServiceImpl
<
SweetRichtextFiveMapper
,
SweetRichtextFive
>
implements
ISweetRichtextFiveService
{
@Autowired
private
SweetRichtextFiveMapper
sweetRichtextFiveMapper
;
@Autowired
private
RedisFiveDataUtils
redisDataUtils
;
@Override
public
ResponseDto
<
SweetRichtextFive
>
get
(
String
manualId
,
Integer
type
)
{
try
{
return
ResponseDto
.
success
(
sweetRichtextFiveMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
SweetRichtextFive
.
class
).
eq
(
SweetRichtextFive:
:
getManualId
,
manualId
).
eq
(
SweetRichtextFive:
:
getType
,
type
)));
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
}
@Override
public
ResponseDto
<
Boolean
>
add
(
String
manualId
,
String
details
,
String
local
,
String
pirUrl
,
Integer
type
)
{
try
{
int
count
=
sweetRichtextFiveMapper
.
selectCount
(
Wrappers
.
lambdaQuery
(
SweetRichtextFive
.
class
).
eq
(
SweetRichtextFive:
:
getManualId
,
manualId
).
eq
(
SweetRichtextFive:
:
getType
,
type
));
if
(
count
>
0
){
return
ResponseDto
.
failure
(
"不能重复添加"
);
}
SweetRichtextFive
sweetRichtext
=
SweetRichtextFive
.
getNew
();
sweetRichtext
.
setRichtextId
(
IDGenerator
.
nextSnowId
());
sweetRichtext
.
setManualId
(
manualId
);
if
(
type
==
5
)
{
sweetRichtext
.
setLocal
(
local
);
sweetRichtext
.
setDetails
(
details
);
}
else
if
(
type
==
2
)
{
sweetRichtext
.
setPicUrl
(
pirUrl
);
}
else
{
sweetRichtext
.
setDetails
(
details
);
}
sweetRichtext
.
setType
(
type
);
sweetRichtext
.
setCreatedAt
(
LocalDateTime
.
now
());
sweetRichtextFiveMapper
.
insert
(
sweetRichtext
);
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
return
ResponseDto
.
success
();
}
@Override
public
ResponseDto
<
Boolean
>
change
(
String
manualId
,
String
details
,
String
local
,
String
pirUrl
,
Integer
type
)
{
try
{
SweetRichtextFive
sweetRichtext
=
SweetRichtextFive
.
getNew
();
sweetRichtext
.
setRichtextId
(
IDGenerator
.
nextSnowId
());
sweetRichtext
.
setManualId
(
manualId
);
sweetRichtext
.
setDetails
(
details
);
if
(
type
==
5
)
{
sweetRichtext
.
setLocal
(
local
);
}
else
if
(
type
==
2
)
{
sweetRichtext
.
setPicUrl
(
pirUrl
);
}
sweetRichtext
.
setType
(
type
);
sweetRichtext
.
setCreatedAt
(
LocalDateTime
.
now
());
sweetRichtextFiveMapper
.
update
(
sweetRichtext
,
Wrappers
.
lambdaUpdate
(
SweetRichtextFive
.
class
).
eq
(
SweetRichtextFive:
:
getManualId
,
manualId
).
eq
(
SweetRichtextFive:
:
getType
,
type
));
redisDataUtils
.
setRichTextRedisData
(
manualId
,
type
.
toString
(),
sweetRichtext
);
}
catch
(
Exception
e
)
{
return
ResponseDto
.
failure
();
}
return
ResponseDto
.
success
();
}
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/service/impl/five/SweetUserRelationFiveServiceImpl.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
service
.
impl
.
five
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.liquidnet.service.sweet.entity.SweetUserRelationFive
;
import
com.liquidnet.service.sweet.mapper.SweetUserRelationFiveMapper
;
import
com.liquidnet.service.sweet.service.five.ISweetUserRelationFiveService
;
import
org.springframework.stereotype.Service
;
/**
* <p>
* 用户 收藏/喜欢等状态 服务实现类
* </p>
*
* @author liquidnet
* @since 2021-08-09
*/
@Service
public
class
SweetUserRelationFiveServiceImpl
extends
ServiceImpl
<
SweetUserRelationFiveMapper
,
SweetUserRelationFive
>
implements
ISweetUserRelationFiveService
{
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/utils/ObjectUtil.java
View file @
75cd17ba
...
...
@@ -4,6 +4,7 @@ import com.liquidnet.service.sweet.dto.*;
import
com.liquidnet.service.sweet.dto.vo.IntegralActivityDrawVo
;
import
com.liquidnet.service.sweet.dto.vo.IntegralActivityVo
;
import
com.liquidnet.service.sweet.entity.SweetManualShop
;
import
com.liquidnet.service.sweet.entity.SweetManualShopFive
;
import
com.liquidnet.service.sweet.entity.SweetManualShopMdsk
;
import
com.liquidnet.service.sweet.entity.SweetManualShopTfc
;
import
com.liquidnet.service.sweet.vo.SweetCItyVoteStatVo
;
...
...
@@ -19,6 +20,10 @@ public class ObjectUtil {
private
static
final
ArrayList
<
SweetManualArtistListMDSKDto
>
sweetManualArtistListMDSKDtoList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
SweetManualShopMdsk
>
sweetManualShopMDSKList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
SweetManualAppletFiveDto
>
sweetManualAppletFiveDtoList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
SweetManualArtistListFiveDto
>
sweetManualArtistListFiveDtoList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
SweetManualShopFive
>
sweetManualShopFiveList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
SweetManualAppletTFCDto
>
sweetManualAppletTFCDtoList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
SweetManualArtistListTFCDto
>
sweetManualArtistListTFCDtoList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
SweetManualShopTfc
>
sweetManualShopTFCList
=
new
ArrayList
<>();
...
...
@@ -44,6 +49,10 @@ public class ObjectUtil {
return
(
ArrayList
<
SweetManualAppletMDSKDto
>)
sweetManualAppletMDSKDtoList
.
clone
();
}
public
static
ArrayList
<
SweetManualAppletFiveDto
>
getSweetManualAppletFiveDtoList
()
{
return
(
ArrayList
<
SweetManualAppletFiveDto
>)
sweetManualAppletFiveDtoList
.
clone
();
}
public
static
ArrayList
<
SweetManualAppletTFCDto
>
getSweetManualAppletTFCDtoList
()
{
return
(
ArrayList
<
SweetManualAppletTFCDto
>)
sweetManualAppletTFCDtoList
.
clone
();
}
...
...
@@ -64,6 +73,14 @@ public class ObjectUtil {
return
(
ArrayList
<
SweetManualShopMdsk
>)
sweetManualShopMDSKList
.
clone
();
}
public
static
ArrayList
<
SweetManualArtistListFiveDto
>
getSweetManualArtistListFiveDtoList
()
{
return
(
ArrayList
<
SweetManualArtistListFiveDto
>)
sweetManualArtistListFiveDtoList
.
clone
();
}
public
static
ArrayList
<
SweetManualShopFive
>
getSweetManualShopFiveList
()
{
return
(
ArrayList
<
SweetManualShopFive
>)
sweetManualShopFiveList
.
clone
();
}
public
static
ArrayList
<
SweetCItyVoteStatVo
>
getSweetCItyVoteStatVoList
()
{
return
(
ArrayList
<
SweetCItyVoteStatVo
>)
sweetCItyVoteStatVoList
.
clone
();
}
...
...
liquidnet-bus-service/liquidnet-service-sweet/src/main/java/com/liquidnet/service/sweet/utils/RedisFiveDataUtils.java
0 → 100644
View file @
75cd17ba
package
com
.
liquidnet
.
service
.
sweet
.
utils
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.liquidnet.common.cache.redis.util.RedisUtil
;
import
com.liquidnet.commons.lang.util.CollectionUtil
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
com.liquidnet.service.base.SqlMapping
;
import
com.liquidnet.service.base.constant.MQConst
;
import
com.liquidnet.service.feign.slime.api.FeignSlimeApiClient
;
import
com.liquidnet.service.slime.dto.vo.SlimeFieldsDetailsVo
;
import
com.liquidnet.service.sweet.constant.SweetConstant
;
import
com.liquidnet.service.sweet.dto.SweetManualAppletFiveDto
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistList2FiveDto
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistListFiveDto
;
import
com.liquidnet.service.sweet.dto.SweetManualArtistStageListFiveDto
;
import
com.liquidnet.service.sweet.entity.SweetManualNotifyFive
;
import
com.liquidnet.service.sweet.entity.SweetManualShopFive
;
import
com.liquidnet.service.sweet.entity.SweetManualSortFive
;
import
com.liquidnet.service.sweet.entity.SweetRichtextFive
;
import
com.liquidnet.service.sweet.mapper.*
;
import
com.liquidnet.service.sweet.vo.SweetArtistsRelationVo
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
import
java.time.LocalDateTime
;
import
java.util.*
;
@Component
public
class
RedisFiveDataUtils
{
@Autowired
private
RedisUtil
redisUtil
;
@Autowired
private
QueueUtils
queueUtils
;
@Autowired
private
SweetManualFiveMapper
sweetManualFiveMapper
;
@Autowired
private
SweetManualArtistsFiveMapper
sweetManualArtistsFiveMapper
;
@Autowired
private
SweetRichtextFiveMapper
sweetRichtextFiveMapper
;
@Autowired
private
SweetManualSortFiveMapper
sweetManualSortFiveMapper
;
@Autowired
private
SweetManualNotifyFiveMapper
sweetManualNotifyFiveMapper
;
@Autowired
private
SweetManualShopFiveMapper
sweetManualShopFiveMapper
;
@Autowired
private
SweetArtistsMapper
sweetArtistsMapper
;
@Autowired
private
FeignSlimeApiClient
feignSlimeApiClient
;
public
List
<
SweetManualAppletFiveDto
>
setPushList
()
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_PUSH_LIST
;
List
<
SweetManualAppletFiveDto
>
data
=
sweetManualFiveMapper
.
getManualAppletDto
();
for
(
SweetManualAppletFiveDto
item
:
data
)
{
if
(!
item
.
getIsMember
().
equals
(
1
)){
item
.
setTimeSell
(
DateUtil
.
format
(
DateUtil
.
addMin
(
DateUtil
.
parse
(
item
.
getTimeSell
(),
"yyyy-MM-dd HH:mm:ss"
),-
item
.
getPayCountdownMinute
()),
DateUtil
.
Formatter
.
yyyyMMddHHmmss
));
}
SlimeFieldsDetailsVo
slimeFieldsDetailsVo
=
feignSlimeApiClient
.
fieldDetails
(
item
.
getFieldId
()).
getData
();
String
fieldName
=
slimeFieldsDetailsVo
.
getName
();
String
cityName
=
slimeFieldsDetailsVo
.
getCityName
();
String
latitude
=
slimeFieldsDetailsVo
.
getLatitude
();
String
longitude
=
slimeFieldsDetailsVo
.
getLongitude
();
item
.
setFieldName
(
fieldName
);
item
.
setCityName
(
cityName
);
item
.
setLatitude
(
latitude
);
item
.
setLongitude
(
longitude
);
}
redisUtil
.
set
(
redisKey
,
data
);
return
data
;
}
//获取电子手册列表 (城市)
public
List
<
SweetManualAppletFiveDto
>
getPushList
()
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_PUSH_LIST
;
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
setPushList
();
}
else
{
return
(
List
<
SweetManualAppletFiveDto
>)
obj
;
}
}
//获取电子手册演出详情
public
SweetManualAppletFiveDto
getAppletPerformance
(
String
manualId
)
{
List
<
SweetManualAppletFiveDto
>
data
=
getPushList
();
SweetManualAppletFiveDto
returnData
=
SweetManualAppletFiveDto
.
getNew
();
for
(
SweetManualAppletFiveDto
item
:
data
)
{
if
(
item
.
getManualId
().
equalsIgnoreCase
(
manualId
))
{
returnData
=
item
;
break
;
}
}
return
returnData
;
}
public
SweetManualArtistList2FiveDto
setTimeList
(
String
manualId
,
String
content
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_TIME_LIST
.
concat
(
manualId
);
HashMap
<
String
,
Object
>
map
=
CollectionUtil
.
mapStringObject
();
map
.
put
(
"manualId"
,
manualId
);
List
<
SweetManualArtistListFiveDto
>
data
=
sweetManualArtistsFiveMapper
.
getManualList
(
map
);
//获取时间
SweetManualAppletFiveDto
sweetManualAppletDto
=
getAppletPerformance
(
manualId
);
Date
dateEnd
=
DateUtil
.
parse
(
sweetManualAppletDto
.
getTimeEnd
(),
DateUtil
.
DATE_SMALL_STR
);
Date
dateStart
=
DateUtil
.
parse
(
sweetManualAppletDto
.
getTimeStart
(),
DateUtil
.
DATE_SMALL_STR
);
int
intervalDay
=
(
int
)
DateUtil
.
intervalDays
(
dateStart
,
dateEnd
);
ArrayList
<
String
>
list
=
CollectionUtil
.
arrayListString
();
list
.
add
(
DateUtil
.
format
(
dateStart
,
DateUtil
.
Formatter
.
yyyy_MM_dd
));
for
(
int
i
=
0
;
i
<
intervalDay
;
i
++)
{
list
.
add
(
DateUtil
.
format
(
DateUtil
.
addDay
(
dateStart
,
i
+
1
),
DateUtil
.
Formatter
.
yyyy_MM_dd
));
}
//获取舞台
List
<
SweetManualArtistStageListFiveDto
>
stageData
=
sweetManualArtistsFiveMapper
.
getStageNameList
(
map
);
SweetManualArtistList2FiveDto
returnData
=
SweetManualArtistList2FiveDto
.
getNew
();
returnData
.
setDate
(
list
);
returnData
.
setData
(
data
);
returnData
.
setStage
(
stageData
);
redisUtil
.
set
(
redisKey
,
returnData
);
return
returnData
;
}
//获取时间表
public
SweetManualArtistList2FiveDto
getTimeList
(
String
manualId
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_TIME_LIST
.
concat
(
manualId
);
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
setTimeList
(
manualId
,
null
);
}
else
{
return
(
SweetManualArtistList2FiveDto
)
obj
;
}
}
public
SweetRichtextFive
setRichTextRedisData
(
String
manualId
,
String
type
,
SweetRichtextFive
content
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_RICH_TEXT
.
concat
(
manualId
).
concat
(
":type:"
+
type
);
SweetRichtextFive
sweetRichtext
;
if
(
content
!=
null
)
{
sweetRichtext
=
content
;
}
else
{
sweetRichtext
=
sweetRichtextFiveMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
SweetRichtextFive
.
class
).
eq
(
SweetRichtextFive:
:
getManualId
,
manualId
).
eq
(
SweetRichtextFive:
:
getType
,
type
));
}
redisUtil
.
set
(
redisKey
,
sweetRichtext
);
return
sweetRichtext
;
}
//获取富文本详情
public
SweetRichtextFive
getRichTextRedisData
(
String
manualId
,
String
type
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_RICH_TEXT
.
concat
(
manualId
).
concat
(
":type:"
+
type
);
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
setRichTextRedisData
(
manualId
,
type
,
null
);
}
else
{
return
(
SweetRichtextFive
)
obj
;
}
}
public
List
<
String
>
setTagRedisData
(
String
manualId
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_SORT
.
concat
(
manualId
);
SweetManualSortFive
data
=
sweetManualSortFiveMapper
.
selectOne
(
Wrappers
.
lambdaQuery
(
SweetManualSortFive
.
class
).
eq
(
SweetManualSortFive:
:
getManualId
,
manualId
));
String
[]
arrays
=
data
.
getShowPosition
().
split
(
","
);
List
<
String
>
returnData
=
new
ArrayList
<>();
for
(
String
item
:
arrays
)
{
returnData
.
add
(
item
);
// returnData.add(SweetConstant.ManualPosition.getMessage(item));
}
redisUtil
.
set
(
redisKey
,
returnData
);
return
returnData
;
}
//获取显示的标签
public
List
<
String
>
getTagRedisData
(
String
manualId
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_SORT
.
concat
(
manualId
);
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
setTagRedisData
(
manualId
);
}
else
{
return
(
List
<
String
>)
obj
;
}
}
public
List
<
SweetManualNotifyFive
>
setNotifyRedisData
(
String
manualId
,
List
<
SweetManualNotifyFive
>
content
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_NOTIFY_LIST
.
concat
(
manualId
);
List
<
SweetManualNotifyFive
>
data
;
if
(
content
!=
null
)
{
data
=
content
;
}
else
{
data
=
sweetManualNotifyFiveMapper
.
selectList
(
Wrappers
.
lambdaQuery
(
SweetManualNotifyFive
.
class
).
eq
(
SweetManualNotifyFive:
:
getManualId
,
manualId
).
eq
(
SweetManualNotifyFive:
:
getStatus
,
1
));
}
redisUtil
.
set
(
redisKey
,
data
);
return
data
;
}
//获取通知
public
List
<
SweetManualNotifyFive
>
getNotifyRedisData
(
String
manualId
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_NOTIFY_LIST
.
concat
(
manualId
);
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
setNotifyRedisData
(
manualId
,
null
);
}
else
{
return
(
List
<
SweetManualNotifyFive
>)
obj
;
}
}
public
void
deletePushListRedisData
()
{
redisUtil
.
del
(
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_PUSH_LIST
);
//列表
}
public
void
deleteTimeListRedisData
(
String
manualId
)
{
redisUtil
.
del
(
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_TIME_LIST
.
concat
(
manualId
));
//列表
}
public
void
deleteSortRedisData
(
String
manualId
)
{
redisUtil
.
del
(
SweetConstant
.
REDIS_KEY_SWEET_FIVE_MANUAL_SORT
.
concat
(
manualId
));
//列表
}
public
void
setArtistsRelationRedisVo
(
String
uid
,
String
artistsId
,
String
manualId
,
String
type
)
{
LinkedList
<
String
>
sqls
=
CollectionUtil
.
linkedListString
();
LinkedList
<
Object
[]>
sqlsDataA
=
CollectionUtil
.
linkedListObjectArr
();
LocalDateTime
now
=
LocalDateTime
.
now
();
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_ARTISTS_RELATION
.
concat
(
uid
).
concat
(
":manualId:"
).
concat
(
manualId
);
SweetArtistsRelationVo
vo
=
getArtistsRelationRedisVo
(
uid
,
manualId
);
vo
.
setUid
(
uid
);
if
(
type
.
equalsIgnoreCase
(
"sign"
))
{
if
(
vo
.
getSignList
()
==
null
)
{
ArrayList
<
String
>
signList
=
CollectionUtil
.
arrayListString
();
signList
.
add
(
artistsId
);
vo
.
setSignList
(
signList
);
sqls
.
add
(
SqlMapping
.
get
(
"sweet_user_relation_five.insert"
));
sqlsDataA
.
add
(
new
Object
[]{
uid
,
2
,
artistsId
,
manualId
,
now
});
}
else
{
if
(
vo
.
getSignList
().
contains
(
artistsId
))
{
vo
.
getSignList
().
remove
(
artistsId
);
sqls
.
add
(
SqlMapping
.
get
(
"sweet_user_relation_five.delete"
));
sqlsDataA
.
add
(
new
Object
[]{
uid
,
artistsId
,
manualId
,
2
});
}
else
{
vo
.
getSignList
().
add
(
artistsId
);
sqls
.
add
(
SqlMapping
.
get
(
"sweet_user_relation_five.insert"
));
sqlsDataA
.
add
(
new
Object
[]{
uid
,
2
,
artistsId
,
manualId
,
now
});
}
}
}
else
if
(
type
.
equalsIgnoreCase
(
"watch"
))
{
if
(
vo
.
getWatchList
()
==
null
)
{
ArrayList
<
String
>
watchList
=
CollectionUtil
.
arrayListString
();
watchList
.
add
(
artistsId
);
vo
.
setWatchList
(
watchList
);
sqls
.
add
(
SqlMapping
.
get
(
"sweet_user_relation_five.insert"
));
sqlsDataA
.
add
(
new
Object
[]{
uid
,
1
,
artistsId
,
manualId
,
now
});
}
else
{
if
(
vo
.
getWatchList
().
contains
(
artistsId
))
{
vo
.
getWatchList
().
remove
(
artistsId
);
sqls
.
add
(
SqlMapping
.
get
(
"sweet_user_relation_five.delete"
));
sqlsDataA
.
add
(
new
Object
[]{
uid
,
artistsId
,
manualId
,
1
});
}
else
{
vo
.
getWatchList
().
add
(
artistsId
);
sqls
.
add
(
SqlMapping
.
get
(
"sweet_user_relation_five.insert"
));
sqlsDataA
.
add
(
new
Object
[]{
uid
,
1
,
artistsId
,
manualId
,
now
});
}
}
}
redisUtil
.
set
(
redisKey
,
vo
);
queueUtils
.
sendMsgByRedis
(
MQConst
.
SweetQueue
.
ARTISTS_RELATION
.
getKey
(),
SqlMapping
.
gets
(
sqls
,
sqlsDataA
));
}
//获取 签售
//获取 想看
public
SweetArtistsRelationVo
getArtistsRelationRedisVo
(
String
uid
,
String
manualId
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_ARTISTS_RELATION
.
concat
(
uid
).
concat
(
":manualId:"
).
concat
(
manualId
);
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
SweetArtistsRelationVo
.
getNew
();
}
else
{
return
(
SweetArtistsRelationVo
)
obj
;
}
}
//获取 商铺
public
List
<
SweetManualShopFive
>
setManualShopRedisData
(
String
manualId
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_SHOP
.
concat
(
manualId
);
List
<
SweetManualShopFive
>
list
=
sweetManualShopFiveMapper
.
selectList
(
Wrappers
.
lambdaQuery
(
SweetManualShopFive
.
class
).
eq
(
SweetManualShopFive:
:
getManualId
,
manualId
).
orderBy
(
true
,
false
,
SweetManualShopFive:
:
getSort
));
redisUtil
.
set
(
redisKey
,
list
);
return
list
;
}
public
List
<
SweetManualShopFive
>
getManualShopRedisData
(
String
manualId
)
{
String
redisKey
=
SweetConstant
.
REDIS_KEY_SWEET_FIVE_SHOP
.
concat
(
manualId
);
Object
obj
=
redisUtil
.
get
(
redisKey
);
if
(
obj
==
null
)
{
return
setManualShopRedisData
(
manualId
);
}
else
{
return
(
List
<
SweetManualShopFive
>)
obj
;
}
}
// // 艺人详情
// public SweetArtists setArtistsDetails(String artistsId) {
// String redisKey = SweetConstant.REDIS_KEY_SWEET_FIVE_ARTISTS_DETAILS.concat(artistsId);
// SweetArtists sweetArtists = sweetArtistsMapper.selectOne(Wrappers.lambdaQuery(SweetArtists.class).eq(SweetArtists::getArtistsId, artistsId).eq(SweetArtists::getStatus, 1));
// redisUtil.set(redisKey, sweetArtists);
// return sweetArtists;
// }
//
// public SweetArtists getArtistsDetails(String artistsId) {
// String redisKey = SweetConstant.REDIS_KEY_SWEET_FIVE_ARTISTS_DETAILS.concat(artistsId);
// Object obj = redisUtil.get(redisKey);
// if (obj == null) {
// return setArtistsDetails(artistsId);
// } else {
// return (SweetArtists) obj;
// }
// }
}
liquidnet-bus-service/liquidnet-service-sweet/src/main/resources/sqlmap.properties
View file @
75cd17ba
kylin_order_ticket_entities.updateStatusByStation
=
UPDATE kylin_order_ticket_entities SET `status`=?,check_client=?,updated_at=? WHERE order_ticket_entities_id=? # ------------------------缺票登记(不用考虑并发)---------------------------- kylin_lack_register.insert=INSERT INTO `kylin_lack_registers`(`lack_registers_id` ,`performance_id` ,`ticket_id` ,`user_id` ,`user_name` ,`user_mobile` ,`send_status` ,`ip_address` ,`created_at`)VALUES(? ,? ,? ,? ,? ,? ,? ,? ,?); # ------------------------支付回调---------------------------- kylin_order_ticket.synPay=UPDATE kylin_order_tickets SET payment_type = ? ,pay_code = ? , time_pay = ?, qr_code = ? , updated_at = ? WHERE order_tickets_id = ? and (updated_at <= ? or created_at = ?) kylin_order_ticket_status.synPay=UPDATE kylin_order_ticket_status SET `status` = ?,pay_status = ?,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ?) kylin_order_ticket_relation.synPay=UPDATE kylin_order_ticket_relations SET updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ?) kylin_order_ticket_entities.synPay=UPDATE kylin_order_ticket_entities SET is_payment = ?,updated_at = ?,sys_damai = 1 WHERE order_id = ? and (updated_at <= ? or created_at = ?) # ------------------------用户关系---------------------------- sweet_user_relation.insert=INSERT INTO sweet_user_relation (user_id,type,target_id,manual_id,status,created_at) VALUES (?,?,?,?,1,?) sweet_user_relation.delete=DELETE FROM sweet_user_relation WHERE user_id = ? and target_id = ? and manual_id = ? and type = ? sweet_user_relation_mdsk.insert=INSERT INTO sweet_user_relation_mdsk (user_id,type,target_id,manual_id,status,created_at) VALUES (?,?,?,?,1,?) sweet_user_relation_mdsk.delete=DELETE FROM sweet_user_relation_mdsk WHERE user_id = ? and target_id = ? and manual_id = ? and type = ? # ------------------------抽奖---------------------------- sweet_luck_draw.insert=INSERT INTO sweet_luck_draw (mobile,union_id,luck_draw_num,prize,prize_all,status,created_at) VALUES (?,?,?,?,?,1,?) # --------------------------答案-------------------------- sweet_answer.insert=INSERT INTO sweet_answer (answer_id,phone,answer_json,img_url) VALUES (?,?,?,?) # --------------------------提醒记录-------------------------- sweet_remind.insert=INSERT INTO sweet_remind (remind_id,openId,unionId,performancesId) VALUES (?,?,?,?) sweet_applet_sub_msg.insert=INSERT INTO sweet_applet_sub_msg (msg_id,open_id,union_id,user_id,template_id,target_id,applet_type,activity_type) VALUES (?,?,?,?,?,?,?,?) # --------------------------用户投票记录-------------------------- sweet_city_vote.insert=INSERT INTO sweet_city_vote (vote_id,phone,openId,unionId,type,city_code,city_name,day_time) VALUES (?,?,?,?,?,?,?,?) sweet_city_vote_stat.insert=INSERT INTO sweet_city_vote_stat (stat_id,city_code,city_name,vote_num,type) VALUES (?,?,?,?,?) sweet_city_vote_stat.update=UPDATE sweet_city_vote_stat SET vote_num = IFNULL(vote_num, 0) + 1, updated_at = ? WHERE city_code = ? AND type = ? # --------------------------防疫答题-------------------------- sweet_antigenic_question.insert=INSERT INTO sweet_antigenic_question (question_id,type,openId,unionId,nickname,address,phone,urgent_phone,keyword1,keyword11,keyword2,keyword3,keyword4,keyword5,keyword6,keyword7) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) # ------------------------积分抽奖---------------------------- sweet_integral_activity_draw.insert=INSERT INTO sweet_integral_activity_draw (draw_id,integral_activity_id,activity_num,prize_id,prize_title,prize_type,prize_type_num,user_id,nickname,receiving_status) VALUES (?,?,?,?,?,?,?,?,?,?) sweet_integral_activity_draw.update=UPDATE sweet_integral_activity_draw SET receiving_addresses_id = ?, receiving_name = ?, receiving_phone = ?, receiving_address = ?, receiving_province = ?, receiving_city = ?, receiving_county = ?, updated_at = ? WHERE draw_id = ? sweet_integral_activity_draw.updateStatus=UPDATE sweet_integral_activity_draw SET receiving_status = ?, relation_id = ?, updated_at = ? WHERE draw_id = ? sweet_integral_activity_draw.get_coupon=INSERT INTO candy_mgt_coupon (mcoupon_id, coupon_id, `state`, event_amt, event_type, event_limit, event_at, `operator`, created_at) VALUES (?, ?, 0, ?, 2, ?, ?, ?, ?) # --------------------------小程序登录记录用户解密后信息-------------------------- sweet_applet_users.insert=INSERT INTO sweet_applet_users (applet_user_id,user_id,open_id,union_id,phone_number,pure_phone_number,country_code,type) VALUES (?,?,?,?,?,?,?,?) # --------------------------微信用户信息表公众号-------------------------- sweet_wechat_users.insert=INSERT INTO sweet_wechat_users (wechat_user_id,type,open_id,union_id,nickname,sex_desc,sex,head_img_url,language,country,province,city,subscribe_time,subscribe_scene) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?) sweet_wechat_users.delete=DELETE FROM sweet_wechat_users WHERE union_id = ? and type = ? sweet_wechat_users.update=UPDATE sweet_wechat_users SET is_cancel = ?, updated_at = ? WHERE union_id = ? AND type = ? AND is_cancel = 1 #---------------------------音乐节活动海报-------------------------------- sweet_strawberry_poster_user=INSERT INTO sweet_strawberry_poster(open_id,poster_id,union_id,nickname,city_name,city_code,custom_text,created_at,updated_at) VALUES (?,?,?,?,?,?,?,?,?) sweet_strawberry_poster_Musician=INSERT INTO sweet_strawberry_poster_lineup(lineup_id,poster_id,lineup_num,musician_name,created_at,updated_at) VALUES (?,?,?,?,?,?) #---------------------------猫登天空-------------------------------- sweet_wechat_maodeng.insert=INSERT INTO sweet_wechat_maodeng(mao_id,user_id,text_msg,pic_url,img_url,created_at) VALUES (?,?,?,?,?,?) sweet_wechat_maodeng.text.update=UPDATE sweet_wechat_maodeng SET text_msg=? WHERE user_id=? AND mao_id=? sweet_wechat_maodeng.img.update=UPDATE sweet_wechat_maodeng SET img_url=? WHERE user_id=? AND mao_id=? # --------------------------数字藏品预约活动-------------------------- sweet_collection_reservation.insert=INSERT INTO sweet_collection_reservation (reservation_id,nickname,mobile,mailbox,enterprise_name,title,created_at,updated_at) VALUES (?,?,?,?,?,?,?,?) # --------------------------YB??-------------------------- sweet_yb_enroll.insert=INSERT INTO sweet_yb_enroll (enroll_id,contact_tell,contact_wechat,nickname,style,img_url,audio_url,universities,city_name) VALUES (?,?,?,?,?,?,?,?,?)
\ No newline at end of file
kylin_order_ticket_entities.updateStatusByStation
=
UPDATE kylin_order_ticket_entities SET `status`=?,check_client=?,updated_at=? WHERE order_ticket_entities_id=? # ------------------------缺票登记(不用考虑并发)---------------------------- kylin_lack_register.insert=INSERT INTO `kylin_lack_registers`(`lack_registers_id` ,`performance_id` ,`ticket_id` ,`user_id` ,`user_name` ,`user_mobile` ,`send_status` ,`ip_address` ,`created_at`)VALUES(? ,? ,? ,? ,? ,? ,? ,? ,?); # ------------------------支付回调---------------------------- kylin_order_ticket.synPay=UPDATE kylin_order_tickets SET payment_type = ? ,pay_code = ? , time_pay = ?, qr_code = ? , updated_at = ? WHERE order_tickets_id = ? and (updated_at <= ? or created_at = ?) kylin_order_ticket_status.synPay=UPDATE kylin_order_ticket_status SET `status` = ?,pay_status = ?,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ?) kylin_order_ticket_relation.synPay=UPDATE kylin_order_ticket_relations SET updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ?) kylin_order_ticket_entities.synPay=UPDATE kylin_order_ticket_entities SET is_payment = ?,updated_at = ?,sys_damai = 1 WHERE order_id = ? and (updated_at <= ? or created_at = ?) # ------------------------用户关系---------------------------- sweet_user_relation.insert=INSERT INTO sweet_user_relation (user_id,type,target_id,manual_id,status,created_at) VALUES (?,?,?,?,1,?) sweet_user_relation.delete=DELETE FROM sweet_user_relation WHERE user_id = ? and target_id = ? and manual_id = ? and type = ? sweet_user_relation_mdsk.insert=INSERT INTO sweet_user_relation_mdsk (user_id,type,target_id,manual_id,status,created_at) VALUES (?,?,?,?,1,?) sweet_user_relation_mdsk.delete=DELETE FROM sweet_user_relation_mdsk WHERE user_id = ? and target_id = ? and manual_id = ? and type = ? sweet_user_relation_five.insert=INSERT INTO sweet_user_relation_five (user_id,type,target_id,manual_id,status,created_at) VALUES (?,?,?,?,1,?) sweet_user_relation_five.delete=DELETE FROM sweet_user_relation_five WHERE user_id = ? and target_id = ? and manual_id = ? and type = ? # ------------------------抽奖---------------------------- sweet_luck_draw.insert=INSERT INTO sweet_luck_draw (mobile,union_id,luck_draw_num,prize,prize_all,status,created_at) VALUES (?,?,?,?,?,1,?) # --------------------------答案-------------------------- sweet_answer.insert=INSERT INTO sweet_answer (answer_id,phone,answer_json,img_url) VALUES (?,?,?,?) # --------------------------提醒记录-------------------------- sweet_remind.insert=INSERT INTO sweet_remind (remind_id,openId,unionId,performancesId) VALUES (?,?,?,?) sweet_applet_sub_msg.insert=INSERT INTO sweet_applet_sub_msg (msg_id,open_id,union_id,user_id,template_id,target_id,applet_type,activity_type) VALUES (?,?,?,?,?,?,?,?) # --------------------------用户投票记录-------------------------- sweet_city_vote.insert=INSERT INTO sweet_city_vote (vote_id,phone,openId,unionId,type,city_code,city_name,day_time) VALUES (?,?,?,?,?,?,?,?) sweet_city_vote_stat.insert=INSERT INTO sweet_city_vote_stat (stat_id,city_code,city_name,vote_num,type) VALUES (?,?,?,?,?) sweet_city_vote_stat.update=UPDATE sweet_city_vote_stat SET vote_num = IFNULL(vote_num, 0) + 1, updated_at = ? WHERE city_code = ? AND type = ? # --------------------------防疫答题-------------------------- sweet_antigenic_question.insert=INSERT INTO sweet_antigenic_question (question_id,type,openId,unionId,nickname,address,phone,urgent_phone,keyword1,keyword11,keyword2,keyword3,keyword4,keyword5,keyword6,keyword7) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) # ------------------------积分抽奖---------------------------- sweet_integral_activity_draw.insert=INSERT INTO sweet_integral_activity_draw (draw_id,integral_activity_id,activity_num,prize_id,prize_title,prize_type,prize_type_num,user_id,nickname,receiving_status) VALUES (?,?,?,?,?,?,?,?,?,?) sweet_integral_activity_draw.update=UPDATE sweet_integral_activity_draw SET receiving_addresses_id = ?, receiving_name = ?, receiving_phone = ?, receiving_address = ?, receiving_province = ?, receiving_city = ?, receiving_county = ?, updated_at = ? WHERE draw_id = ? sweet_integral_activity_draw.updateStatus=UPDATE sweet_integral_activity_draw SET receiving_status = ?, relation_id = ?, updated_at = ? WHERE draw_id = ? sweet_integral_activity_draw.get_coupon=INSERT INTO candy_mgt_coupon (mcoupon_id, coupon_id, `state`, event_amt, event_type, event_limit, event_at, `operator`, created_at) VALUES (?, ?, 0, ?, 2, ?, ?, ?, ?) # --------------------------小程序登录记录用户解密后信息-------------------------- sweet_applet_users.insert=INSERT INTO sweet_applet_users (applet_user_id,user_id,open_id,union_id,phone_number,pure_phone_number,country_code,type) VALUES (?,?,?,?,?,?,?,?) # --------------------------微信用户信息表公众号-------------------------- sweet_wechat_users.insert=INSERT INTO sweet_wechat_users (wechat_user_id,type,open_id,union_id,nickname,sex_desc,sex,head_img_url,language,country,province,city,subscribe_time,subscribe_scene) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?) sweet_wechat_users.delete=DELETE FROM sweet_wechat_users WHERE union_id = ? and type = ? sweet_wechat_users.update=UPDATE sweet_wechat_users SET is_cancel = ?, updated_at = ? WHERE union_id = ? AND type = ? AND is_cancel = 1 #---------------------------音乐节活动海报-------------------------------- sweet_strawberry_poster_user=INSERT INTO sweet_strawberry_poster(open_id,poster_id,union_id,nickname,city_name,city_code,custom_text,created_at,updated_at) VALUES (?,?,?,?,?,?,?,?,?) sweet_strawberry_poster_Musician=INSERT INTO sweet_strawberry_poster_lineup(lineup_id,poster_id,lineup_num,musician_name,created_at,updated_at) VALUES (?,?,?,?,?,?) #---------------------------猫登天空-------------------------------- sweet_wechat_maodeng.insert=INSERT INTO sweet_wechat_maodeng(mao_id,user_id,text_msg,pic_url,img_url,created_at) VALUES (?,?,?,?,?,?) sweet_wechat_maodeng.text.update=UPDATE sweet_wechat_maodeng SET text_msg=? WHERE user_id=? AND mao_id=? sweet_wechat_maodeng.img.update=UPDATE sweet_wechat_maodeng SET img_url=? WHERE user_id=? AND mao_id=? # --------------------------数字藏品预约活动-------------------------- sweet_collection_reservation.insert=INSERT INTO sweet_collection_reservation (reservation_id,nickname,mobile,mailbox,enterprise_name,title,created_at,updated_at) VALUES (?,?,?,?,?,?,?,?) # --------------------------YB??-------------------------- sweet_yb_enroll.insert=INSERT INTO sweet_yb_enroll (enroll_id,contact_tell,contact_wechat,nickname,style,img_url,audio_url,universities,city_name) VALUES (?,?,?,?,?,?,?,?,?)
\ 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