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
86baa3d8
Commit
86baa3d8
authored
Mar 23, 2021
by
朱亚洁
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:[1004309]上分MVP课程模块
parent
ca6c2513
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
459 additions
and
1 deletions
+459
-1
BookServeQueryDTO.java
...ain/java/com/pcloud/book/group/dto/BookServeQueryDTO.java
+32
-0
BookGroupService.java
.../java/com/pcloud/book/group/service/BookGroupService.java
+5
-0
pom.xml
pcloud-service-book/pom.xml
+7
-0
ResourceConsr.java
.../java/com/pcloud/book/consumer/content/ResourceConsr.java
+17
-0
ExerciseBookConsr.java
.../pcloud/book/consumer/exercisebook/ExerciseBookConsr.java
+41
-0
BookGroupBiz.java
...src/main/java/com/pcloud/book/group/biz/BookGroupBiz.java
+26
-0
BookGroupBizImpl.java
...java/com/pcloud/book/group/biz/impl/BookGroupBizImpl.java
+195
-0
BookGroupServeDao.java
...ain/java/com/pcloud/book/group/dao/BookGroupServeDao.java
+7
-0
BookGroupServeDaoImpl.java
...com/pcloud/book/group/dao/impl/BookGroupServeDaoImpl.java
+8
-0
BookAppletSceneDTO.java
...in/java/com/pcloud/book/group/dto/BookAppletSceneDTO.java
+4
-1
BookServeDTO.java
...src/main/java/com/pcloud/book/group/dto/BookServeDTO.java
+5
-0
BookGroupServe.java
...ain/java/com/pcloud/book/group/entity/BookGroupServe.java
+2
-0
BookGroupFacadeImpl.java
...om/pcloud/book/group/facade/impl/BookGroupFacadeImpl.java
+13
-0
BookGroupServiceImpl.java
.../pcloud/book/group/service/impl/BookGroupServiceImpl.java
+8
-0
ExerciseBookCourseVO.java
...n/java/com/pcloud/book/group/vo/ExerciseBookCourseVO.java
+29
-0
BookGroupServe.xml
...e-book/src/main/resources/mapper/group/BookGroupServe.xml
+60
-0
No files found.
pcloud-facade-book/src/main/java/com/pcloud/book/group/dto/BookServeQueryDTO.java
0 → 100644
View file @
86baa3d8
package
com
.
pcloud
.
book
.
group
.
dto
;
import
java.util.List
;
import
lombok.Data
;
/**
* @ClassName com.pcloud.book.group.dto.BookServeQueryDTO
* @Author zhuyajie
* @Description 书刊资源
* @Date 2021/3/9 16:16
* @Version 1.0
**/
@Data
public
class
BookServeQueryDTO
{
private
Long
bookId
;
private
Long
channelId
;
private
Long
adviserId
;
private
List
<
String
>
typeCodes
;
private
String
gradeLabelName
;
private
String
subjectLabelName
;
private
Integer
currentPage
;
private
Integer
numPerPage
;
/**
* 上分mvp-课程类型
*/
private
Integer
moduleType
;
}
pcloud-facade-book/src/main/java/com/pcloud/book/group/service/BookGroupService.java
View file @
86baa3d8
...
@@ -9,6 +9,7 @@ import com.pcloud.book.group.dto.BookGroupScanStatisticsRespDTO;
...
@@ -9,6 +9,7 @@ import com.pcloud.book.group.dto.BookGroupScanStatisticsRespDTO;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRequestDTO
;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRequestDTO
;
import
com.pcloud.book.group.dto.BookGroupServeCountDTO
;
import
com.pcloud.book.group.dto.BookGroupServeCountDTO
;
import
com.pcloud.book.group.dto.BookGroupServeDTO
;
import
com.pcloud.book.group.dto.BookGroupServeDTO
;
import
com.pcloud.book.group.dto.BookServeQueryDTO
;
import
com.pcloud.book.group.dto.ErpBookGroupDTO
;
import
com.pcloud.book.group.dto.ErpBookGroupDTO
;
import
com.pcloud.book.group.dto.ErpGroupQrcodeDTO
;
import
com.pcloud.book.group.dto.ErpGroupQrcodeDTO
;
import
com.pcloud.book.group.dto.GroupCipherDTO
;
import
com.pcloud.book.group.dto.GroupCipherDTO
;
...
@@ -255,4 +256,8 @@ public interface BookGroupService {
...
@@ -255,4 +256,8 @@ public interface BookGroupService {
@ApiOperation
(
"获取社群书的扫码统计信息"
)
@ApiOperation
(
"获取社群书的扫码统计信息"
)
@PostMapping
(
"getBookGroupScanStatistics"
)
@PostMapping
(
"getBookGroupScanStatistics"
)
ResponseEntity
<
ResponseDto
<
List
<
BookGroupScanStatisticsRespDTO
>>>
getBookGroupScanStatistics
(
@RequestBody
BookGroupScanStatisticsRequestDTO
reqDTO
);
ResponseEntity
<
ResponseDto
<
List
<
BookGroupScanStatisticsRespDTO
>>>
getBookGroupScanStatistics
(
@RequestBody
BookGroupScanStatisticsRequestDTO
reqDTO
);
@ApiOperation
(
"获取书刊资源配置集合"
)
@RequestMapping
(
value
=
"/getBookGroupServeListByBook"
,
method
=
RequestMethod
.
POST
)
ResponseEntity
<
ResponseDto
<
List
<
BookGroupServeDTO
>>>
getBookGroupServeListByBook
(
@RequestBody
BookServeQueryDTO
bookServeQueryDTO
);
}
}
pcloud-service-book/pom.xml
View file @
86baa3d8
...
@@ -223,6 +223,13 @@
...
@@ -223,6 +223,13 @@
<version>
${pcloud-facade.version}
</version>
<version>
${pcloud-facade.version}
</version>
</dependency>
</dependency>
<dependency>
<groupId>
com.pcloud.facade
</groupId>
<artifactId>
pcloud-facade-exercisebook
</artifactId>
<version>
${pcloud-facade.version}
</version>
</dependency>
<dependency>
<dependency>
<groupId>
fakepath
</groupId>
<groupId>
fakepath
</groupId>
<artifactId>
jbarcode
</artifactId>
<artifactId>
jbarcode
</artifactId>
...
...
pcloud-service-book/src/main/java/com/pcloud/book/consumer/content/ResourceConsr.java
View file @
86baa3d8
package
com
.
pcloud
.
book
.
consumer
.
content
;
package
com
.
pcloud
.
book
.
consumer
.
content
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -10,11 +11,15 @@ import org.springframework.beans.factory.annotation.Autowired;
...
@@ -10,11 +11,15 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.stereotype.Repository
;
import
org.springframework.stereotype.Repository
;
import
com.pcloud.book.base.exception.BookBizException
;
import
com.pcloud.book.base.exception.BookBizException
;
import
com.pcloud.common.core.aspect.ParamLog
;
import
com.pcloud.common.exceptions.BizException
;
import
com.pcloud.common.exceptions.BizException
;
import
com.pcloud.common.utils.ListUtils
;
import
com.pcloud.common.utils.ListUtils
;
import
com.pcloud.common.utils.ResponseHandleUtil
;
import
com.pcloud.common.utils.ResponseHandleUtil
;
import
com.pcloud.contentcenter.resource.dto.ResourceDTO
;
import
com.pcloud.contentcenter.resource.dto.ResourceDTO
;
import
com.pcloud.contentcenter.resource.service.ResourceService
;
import
com.pcloud.contentcenter.resource.service.ResourceService
;
import
com.pcloud.resourcecenter.product.dto.ProductVideoScheduleDTO
;
import
com.pcloud.resourcecenter.product.dto.ProductVideoScheduleQueryDTO
;
import
com.pcloud.resourcecenter.product.service.ProductVideoScheduleService
;
/**
/**
...
@@ -33,6 +38,8 @@ public class ResourceConsr {
...
@@ -33,6 +38,8 @@ public class ResourceConsr {
@Autowired
@Autowired
private
ResourceService
resourceService
;
private
ResourceService
resourceService
;
@Autowired
private
ProductVideoScheduleService
productVideoScheduleService
;
/**
/**
...
@@ -78,4 +85,14 @@ public class ResourceConsr {
...
@@ -78,4 +85,14 @@ public class ResourceConsr {
return
resourceDtos
;
return
resourceDtos
;
}
}
@ParamLog
(
"查视频课-上分mvp"
)
public
List
<
ProductVideoScheduleDTO
>
getProductVideoCourseList4ExerciseBook
(
ProductVideoScheduleQueryDTO
productVideoScheduleQueryDTO
)
{
List
<
ProductVideoScheduleDTO
>
list
=
new
ArrayList
<>();
try
{
list
=
ResponseHandleUtil
.
parseList
(
productVideoScheduleService
.
getProductVideoCourseList4ExerciseBook
(
productVideoScheduleQueryDTO
),
ProductVideoScheduleDTO
.
class
);
}
catch
(
Exception
e
)
{
LOGGER
.
error
(
"调用失败"
+
e
.
getMessage
(),
e
);
}
return
list
;
}
}
}
pcloud-service-book/src/main/java/com/pcloud/book/consumer/exercisebook/ExerciseBookConsr.java
0 → 100644
View file @
86baa3d8
package
com
.
pcloud
.
book
.
consumer
.
exercisebook
;
import
com.pcloud.common.core.aspect.ParamLog
;
import
com.pcloud.common.utils.ResponseHandleUtil
;
import
com.pcloud.exercisebook.dto.CourseModuleDTO
;
import
com.pcloud.exercisebook.service.ExerciseBookService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
import
java.util.HashMap
;
import
java.util.Map
;
import
lombok.extern.slf4j.Slf4j
;
/**
* @ClassName com.pcloud.book.consumer.exercisebook.ExerciseBookConsr
* @Author zhuyajie
* @Description 作业本
* @Date 2021/3/10 10:23
* @Version 1.0
**/
@Slf4j
@Component
public
class
ExerciseBookConsr
{
@Autowired
private
ExerciseBookService
exerciseBookService
;
@ParamLog
(
"查课程模块类型"
)
public
Map
<
Integer
,
CourseModuleDTO
>
getCourseModuleMap
()
{
Map
<
Integer
,
CourseModuleDTO
>
moduleDTOMap
=
new
HashMap
<>();
try
{
moduleDTOMap
=
ResponseHandleUtil
.
parseMap
(
exerciseBookService
.
getCourseModuleMap
(),
Integer
.
class
,
CourseModuleDTO
.
class
);
}
catch
(
Exception
e
)
{
log
.
error
(
"调用exerciseBookService.getCourseModuleMap失败"
+
e
.
getMessage
(),
e
);
}
return
moduleDTOMap
;
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/biz/BookGroupBiz.java
View file @
86baa3d8
...
@@ -16,9 +16,11 @@ import com.pcloud.book.group.dto.BookGroupScanStatisticsRespDTO;
...
@@ -16,9 +16,11 @@ import com.pcloud.book.group.dto.BookGroupScanStatisticsRespDTO;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRequestDTO
;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRequestDTO
;
import
com.pcloud.book.group.dto.BookGroupSceneDTO
;
import
com.pcloud.book.group.dto.BookGroupSceneDTO
;
import
com.pcloud.book.group.dto.BookGroupServeCountDTO
;
import
com.pcloud.book.group.dto.BookGroupServeCountDTO
;
import
com.pcloud.book.group.dto.BookGroupServeDTO
;
import
com.pcloud.book.group.dto.BookGroupStatistic4AgentDTO
;
import
com.pcloud.book.group.dto.BookGroupStatistic4AgentDTO
;
import
com.pcloud.book.group.dto.BookGroupStatisticsDTO
;
import
com.pcloud.book.group.dto.BookGroupStatisticsDTO
;
import
com.pcloud.book.group.dto.BookServeDTO
;
import
com.pcloud.book.group.dto.BookServeDTO
;
import
com.pcloud.book.group.dto.BookServeQueryDTO
;
import
com.pcloud.book.group.dto.BookServeResourceDTO
;
import
com.pcloud.book.group.dto.BookServeResourceDTO
;
import
com.pcloud.book.group.dto.ChangeQrCodeTypeDto
;
import
com.pcloud.book.group.dto.ChangeQrCodeTypeDto
;
import
com.pcloud.book.group.dto.ClassifyKeywordDTO
;
import
com.pcloud.book.group.dto.ClassifyKeywordDTO
;
...
@@ -50,6 +52,7 @@ import com.pcloud.book.group.entity.BookGroupServe;
...
@@ -50,6 +52,7 @@ import com.pcloud.book.group.entity.BookGroupServe;
import
com.pcloud.book.group.entity.WxWechatUserCorrelation
;
import
com.pcloud.book.group.entity.WxWechatUserCorrelation
;
import
com.pcloud.book.group.vo.BookGroupAnalysisParam
;
import
com.pcloud.book.group.vo.BookGroupAnalysisParam
;
import
com.pcloud.book.group.vo.BookGroupAnalysisVO
;
import
com.pcloud.book.group.vo.BookGroupAnalysisVO
;
import
com.pcloud.book.group.vo.ExerciseBookCourseVO
;
import
com.pcloud.book.group.vo.FriendsVO
;
import
com.pcloud.book.group.vo.FriendsVO
;
import
com.pcloud.book.group.vo.GroupIncomeStaticParamVO
;
import
com.pcloud.book.group.vo.GroupIncomeStaticParamVO
;
import
com.pcloud.book.group.vo.GroupScanTrendParamVO
;
import
com.pcloud.book.group.vo.GroupScanTrendParamVO
;
...
@@ -1053,4 +1056,27 @@ public interface BookGroupBiz {
...
@@ -1053,4 +1056,27 @@ public interface BookGroupBiz {
List
<
BookServeDTO
>
getBookAndBookGroupRaysApps
(
Long
adviserId
,
Long
bookId
,
Long
channelId
);
List
<
BookServeDTO
>
getBookAndBookGroupRaysApps
(
Long
adviserId
,
Long
bookId
,
Long
channelId
);
List
<
BookGroupScanStatisticsRespDTO
>
getBookGroupScanStatistics
(
BookGroupScanStatisticsRequestDTO
reqDTO
);
List
<
BookGroupScanStatisticsRespDTO
>
getBookGroupScanStatistics
(
BookGroupScanStatisticsRequestDTO
reqDTO
);
/**
* 获取书刊资源配置集合
* @author:zhuyajie
* @date:2021/3/9 16:20
* * @param null
*/
List
<
BookGroupServeDTO
>
getBookGroupServeListByBook
(
BookServeQueryDTO
bookServeQueryDTO
);
/**
* 上分MVP-课程资源列表
* @author:zhuyajie
* @date:2021/3/9 16:42
* * @param null
*/
PageBeanNew
<
BookServeDTO
>
listPageCourse4ExerciseBook
(
BookServeQueryDTO
bookServeQueryDTO
);
/**
* 上分MVP-课程资源列表
* @author:zhuyajie
* @date:2021/3/11 16:37
* * @param null
*/
List
<
ExerciseBookCourseVO
>
listCourse4ExerciseBook
(
BookServeQueryDTO
bookServeQueryDTO
);
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/biz/impl/BookGroupBizImpl.java
View file @
86baa3d8
...
@@ -46,6 +46,7 @@ import com.pcloud.book.consumer.app.AssistTempletConsr;
...
@@ -46,6 +46,7 @@ import com.pcloud.book.consumer.app.AssistTempletConsr;
import
com.pcloud.book.consumer.channel.QrcodeSceneConsr
;
import
com.pcloud.book.consumer.channel.QrcodeSceneConsr
;
import
com.pcloud.book.consumer.common.ExportConsr
;
import
com.pcloud.book.consumer.common.ExportConsr
;
import
com.pcloud.book.consumer.content.ResourceConsr
;
import
com.pcloud.book.consumer.content.ResourceConsr
;
import
com.pcloud.book.consumer.exercisebook.ExerciseBookConsr
;
import
com.pcloud.book.consumer.message.MessageConsr
;
import
com.pcloud.book.consumer.message.MessageConsr
;
import
com.pcloud.book.consumer.raystask.MainLineConsr
;
import
com.pcloud.book.consumer.raystask.MainLineConsr
;
import
com.pcloud.book.consumer.resource.ProductConsr
;
import
com.pcloud.book.consumer.resource.ProductConsr
;
...
@@ -78,6 +79,8 @@ import com.pcloud.book.group.dao.CopyCipherRecordDao;
...
@@ -78,6 +79,8 @@ import com.pcloud.book.group.dao.CopyCipherRecordDao;
import
com.pcloud.book.group.dao.GroupQrcodeDao
;
import
com.pcloud.book.group.dao.GroupQrcodeDao
;
import
com.pcloud.book.group.dao.GroupQrcodeStyleDao
;
import
com.pcloud.book.group.dao.GroupQrcodeStyleDao
;
import
com.pcloud.book.group.dao.JoinGroupCipherDao
;
import
com.pcloud.book.group.dao.JoinGroupCipherDao
;
import
com.pcloud.book.group.dto.BookGroupServeDTO
;
import
com.pcloud.book.group.dto.BookServeQueryDTO
;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRespDTO
;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRespDTO
;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRequestDTO
;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRequestDTO
;
import
com.pcloud.book.group.dto.HotAppDTO
;
import
com.pcloud.book.group.dto.HotAppDTO
;
...
@@ -170,6 +173,7 @@ import com.pcloud.book.group.vo.BookGroupServeCountVO;
...
@@ -170,6 +173,7 @@ import com.pcloud.book.group.vo.BookGroupServeCountVO;
import
com.pcloud.book.group.vo.ClassifyAndGroupCountVO
;
import
com.pcloud.book.group.vo.ClassifyAndGroupCountVO
;
import
com.pcloud.book.group.vo.ClassifyQrcodeVO
;
import
com.pcloud.book.group.vo.ClassifyQrcodeVO
;
import
com.pcloud.book.group.vo.ExcelDataVO
;
import
com.pcloud.book.group.vo.ExcelDataVO
;
import
com.pcloud.book.group.vo.ExerciseBookCourseVO
;
import
com.pcloud.book.group.vo.FriendsVO
;
import
com.pcloud.book.group.vo.FriendsVO
;
import
com.pcloud.book.group.vo.GroupIncomeStaticParamVO
;
import
com.pcloud.book.group.vo.GroupIncomeStaticParamVO
;
import
com.pcloud.book.group.vo.GroupQrcodeBaseInfoVO
;
import
com.pcloud.book.group.vo.GroupQrcodeBaseInfoVO
;
...
@@ -215,6 +219,7 @@ import com.pcloud.channelcenter.qrcode.dto.QrcodeSceneDto;
...
@@ -215,6 +219,7 @@ 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.BookServeParamVO
;
import
com.pcloud.channelcenter.wechat.dto.MessageDto
;
import
com.pcloud.channelcenter.wechat.dto.MessageDto
;
import
com.pcloud.channelcenter.wechat.entity.AccountSetting
;
import
com.pcloud.channelcenter.wechat.vo.BookServeVO
;
import
com.pcloud.channelcenter.wechat.vo.BookServeVO
;
import
com.pcloud.common.constant.CacheConstant
;
import
com.pcloud.common.constant.CacheConstant
;
import
com.pcloud.common.constant.QrcodeStyleConstant
;
import
com.pcloud.common.constant.QrcodeStyleConstant
;
...
@@ -244,6 +249,7 @@ import com.pcloud.common.utils.httpclient.UrlUtils;
...
@@ -244,6 +249,7 @@ import com.pcloud.common.utils.httpclient.UrlUtils;
import
com.pcloud.common.utils.string.StringUtil
;
import
com.pcloud.common.utils.string.StringUtil
;
import
com.pcloud.common.utils.zip.CompressUtils
;
import
com.pcloud.common.utils.zip.CompressUtils
;
import
com.pcloud.contentcenter.resource.dto.ResourceDTO
;
import
com.pcloud.contentcenter.resource.dto.ResourceDTO
;
import
com.pcloud.exercisebook.dto.CourseModuleDTO
;
import
com.pcloud.facade.tradecenter.dto.ClassifyPayDetailDto
;
import
com.pcloud.facade.tradecenter.dto.ClassifyPayDetailDto
;
import
com.pcloud.facade.tradecenter.dto.GroupIncomeSearchDto
;
import
com.pcloud.facade.tradecenter.dto.GroupIncomeSearchDto
;
import
com.pcloud.facade.tradecenter.dto.GroupMoneyDto
;
import
com.pcloud.facade.tradecenter.dto.GroupMoneyDto
;
...
@@ -258,6 +264,8 @@ import com.pcloud.liveapp.live.service.TimeTableService;
...
@@ -258,6 +264,8 @@ import com.pcloud.liveapp.live.service.TimeTableService;
import
com.pcloud.resourcecenter.product.dto.AddAppProductParamDTO
;
import
com.pcloud.resourcecenter.product.dto.AddAppProductParamDTO
;
import
com.pcloud.resourcecenter.product.dto.ProductDto
;
import
com.pcloud.resourcecenter.product.dto.ProductDto
;
import
com.pcloud.resourcecenter.product.dto.ProductTypeDto
;
import
com.pcloud.resourcecenter.product.dto.ProductTypeDto
;
import
com.pcloud.resourcecenter.product.dto.ProductVideoScheduleDTO
;
import
com.pcloud.resourcecenter.product.dto.ProductVideoScheduleQueryDTO
;
import
com.pcloud.resourcecenter.product.dto.SpecificationDto
;
import
com.pcloud.resourcecenter.product.dto.SpecificationDto
;
import
com.pcloud.resourcecenter.product.dto.UpdateAppProductParamDTO
;
import
com.pcloud.resourcecenter.product.dto.UpdateAppProductParamDTO
;
import
com.pcloud.resourcecenter.product.entity.Product
;
import
com.pcloud.resourcecenter.product.entity.Product
;
...
@@ -489,6 +497,8 @@ public class BookGroupBizImpl implements BookGroupBiz {
...
@@ -489,6 +497,8 @@ public class BookGroupBizImpl implements BookGroupBiz {
private
AssistTempletConsr
assistTempletConsr
;
private
AssistTempletConsr
assistTempletConsr
;
@Autowired
@Autowired
private
WordappConsr
wordappConsr
;
private
WordappConsr
wordappConsr
;
@Autowired
private
ExerciseBookConsr
exerciseBookConsr
;
private
static
final
ThreadPoolExecutor
PLATFORM_STATISTICS_EXPORT_THREAD
=
new
ThreadPoolExecutor
(
2
,
2
,
private
static
final
ThreadPoolExecutor
PLATFORM_STATISTICS_EXPORT_THREAD
=
new
ThreadPoolExecutor
(
2
,
2
,
0
,
TimeUnit
.
SECONDS
,
new
LinkedBlockingQueue
<>(),
0
,
TimeUnit
.
SECONDS
,
new
LinkedBlockingQueue
<>(),
...
@@ -5092,6 +5102,7 @@ public class BookGroupBizImpl implements BookGroupBiz {
...
@@ -5092,6 +5102,7 @@ public class BookGroupBizImpl implements BookGroupBiz {
//权益
//权益
RightsSettingDto
rightsSettingDto
=
rightsSettingBiz
.
getRightsSettingByBookId4AppletHome
(
bookGroupDTO
.
getBookId
(),
bookGroupDTO
.
getCreateUser
(),
bookGroupDTO
.
getChannelId
());
RightsSettingDto
rightsSettingDto
=
rightsSettingBiz
.
getRightsSettingByBookId4AppletHome
(
bookGroupDTO
.
getBookId
(),
bookGroupDTO
.
getCreateUser
(),
bookGroupDTO
.
getChannelId
());
if
(
null
!=
rightsSettingDto
)
{
if
(
null
!=
rightsSettingDto
)
{
dto
.
setRightsSettingId
(
rightsSettingDto
.
getId
());
dto
.
setRightsSettingDetail
(
rightsSettingDto
.
getDetail
());
dto
.
setRightsSettingDetail
(
rightsSettingDto
.
getDetail
());
dto
.
setRightsSettingIntroduce
(
rightsSettingDto
.
getIntroduce
());
dto
.
setRightsSettingIntroduce
(
rightsSettingDto
.
getIntroduce
());
dto
.
setRightsSettingCount
(
rightsSettingDto
.
getCount
());
dto
.
setRightsSettingCount
(
rightsSettingDto
.
getCount
());
...
@@ -6678,6 +6689,190 @@ public class BookGroupBizImpl implements BookGroupBiz {
...
@@ -6678,6 +6689,190 @@ public class BookGroupBizImpl implements BookGroupBiz {
}
}
@Override
@Override
public
List
<
BookGroupServeDTO
>
getBookGroupServeListByBook
(
BookServeQueryDTO
bookServeQueryDTO
)
{
if
(
null
==
bookServeQueryDTO
||
null
==
bookServeQueryDTO
.
getBookId
()
||
null
==
bookServeQueryDTO
.
getChannelId
()
||
null
==
bookServeQueryDTO
.
getAdviserId
())
{
return
new
ArrayList
<>();
}
List
<
BookGroupServe
>
bookGroupServes
=
bookGroupServeDao
.
getServeListByBookAndType
(
bookServeQueryDTO
.
getBookId
(),
bookServeQueryDTO
.
getChannelId
(),
bookServeQueryDTO
.
getAdviserId
(),
bookServeQueryDTO
.
getTypeCodes
());
if
(
ListUtils
.
isEmpty
(
bookGroupServes
))
{
return
new
ArrayList
<>();
}
List
<
BookGroupServeDTO
>
serveDTOList
=
new
ArrayList
<>();
BeanUtils
.
copyListProperties
(
bookGroupServes
,
serveDTOList
,
BookGroupServeDTO
.
class
);
return
serveDTOList
;
}
@Override
public
PageBeanNew
<
BookServeDTO
>
listPageCourse4ExerciseBook
(
BookServeQueryDTO
bookServeQueryDTO
)
{
if
(
null
==
bookServeQueryDTO
||
null
==
bookServeQueryDTO
.
getCurrentPage
()
||
null
==
bookServeQueryDTO
.
getNumPerPage
())
{
throw
new
BookBizException
(
BookBizException
.
PARAM_IS_NULL
,
"分页参数缺失"
);
}
if
(
null
==
bookServeQueryDTO
.
getModuleType
())
{
throw
new
BookBizException
(
BookBizException
.
PARAM_IS_NULL
,
"模块类型缺失"
);
}
if
(
StringUtil
.
isEmpty
(
bookServeQueryDTO
.
getSubjectLabelName
())
||
StringUtil
.
isEmpty
(
bookServeQueryDTO
.
getGradeLabelName
()))
{
throw
new
BookBizException
(
BookBizException
.
PARAM_IS_NULL
,
"标签参数缺失"
);
}
Map
<
Integer
,
CourseModuleDTO
>
moduleDTOMap
=
exerciseBookConsr
.
getCourseModuleMap
();
if
(
MapUtils
.
isEmpty
(
moduleDTOMap
)
||
!
moduleDTOMap
.
containsKey
(
bookServeQueryDTO
.
getModuleType
()))
{
return
new
PageBeanNew
<>();
}
CourseModuleDTO
moduleDTO
=
moduleDTOMap
.
get
(
bookServeQueryDTO
.
getModuleType
());
final
Long
channelId
=
moduleDTO
.
getChannelId
();
final
Long
adviserId
=
moduleDTO
.
getAdviserId
();
final
Long
bookId
=
moduleDTO
.
getBookId
();
List
<
String
>
typeCodes
=
Arrays
.
asList
(
ProductTypeConstant
.
VIDEO_SCHEDULE
);
List
<
BookGroupServe
>
bookGroupServes
=
bookGroupServeDao
.
getServeListByBookAndType
(
bookId
,
channelId
,
adviserId
,
typeCodes
);
if
(
ListUtils
.
isEmpty
(
bookGroupServes
))
{
return
new
PageBeanNew
<>();
}
List
<
Long
>
productIds
=
bookGroupServes
.
stream
().
filter
(
s
->
s
.
getServeType
().
equals
(
AppAndProductTypeEnum
.
PRODUCT
.
value
)).
map
(
BookGroupServe:
:
getServeId
).
distinct
().
collect
(
Collectors
.
toList
());
//资源中心查询
ProductVideoScheduleQueryDTO
productVideoScheduleQueryDTO
=
new
ProductVideoScheduleQueryDTO
();
productVideoScheduleQueryDTO
.
setChannelId
(
channelId
);
productVideoScheduleQueryDTO
.
setProductIds
(
productIds
);
productVideoScheduleQueryDTO
.
setGradeLabelName
(
bookServeQueryDTO
.
getGradeLabelName
());
productVideoScheduleQueryDTO
.
setSubjectLabelName
(
bookServeQueryDTO
.
getSubjectLabelName
());
List
<
ProductVideoScheduleDTO
>
scheduleDTOS
=
resourceConsr
.
getProductVideoCourseList4ExerciseBook
(
productVideoScheduleQueryDTO
);
if
(
ListUtils
.
isEmpty
(
scheduleDTOS
))
{
return
new
PageBeanNew
<>();
}
//根据筛选条件bookGroupServe查询
List
<
Long
>
serveIds
=
scheduleDTOS
.
stream
().
map
(
ProductVideoScheduleDTO:
:
getProductId
).
collect
(
Collectors
.
toList
());
Map
<
String
,
Object
>
paramMap
=
new
HashMap
<>();
paramMap
.
put
(
"adviserId"
,
adviserId
);
paramMap
.
put
(
"bookId"
,
bookId
);
paramMap
.
put
(
"channelId"
,
channelId
);
paramMap
.
put
(
"serveIds"
,
serveIds
);
PageBeanNew
<
BookGroupServe
>
servePageBeanNew
=
bookGroupServeDao
.
listPageNew
(
new
PageParam
(
bookServeQueryDTO
.
getCurrentPage
(),
bookServeQueryDTO
.
getNumPerPage
()),
paramMap
,
"listServeListByBook"
);
if
(
ListUtils
.
isEmpty
(
servePageBeanNew
.
getRecordList
()))
{
return
new
PageBeanNew
<>();
}
List
<
BookServeDTO
>
serveDTOList
=
fillServeCourse4ExerciseBook
(
servePageBeanNew
.
getRecordList
(),
channelId
,
scheduleDTOS
);
PageBeanNew
<
BookServeDTO
>
pageBeanNew
=
new
PageBeanNew
<>(
bookServeQueryDTO
.
getCurrentPage
(),
bookServeQueryDTO
.
getNumPerPage
(),
servePageBeanNew
.
getTotalCount
(),
serveDTOList
);
return
pageBeanNew
;
}
private
List
<
BookServeDTO
>
fillServeCourse4ExerciseBook
(
List
<
BookGroupServe
>
serveList
,
Long
channelId
,
List
<
ProductVideoScheduleDTO
>
scheduleDTOS
)
{
if
(
ListUtils
.
isEmpty
(
serveList
))
{
return
new
ArrayList
<>();
}
List
<
Long
>
serveIds
=
serveList
.
stream
().
map
(
BookGroupServe:
:
getServeId
).
distinct
().
collect
(
Collectors
.
toList
());
//课程数量
Map
<
Long
,
Integer
>
courseNumMap
=
ResponseHandleUtil
.
parseMap
(
scheduleService
.
countAuditResourceByProductIds
(
serveIds
),
Long
.
class
,
Integer
.
class
);
//上分MVP公众号
AccountSetting
accountSetting
=
channelConsr
.
getAppInfo
(
66108L
);
//课程信息
Map
<
Long
,
List
<
ProductVideoScheduleDTO
>>
videoScheduleDTOMap
=
scheduleDTOS
.
stream
().
collect
(
Collectors
.
groupingBy
(
ProductVideoScheduleDTO:
:
getProductId
));
List
<
BookServeDTO
>
serveDTOList
=
new
ArrayList
<>();
for
(
BookGroupServe
bookGroupServe:
serveList
)
{
BookServeDTO
bookServeDTO
=
new
BookServeDTO
();
BeanUtils
.
copyProperties
(
bookGroupServe
,
bookServeDTO
);
bookServeDTO
.
setUrl
(
bookGroupServe
.
getServeUrl
());
bookServeDTO
.
setTypeCode
(
bookGroupServe
.
getServeType
());
bookServeDTO
.
setFromType
(
bookGroupServe
.
getTypeCode
());
List
<
ProductVideoScheduleDTO
>
dtos
=
videoScheduleDTOMap
.
get
(
bookGroupServe
.
getServeId
());
if
(!
ListUtils
.
isEmpty
(
dtos
))
{
ProductVideoScheduleDTO
dto
=
dtos
.
get
(
0
);
bookServeDTO
.
setServeName
(
dto
.
getProductName
());
bookServeDTO
.
setCoverImg
(
dto
.
getCoverImg
());
bookServeDTO
.
setTransverseImg
(
dto
.
getPicture1
());
bookServeDTO
.
setPrice
(
dto
.
getRetailPrice
());
}
if
(
null
!=
accountSetting
)
{
AccountSettingDto
accountSettingDto
=
new
AccountSettingDto
();
BeanUtils
.
copyProperties
(
accountSetting
,
accountSettingDto
);
String
resultLinkUrl
=
SendWeixinRequestTools
.
splitUrl
(
accountSettingDto
,
bookGroupServe
.
getServeUrl
());
bookServeDTO
.
setResultUrl
(
resultLinkUrl
);
}
if
(!
MapUtils
.
isEmpty
(
courseNumMap
)
&&
courseNumMap
.
containsKey
(
bookGroupServe
.
getServeId
()))
{
bookServeDTO
.
setCourseNum
(
courseNumMap
.
get
(
bookGroupServe
.
getServeId
()));
}
else
{
bookServeDTO
.
setCourseNum
(
0
);
}
serveDTOList
.
add
(
bookServeDTO
);
}
return
serveDTOList
;
}
@Override
public
List
<
ExerciseBookCourseVO
>
listCourse4ExerciseBook
(
BookServeQueryDTO
bookServeQueryDTO
)
{
if
(
StringUtil
.
isEmpty
(
bookServeQueryDTO
.
getSubjectLabelName
())
||
StringUtil
.
isEmpty
(
bookServeQueryDTO
.
getGradeLabelName
()))
{
throw
new
BookBizException
(
BookBizException
.
PARAM_IS_NULL
,
"标签参数缺失"
);
}
Map
<
Integer
,
CourseModuleDTO
>
moduleDTOMap
=
exerciseBookConsr
.
getCourseModuleMap
();
if
(
MapUtils
.
isEmpty
(
moduleDTOMap
))
{
return
new
ArrayList
<>();
}
Map
<
Long
,
CourseModuleDTO
>
bookModuleMap
=
new
HashMap
<>();
Long
channelId
=
null
;
List
<
Long
>
bookIds
=
new
ArrayList
<>();
for
(
Map
.
Entry
<
Integer
,
CourseModuleDTO
>
entry:
moduleDTOMap
.
entrySet
())
{
bookIds
.
add
(
entry
.
getValue
().
getBookId
());
channelId
=
entry
.
getValue
().
getChannelId
();
bookModuleMap
.
put
(
entry
.
getValue
().
getBookId
(),
entry
.
getValue
());
}
//所有资源
List
<
BookGroupServe
>
bookGroupServes
=
bookGroupServeDao
.
getServeListByBookList
(
bookIds
,
Arrays
.
asList
(
ProductTypeConstant
.
VIDEO_SCHEDULE
));
if
(
ListUtils
.
isEmpty
(
bookGroupServes
))
{
return
new
ArrayList
<>();
}
//标签筛选
List
<
Long
>
productIds
=
bookGroupServes
.
stream
().
filter
(
s
->
s
.
getServeType
().
equals
(
AppAndProductTypeEnum
.
PRODUCT
.
value
)).
distinct
().
map
(
BookGroupServe:
:
getServeId
).
distinct
().
collect
(
Collectors
.
toList
());
ProductVideoScheduleQueryDTO
productVideoScheduleQueryDTO
=
new
ProductVideoScheduleQueryDTO
();
productVideoScheduleQueryDTO
.
setChannelId
(
channelId
);
productVideoScheduleQueryDTO
.
setProductIds
(
productIds
);
productVideoScheduleQueryDTO
.
setGradeLabelName
(
bookServeQueryDTO
.
getGradeLabelName
());
productVideoScheduleQueryDTO
.
setSubjectLabelName
(
bookServeQueryDTO
.
getSubjectLabelName
());
List
<
ProductVideoScheduleDTO
>
scheduleDTOS
=
resourceConsr
.
getProductVideoCourseList4ExerciseBook
(
productVideoScheduleQueryDTO
);
if
(
ListUtils
.
isEmpty
(
scheduleDTOS
))
{
return
new
ArrayList
<>();
}
List
<
Long
>
serveIds
=
scheduleDTOS
.
stream
().
map
(
ProductVideoScheduleDTO:
:
getProductId
).
collect
(
Collectors
.
toList
());
//数据筛选
Map
<
Long
,
List
<
BookGroupServe
>>
listMap
=
bookGroupServes
.
stream
().
collect
(
Collectors
.
groupingBy
(
BookGroupServe:
:
getBookId
));
Map
<
Long
,
Integer
>
serveCountMap
=
new
HashMap
<>();
List
<
BookGroupServe
>
serveList
=
new
ArrayList
<>();
for
(
Map
.
Entry
<
Long
,
List
<
BookGroupServe
>>
entry:
listMap
.
entrySet
())
{
List
<
BookGroupServe
>
list
=
new
ArrayList
<>();
CourseModuleDTO
moduleDTO
=
bookModuleMap
.
get
(
entry
.
getKey
());
List
<
Integer
>
top10Modules
=
Arrays
.
asList
(
6
,
7
);
for
(
BookGroupServe
groupServe:
entry
.
getValue
())
{
if
(
top10Modules
.
contains
(
moduleDTO
.
getModuleType
()))
{
//热门课程Top10
if
(
list
.
size
()>=
10
)
{
break
;
}
}
else
if
(
list
.
size
()>=
2
)
{
//每个模块最多两个展示课程
break
;
}
if
(
serveIds
.
contains
(
groupServe
.
getServeId
()))
{
list
.
add
(
groupServe
);
}
}
serveList
.
addAll
(
list
);
List
<
Long
>
serves
=
entry
.
getValue
().
stream
().
filter
(
s
->
serveIds
.
contains
(
s
.
getServeId
())).
map
(
BookGroupServe:
:
getServeId
).
distinct
().
collect
(
Collectors
.
toList
());
serveCountMap
.
put
(
entry
.
getKey
(),
serves
.
size
());
}
List
<
BookServeDTO
>
serveDTOList
=
fillServeCourse4ExerciseBook
(
serveList
,
channelId
,
scheduleDTOS
);
Map
<
Long
,
List
<
BookServeDTO
>>
bookServeMap
=
serveDTOList
.
stream
().
collect
(
Collectors
.
groupingBy
(
BookServeDTO:
:
getBookId
));
List
<
ExerciseBookCourseVO
>
resultList
=
new
ArrayList
<>();
for
(
Map
.
Entry
<
Long
,
List
<
BookServeDTO
>>
entry:
bookServeMap
.
entrySet
())
{
CourseModuleDTO
moduleDTO
=
bookModuleMap
.
get
(
entry
.
getKey
());
ExerciseBookCourseVO
courseVO
=
new
ExerciseBookCourseVO
();
courseVO
.
setModuleType
(
moduleDTO
.
getModuleType
());
courseVO
.
setModuleName
(
moduleDTO
.
getModuleName
());
courseVO
.
setBookServeDTOS
(
entry
.
getValue
());
courseVO
.
setServeCount
(
serveCountMap
.
get
(
entry
.
getKey
()));
resultList
.
add
(
courseVO
);
}
return
resultList
;
}
@Override
public
List
<
BookGroupScanStatisticsRespDTO
>
getBookGroupScanStatistics
(
BookGroupScanStatisticsRequestDTO
reqDTO
)
{
public
List
<
BookGroupScanStatisticsRespDTO
>
getBookGroupScanStatistics
(
BookGroupScanStatisticsRequestDTO
reqDTO
)
{
if
(
ObjectUtil
.
hasEmpty
(
reqDTO
,
reqDTO
.
getBookIds
(),
reqDTO
.
getAdviserIds
(),
reqDTO
.
getChannelIds
(),
reqDTO
.
getStart
(),
reqDTO
.
getEnd
()))
if
(
ObjectUtil
.
hasEmpty
(
reqDTO
,
reqDTO
.
getBookIds
(),
reqDTO
.
getAdviserIds
(),
reqDTO
.
getChannelIds
(),
reqDTO
.
getStart
(),
reqDTO
.
getEnd
()))
return
new
ArrayList
<>();
return
new
ArrayList
<>();
...
...
pcloud-service-book/src/main/java/com/pcloud/book/group/dao/BookGroupServeDao.java
View file @
86baa3d8
...
@@ -112,4 +112,11 @@ public interface BookGroupServeDao extends BaseDao<BookGroupServe> {
...
@@ -112,4 +112,11 @@ public interface BookGroupServeDao extends BaseDao<BookGroupServe> {
* * @param null
* * @param null
*/
*/
List
<
BookGroupServe
>
getServeListByBookAndType
(
Long
bookId
,
Long
channelId
,
Long
adviserId
,
List
<
String
>
typeCodes
);
List
<
BookGroupServe
>
getServeListByBookAndType
(
Long
bookId
,
Long
channelId
,
Long
adviserId
,
List
<
String
>
typeCodes
);
/**
* 查资源配置
* @author:zhuyajie
* @date:2021/3/11 16:59
* * @param null
*/
List
<
BookGroupServe
>
getServeListByBookList
(
List
<
Long
>
bookIds
,
List
<
String
>
typeCodes
);
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/dao/impl/BookGroupServeDaoImpl.java
View file @
86baa3d8
...
@@ -223,4 +223,12 @@ public class BookGroupServeDaoImpl extends BaseDaoImpl<BookGroupServe> implement
...
@@ -223,4 +223,12 @@ public class BookGroupServeDaoImpl extends BaseDaoImpl<BookGroupServe> implement
map
.
put
(
"typeCodes"
,
typeCodes
);
map
.
put
(
"typeCodes"
,
typeCodes
);
return
getSessionTemplate
().
selectList
(
getStatement
(
"getServeListByBookAndType"
),
map
);
return
getSessionTemplate
().
selectList
(
getStatement
(
"getServeListByBookAndType"
),
map
);
}
}
@Override
public
List
<
BookGroupServe
>
getServeListByBookList
(
List
<
Long
>
bookIds
,
List
<
String
>
typeCodes
)
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"bookIds"
,
bookIds
);
map
.
put
(
"typeCodes"
,
typeCodes
);
return
getSessionTemplate
().
selectList
(
getStatement
(
"getServeListByBookList"
),
map
);
}
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/dto/BookAppletSceneDTO.java
View file @
86baa3d8
...
@@ -57,5 +57,8 @@ public class BookAppletSceneDTO extends BaseDto {
...
@@ -57,5 +57,8 @@ public class BookAppletSceneDTO extends BaseDto {
* 现代纸书自建码的id
* 现代纸书自建码的id
*/
*/
private
Long
sceneId
;
private
Long
sceneId
;
/**
*权益id
*/
private
Long
rightsSettingId
;
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/dto/BookServeDTO.java
View file @
86baa3d8
...
@@ -51,4 +51,9 @@ public class BookServeDTO extends BaseDto {
...
@@ -51,4 +51,9 @@ public class BookServeDTO extends BaseDto {
@ApiModelProperty
(
"跳转结果链接"
)
@ApiModelProperty
(
"跳转结果链接"
)
private
String
resultUrl
;
private
String
resultUrl
;
@ApiModelProperty
(
"课程数量"
)
private
Integer
courseNum
;
private
Long
bookId
;
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/entity/BookGroupServe.java
View file @
86baa3d8
...
@@ -66,4 +66,6 @@ public class BookGroupServe extends BaseEntity {
...
@@ -66,4 +66,6 @@ public class BookGroupServe extends BaseEntity {
@ApiModelProperty
(
"类型"
)
@ApiModelProperty
(
"类型"
)
private
String
typeCode
;
private
String
typeCode
;
private
Long
bookId
;
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/facade/impl/BookGroupFacadeImpl.java
View file @
86baa3d8
...
@@ -13,6 +13,7 @@ import com.pcloud.book.group.dto.BackgroundGroupQrcodeDTO;
...
@@ -13,6 +13,7 @@ import com.pcloud.book.group.dto.BackgroundGroupQrcodeDTO;
import
com.pcloud.book.group.dto.BookAppletSceneDTO
;
import
com.pcloud.book.group.dto.BookAppletSceneDTO
;
import
com.pcloud.book.group.dto.BookGroupCreateDTO
;
import
com.pcloud.book.group.dto.BookGroupCreateDTO
;
import
com.pcloud.book.group.dto.BookGroupDTO
;
import
com.pcloud.book.group.dto.BookGroupDTO
;
import
com.pcloud.book.group.dto.BookServeQueryDTO
;
import
com.pcloud.book.group.dto.ChangeQrCodeTypeDto
;
import
com.pcloud.book.group.dto.ChangeQrCodeTypeDto
;
import
com.pcloud.book.group.dto.GroupStoreMyPayDto
;
import
com.pcloud.book.group.dto.GroupStoreMyPayDto
;
import
com.pcloud.book.group.dto.HotAppDTO
;
import
com.pcloud.book.group.dto.HotAppDTO
;
...
@@ -1406,4 +1407,16 @@ public class BookGroupFacadeImpl implements BookGroupFacade {
...
@@ -1406,4 +1407,16 @@ public class BookGroupFacadeImpl implements BookGroupFacade {
@RequestParam
(
"adviserId"
)
Long
adviserId
,
@RequestParam
(
"bookId"
)
Long
bookId
,
@RequestParam
(
"channelId"
)
Long
channelId
){
@RequestParam
(
"adviserId"
)
Long
adviserId
,
@RequestParam
(
"bookId"
)
Long
bookId
,
@RequestParam
(
"channelId"
)
Long
channelId
){
return
new
ResponseDto
<>(
bookGroupBiz
.
getBookAndBookGroupRaysApps
(
adviserId
,
bookId
,
channelId
));
return
new
ResponseDto
<>(
bookGroupBiz
.
getBookAndBookGroupRaysApps
(
adviserId
,
bookId
,
channelId
));
}
}
@ApiOperation
(
"上分MVP-根据模块查课程资源列表"
)
@PostMapping
(
"listPageCourse4ExerciseBook"
)
public
ResponseDto
<?>
listPageCourse4ExerciseBook
(
@RequestBody
BookServeQueryDTO
bookServeQueryDTO
)
{
return
new
ResponseDto
<>(
bookGroupBiz
.
listPageCourse4ExerciseBook
(
bookServeQueryDTO
));
}
@ApiOperation
(
"上分MVP-课程列表"
)
@PostMapping
(
"listCourse4ExerciseBook"
)
public
ResponseDto
<?>
listCourse4ExerciseBook
(
@RequestBody
BookServeQueryDTO
bookServeQueryDTO
)
{
return
new
ResponseDto
<>(
bookGroupBiz
.
listCourse4ExerciseBook
(
bookServeQueryDTO
));
}
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/service/impl/BookGroupServiceImpl.java
View file @
86baa3d8
...
@@ -11,6 +11,7 @@ import com.pcloud.book.group.dto.BookGroupScanStatisticsRespDTO;
...
@@ -11,6 +11,7 @@ import com.pcloud.book.group.dto.BookGroupScanStatisticsRespDTO;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRequestDTO
;
import
com.pcloud.book.group.dto.BookGroupScanStatisticsRequestDTO
;
import
com.pcloud.book.group.dto.BookGroupServeCountDTO
;
import
com.pcloud.book.group.dto.BookGroupServeCountDTO
;
import
com.pcloud.book.group.dto.BookGroupServeDTO
;
import
com.pcloud.book.group.dto.BookGroupServeDTO
;
import
com.pcloud.book.group.dto.BookServeQueryDTO
;
import
com.pcloud.book.group.dto.ErpBookGroupDTO
;
import
com.pcloud.book.group.dto.ErpBookGroupDTO
;
import
com.pcloud.book.group.dto.ErpGroupQrcodeDTO
;
import
com.pcloud.book.group.dto.ErpGroupQrcodeDTO
;
import
com.pcloud.book.group.dto.GroupCipherDTO
;
import
com.pcloud.book.group.dto.GroupCipherDTO
;
...
@@ -444,4 +445,11 @@ public class BookGroupServiceImpl implements BookGroupService {
...
@@ -444,4 +445,11 @@ public class BookGroupServiceImpl implements BookGroupService {
public
ResponseEntity
<
ResponseDto
<
List
<
BookGroupScanStatisticsRespDTO
>>>
getBookGroupScanStatistics
(
@RequestBody
BookGroupScanStatisticsRequestDTO
reqDTO
)
{
public
ResponseEntity
<
ResponseDto
<
List
<
BookGroupScanStatisticsRespDTO
>>>
getBookGroupScanStatistics
(
@RequestBody
BookGroupScanStatisticsRequestDTO
reqDTO
)
{
return
ResponseHandleUtil
.
toResponse
(
bookGroupBiz
.
getBookGroupScanStatistics
(
reqDTO
));
return
ResponseHandleUtil
.
toResponse
(
bookGroupBiz
.
getBookGroupScanStatistics
(
reqDTO
));
}
}
@Override
@RequestMapping
(
value
=
"/getBookGroupServeListByBook"
,
method
=
RequestMethod
.
POST
)
public
ResponseEntity
<
ResponseDto
<
List
<
BookGroupServeDTO
>>>
getBookGroupServeListByBook
(
@RequestBody
BookServeQueryDTO
bookServeQueryDTO
)
{
List
<
BookGroupServeDTO
>
bookGroupServeDTOS
=
bookGroupBiz
.
getBookGroupServeListByBook
(
bookServeQueryDTO
);
return
ResponseHandleUtil
.
toResponse
(
bookGroupServeDTOS
);
}
}
}
pcloud-service-book/src/main/java/com/pcloud/book/group/vo/ExerciseBookCourseVO.java
0 → 100644
View file @
86baa3d8
package
com
.
pcloud
.
book
.
group
.
vo
;
import
com.pcloud.book.group.dto.BookServeDTO
;
import
com.pcloud.common.dto.BaseDto
;
import
java.util.List
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
/**
* @ClassName com.pcloud.book.group.vo.ExerciseBookCourseVO
* @Author zhuyajie
* @Description 上分mvp课程
* @Date 2021/3/16 9:52
* @Version 1.0
**/
@Data
public
class
ExerciseBookCourseVO
extends
BaseDto
{
@ApiModelProperty
(
"模块类型"
)
private
Integer
moduleType
;
@ApiModelProperty
(
"模块名称"
)
private
String
moduleName
;
@ApiModelProperty
(
"资源"
)
private
List
<
BookServeDTO
>
bookServeDTOS
;
@ApiModelProperty
(
"资源总数"
)
private
Integer
serveCount
;
}
pcloud-service-book/src/main/resources/mapper/group/BookGroupServe.xml
View file @
86baa3d8
...
@@ -377,4 +377,64 @@
...
@@ -377,4 +377,64 @@
GROUP BY bookId, channelId, adviserId
GROUP BY bookId, channelId, adviserId
</select>
</select>
<select
id=
"listServeListByBook"
parameterType=
"map"
resultMap=
"BaseResultMap"
>
SELECT
s.id,
s.serve_id,
s.serve_type,
s.serve_url,
s.short_url,
s.book_group_id,
s.create_user,
s.create_time,
s.type_code
FROM
book_group_serve s
LEFT JOIN book_group g ON s.book_group_id = g.id
WHERE
g.book_id = #{bookId}
AND g.channel_id = #{channelId}
AND g.create_user = #{adviserId}
<if
test=
"serveIds != null and serveIds.size>0"
>
AND s.serve_id in
<foreach
collection=
"serveIds"
index=
"index"
item=
"serveId"
close=
")"
open=
"("
separator=
","
>
${serveId}
</foreach>
</if>
GROUP BY
s.serve_id
ORDER BY
s.id
</select>
<select
id=
"getServeListByBookList"
parameterType=
"map"
resultMap=
"BaseResultMap"
>
SELECT
s.id,
s.serve_id,
s.serve_type,
s.serve_url,
s.short_url,
s.book_group_id,
s.create_user,
s.create_time,
s.type_code,
g.book_id bookId
FROM
book_group_serve s
LEFT JOIN book_group g ON s.book_group_id = g.id
WHERE 1=1
<if
test=
"bookIds != null and bookIds.size>0"
>
AND g.book_id in
<foreach
collection=
"bookIds"
index=
"index"
close=
")"
open=
"("
separator=
","
item =
"bookId"
>
#{bookId}
</foreach>
</if>
<if
test=
"typeCodes != null and typeCodes.size>0"
>
AND s.type_code IN
<foreach
collection=
"typeCodes"
open=
"("
close=
")"
item=
"typeCode"
index=
"index"
separator=
","
>
#{typeCode}
</foreach>
</if>
ORDER BY
s.id
</select>
</mapper>
</mapper>
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