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
0744daab
Commit
0744daab
authored
Mar 13, 2021
by
ping.wu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
属性英文修改
parent
19d81d18
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
32 additions
and
2 deletions
+32
-2
assortment-ordercenter-sdk/src/main/java/com/freemud/sdk/api/assortment/order/adapter/OrderSdkAdapter.java
+1
-0
order-application-service/src/main/java/cn/freemud/adapter/OrderAdapter.java
+2
-0
order-application-service/src/main/java/cn/freemud/adapter/ShoppingCartAdapter.java
+22
-0
order-application-service/src/main/java/cn/freemud/entities/dto/OrderProductAddInfo.java
+1
-1
order-application-service/src/main/java/cn/freemud/entities/dto/shoppingCart/ShoppingCartGoodsDto.java
+1
-1
order-application-service/src/main/java/cn/freemud/entities/vo/ProductVo.java
+5
-0
No files found.
assortment-ordercenter-sdk/src/main/java/com/freemud/sdk/api/assortment/order/adapter/OrderSdkAdapter.java
View file @
0744daab
...
@@ -929,6 +929,7 @@ public class OrderSdkAdapter {
...
@@ -929,6 +929,7 @@ public class OrderSdkAdapter {
map
.
put
(
"attributeForeignNames"
,
orderItemResp
.
getProductForeignProperty
());
map
.
put
(
"attributeForeignNames"
,
orderItemResp
.
getProductForeignProperty
());
productBean
.
setAddInfo
(
JSONObject
.
toJSONString
(
map
));
productBean
.
setAddInfo
(
JSONObject
.
toJSONString
(
map
));
productBean
.
setProductProperty
(
orderItemResp
.
getProductProperty
());
productBean
.
setProductProperty
(
orderItemResp
.
getProductProperty
());
productBean
.
setProductForeignProperty
(
orderItemResp
.
getProductForeignProperty
());
productBean
.
setExtInfo
(
orderItemResp
.
getExtInfo
());
productBean
.
setExtInfo
(
orderItemResp
.
getExtInfo
());
productBean
.
setNote
(
orderItemResp
.
getNote
());
productBean
.
setNote
(
orderItemResp
.
getNote
());
...
...
order-application-service/src/main/java/cn/freemud/adapter/OrderAdapter.java
View file @
0744daab
...
@@ -2131,6 +2131,8 @@ public class OrderAdapter {
...
@@ -2131,6 +2131,8 @@ public class OrderAdapter {
productVo
.
setOriginalPrice
(
productBean
.
getPrice
());
productVo
.
setOriginalPrice
(
productBean
.
getPrice
());
productVo
.
setFinalPrice
(
productBean
.
getSalePrice
());
productVo
.
setFinalPrice
(
productBean
.
getSalePrice
());
productVo
.
setExtras
(
shoppingCartAdapter
.
getExtraName
(
productBean
.
getSpecificationName
(),
attributeNames
));
productVo
.
setExtras
(
shoppingCartAdapter
.
getExtraName
(
productBean
.
getSpecificationName
(),
attributeNames
));
productVo
.
setForeignExtras
(
shoppingCartAdapter
.
getForeignExtras
(
productBean
.
getSpecificationForeignName
(),
productBean
.
getProductForeignProperty
()));
productVo
.
setAttributeNamesEn
(
productBean
.
getProductForeignProperty
());
//计算商品原总金额=商品原价格 * 商品数量
//计算商品原总金额=商品原价格 * 商品数量
Long
originalTotalAmount
=
productBean
.
getPrice
()
*
productBean
.
getNumber
();
Long
originalTotalAmount
=
productBean
.
getPrice
()
*
productBean
.
getNumber
();
if
(
ProductTypeEnum
.
WEIGHT_PRODUCT
.
getCode
().
equals
(
productBean
.
getProductType
())){
if
(
ProductTypeEnum
.
WEIGHT_PRODUCT
.
getCode
().
equals
(
productBean
.
getProductType
())){
...
...
order-application-service/src/main/java/cn/freemud/adapter/ShoppingCartAdapter.java
View file @
0744daab
...
@@ -53,4 +53,26 @@ public class ShoppingCartAdapter {
...
@@ -53,4 +53,26 @@ public class ShoppingCartAdapter {
}
}
return
extraName
.
toString
();
return
extraName
.
toString
();
}
}
public
String
getForeignExtras
(
String
skuNameEn
,
String
attributeNamesEn
)
{
if
(
StringUtils
.
isBlank
(
skuNameEn
))
{
skuNameEn
=
""
;
}
if
(
StringUtils
.
isBlank
(
attributeNamesEn
))
{
attributeNamesEn
=
""
;
}
skuNameEn
=
skuNameEn
.
replace
(
"|"
,
"/"
)
+
"/"
+
attributeNamesEn
;
String
[]
names
=
skuNameEn
.
split
(
"/"
);
StringBuilder
extraName
=
new
StringBuilder
(
""
);
if
(
names
.
length
>=
2
)
{
for
(
int
i
=
1
;
i
<
names
.
length
;
i
++)
{
if
(
i
==
names
.
length
-
1
)
{
extraName
.
append
(
names
[
i
]);
}
else
{
extraName
.
append
(
names
[
i
]).
append
(
"/"
);
}
}
}
return
extraName
.
toString
();
}
}
}
order-application-service/src/main/java/cn/freemud/entities/dto/OrderProductAddInfo.java
View file @
0744daab
...
@@ -15,7 +15,7 @@ public class OrderProductAddInfo {
...
@@ -15,7 +15,7 @@ public class OrderProductAddInfo {
*/
*/
private
String
attributeNames
;
private
String
attributeNames
;
private
String
attributeForeignName
;
private
String
attributeForeignName
s
;
/**
/**
* 活动商品集合
* 活动商品集合
*/
*/
...
...
order-application-service/src/main/java/cn/freemud/entities/dto/shoppingCart/ShoppingCartGoodsDto.java
View file @
0744daab
...
@@ -314,7 +314,7 @@ public class ShoppingCartGoodsDto {
...
@@ -314,7 +314,7 @@ public class ShoppingCartGoodsDto {
extras
=
extraList
.
stream
().
map
(
CartGoodsDetailDto
.
CartGoodsExtra
::
getAttributeName
).
collect
(
Collectors
.
joining
(
"/"
));
extras
=
extraList
.
stream
().
map
(
CartGoodsDetailDto
.
CartGoodsExtra
::
getAttributeName
).
collect
(
Collectors
.
joining
(
"/"
));
foreignExtras
=
extraList
.
stream
().
map
(
CartGoodsDetailDto
.
CartGoodsExtra
::
getAttributeForeignName
).
collect
(
Collectors
.
joining
(
"/"
));
foreignExtras
=
extraList
.
stream
().
map
(
CartGoodsDetailDto
.
CartGoodsExtra
::
getAttributeForeignName
).
collect
(
Collectors
.
joining
(
"/"
));
}
}
return
JSON
.
toJSONString
(
OrderProductAddInfo
.
builder
().
attributeNames
(
extras
).
attributeForeignName
(
foreignExtras
).
build
());
return
JSON
.
toJSONString
(
OrderProductAddInfo
.
builder
().
attributeNames
(
extras
).
attributeForeignName
s
(
foreignExtras
).
build
());
}
}
}
}
...
...
order-application-service/src/main/java/cn/freemud/entities/vo/ProductVo.java
View file @
0744daab
...
@@ -152,6 +152,11 @@ public class ProductVo {
...
@@ -152,6 +152,11 @@ public class ProductVo {
* 属性名称 订单详情展示 V1.5.2版本增加
* 属性名称 订单详情展示 V1.5.2版本增加
*/
*/
private
String
attributeNames
;
private
String
attributeNames
;
/**
* 属性名称英文
*/
private
String
attributeNamesEn
;
/**
/**
* 是否包含商品券 V1.5.2版本增加
* 是否包含商品券 V1.5.2版本增加
*/
*/
...
...
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