Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vehicle-quality-review
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
王飞
vehicle-quality-review
Commits
cb447d85
Commit
cb447d85
authored
Mar 05, 2024
by
盖献康
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
PDF - 企业留档文件(修改)
parent
545fa439
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
PdfTemplateManagementServiceImpl.java
.../ruoyi/service/impl/PdfTemplateManagementServiceImpl.java
+1
-0
PdfTemplateManagementController.java
...n/java/com/ruoyi/web/PdfTemplateManagementController.java
+2
-3
No files found.
quality-review/src/main/java/com/ruoyi/service/impl/PdfTemplateManagementServiceImpl.java
View file @
cb447d85
...
@@ -121,6 +121,7 @@ public class PdfTemplateManagementServiceImpl implements PdfTemplateManagementSe
...
@@ -121,6 +121,7 @@ public class PdfTemplateManagementServiceImpl implements PdfTemplateManagementSe
// 内容
// 内容
// 封面
// 封面
document
.
setParagraph
(
"检验中心名称"
,
12
f
,
0
,
60
,
15
f
,
120
f
);
document
.
setParagraph
(
"检验中心名称"
,
12
f
,
0
,
60
,
15
f
,
120
f
);
document
.
setParagraph
(
"企业留档文件"
,
30
f
,
Element
.
ALIGN_CENTER
,
0
,
15
f
,
180
f
);
PdfPTable
customTable
=
new
PdfPTable
(
new
float
[]{
15
,
50
});
PdfPTable
customTable
=
new
PdfPTable
(
new
float
[]{
15
,
50
});
customTable
.
setWidthPercentage
(
70
);
customTable
.
setWidthPercentage
(
70
);
document
.
writeNoBorderCell
(
"检验依据:"
,
Element
.
ALIGN_LEFT
,
1
,
1
,
customTable
);
document
.
writeNoBorderCell
(
"检验依据:"
,
Element
.
ALIGN_LEFT
,
1
,
1
,
customTable
);
...
...
quality-review/src/main/java/com/ruoyi/web/PdfTemplateManagementController.java
View file @
cb447d85
...
@@ -48,11 +48,10 @@ public class PdfTemplateManagementController {
...
@@ -48,11 +48,10 @@ public class PdfTemplateManagementController {
@ApiOperation
(
"企业留档文件PDF下载"
)
@ApiOperation
(
"企业留档文件PDF下载"
)
@GetMapping
(
value
=
"/retentionFile"
,
produces
=
"application/json"
)
@GetMapping
(
value
=
"/retentionFile"
,
produces
=
"application/json"
)
public
R
<
String
>
downloadRetentionFile
()
{
public
R
<
String
>
downloadRetentionFile
()
{
// response.setHeader("content-disposition","attachment;fileName="+"RetentionFile.pdf");
try
{
try
{
// demo-模板
// demo-模板
String
s
=
pdfTemplateManagementService
.
generateRetentionFile
();
String
url
=
pdfTemplateManagementService
.
generateRetentionFile
();
return
R
.
ok
(
s
);
return
R
.
ok
(
url
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
return
R
.
fail
();
return
R
.
fail
();
...
...
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