Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dc-cost-system
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
bltdc
dc-cost-system
Commits
cb969661
Commit
cb969661
authored
Jan 08, 2021
by
huluobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
34763f35
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
20 deletions
+15
-20
Swagger2Config.java
...main/java/com/blt/other/common/config/Swagger2Config.java
+1
-1
FileController.java
...m/blt/other/module/commons/controller/FileController.java
+0
-1
PurchasingListController.java
...odule/purchasing/controller/PurchasingListController.java
+14
-18
No files found.
bailuntec-cost-core/src/main/java/com/blt/other/common/config/Swagger2Config.java
View file @
cb969661
...
...
@@ -104,7 +104,7 @@ public class Swagger2Config {
@Bean
public
Docket
sysApi
()
{
return
new
Docket
(
DocumentationType
.
SWAGGER_2
)
.
groupName
(
"
费用
系统设置接口"
)
.
groupName
(
"系统设置接口"
)
.
apiInfo
(
apiInfo
())
.
select
()
.
apis
(
RequestHandlerSelectors
.
basePackage
(
"com.blt.other.module.sys"
))
...
...
bailuntec-cost-core/src/main/java/com/blt/other/module/commons/controller/FileController.java
View file @
cb969661
...
...
@@ -7,7 +7,6 @@ import com.blt.other.common.util.PathUtil;
import
com.blt.other.module.cost.utils.CostFileUtil
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
lombok.extern.java.Log
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.multipart.MultipartFile
;
...
...
bailuntec-cost-core/src/main/java/com/blt/other/module/purchasing/controller/PurchasingListController.java
View file @
cb969661
...
...
@@ -10,12 +10,17 @@ import org.springframework.core.io.InputStreamResource;
import
org.springframework.http.HttpHeaders
;
import
org.springframework.http.MediaType
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RestController
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
java.io.IOException
;
import
java.util.*
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
@RestController
@RequestMapping
(
"/purchasing/list"
)
...
...
@@ -25,8 +30,8 @@ public class PurchasingListController {
private
BuyService
buyService
;
@GetMapping
(
"/getAllBuy"
)
public
Map
<
String
,
Object
>
getAllBuy
(
HttpServletResponse
response
,
HttpServletRequest
request
)
{
AxiosUtil
.
setCors
(
response
,
request
);
public
Map
<
String
,
Object
>
getAllBuy
(
HttpServletResponse
response
,
HttpServletRequest
request
)
{
AxiosUtil
.
setCors
(
response
,
request
);
String
pageNum
=
request
.
getParameter
(
"pageNum"
);
String
pageSize
=
request
.
getParameter
(
"pageSize"
);
...
...
@@ -35,16 +40,6 @@ public class PurchasingListController {
return
allBuyList
;
}
// 批量确认
// @PostMapping("batchAffirm")
// public Map<String,Object> batchAffirm(HttpServletResponse response,HttpServletRequest request){
// AxiosUtil.setCors(response,request);
// Map<String,Object> result = new HashMap<>();
//
// result.put("success",true);
// result.put("msg","采购单已确认");
// return result;
// }
@GetMapping
(
"/print"
)
public
Map
<
String
,
Object
>
printList
(
HttpServletResponse
response
,
HttpServletRequest
request
,
...
...
@@ -52,9 +47,9 @@ public class PurchasingListController {
AxiosUtil
.
setCors
(
response
,
request
);
if
(
printBuyIds
!=
null
&&
printBuyIds
.
length
>
0
)
{
List
<
BuyListPrintDto
>
printDtoList
=
buyService
.
getBuyPrintList
(
printBuyIds
);
Map
<
String
,
Object
>
result
=
new
HashMap
<>();
result
.
put
(
"success"
,
true
);
result
.
put
(
"printList"
,
printDtoList
);
Map
<
String
,
Object
>
result
=
new
HashMap
<>();
result
.
put
(
"success"
,
true
);
result
.
put
(
"printList"
,
printDtoList
);
return
result
;
}
return
null
;
...
...
@@ -62,6 +57,7 @@ public class PurchasingListController {
/**
* 采购单导出excel
*
* @param buyIds
* @return
* @throws IOException
...
...
@@ -73,7 +69,7 @@ public class PurchasingListController {
String
fileName
=
PathUtil
.
getFileName
(
filePath
);
HttpHeaders
headers
=
new
HttpHeaders
();
headers
.
add
(
"Cache-Control"
,
"no-cache, no-store, must-revalidate"
);
headers
.
add
(
"Content-Disposition"
,
String
.
format
(
"attachment; filename=\"%s\""
,
new
String
(
fileName
.
getBytes
(
"UTF-8"
),
"iso-8859-1"
)));
headers
.
add
(
"Content-Disposition"
,
String
.
format
(
"attachment; filename=\"%s\""
,
new
String
(
fileName
.
getBytes
(
"UTF-8"
),
"iso-8859-1"
)));
headers
.
add
(
"Pragma"
,
"no-cache"
);
headers
.
add
(
"Expires"
,
"0"
);
...
...
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