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
d4aaa4a4
Commit
d4aaa4a4
authored
Aug 11, 2021
by
ping.wu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
积分商城
parent
29070a7b
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
335 additions
and
2 deletions
+335
-2
order-application-service/src/main/java/cn/freemud/entities/dto/ProductInfosDto.java
+0
-1
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/EntityProductType.java
+23
-0
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/IntegralProductType.java
+82
-0
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/PointMallListProductInfoRequest.java
+45
-0
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/PointMallListProductInfoResponse.java
+12
-0
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/ProductStockRequest.java
+18
-0
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/UpdatePointsMallStocksRequest.java
+41
-0
order-application-service/src/main/java/cn/freemud/entities/dto/user/UserScoreRequest.java
+17
-0
order-application-service/src/main/java/cn/freemud/entities/vo/CreateOrderVo.java
+6
-0
order-application-service/src/main/java/cn/freemud/entities/vo/order/CreateOrderProductVo.java
+12
-0
order-application-service/src/main/java/cn/freemud/enums/OrderChannelType.java
+3
-1
order-application-service/src/main/java/cn/freemud/service/PointsMallOrderService.java
+12
-0
order-application-service/src/main/java/cn/freemud/service/impl/OrderAdapterServiceImpl.java
+9
-0
order-application-service/src/main/java/cn/freemud/service/impl/PointsMallOrderServiceImpl.java
+0
-0
order-application-service/src/main/java/cn/freemud/service/thirdparty/CustomerPropertyClient.java
+22
-0
order-application-service/src/main/java/cn/freemud/service/thirdparty/PointMallProductClient.java
+33
-0
No files found.
order-application-service/src/main/java/cn/freemud/entities/dto/ProductInfosDto.java
View file @
d4aaa4a4
...
@@ -12,7 +12,6 @@
...
@@ -12,7 +12,6 @@
*/
*/
package
cn
.
freemud
.
entities
.
dto
;
package
cn
.
freemud
.
entities
.
dto
;
import
cn.freemud.entities.dto.GetMenuResponseDto.DataBean.RootNodeBean.ChildrenBeanFirst.ChildrenBeanSecond.ProductBean
;
import
cn.freemud.entities.dto.product.ProductInfo
;
import
cn.freemud.entities.dto.product.ProductInfo
;
import
lombok.Data
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
lombok.NoArgsConstructor
;
...
...
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/EntityProductType.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
entities
.
dto
.
product
.
pointsmall
;
import
lombok.Data
;
@Data
public
class
EntityProductType
{
// @ApiModelProperty(value = "商品编号")
private
String
productId
;
// @ApiModelProperty(value = "商品描述")
// private String detailText;
// @ApiModelProperty(value = "商品图片")
protected
String
picture
;
// @ApiModelProperty(value = "商品说明图片")
// private List<String> detailImageList;
// @ApiModelProperty(value = "轮播图")
// private List<String> carouselList;
}
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/IntegralProductType.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
entities
.
dto
.
product
.
pointsmall
;
import
lombok.Data
;
import
java.util.List
;
@Data
public
class
IntegralProductType
{
// @ApiModelProperty(value = "商品编号")
private
String
productId
;
// @ApiModelProperty(value = "商品名称")
private
String
productName
;
// @ApiModelProperty(value = "商品类型(1优惠券,2实物)")
private
Integer
productType
;
// @ApiModelProperty(value = "图片列表")
private
List
<
String
>
pictureList
;
// @ApiModelProperty(value = "优惠券编号")
private
String
couponCode
;
// @ApiModelProperty(value = "兑换方式(1积分,2现金,3积分+现金)")
private
Integer
exchangeType
;
// @ApiModelProperty(value = "积分价格")
private
Integer
integralPrice
;
// @ApiModelProperty(value = "现金价格(分)")
private
Integer
cashPrice
;
// @ApiModelProperty(value = "分类编号")
private
String
categoryId
;
// @ApiModelProperty(value = "分类名称")
private
String
categoryName
;
// @ApiModelProperty(value = "首页推荐(0不推荐,1推荐)")
private
Integer
isRecommend
;
// @ApiModelProperty(value = "开始可售时间")
private
String
startTime
;
// @ApiModelProperty(value = "结束可售时间")
private
String
endTime
;
// @ApiModelProperty(value = "库存限制(1:限制库存, 2不限制库存)")
private
Integer
stockLimit
;
// @ApiModelProperty(value = "用户限购类型(1不限制,2限制每人N件,3限制每人每天N件)")
private
Integer
limitType
;
// @ApiModelProperty(value = "限购数量")
private
Integer
limitNumber
;
// @ApiModelProperty(value = "用户等级限制(1不限制,2限制会员等级,3付费会员,4非付费会员)")
private
Integer
levelType
;
// @ApiModelProperty(value = "会员等级列表")
private
List
<
String
>
levelList
;
// @ApiModelProperty(value = "商品排序值")
private
Integer
sequence
;
// @ApiModelProperty(value = "分类排序值")
private
Integer
categorySequence
;
// @ApiModelProperty(value = "商品状态(1下架,2上架,3售罄,4不在可售时间内,5超过每人总限购数量,6超过每人每天限购数量,7用户等级不足,8用户身份不足)")
private
Integer
status
;
// @ApiModelProperty(value = "实物商品信息")
private
EntityProductType
entityProductInfo
;
// @ApiModelProperty(value = "剩余库存数量")
private
Integer
stockNumber
;
// @ApiModelProperty(value = "已兑换数量")
private
Integer
exchangeNumber
;
}
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/PointMallListProductInfoRequest.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
entities
.
dto
.
product
.
pointsmall
;
import
lombok.Data
;
import
java.util.List
;
/**
* All rights Reserved, Designed By www.freemud.cn
*
* @version V1.0
* @Title: PointMallListProductInfoRequest
* @Package com.freemud.product.contract
* @Description:
* @author yue.liu
* @date: 2021/8/9 14:28
* @Copyright: 2017 www.freemud.cn Inc. All rights reserved.
* 注意:本内容仅限于上海非码科技内部传阅,禁止外泄以及用于其他的商业目
*/
@Data
public
class
PointMallListProductInfoRequest
{
// @ApiModelProperty(value = "商户编号", required = true)
private
String
partnerId
;
private
String
memberId
;
// @ApiModelProperty(value = "商品编号列表")
private
List
<
String
>
productIdList
;
// @ApiModelProperty(value = "会员等级编号列表")
private
List
<
String
>
levelIdList
;
// @ApiModelProperty(value = "会员类型(1付费会员,2非付费会员)")
private
Integer
memberType
;
// @ApiModelProperty(value = "是否校验可售时间(true校验,false不校验)")
private
boolean
isValidateTime
;
// @ApiModelProperty(value = "是否校验库存(true校验,false不校验)")
private
boolean
isValidateStock
;
// @ApiModelProperty(value = "是否校验用户限制(true校验,false不校验)")
private
boolean
isValidateMember
;
}
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/PointMallListProductInfoResponse.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
entities
.
dto
.
product
.
pointsmall
;
import
lombok.Data
;
@Data
public
class
PointMallListProductInfoResponse
<
T
>
{
private
T
result
;
private
Integer
statusCode
;
private
String
message
;
}
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/ProductStockRequest.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
entities
.
dto
.
product
.
pointsmall
;
import
lombok.Data
;
@Data
public
class
ProductStockRequest
{
//兑换数量
public
Integer
exchangeNumber
;
//非码商品编号
public
String
productId
;
//库存数量
public
Integer
stockNumber
;
}
order-application-service/src/main/java/cn/freemud/entities/dto/product/pointsmall/UpdatePointsMallStocksRequest.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
entities
.
dto
.
product
.
pointsmall
;
import
lombok.Data
;
import
java.util.List
;
/**
* All rights Reserved, Designed By www.freemud.cn
*
* @version V1.0
* @Title: UpdateStocksRequest
* @Package com.freemud.product.contract
* @Description:
* @author yue.liu
* @date: 2021/8/9 14:28
* @Copyright: 2017 www.freemud.cn Inc. All rights reserved.
* 注意:本内容仅限于上海非码科技内部传阅,禁止外泄以及用于其他的商业目
*/
@Data
public
class
UpdatePointsMallStocksRequest
{
// @ApiModelProperty(value = "1增加库存或兑换数量,2减少库存,3修改库存,兑换数量只支持新增", required = true)
public
String
changeType
;
// @ApiModelProperty(value = "交易号, maxLength = 36", required = true)
public
String
transNo
;
// @ApiModelProperty("备注, maxLength = 50")
public
String
remark
;
// @ApiModelProperty("交易时间 格式类型 yyyy-MM-dd HH:mm:ss")
public
String
transTime
;
// @ApiModelProperty(value = "商品库存信息,建议数量不要超过500", required = true)
public
List
<
ProductStockRequest
>
productStocks
;
// @ApiModelProperty(value = "会员编号", required = true)
public
String
memberId
;
}
order-application-service/src/main/java/cn/freemud/entities/dto/user/UserScoreRequest.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
entities
.
dto
.
user
;
import
lombok.Data
;
@Data
public
class
UserScoreRequest
{
private
Integer
reduceAmount
;
private
String
scoreOrderNo
;
private
Integer
UseScore
;
private
Integer
changeType
;
private
Integer
operationType
;
private
String
memberId
;
private
String
partnerId
;
private
String
storeId
;
}
order-application-service/src/main/java/cn/freemud/entities/vo/CreateOrderVo.java
View file @
d4aaa4a4
...
@@ -13,6 +13,7 @@
...
@@ -13,6 +13,7 @@
package
cn
.
freemud
.
entities
.
vo
;
package
cn
.
freemud
.
entities
.
vo
;
import
cn.freemud.entities.dto.UserDeliveryInfoDto
;
import
cn.freemud.entities.dto.UserDeliveryInfoDto
;
import
cn.freemud.entities.vo.order.CreateOrderProductVo
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.freemud.application.sdk.api.ordercenter.request.create.OrderPayItemCreateReq
;
import
com.freemud.application.sdk.api.ordercenter.request.create.OrderPayItemCreateReq
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModel
;
...
@@ -269,6 +270,11 @@ public class CreateOrderVo {
...
@@ -269,6 +270,11 @@ public class CreateOrderVo {
@Valid
@Valid
@ApiModelProperty
(
value
=
"电子风味卡"
)
@ApiModelProperty
(
value
=
"电子风味卡"
)
private
UnionPayCard
unionPayCard
;
private
UnionPayCard
unionPayCard
;
/**
* 下单商品,积分商城使用
*/
private
List
<
CreateOrderProductVo
>
products
;
/**
/**
* 电子风味卡
* 电子风味卡
*/
*/
...
...
order-application-service/src/main/java/cn/freemud/entities/vo/order/CreateOrderProductVo.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
entities
.
vo
.
order
;
import
lombok.Data
;
@Data
public
class
CreateOrderProductVo
{
private
String
spuId
;
private
String
skuId
;
}
order-application-service/src/main/java/cn/freemud/enums/OrderChannelType.java
View file @
d4aaa4a4
...
@@ -24,7 +24,9 @@ public enum OrderChannelType {
...
@@ -24,7 +24,9 @@ public enum OrderChannelType {
BEAUTIFUL
(
"beautiful"
,
"美业"
),
BEAUTIFUL
(
"beautiful"
,
"美业"
),
APP
(
"app"
,
"APP"
);
APP
(
"app"
,
"APP"
),
POINTSMALL
(
"pointsmall"
,
"积分商城"
);
private
String
code
;
private
String
code
;
...
...
order-application-service/src/main/java/cn/freemud/service/PointsMallOrderService.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
service
;
import
cn.freemud.base.entity.BaseResponse
;
import
cn.freemud.entities.vo.CreateOrderVo
;
public
interface
PointsMallOrderService
{
/**
* 创建订单
*/
BaseResponse
createOrder
(
CreateOrderVo
createOrderVo
);
}
order-application-service/src/main/java/cn/freemud/service/impl/OrderAdapterServiceImpl.java
View file @
d4aaa4a4
...
@@ -97,6 +97,8 @@ public class OrderAdapterServiceImpl implements OrderAdapterService {
...
@@ -97,6 +97,8 @@ public class OrderAdapterServiceImpl implements OrderAdapterService {
@Autowired
@Autowired
private
MallOrderService
mallOrderService
;
private
MallOrderService
mallOrderService
;
@Autowired
@Autowired
private
PointsMallOrderService
pointsMallOrderService
;
@Autowired
private
AppOrderService
appOrderService
;
private
AppOrderService
appOrderService
;
@Autowired
@Autowired
private
RedisCache
redisCache
;
private
RedisCache
redisCache
;
...
@@ -157,6 +159,13 @@ public class OrderAdapterServiceImpl implements OrderAdapterService {
...
@@ -157,6 +159,13 @@ public class OrderAdapterServiceImpl implements OrderAdapterService {
}
}
/**
/**
* 积分商城
*/
if
(
OrderChannelType
.
POINTSMALL
.
getCode
().
equals
(
createOrderVo
.
getChannelType
()))
{
return
pointsMallOrderService
.
createOrder
(
createOrderVo
);
}
/**
* 商城订单
* 商城订单
*/
*/
if
(
OrderChannelType
.
SAASMALL
.
getCode
().
equals
(
createOrderVo
.
getChannelType
()))
{
if
(
OrderChannelType
.
SAASMALL
.
getCode
().
equals
(
createOrderVo
.
getChannelType
()))
{
...
...
order-application-service/src/main/java/cn/freemud/service/impl/PointsMallOrderServiceImpl.java
0 → 100644
View file @
d4aaa4a4
This diff is collapsed.
Click to expand it.
order-application-service/src/main/java/cn/freemud/service/thirdparty/CustomerPropertyClient.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
service
.
thirdparty
;
import
cn.freemud.annotations.LogIgnoreFeign
;
import
cn.freemud.base.entity.BaseResponse
;
import
cn.freemud.entities.dto.user.UserScoreRequest
;
import
org.springframework.cloud.openfeign.FeignClient
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
@FeignClient
(
name
=
"customer-property-service"
,
url
=
"${saas.customerpropertyclient.feign.url}"
)
@RequestMapping
(
produces
=
{
"application/json;charset=UTF-8"
})
public
interface
CustomerPropertyClient
{
//
@LogIgnoreFeign
(
logMessage
=
"useScore"
)
@PostMapping
(
value
=
"user/useScore"
)
BaseResponse
useScore
(
@RequestBody
UserScoreRequest
userScoreRequest
);
}
order-application-service/src/main/java/cn/freemud/service/thirdparty/PointMallProductClient.java
0 → 100644
View file @
d4aaa4a4
package
cn
.
freemud
.
service
.
thirdparty
;
import
cn.freemud.annotations.LogIgnoreFeign
;
import
cn.freemud.constant.ResponseCodeKeyConstant
;
import
cn.freemud.entities.dto.product.pointsmall.IntegralProductType
;
import
cn.freemud.entities.dto.product.pointsmall.PointMallListProductInfoRequest
;
import
cn.freemud.entities.dto.product.pointsmall.PointMallListProductInfoResponse
;
import
cn.freemud.entities.dto.product.pointsmall.UpdatePointsMallStocksRequest
;
import
org.springframework.cloud.openfeign.FeignClient
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
@FeignClient
(
value
=
"PRODUCTSERVICE"
,
url
=
"http://172.16.19.240:9996/swagger-ui.html#/"
)
//${saas.pointMallProductClient.feign.url}
@RequestMapping
(
produces
=
{
"application/json;charset=UTF-8"
})
public
interface
PointMallProductClient
{
/**
* 获取商品的详细信息
*/
@LogIgnoreFeign
(
logMessage
=
"listProductInfos"
,
statusCodeFieldName
=
ResponseCodeKeyConstant
.
STATUS_CODE
)
@PostMapping
(
"/biz/product/listProductInfo"
)
PointMallListProductInfoResponse
<
IntegralProductType
>
listProductInfo
(
@RequestBody
PointMallListProductInfoRequest
productInfoRequest
);
@LogIgnoreFeign
(
logMessage
=
"listProductInfos"
,
statusCodeFieldName
=
ResponseCodeKeyConstant
.
STATUS_CODE
)
@PostMapping
(
"/biz/stock/update"
)
PointMallListProductInfoResponse
updateStock
(
@RequestBody
UpdatePointsMallStocksRequest
updatePointsMallStocksRequest
);
}
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