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
c1654609
Commit
c1654609
authored
Mar 08, 2020
by
章春雨
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'fixbug' into 'master'
修复1002503部分bug See merge request rays/pcloud-book!528
parents
35133f3c
e15546b6
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
26 additions
and
9 deletions
+26
-9
CustomPlanBiz.java
...c/main/java/com/pcloud/book/custom/biz/CustomPlanBiz.java
+1
-1
CustomPlanBizImpl.java
...va/com/pcloud/book/custom/biz/impl/CustomPlanBizImpl.java
+4
-4
CustomPlanFacade.java
.../java/com/pcloud/book/custom/facade/CustomPlanFacade.java
+3
-2
CustomPlanMapper.java
.../java/com/pcloud/book/custom/mapper/CustomPlanMapper.java
+6
-2
CustomPlanMapper.xml
...ook/src/main/resources/mapper/custom/CustomPlanMapper.xml
+12
-0
No files found.
pcloud-service-book/src/main/java/com/pcloud/book/custom/biz/CustomPlanBiz.java
View file @
c1654609
...
@@ -25,7 +25,7 @@ public interface CustomPlanBiz {
...
@@ -25,7 +25,7 @@ public interface CustomPlanBiz {
void
deleteCustomPlanById
(
Integer
planId
);
void
deleteCustomPlanById
(
Integer
planId
);
PageBeanNew
<
CustomPlan
>
listCustomPlanByPage
(
Integer
currentPage
,
Integer
numPerPage
,
String
content
,
Integer
useState
);
PageBeanNew
<
CustomPlan
>
listCustomPlanByPage
(
Integer
currentPage
,
Integer
numPerPage
,
String
content
,
Integer
useState
,
Integer
hasPdf
);
void
editCustomPlanModule
(
EditCustomPlanModuleVO
editCustomPlanModuleVO
);
void
editCustomPlanModule
(
EditCustomPlanModuleVO
editCustomPlanModuleVO
);
...
...
pcloud-service-book/src/main/java/com/pcloud/book/custom/biz/impl/CustomPlanBizImpl.java
View file @
c1654609
...
@@ -135,12 +135,12 @@ public class CustomPlanBizImpl implements CustomPlanBiz {
...
@@ -135,12 +135,12 @@ public class CustomPlanBizImpl implements CustomPlanBiz {
}
}
@Override
@Override
public
PageBeanNew
<
CustomPlan
>
listCustomPlanByPage
(
Integer
currentPage
,
Integer
numPerPage
,
String
content
,
Integer
useState
)
{
public
PageBeanNew
<
CustomPlan
>
listCustomPlanByPage
(
Integer
currentPage
,
Integer
numPerPage
,
String
content
,
Integer
useState
,
Integer
hasPdf
)
{
int
count
=
customPlanMapper
.
getCustomPlanCount
(
content
,
useState
);
int
count
=
customPlanMapper
.
getCustomPlanCount
(
content
,
useState
,
hasPdf
);
if
(
count
<=
0
)
{
if
(
count
<=
0
)
{
return
new
PageBeanNew
<>(
currentPage
,
numPerPage
,
new
ArrayList
<>());
return
new
PageBeanNew
<>(
currentPage
,
numPerPage
,
new
ArrayList
<>());
}
}
List
<
CustomPlan
>
customPlanList
=
customPlanMapper
.
listCustomPlanByPage
(
currentPage
*
numPerPage
,
numPerPage
,
content
,
useState
);
List
<
CustomPlan
>
customPlanList
=
customPlanMapper
.
listCustomPlanByPage
(
currentPage
*
numPerPage
,
numPerPage
,
content
,
useState
,
hasPdf
);
return
new
PageBeanNew
<>(
currentPage
,
numPerPage
,
count
,
customPlanList
);
return
new
PageBeanNew
<>(
currentPage
,
numPerPage
,
count
,
customPlanList
);
}
}
...
@@ -175,7 +175,7 @@ public class CustomPlanBizImpl implements CustomPlanBiz {
...
@@ -175,7 +175,7 @@ public class CustomPlanBizImpl implements CustomPlanBiz {
CustomPlan
customPlan
=
new
CustomPlan
();
CustomPlan
customPlan
=
new
CustomPlan
();
customPlan
.
setId
(
planId
);
customPlan
.
setId
(
planId
);
customPlan
.
setPdfUrl
(
pdfUrl
);
customPlan
.
setPdfUrl
(
pdfUrl
);
customPlanMapper
.
update
(
customPlan
);
customPlanMapper
.
update
PdfUrl
(
customPlan
);
}
}
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
LOGGER
.
error
(
"转PDF失败"
,
e
);
LOGGER
.
error
(
"转PDF失败"
,
e
);
...
...
pcloud-service-book/src/main/java/com/pcloud/book/custom/facade/CustomPlanFacade.java
View file @
c1654609
...
@@ -78,8 +78,9 @@ public class CustomPlanFacade {
...
@@ -78,8 +78,9 @@ public class CustomPlanFacade {
@ApiOperation
(
"分页获取定制方案"
)
@ApiOperation
(
"分页获取定制方案"
)
@GetMapping
(
"listCustomPlanByPage"
)
@GetMapping
(
"listCustomPlanByPage"
)
ResponseDto
<?>
listCustomPlanByPage
(
@RequestHeader
String
token
,
@RequestParam
Integer
currentPage
,
@RequestParam
Integer
numPerPage
,
ResponseDto
<?>
listCustomPlanByPage
(
@RequestHeader
String
token
,
@RequestParam
Integer
currentPage
,
@RequestParam
Integer
numPerPage
,
@RequestParam
(
value
=
"content"
,
required
=
false
)
String
content
,
@RequestParam
(
value
=
"useState"
,
required
=
false
)
Integer
useState
)
{
@RequestParam
(
value
=
"content"
,
required
=
false
)
String
content
,
@RequestParam
(
value
=
"useState"
,
required
=
false
)
Integer
useState
,
return
new
ResponseDto
<>(
customPlanBiz
.
listCustomPlanByPage
(
currentPage
,
numPerPage
,
content
,
useState
));
@RequestParam
(
value
=
"hasPdf"
,
required
=
false
)
Integer
hasPdf
)
{
return
new
ResponseDto
<>(
customPlanBiz
.
listCustomPlanByPage
(
currentPage
,
numPerPage
,
content
,
useState
,
hasPdf
));
}
}
@ApiOperation
(
"编辑方案模块"
)
@ApiOperation
(
"编辑方案模块"
)
...
...
pcloud-service-book/src/main/java/com/pcloud/book/custom/mapper/CustomPlanMapper.java
View file @
c1654609
...
@@ -20,11 +20,14 @@ public interface CustomPlanMapper {
...
@@ -20,11 +20,14 @@ public interface CustomPlanMapper {
void
deleteById
(
@Param
(
"id"
)
Integer
id
);
void
deleteById
(
@Param
(
"id"
)
Integer
id
);
int
getCustomPlanCount
(
@Param
(
"content"
)
String
content
,
@Param
(
"useState"
)
Integer
useState
);
int
getCustomPlanCount
(
@Param
(
"content"
)
String
content
,
@Param
(
"useState"
)
Integer
useState
,
@Param
(
"hasPdf"
)
Integer
hasPdf
);
List
<
CustomPlan
>
listCustomPlanByPage
(
@Param
(
"pageNum"
)
Integer
pageNum
,
@Param
(
"numPerPage"
)
Integer
numPerPage
,
@Param
(
"content"
)
String
content
,
@Param
(
"useState"
)
Integer
useState
);
List
<
CustomPlan
>
listCustomPlanByPage
(
@Param
(
"pageNum"
)
Integer
pageNum
,
@Param
(
"numPerPage"
)
Integer
numPerPage
,
@Param
(
"content"
)
String
content
,
@Param
(
"useState"
)
Integer
useState
,
@Param
(
"hasPdf"
)
Integer
hasPdf
);
int
getPlanPaperCount
(
Map
<
String
,
Object
>
paramMap
);
int
getPlanPaperCount
(
Map
<
String
,
Object
>
paramMap
);
List
<
CustomPlanPaperVO
>
listPlanPaperByPage
(
Map
<
String
,
Object
>
paramMap
);
List
<
CustomPlanPaperVO
>
listPlanPaperByPage
(
Map
<
String
,
Object
>
paramMap
);
void
updatePdfUrl
(
CustomPlan
customPlan
);
}
}
\ No newline at end of file
pcloud-service-book/src/main/resources/mapper/custom/CustomPlanMapper.xml
View file @
c1654609
...
@@ -109,6 +109,9 @@
...
@@ -109,6 +109,9 @@
<if
test=
"useState != null"
>
<if
test=
"useState != null"
>
and use_state = #{useState}
and use_state = #{useState}
</if>
</if>
<if
test=
"hasPdf == 1"
>
and pdf_url is not null
</if>
</select>
</select>
<select
id=
"listCustomPlanByPage"
resultMap=
"BaseResultMap"
>
<select
id=
"listCustomPlanByPage"
resultMap=
"BaseResultMap"
>
...
@@ -126,6 +129,9 @@
...
@@ -126,6 +129,9 @@
<if
test=
"useState != null"
>
<if
test=
"useState != null"
>
and use_state = #{useState}
and use_state = #{useState}
</if>
</if>
<if
test=
"hasPdf == 1"
>
and pdf_url is not null
</if>
GROUP BY a.id
GROUP BY a.id
ORDER BY update_time DESC
ORDER BY update_time DESC
LIMIT #{pageNum}, #{numPerPage}
LIMIT #{pageNum}, #{numPerPage}
...
@@ -173,4 +179,9 @@
...
@@ -173,4 +179,9 @@
ORDER BY update_time DESC
ORDER BY update_time DESC
LIMIT #{pageNum}, #{numPerPage}
LIMIT #{pageNum}, #{numPerPage}
</select>
</select>
<update
id=
"updatePdfUrl"
parameterType=
"CustomPlan"
>
update custom_plan set pdf_url =#{pdfUrl}
where id = #{id,jdbcType=INTEGER}
</update>
</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