Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
O
order-group
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
order-group-application
order-group
Commits
5ffa7617
Commit
5ffa7617
authored
Feb 02, 2021
by
chongfu.liang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
重构二期
parent
7ea2e380
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
12 deletions
+14
-12
shopping-cart-application-service/src/main/java/cn/freemud/controller/ShoppingCartController.java
+13
-4
shopping-cart-application-service/src/main/java/cn/freemud/demo/controller/ShoppingCartDemoController.java
+1
-8
No files found.
shopping-cart-application-service/src/main/java/cn/freemud/controller/ShoppingCartController.java
View file @
5ffa7617
...
...
@@ -109,7 +109,12 @@ public class ShoppingCartController {
@ApiAnnotation
(
logMessage
=
"listCartGoods"
)
@PostMapping
(
value
=
"/listCartGoods"
)
public
BaseResponse
listCartGoods
(
@Validated
@LogParams
@RequestBody
ShoppingCartInfoRequestVo
request
)
{
return
getInstanceByRequest
(
request
).
getGoodsList
(
request
);
if
(
SDKCommonBaseContextWare
.
getBean
(
ShoppingCartNewServiceImpl
.
class
).
newShoppingCartGray
(
request
.
getPartnerId
(),
request
.
getShopId
())){
Map
requestMap
=
mapperFacade
.
map
(
request
,
Map
.
class
);
return
shoppingCartDemoController
.
listCartGoods
(
requestMap
);
}
else
{
return
getInstanceByRequest
(
request
).
getGoodsList
(
request
);
}
}
/**
...
...
@@ -161,9 +166,13 @@ public class ShoppingCartController {
return
ResponseUtil
.
error
(
ResponseResult
.
NOT_LOGIN
);
}
ShoppingCartInfoRequestVo
shoppingCartInfoRequestVo
=
getShoppingCartGoodsApportionRequestVo
.
getShoppingCartInfoRequestVo
();
return
getInstanceByRequest
(
shoppingCartInfoRequestVo
).
getShoppingCartGoods
(
shoppingCartInfoRequestVo
,
getShoppingCartGoodsApportionRequestVo
.
getPremiumExchangeActivity
());
if
(
SDKCommonBaseContextWare
.
getBean
(
ShoppingCartNewServiceImpl
.
class
).
newShoppingCartGray
(
shoppingCartInfoRequestVo
.
getPartnerId
(),
shoppingCartInfoRequestVo
.
getShopId
())){
return
shoppingCartDemoController
.
getShoppingCartGoodsApportion
(
getShoppingCartGoodsApportionRequestVo
);
}
else
{
return
getInstanceByRequest
(
shoppingCartInfoRequestVo
).
getShoppingCartGoods
(
shoppingCartInfoRequestVo
,
getShoppingCartGoodsApportionRequestVo
.
getPremiumExchangeActivity
());
}
}
...
...
shopping-cart-application-service/src/main/java/cn/freemud/demo/controller/ShoppingCartDemoController.java
View file @
5ffa7617
...
...
@@ -161,13 +161,7 @@ public class ShoppingCartDemoController {
@PostMapping
(
value
=
"/listCartGoods"
)
public
BaseResponse
listCartGoods
(
@LogParams
@RequestBody
Map
<
String
,
Object
>
request
)
{
ListCartGoodsRequestDTO
baseRequestDTO
=
new
ListCartGoodsRequestDTO
();
try
{
BeanUtils
.
populate
(
baseRequestDTO
,
request
);
}
catch
(
Exception
exception
){
return
ResponseUtil
.
error
(
""
);
}
ListCartGoodsRequestDTO
baseRequestDTO
=
mapperFacade
.
map
(
request
,
ListCartGoodsRequestDTO
.
class
);
/**
* 是否用新字段,还是沿用老逻辑
*/
...
...
@@ -207,7 +201,6 @@ public class ShoppingCartDemoController {
return
ResponseUtil
.
success
(
baseApportionVO
);
}
return
getInstanceByRequest
(
shoppingCartInfoRequestVo
).
getShoppingCartGoods
(
shoppingCartInfoRequestVo
,
getShoppingCartGoodsApportionRequestVo
.
getPremiumExchangeActivity
());
...
...
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