Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
S
shop
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
曲欣亮
shop
Commits
344f9909
Commit
344f9909
authored
Nov 28, 2023
by
张永
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
需求 #16076
parent
e6639bc2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
CartController.java
src/main/java/com/egolm/shop/api/CartController.java
+5
-1
No files found.
src/main/java/com/egolm/shop/api/CartController.java
View file @
344f9909
...
...
@@ -42,7 +42,7 @@ public class CartController {
@RequestMapping
(
value
=
"/getCartCount"
,
method
=
RequestMethod
.
GET
)
@IDCLogResource
(
name
=
"购物车商品种类数量"
)
public
String
cartQuery
(
String
orgNo
,
String
shopNo
)
{
public
String
getCartCount
(
String
orgNo
,
String
shopNo
)
{
Map
<
String
,
Object
>
map
=
cartService
.
count
(
orgNo
,
shopNo
);
return
Rjx
.
jsonOk
().
set
(
"count"
,
map
.
get
(
"totalCount"
)).
set
(
"qty"
,
map
.
get
(
"totalSaleQty"
)).
toJson
();
}
...
...
@@ -136,6 +136,10 @@ public class CartController {
String
reqJson
=
request
.
getParameter
(
"data"
);
JSONObject
jsonObj
=
JSONObject
.
parseObject
(
reqJson
);
jsonObj
.
put
(
"orgNo"
,
orgNo
);
Integer
saleQty
=
jsonObj
.
getInteger
(
"saleQty"
);
if
(
saleQty
<
0
)
{
return
Rjx
.
jsonErr
().
setMessage
(
"数量不能小于0"
).
toJson
();
}
System
.
out
.
println
(
"updateQty-------"
+
reqJson
);
String
terminal
=
request
.
getParameter
(
"terminal"
);
return
cartService
.
updateQty
(
jsonObj
,
terminal
);
...
...
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