Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
pension
Project
Project
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
mengmeng
pension
Commits
2abdd07c
Commit
2abdd07c
authored
May 08, 2021
by
Shen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1. 文件信息保存修改
2. 静态资源访问与swagger冲突修复
parent
1ec5f002
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
4 deletions
+14
-4
WebMvcConfig.java
hmit-api/src/main/java/io/hmit/config/WebMvcConfig.java
+2
-1
PensionConsigneeController.java
...s/serviceOrder/controller/PensionConsigneeController.java
+0
-1
PensionDocumentServiceImpl.java
...serviceOrder/service/impl/PensionDocumentServiceImpl.java
+6
-1
PensionOrderServiceImpl.java
...es/serviceOrder/service/impl/PensionOrderServiceImpl.java
+6
-1
No files found.
hmit-api/src/main/java/io/hmit/config/WebMvcConfig.java
View file @
2abdd07c
...
...
@@ -36,7 +36,8 @@ public class WebMvcConfig implements WebMvcConfigurer {
@Override
public
void
addResourceHandlers
(
ResourceHandlerRegistry
registry
)
{
registry
.
addResourceHandler
(
"/swagger2/**"
).
addResourceLocations
(
"classpath:/swagger2/"
);
registry
.
addResourceHandler
(
"/static/**"
).
addResourceLocations
(
"file:D:/123/"
);
registry
.
addResourceHandler
(
"/static/**"
).
addResourceLocations
(
"file:/home/websoft/java_jar/pension_service/myfile/"
);
// registry.addResourceHandler("/static/**").addResourceLocations("file:D:/123/");
}
@Autowired
...
...
hmit-api/src/main/java/io/hmit/modules/serviceOrder/controller/PensionConsigneeController.java
View file @
2abdd07c
...
...
@@ -23,7 +23,6 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.web.bind.annotation.*
;
import
springfox.documentation.annotations.ApiIgnore
;
import
javax.servlet.http.HttpServletResponse
;
import
java.util.List
;
import
java.util.Map
;
...
...
hmit-api/src/main/java/io/hmit/modules/serviceOrder/service/impl/PensionDocumentServiceImpl.java
View file @
2abdd07c
...
...
@@ -62,12 +62,17 @@ public class PensionDocumentServiceImpl extends CrudServiceImpl<PensionDocumentD
//保存文件信息
PensionDocumentEntity
pensionDocumentEntity
=
new
PensionDocumentEntity
();
pensionDocumentEntity
.
setFileName
(
fileAct
.
getName
());
String
fileName
=
fileAct
.
getName
();
pensionDocumentEntity
.
setFileName
(
fileName
);
pensionDocumentEntity
.
setFilePath
(
file_path
);
pensionDocumentEntity
.
setFilePathAct
(
fileAct
.
getPath
());
pensionDocumentEntity
.
setFileSize
(
Double
.
parseDouble
(
String
.
valueOf
(
file
.
getSize
())));
pensionDocumentEntity
.
setFileType
(
file
.
getContentType
());
pensionDocumentEntity
.
setStatus
(
"1"
);
// Integer fileLength = fileName.length();
// if (fileName.substring(fileLength-3, fileLength).equals("mp3")) {
// pensionDocumentEntity.setRemark("2");
// }
insert
(
pensionDocumentEntity
);
Map
<
String
,
Object
>
result
=
new
HashMap
<>();
...
...
hmit-api/src/main/java/io/hmit/modules/serviceOrder/service/impl/PensionOrderServiceImpl.java
View file @
2abdd07c
...
...
@@ -267,7 +267,7 @@ public class PensionOrderServiceImpl extends CrudServiceImpl<PensionOrderDao, Pe
orderDocumentDTO
.
setOrderId
(
orderId
);
orderDocumentDTO
.
setCreateDate
(
new
Date
());
RoleDTO
roleDTO
=
roleService
.
get
(
roleId
);
/*
RoleDTO roleDTO = roleService.get(roleId);
if(roleDTO != null && roleDTO.getName().contains("老人")){
orderDocumentDTO.setRemark("3");
}
...
...
@@ -279,6 +279,11 @@ public class PensionOrderServiceImpl extends CrudServiceImpl<PensionOrderDao, Pe
orderDocumentDTO.setRemark("2");
}
}*/
if
(
item
.
toLowerCase
().
endsWith
(
".mp3"
))
{
orderDocumentDTO
.
setRemark
(
"2"
);
}
else
{
orderDocumentDTO
.
setRemark
(
"1"
);
}
PensionOrderDocumentService
.
save
(
orderDocumentDTO
);
...
...
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