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
fa2cd2b4
Commit
fa2cd2b4
authored
May 08, 2020
by
郑永强
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【1002844】2.书刊权益新增和修改,默认代入书刊对应权益的基本信息
parent
15cb709c
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
39 additions
and
2 deletions
+39
-2
BookBizImpl.java
.../main/java/com/pcloud/book/book/biz/impl/BookBizImpl.java
+5
-0
RightsSettingBiz.java
...a/com/pcloud/book/rightsSetting/biz/RightsSettingBiz.java
+2
-0
RightsSettingBizImpl.java
...oud/book/rightsSetting/biz/impl/RightsSettingBizImpl.java
+4
-0
RightsSettingFacede.java
...pcloud/book/rightsSetting/facade/RightsSettingFacede.java
+12
-0
Book.Mapper.xml
...rvice-book/src/main/resources/mapper/book/Book.Mapper.xml
+16
-2
No files found.
pcloud-service-book/src/main/java/com/pcloud/book/book/biz/impl/BookBizImpl.java
View file @
fa2cd2b4
...
...
@@ -1986,6 +1986,11 @@ public class BookBizImpl implements BookBiz {
map
.
put
(
"adviserIds"
,
adviserIds
);
}
}
if
(!
StringUtil
.
isEmpty
(
keyword
))
{
// 模糊匹配编辑名称
List
<
Long
>
adviserIds
=
adviserConsr
.
getAdviserIdsByName
(
keyword
);
map
.
put
(
"adviserIds4Name"
,
adviserIds
);
}
PageBeanNew
<
BookDto
>
page
=
bookDao
.
listPageNew
(
new
PageParam
(
currentPage
,
numPerPage
),
map
,
"getAdviserBooks4Pcloud"
,
"getAdviserBooksCount4Pcloud"
);
fillBookInfo
(
page
.
getRecordList
());
if
(!
ListUtils
.
isEmpty
(
page
.
getRecordList
()))
{
...
...
pcloud-service-book/src/main/java/com/pcloud/book/rightsSetting/biz/RightsSettingBiz.java
View file @
fa2cd2b4
...
...
@@ -105,6 +105,8 @@ public interface RightsSettingBiz {
List
<
RightsItemGroup
>
getRightsItemGroups
(
Long
rightsSettingId
,
Long
adviserId
,
Long
bookId
,
Long
channelId
,
Boolean
removeCanNotBuy
);
RightsSettingDto
getRightSettingByBookId
(
Long
bookId
,
Long
adviserId
,
Long
channelId
);
List
<
RightsNowPic
>
getAllDefaultRightsNowPics
();
void
addRightsNowPic
(
RightsNowPic
rightsNowPic
);
...
...
pcloud-service-book/src/main/java/com/pcloud/book/rightsSetting/biz/impl/RightsSettingBizImpl.java
View file @
fa2cd2b4
...
...
@@ -966,16 +966,20 @@ public class RightsSettingBizImpl implements RightsSettingBiz {
baseTempletClassify
.
setGradeLabelId
(
bookAdviserDto
.
getGraLabelId
());
baseTempletClassify
.
setSubjectLabelId
(
bookAdviserDto
.
getSubLabelId
());
setClassifyAndLabel
(
baseTempletClassify
);
if
(
NumberUtil
.
isNumber
(
baseTempletClassify
.
getFirstClassify
())){
// 通过书刊分类拿群
groupActivity4AppletDTO
=
pcloudGroupActivityDao
.
getGroupActivity4Applet
(
baseTempletClassify
.
getFirstClassify
(),
baseTempletClassify
.
getSecondClassify
(),
baseTempletClassify
.
getGradeLabelId
(),
baseTempletClassify
.
getSubjectLabelId
());
}
}
if
(
groupActivity4AppletDTO
==
null
){
// 如果书刊没拿到群,则通过权益分类拿群
RightsSetting
rightsSetting
=
rightsSettingDAO
.
selectByPrimaryKey
(
list
.
get
(
0
).
getRightsSettingId
());
setClassifyAndLabel
(
rightsSetting
);
if
(
NumberUtil
.
isNumber
(
rightsSetting
.
getFirstClassify
())){
groupActivity4AppletDTO
=
pcloudGroupActivityDao
.
getGroupActivity4Applet
(
rightsSetting
.
getFirstClassify
(),
rightsSetting
.
getSecondClassify
(),
rightsSetting
.
getGradeLabelId
(),
rightsSetting
.
getSubjectLabelId
());
}
}
if
(
groupActivity4AppletDTO
!=
null
){
String
filterStr
=
StringUtilParent
.
replaceHtml
(
groupActivity4AppletDTO
.
getDesc
());
String
subStr
=
filterStr
.
length
()
>
60
?
filterStr
.
substring
(
0
,
60
)
+
"..."
:
filterStr
;
...
...
pcloud-service-book/src/main/java/com/pcloud/book/rightsSetting/facade/RightsSettingFacede.java
View file @
fa2cd2b4
...
...
@@ -202,6 +202,18 @@ public class RightsSettingFacede {
return
new
ResponseDto
<>(
rightsSettingBiz
.
getRightsItemGroups
(
rightsSettingId
,
adviserId
,
bookId
,
channelId
,
true
));
}
@ApiOperation
(
"根据书刊的分类获取对应的分类权益信息"
)
@GetMapping
(
"getRightSettingByBookId"
)
public
ResponseDto
<?>
getRightSettingByBookId
(
@RequestHeader
(
"token"
)
String
token
,
@RequestParam
(
"bookId"
)
Long
bookId
,
@RequestParam
(
"adviserId"
)
Long
adviserId
,
@RequestParam
(
"channelId"
)
Long
channelId
)
throws
PermissionException
{
SessionUtil
.
getToken4Redis
(
token
);
return
new
ResponseDto
<>(
rightsSettingBiz
.
getRightSettingByBookId
(
bookId
,
adviserId
,
channelId
));
}
@ApiOperation
(
"获取即享权益默认图片库"
)
@GetMapping
(
"getAllDefaultRightsNowPics"
)
public
ResponseDto
<?>
getAllDefaultRightsNowPics
(
...
...
pcloud-service-book/src/main/resources/mapper/book/Book.Mapper.xml
View file @
fa2cd2b4
...
...
@@ -2069,7 +2069,14 @@
<if
test=
"keyword != null"
>
AND (B.BOOK_NAME LIKE CONCAT('%', #{keyword}, '%')
OR B.ISBN LIKE CONCAT(#{keyword},'%')
OR CONCAT('BK',A.BOOK_ID) = #{keyword})
OR CONCAT('BK',A.BOOK_ID) = #{keyword}
<if
test=
"adviserIds4Name!=null and adviserIds4Name.size()>0"
>
OR
A.ADVISER_ID in
<foreach
collection=
"adviserIds4Name"
item=
"item"
open=
"("
separator=
","
close=
")"
>
${item}
</foreach>
</if>
)
</if>
<if
test=
"templetId != null"
>
AND
...
...
@@ -2106,7 +2113,14 @@
<if
test=
"keyword != null"
>
AND (B.BOOK_NAME LIKE CONCAT('%', #{keyword}, '%')
OR B.ISBN LIKE CONCAT(#{keyword},'%')
OR CONCAT('BK',A.BOOK_ID) = #{keyword})
OR CONCAT('BK',A.BOOK_ID) = #{keyword}
<if
test=
"adviserIds4Name!=null and adviserIds4Name.size()>0"
>
OR
A.ADVISER_ID in
<foreach
collection=
"adviserIds4Name"
item=
"item"
open=
"("
separator=
","
close=
")"
>
${item}
</foreach>
</if>
)
</if>
<if
test=
"templetId != null"
>
AND
...
...
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