Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
smalltools
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
王家辉
smalltools
Commits
49ab5823
Commit
49ab5823
authored
Feb 15, 2019
by
王家辉
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改生产的返回code,fix bug
parent
b4acd6b2
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
2 deletions
+7
-2
src/main/java/com/freemud/Controller/OrdersController.java
+0
-1
src/main/java/com/freemud/Service/Impl/OrdersServiceImpl.java
+5
-1
src/main/resources/application-dev.properties
+1
-0
src/main/resources/application-prod.properties
+1
-0
No files found.
src/main/java/com/freemud/Controller/OrdersController.java
View file @
49ab5823
...
@@ -17,7 +17,6 @@ import com.freemud.Service.OrdersService;
...
@@ -17,7 +17,6 @@ import com.freemud.Service.OrdersService;
import
com.freemud.dto.OrderProductDTO
;
import
com.freemud.dto.OrderProductDTO
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
...
...
src/main/java/com/freemud/Service/Impl/OrdersServiceImpl.java
View file @
49ab5823
...
@@ -47,6 +47,9 @@ public class OrdersServiceImpl implements OrdersService {
...
@@ -47,6 +47,9 @@ public class OrdersServiceImpl implements OrdersService {
@Value
(
"${order.FileDir}"
)
@Value
(
"${order.FileDir}"
)
private
String
FileDir
;
private
String
FileDir
;
@Value
(
"${order.returnCode}"
)
private
String
returnCode
;
@Override
@Override
public
List
<
OrderProductDTO
>
getOrderProductDTOByOrderId
(
String
orderId
)
{
public
List
<
OrderProductDTO
>
getOrderProductDTOByOrderId
(
String
orderId
)
{
...
@@ -71,7 +74,8 @@ public class OrdersServiceImpl implements OrdersService {
...
@@ -71,7 +74,8 @@ public class OrdersServiceImpl implements OrdersService {
MultiValueMap
<
String
,
Object
>
param
=
new
LinkedMultiValueMap
<>();
MultiValueMap
<
String
,
Object
>
param
=
new
LinkedMultiValueMap
<>();
param
.
add
(
"file"
,
resource
);
param
.
add
(
"file"
,
resource
);
String
code
=
restTemplate
.
postForObject
(
url
,
param
,
String
.
class
);
String
code
=
restTemplate
.
postForObject
(
url
,
param
,
String
.
class
);
if
(
code
.
equals
(
"100"
)){
log
.
info
(
"调用接口{}返回的code:{}"
,
url
,
code
);
if
(
code
.
equals
(
returnCode
)){
log
.
info
(
"修改sku成功{},{}"
,
id
,
sku
);
log
.
info
(
"修改sku成功{},{}"
,
id
,
sku
);
return
true
;
return
true
;
}
}
...
...
src/main/resources/application-dev.properties
View file @
49ab5823
...
@@ -20,5 +20,6 @@ mybatis.mapper-locations=classpath:Mapper/*.xml
...
@@ -20,5 +20,6 @@ mybatis.mapper-locations=classpath:Mapper/*.xml
order.RequestUrl
=
http://172.16.15.179:3017
order.RequestUrl
=
http://172.16.15.179:3017
order.FileDir
=
D://test.xls
order.FileDir
=
D://test.xls
order.returnCode
=
100
src/main/resources/application-prod.properties
View file @
49ab5823
...
@@ -20,5 +20,6 @@ mybatis.mapper-locations=classpath:Mapper/*.xml
...
@@ -20,5 +20,6 @@ mybatis.mapper-locations=classpath:Mapper/*.xml
order.RequestUrl
=
http://10.50.1.40:9929
order.RequestUrl
=
http://10.50.1.40:9929
order.FileDir
=
/data/smalltools/test.xls
order.FileDir
=
/data/smalltools/test.xls
order.returnCode
=
Success
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