Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
midjourney-proxy
Overview
Overview
Details
Activity
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
徐少华
midjourney-proxy
Commits
fa403ebc
Commit
fa403ebc
authored
Apr 14, 2020
by
裴大威
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feat-zyj-1002754' into 'master'
1002754获取社群码配置资源 See merge request rays/pcloud-book!626
parents
e872a769
85d480f0
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
217 additions
and
16 deletions
+217
-16
AppletUserBookcaseBizImpl.java
...cloud/book/applet/biz/impl/AppletUserBookcaseBizImpl.java
+12
-16
AppletUserBookcaseDao.java
...ava/com/pcloud/book/applet/dao/AppletUserBookcaseDao.java
+6
-0
AppletUserBookcaseDaoImpl.java
...cloud/book/applet/dao/impl/AppletUserBookcaseDaoImpl.java
+5
-0
BookGroupBiz.java
...src/main/java/com/pcloud/book/group/biz/BookGroupBiz.java
+18
-0
BookGroupBizImpl.java
...java/com/pcloud/book/group/biz/impl/BookGroupBizImpl.java
+111
-0
BookServeDTO.java
...src/main/java/com/pcloud/book/group/dto/BookServeDTO.java
+41
-0
BookGroupFacade.java
...in/java/com/pcloud/book/group/facade/BookGroupFacade.java
+6
-0
BookGroupFacadeImpl.java
...om/pcloud/book/group/facade/impl/BookGroupFacadeImpl.java
+10
-0
AppletUserBookcase.xml
...k/src/main/resources/mapper/applet/AppletUserBookcase.xml
+8
-0
No files found.
pcloud-service-book/src/main/java/com/pcloud/book/applet/biz/impl/AppletUserBookcaseBizImpl.java
View file @
fa403ebc
...
@@ -7,9 +7,9 @@ import com.pcloud.book.applet.dto.AppletUserBookcaseDTO;
...
@@ -7,9 +7,9 @@ import com.pcloud.book.applet.dto.AppletUserBookcaseDTO;
import
com.pcloud.book.applet.entity.AppletUserBookcase
;
import
com.pcloud.book.applet.entity.AppletUserBookcase
;
import
com.pcloud.book.applet.entity.AppletUserClickRecord
;
import
com.pcloud.book.applet.entity.AppletUserClickRecord
;
import
com.pcloud.book.consumer.app.AssistTempletConsr
;
import
com.pcloud.book.consumer.app.AssistTempletConsr
;
import
com.pcloud.book.consumer.channel.QrcodeSceneConsr
;
import
com.pcloud.book.consumer.user.AdviserConsr
;
import
com.pcloud.book.consumer.user.AdviserConsr
;
import
com.pcloud.channelcenter.wechat.dto.BookServeParamVO
;
import
com.pcloud.book.group.biz.BookGroupBiz
;
import
com.pcloud.book.group.dto.BookServeDTO
;
import
com.pcloud.channelcenter.wechat.vo.BookServeVO
;
import
com.pcloud.channelcenter.wechat.vo.BookServeVO
;
import
com.pcloud.common.page.PageBeanNew
;
import
com.pcloud.common.page.PageBeanNew
;
import
com.pcloud.common.page.PageParam
;
import
com.pcloud.common.page.PageParam
;
...
@@ -17,8 +17,6 @@ import com.pcloud.common.utils.DateUtils;
...
@@ -17,8 +17,6 @@ import com.pcloud.common.utils.DateUtils;
import
com.pcloud.common.utils.ListUtils
;
import
com.pcloud.common.utils.ListUtils
;
import
com.pcloud.common.utils.cache.redis.JedisClusterUtils
;
import
com.pcloud.common.utils.cache.redis.JedisClusterUtils
;
import
com.pcloud.common.utils.string.StringUtil
;
import
com.pcloud.common.utils.string.StringUtil
;
import
com.pcloud.usercenter.party.adviser.dto.AdviserBaseInfoDto
;
import
org.apache.commons.collections.MapUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
import
org.springframework.stereotype.Component
;
...
@@ -44,10 +42,12 @@ public class AppletUserBookcaseBizImpl implements AppletUserBookcaseBiz {
...
@@ -44,10 +42,12 @@ public class AppletUserBookcaseBizImpl implements AppletUserBookcaseBiz {
@Autowired
@Autowired
private
AssistTempletConsr
assistTempletConsr
;
private
AssistTempletConsr
assistTempletConsr
;
@Autowired
@Autowired
private
QrcodeSceneConsr
qrcodeSceneConsr
;
private
BookGroupBiz
bookGroupBiz
;
@Override
@Override
public
void
addUserBook
(
AppletUserBookcase
appletUserBookcase
)
{
public
void
addUserBook
(
AppletUserBookcase
appletUserBookcase
)
{
//数据库去重
appletUserBookcaseDao
.
deleteByBookIdUserId
(
appletUserBookcase
);
appletUserBookcaseDao
.
insert
(
appletUserBookcase
);
appletUserBookcaseDao
.
insert
(
appletUserBookcase
);
Long
wechatUserId
=
appletUserBookcase
.
getWechatUserId
();
Long
wechatUserId
=
appletUserBookcase
.
getWechatUserId
();
String
key
=
"BOOK:APPLET:listByWechatUserId"
+
wechatUserId
;
String
key
=
"BOOK:APPLET:listByWechatUserId"
+
wechatUserId
;
...
@@ -90,21 +90,17 @@ public class AppletUserBookcaseBizImpl implements AppletUserBookcaseBiz {
...
@@ -90,21 +90,17 @@ public class AppletUserBookcaseBizImpl implements AppletUserBookcaseBiz {
@Override
@Override
public
Map
<
String
,
Object
>
getUserClickStatistic
(
Long
wechatUserId
,
Long
bookId
,
Long
channelId
,
Long
adviserId
)
{
public
Map
<
String
,
Object
>
getUserClickStatistic
(
Long
wechatUserId
,
Long
bookId
,
Long
channelId
,
Long
adviserId
)
{
//书刊下所有资源
//社群书和现代纸书下资源
BookServeParamVO
serveParamVO
=
new
BookServeParamVO
();
List
<
BookServeDTO
>
serveDTOList
=
bookGroupBiz
.
getBookAndBookGroupServeIds
(
adviserId
,
bookId
,
channelId
);
serveParamVO
.
setBookId
(
bookId
);
if
(
ListUtils
.
isEmpty
(
serveDTOList
)){
serveParamVO
.
setAdviserId
(
adviserId
);
serveParamVO
.
setChannelId
(
channelId
);
List
<
BookServeVO
>
serveVOList
=
qrcodeSceneConsr
.
listBookServeIds
(
serveParamVO
);
if
(
ListUtils
.
isEmpty
(
serveVOList
)){
return
new
HashMap
<>();
return
new
HashMap
<>();
}
}
Integer
clickCount
=
0
;
Integer
clickCount
=
0
;
String
startDate
=
DateUtils
.
formatDate
(
new
Date
(),
DateUtils
.
DATE_FORMAT_DATEONLY
);
String
startDate
=
DateUtils
.
formatDate
(
new
Date
(),
DateUtils
.
DATE_FORMAT_DATEONLY
);
List
<
Long
>
appIds
=
serve
VOList
.
stream
().
filter
(
s
->
s
.
getTypeCod
e
().
equalsIgnoreCase
(
"APP"
)).
List
<
Long
>
appIds
=
serve
DTOList
.
stream
().
filter
(
s
->
s
.
getServeTyp
e
().
equalsIgnoreCase
(
"APP"
)).
map
(
BookServe
V
O:
:
getServeId
).
distinct
().
collect
(
Collectors
.
toList
());
map
(
BookServe
DT
O:
:
getServeId
).
distinct
().
collect
(
Collectors
.
toList
());
List
<
Long
>
productIds
=
serve
VOList
.
stream
().
filter
(
s
->
s
.
getTypeCod
e
().
equalsIgnoreCase
(
"PRODUCT"
)).
List
<
Long
>
productIds
=
serve
DTOList
.
stream
().
filter
(
s
->
s
.
getServeTyp
e
().
equalsIgnoreCase
(
"PRODUCT"
)).
map
(
BookServe
V
O:
:
getServeId
).
distinct
().
collect
(
Collectors
.
toList
());
map
(
BookServe
DT
O:
:
getServeId
).
distinct
().
collect
(
Collectors
.
toList
());
if
(!
ListUtils
.
isEmpty
(
appIds
)){
if
(!
ListUtils
.
isEmpty
(
appIds
)){
Integer
appCount
=
appletUserBookcaseDao
.
getUserClickServerCount
(
wechatUserId
,
bookId
,
channelId
,
adviserId
,
appIds
,
"APP"
);
Integer
appCount
=
appletUserBookcaseDao
.
getUserClickServerCount
(
wechatUserId
,
bookId
,
channelId
,
adviserId
,
appIds
,
"APP"
);
if
(
appCount
>
0
){
if
(
appCount
>
0
){
...
...
pcloud-service-book/src/main/java/com/pcloud/book/applet/dao/AppletUserBookcaseDao.java
View file @
fa403ebc
...
@@ -37,4 +37,10 @@ public interface AppletUserBookcaseDao extends BaseDao<AppletUserBookcase> {
...
@@ -37,4 +37,10 @@ public interface AppletUserBookcaseDao extends BaseDao<AppletUserBookcase> {
* @return
* @return
*/
*/
String
getMinClickTime
(
Long
wechatUserId
,
Long
bookId
,
Long
channelId
,
Long
adviserId
,
List
<
Long
>
serveIds
,
String
fromType
);
String
getMinClickTime
(
Long
wechatUserId
,
Long
bookId
,
Long
channelId
,
Long
adviserId
,
List
<
Long
>
serveIds
,
String
fromType
);
/**
* 删除
* @param appletUserBookcase
*/
void
deleteByBookIdUserId
(
AppletUserBookcase
appletUserBookcase
);
}
}
pcloud-service-book/src/main/java/com/pcloud/book/applet/dao/impl/AppletUserBookcaseDaoImpl.java
View file @
fa403ebc
...
@@ -45,4 +45,9 @@ public class AppletUserBookcaseDaoImpl extends BaseDaoImpl<AppletUserBookcase> i
...
@@ -45,4 +45,9 @@ public class AppletUserBookcaseDaoImpl extends BaseDaoImpl<AppletUserBookcase> i
map
.
put
(
"fromType"
,
fromType
);
map
.
put
(
"fromType"
,
fromType
);
return
getSessionTemplate
().
selectOne
(
getStatement
(
"getMinClickTime"
),
map
);
return
getSessionTemplate
().
selectOne
(
getStatement
(
"getMinClickTime"
),
map
);
}
}
@Override
public
void
deleteByBookIdUserId
(
AppletUserBookcase
appletUserBookcase
)
{
getSessionTemplate
().
delete
(
getStatement
(
"deleteByBookIdUserId"
),
appletUserBookcase
);
}
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/biz/BookGroupBiz.java
View file @
fa403ebc
...
@@ -771,4 +771,22 @@ public interface BookGroupBiz {
...
@@ -771,4 +771,22 @@ public interface BookGroupBiz {
* @param scene
* @param scene
*/
*/
void
getByAppletScene
(
Long
wechatUserId
,
String
scene
);
void
getByAppletScene
(
Long
wechatUserId
,
String
scene
);
/**
* 获取小睿社群书和现代纸书所配资源
* @param adviserId
* @param bookId
* @param channelId
* @return
*/
PageBeanNew
<
BookServeDTO
>
getBookAndBookGroupServeList
(
Long
adviserId
,
Long
bookId
,
Long
channelId
);
/**
* 获取小睿社群书和现代纸书所配资源id
* @param adviserId
* @param bookId
* @param channelId
* @return
*/
List
<
BookServeDTO
>
getBookAndBookGroupServeIds
(
Long
adviserId
,
Long
bookId
,
Long
channelId
);
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/biz/impl/BookGroupBizImpl.java
View file @
fa403ebc
...
@@ -86,7 +86,9 @@ import com.pcloud.channelcenter.base.constants.ChannelConstants;
...
@@ -86,7 +86,9 @@ import com.pcloud.channelcenter.base.constants.ChannelConstants;
import
com.pcloud.channelcenter.qrcode.dto.GroupQrcodeVO
;
import
com.pcloud.channelcenter.qrcode.dto.GroupQrcodeVO
;
import
com.pcloud.channelcenter.qrcode.dto.QrcodeSceneDto
;
import
com.pcloud.channelcenter.qrcode.dto.QrcodeSceneDto
;
import
com.pcloud.channelcenter.wechat.dto.AccountSettingDto
;
import
com.pcloud.channelcenter.wechat.dto.AccountSettingDto
;
import
com.pcloud.channelcenter.wechat.dto.BookServeParamVO
;
import
com.pcloud.channelcenter.wechat.dto.MessageDto
;
import
com.pcloud.channelcenter.wechat.dto.MessageDto
;
import
com.pcloud.channelcenter.wechat.vo.BookServeVO
;
import
com.pcloud.common.core.aspect.ParamLog
;
import
com.pcloud.common.core.aspect.ParamLog
;
import
com.pcloud.common.core.constant.ProductTypeConstant
;
import
com.pcloud.common.core.constant.ProductTypeConstant
;
import
com.pcloud.common.core.constant.SystemCode
;
import
com.pcloud.common.core.constant.SystemCode
;
...
@@ -4501,4 +4503,113 @@ public class BookGroupBizImpl implements BookGroupBiz {
...
@@ -4501,4 +4503,113 @@ public class BookGroupBizImpl implements BookGroupBiz {
appletUserBookcaseBiz
.
addUserBook
(
appletUserBookcase
);
appletUserBookcaseBiz
.
addUserBook
(
appletUserBookcase
);
}
}
@Override
public
PageBeanNew
<
BookServeDTO
>
getBookAndBookGroupServeList
(
Long
adviserId
,
Long
bookId
,
Long
channelId
)
{
//社群书和现代纸书下资源
List
<
BookServeDTO
>
serveDTOList
=
getBookAndBookGroupServeIds
(
adviserId
,
bookId
,
channelId
);
if
(
ListUtils
.
isEmpty
(
serveDTOList
)){
return
new
PageBeanNew
<>(
0
,
1
,
0
,
new
ArrayList
<>());
}
//填充资源信息
fillBookServe
(
serveDTOList
);
PageBeanNew
<
BookServeDTO
>
pageBeanNew
=
new
PageBeanNew
<
BookServeDTO
>(
0
,
serveDTOList
.
size
(),
serveDTOList
.
size
(),
serveDTOList
);
pageBeanNew
.
setPageCount
(
1
);
return
pageBeanNew
;
}
public
List
<
BookServeDTO
>
getBookAndBookGroupServeIds
(
Long
adviserId
,
Long
bookId
,
Long
channelId
){
List
<
BookServeDTO
>
serveDTOList
=
new
ArrayList
<>();
BookGroupDTO
bookGroupDTO
=
bookGroupDao
.
getDTOByBookId
(
bookId
,
channelId
,
adviserId
);
List
<
Long
>
appIds
=
new
ArrayList
<>();
List
<
Long
>
productIds
=
new
ArrayList
<>();
AccountSettingDto
accountSettingDto
=
qrcodeSceneConsr
.
getWechatInfo
(
channelId
);
if
(
null
!=
bookGroupDTO
){
//有社群书
//社群书配置资源
List
<
BookGroupServe
>
bookGroupServes
=
bookGroupServeDao
.
getListByBookGroupId
(
bookGroupDTO
.
getId
());
if
(!
ListUtils
.
isEmpty
(
bookGroupServes
)){
for
(
BookGroupServe
bookGroupServe:
bookGroupServes
){
BookServeDTO
bookServeDTO
=
new
BookServeDTO
();
BeanUtils
.
copyProperties
(
bookGroupServe
,
bookServeDTO
);
String
url
=
SendWeixinRequestTools
.
splitUrl
(
accountSettingDto
,
bookGroupServe
.
getServeUrl
());
bookServeDTO
.
setUrl
(
url
);
bookServeDTO
.
setTypeCode
(
bookServeDTO
.
getServeType
());
serveDTOList
.
add
(
bookServeDTO
);
if
(
AppAndProductTypeEnum
.
APP
.
value
.
equals
(
bookServeDTO
.
getServeType
())){
appIds
.
add
(
bookGroupServe
.
getServeId
());
}
else
{
productIds
.
add
(
bookGroupServe
.
getServeId
());
}
}
}
}
//现代纸书二维码配置资源
BookServeParamVO
serveParamVO
=
new
BookServeParamVO
();
serveParamVO
.
setAdviserId
(
adviserId
);
serveParamVO
.
setBookId
(
bookId
);
serveParamVO
.
setChannelId
(
channelId
);
List
<
BookServeVO
>
bookServeVOS
=
qrcodeSceneConsr
.
listBookServeIds
(
serveParamVO
);
if
(!
ListUtils
.
isEmpty
(
bookServeVOS
)){
for
(
BookServeVO
bookServeVO:
bookServeVOS
){
Long
serveId
=
bookServeVO
.
getServeId
();
BookServeDTO
bookServeDTO
=
new
BookServeDTO
();
bookServeDTO
.
setTypeCode
(
bookServeVO
.
getTypeCode
());
String
url
=
SendWeixinRequestTools
.
splitUrl
(
accountSettingDto
,
bookServeVO
.
getUrl
());
if
(
AppAndProductTypeEnum
.
APP
.
value
.
equals
(
bookServeVO
.
getTypeCode
())
&&
!
appIds
.
contains
(
serveId
)){
bookServeDTO
.
setServeId
(
serveId
);
bookServeDTO
.
setServeType
(
bookServeVO
.
getTypeCode
());
bookServeDTO
.
setUrl
(
url
);
serveDTOList
.
add
(
bookServeDTO
);
appIds
.
add
(
serveId
);
}
else
if
(
AppAndProductTypeEnum
.
PRODUCT
.
value
.
equals
(
bookServeVO
.
getTypeCode
())
&&
!
productIds
.
contains
(
serveId
)){
bookServeDTO
.
setServeId
(
serveId
);
bookServeDTO
.
setServeType
(
bookServeVO
.
getTypeCode
());
bookServeDTO
.
setUrl
(
url
);
serveDTOList
.
add
(
bookServeDTO
);
productIds
.
add
(
serveId
);
}
}
}
return
serveDTOList
;
}
private
void
fillBookServe
(
List
<
BookServeDTO
>
serveDTOList
)
{
if
(
ListUtils
.
isEmpty
(
serveDTOList
)){
return
;
}
List
<
Long
>
appIds
=
serveDTOList
.
stream
().
filter
(
s
->
s
.
getServeType
().
equals
(
AppAndProductTypeEnum
.
APP
.
value
)).
map
(
BookServeDTO:
:
getServeId
).
collect
(
Collectors
.
toList
());
List
<
Long
>
productIds
=
serveDTOList
.
stream
().
filter
(
s
->
s
.
getServeType
().
equals
(
AppAndProductTypeEnum
.
PRODUCT
.
value
)).
map
(
BookServeDTO:
:
getServeId
).
collect
(
Collectors
.
toList
());
Map
<
Long
,
ProductDto
>
productDtoMap
=
new
HashMap
<>();
Map
<
Long
,
AppDto
>
appDtoMap
=
new
HashMap
<>();
if
(!
ListUtils
.
isEmpty
(
productIds
))
{
productDtoMap
=
productConsr
.
getProBasesByIds
(
productIds
);
}
if
(!
ListUtils
.
isEmpty
(
appIds
))
{
appDtoMap
=
appConsr
.
mapByIds
(
appIds
);
}
for
(
BookServeDTO
bookServeDTO:
serveDTOList
){
if
(!
MapUtils
.
isEmpty
(
productDtoMap
)
&&
AppAndProductTypeEnum
.
PRODUCT
.
value
.
equals
(
bookServeDTO
.
getServeType
()))
{
ProductDto
productDto
=
productDtoMap
.
get
(
bookServeDTO
.
getServeId
());
if
(
productDto
!=
null
)
{
bookServeDTO
.
setServeName
(
productDto
.
getProductName
());
bookServeDTO
.
setCoverImg
(
productDto
.
getCoverImg
());
ProductTypeDto
productTypeDto
=
productDto
.
getProductTypeDto
();
if
(
productTypeDto
!=
null
)
{
bookServeDTO
.
setFromType
(
productTypeDto
.
getTypeCode
());
bookServeDTO
.
setFromTypeName
(
productTypeDto
.
getTypeName
());
}
}
}
if
(!
MapUtils
.
isEmpty
(
appDtoMap
)
&&
AppAndProductTypeEnum
.
APP
.
value
.
equals
(
bookServeDTO
.
getServeType
()))
{
AppDto
appDto
=
appDtoMap
.
get
(
bookServeDTO
.
getServeId
());
if
(
appDto
!=
null
)
{
bookServeDTO
.
setServeName
(
appDto
.
getTitle
());
bookServeDTO
.
setCoverImg
(
appDto
.
getSquareImg
());
bookServeDTO
.
setFromType
(
appDto
.
getTypeCode
());
bookServeDTO
.
setFromTypeName
(
appDto
.
getTypeName
());
}
}
}
}
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/dto/BookServeDTO.java
0 → 100644
View file @
fa403ebc
package
com
.
pcloud
.
book
.
group
.
dto
;
import
com.pcloud.common.dto.BaseDto
;
import
com.pcloud.common.entity.BaseEntity
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
/**
* @Description
* @Author zhuyajie
* @Date 2020/4/14 17:05
**/
@Data
public
class
BookServeDTO
extends
BaseDto
{
private
static
final
long
serialVersionUID
=
7725930392678110441L
;
@ApiModelProperty
(
"作品或应用id"
)
private
Long
serveId
;
@ApiModelProperty
(
"类型;APP应用,PRODUCT作品"
)
private
String
serveType
;
@ApiModelProperty
(
"应用或作品名称"
)
private
String
serveName
;
@ApiModelProperty
(
"类型"
)
private
String
fromType
;
@ApiModelProperty
(
"类型名称"
)
private
String
fromTypeName
;
@ApiModelProperty
(
"图片地址"
)
private
String
coverImg
;
@ApiModelProperty
(
"链接"
)
private
String
url
;
@ApiModelProperty
(
"类型;APP应用,PRODUCT作品"
)
private
String
typeCode
;
}
pcloud-service-book/src/main/java/com/pcloud/book/group/facade/BookGroupFacade.java
View file @
fa403ebc
...
@@ -704,4 +704,10 @@ public interface BookGroupFacade {
...
@@ -704,4 +704,10 @@ public interface BookGroupFacade {
@ApiOperation
(
"根据小程序id获取信息"
)
@ApiOperation
(
"根据小程序id获取信息"
)
@GetMapping
(
"getByAppletScene"
)
@GetMapping
(
"getByAppletScene"
)
ResponseDto
<?>
getByAppletScene
(
@CookieValue
(
"userInfo"
)
String
userInfo
,
@RequestParam
(
"scene"
)
String
scene
);
ResponseDto
<?>
getByAppletScene
(
@CookieValue
(
"userInfo"
)
String
userInfo
,
@RequestParam
(
"scene"
)
String
scene
);
@ApiOperation
(
"获取小睿社群书和现代纸书所配资源"
)
@GetMapping
(
"getBookAndBookGroupServeList"
)
ResponseDto
<?>
getBookAndBookGroupServeList
(
@RequestParam
(
"adviserId"
)
Long
adviserId
,
@RequestParam
(
"bookId"
)
Long
bookId
,
@RequestParam
(
"channelId"
)
Long
channelId
);
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/facade/impl/BookGroupFacadeImpl.java
View file @
fa403ebc
...
@@ -1134,4 +1134,14 @@ public class BookGroupFacadeImpl implements BookGroupFacade {
...
@@ -1134,4 +1134,14 @@ public class BookGroupFacadeImpl implements BookGroupFacade {
return
new
ResponseDto
<>();
return
new
ResponseDto
<>();
}
}
@Override
@GetMapping
(
"getBookAndBookGroupServeList"
)
public
ResponseDto
<?>
getBookAndBookGroupServeList
(
@RequestParam
(
"adviserId"
)
Long
adviserId
,
@RequestParam
(
"bookId"
)
Long
bookId
,
@RequestParam
(
"channelId"
)
Long
channelId
){
if
(
null
==
adviserId
||
null
==
bookId
||
null
==
channelId
){
throw
new
BookBizException
(
BookBizException
.
PARAM_IS_ERROR
,
"参数缺失!"
);
}
return
new
ResponseDto
<>(
bookGroupBiz
.
getBookAndBookGroupServeList
(
adviserId
,
bookId
,
channelId
));
}
}
}
pcloud-service-book/src/main/resources/mapper/applet/AppletUserBookcase.xml
View file @
fa403ebc
...
@@ -82,6 +82,13 @@
...
@@ -82,6 +82,13 @@
AND from_type = #{fromType}
AND from_type = #{fromType}
</select>
</select>
<delete
id=
"deleteByBookIdUserId"
parameterType=
"com.pcloud.book.applet.entity.AppletUserBookcase"
>
DELETE FROM applet_user_bookcase
WHERE wechat_user_id=#{wechatUserId}
AND book_id=#{bookId}
AND channel_id=#{channelId}
AND adviser_id=#{adviserId}
</delete>
</mapper>
</mapper>
\ 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