记得上下班打卡 | git大法好,push需谨慎
Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
liquidnet-bus-v1
Project
Project
Details
Activity
Releases
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
董敬伟
liquidnet-bus-v1
Commits
13171a6d
Commit
13171a6d
authored
Dec 30, 2021
by
张国柄
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
~商品相关VO;
parent
93d37193
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
221 additions
and
60 deletions
+221
-60
GoblinStoreMgtGoodsAddParam.java
...ervice/goblin/dto/manage/GoblinStoreMgtGoodsAddParam.java
+122
-30
GoblinStoreMgtGoodsAddSkuParam.java
...ice/goblin/dto/manage/GoblinStoreMgtGoodsAddSkuParam.java
+21
-12
GoblinGoodsInfoVo.java
...om/liquidnet/service/goblin/dto/vo/GoblinGoodsInfoVo.java
+3
-0
GoblinGoodsSkuInfoVo.java
...liquidnet/service/goblin/dto/vo/GoblinGoodsSkuInfoVo.java
+21
-14
GoblinGoodsSpecValueVo.java
...quidnet/service/goblin/dto/vo/GoblinGoodsSpecValueVo.java
+11
-1
GoblinGoodsSpecVo.java
...om/liquidnet/service/goblin/dto/vo/GoblinGoodsSpecVo.java
+16
-1
GoblinGoodsSku.java
...a/com/liquidnet/service/goblin/entity/GoblinGoodsSku.java
+5
-0
db_ln_goblin_initialdata.sql
...net-service-goblin-impl/docu/db_ln_goblin_initialdata.sql
+1
-0
ObjectUtil.java
...in/java/com/liquidnet/service/goblin/util/ObjectUtil.java
+21
-2
No files found.
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/manage/GoblinStoreMgtGoodsAddParam.java
View file @
13171a6d
package
com
.
liquidnet
.
service
.
goblin
.
dto
.
manage
;
package
com
.
liquidnet
.
service
.
goblin
.
dto
.
manage
;
import
com.liquidnet.commons.lang.constant.LnsRegex
;
import
com.liquidnet.commons.lang.constant.LnsRegex
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.goblin.dto.GoblinGoodsSpecDto
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsInfoVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsInfoVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsSkuInfoVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsSkuInfoVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsSpecValueVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsSpecVo
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.Data
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.util.CollectionUtils
;
import
javax.validation.constraints.Pattern
;
import
javax.validation.constraints.Pattern
;
import
java.io.Serializable
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.List
;
@ApiModel
(
value
=
"GoblinStoreMgtGoodsAddParam"
,
description
=
"商品管理:添加商品入参"
)
@ApiModel
(
value
=
"GoblinStoreMgtGoodsAddParam"
,
description
=
"商品管理:添加商品入参"
)
...
@@ -23,78 +29,104 @@ public class GoblinStoreMgtGoodsAddParam implements Serializable {
...
@@ -23,78 +29,104 @@ public class GoblinStoreMgtGoodsAddParam implements Serializable {
@ApiModelProperty
(
position
=
11
,
required
=
true
,
value
=
"店铺ID"
)
@ApiModelProperty
(
position
=
11
,
required
=
true
,
value
=
"店铺ID"
)
private
String
storeId
;
private
String
storeId
;
/** ---------------------------- 基本信息 ---------------------------- **/
/**
* ---------------------------- 基本信息 ----------------------------
**/
@ApiModelProperty
(
position
=
12
,
required
=
true
,
value
=
"商品名称[128]"
)
@ApiModelProperty
(
position
=
12
,
required
=
true
,
value
=
"商品名称[128]"
)
private
String
name
;
private
String
name
;
@ApiModelProperty
(
position
=
13
,
required
=
false
,
value
=
"商品名称[128]"
)
private
String
subtitle
;
@ApiModelProperty
(
position
=
14
,
required
=
false
,
value
=
"商品销售价[20,2]"
)
private
BigDecimal
sellPrice
;
@ApiModelProperty
(
position
=
1
3
,
required
=
true
,
value
=
"商品一级分类ID[30]"
)
@ApiModelProperty
(
position
=
1
5
,
required
=
true
,
value
=
"商品一级分类ID[30]"
)
private
String
cateFid
;
private
String
cateFid
;
@ApiModelProperty
(
position
=
1
4
,
required
=
true
,
value
=
"商品二级分类ID[30]"
)
@ApiModelProperty
(
position
=
1
6
,
required
=
true
,
value
=
"商品二级分类ID[30]"
)
private
String
cateSid
;
private
String
cateSid
;
@ApiModelProperty
(
position
=
1
5
,
required
=
true
,
value
=
"商品三级分类ID[30]"
)
@ApiModelProperty
(
position
=
1
7
,
required
=
true
,
value
=
"商品三级分类ID[30]"
)
private
String
cateTid
;
private
String
cateTid
;
@ApiModelProperty
(
position
=
1
6
,
required
=
false
,
value
=
"商品简介[256]"
,
example
=
"商品简介..."
)
@ApiModelProperty
(
position
=
1
8
,
required
=
false
,
value
=
"商品简介[256]"
,
example
=
"商品简介..."
)
private
String
intro
;
private
String
intro
;
@ApiModelProperty
(
position
=
1
7
,
required
=
false
,
value
=
"商品标签列表"
)
@ApiModelProperty
(
position
=
1
9
,
required
=
false
,
value
=
"商品标签列表"
)
private
List
<
String
>
tagList
;
private
List
<
String
>
tagList
;
@ApiModelProperty
(
position
=
18
,
required
=
true
,
value
=
"商品图片列表"
)
@ApiModelProperty
(
position
=
20
,
required
=
true
,
value
=
"商品图片列表"
)
private
List
<
String
>
imageList
;
private
List
<
String
>
imageList
;
@ApiModelProperty
(
position
=
19
,
required
=
false
,
value
=
"商品视频地址"
)
@ApiModelProperty
(
position
=
21
,
required
=
false
,
value
=
"商品视频地址"
)
private
String
coverPic
;
private
String
coverPic
;
@ApiModelProperty
(
position
=
2
0
,
required
=
false
,
value
=
"商品视频地址"
)
@ApiModelProperty
(
position
=
2
2
,
required
=
false
,
value
=
"商品视频地址"
)
private
String
video
;
private
String
video
;
/** ---------------------------- 价格库存 ---------------------------- **/
/**
* ---------------------------- 价格库存 ----------------------------
**/
@ApiModelProperty
(
position
=
2
1
,
required
=
true
,
value
=
"规格展现方式[1-常规|2-组合]"
,
allowableValues
=
"1,2"
,
example
=
"1"
)
@ApiModelProperty
(
position
=
2
3
,
required
=
true
,
value
=
"规格展现方式[1-常规|2-组合]"
,
allowableValues
=
"1,2"
,
example
=
"1"
)
private
String
specMode
;
private
String
specMode
;
@ApiModelProperty
(
position
=
2
2
,
required
=
true
,
value
=
"SKU规格信息"
)
@ApiModelProperty
(
position
=
2
4
,
required
=
true
,
value
=
"SKU规格信息"
)
private
List
<
GoblinStoreMgtGoodsAddSkuParam
>
skuParamList
;
private
List
<
GoblinStoreMgtGoodsAddSkuParam
>
skuParamList
;
@ApiModelProperty
(
position
=
2
3
,
required
=
true
,
value
=
"物流模版"
,
example
=
"松鼠德邦"
)
@ApiModelProperty
(
position
=
2
5
,
required
=
true
,
value
=
"物流模版"
,
example
=
"松鼠德邦"
)
private
String
logisticsTemplate
;
private
String
logisticsTemplate
;
@ApiModelProperty
(
position
=
2
4
,
required
=
false
,
value
=
"商品编码[默认为系统编码,也可手动输入商家自己的编码]"
)
@ApiModelProperty
(
position
=
2
6
,
required
=
false
,
value
=
"商品编码[默认为系统编码,也可手动输入商家自己的编码]"
)
private
String
spuNo
;
private
String
spuNo
;
/** ---------------------------- 商品介绍 ---------------------------- **/
/**
* ---------------------------- 商品介绍 ----------------------------
**/
@ApiModelProperty
(
position
=
2
5
,
required
=
true
,
value
=
"商品详情"
,
example
=
"商品详情..."
)
@ApiModelProperty
(
position
=
2
7
,
required
=
true
,
value
=
"商品详情"
,
example
=
"商品详情..."
)
private
String
details
;
private
String
details
;
/** ---------------------------- 销售属性 ---------------------------- **/
/**
* ---------------------------- 销售属性 ----------------------------
**/
@ApiModelProperty
(
position
=
2
6
,
required
=
true
,
value
=
"上架处理方式[1-等待手动上架|2-直接上架售卖|3-预约定时上架]"
,
example
=
"1"
)
@ApiModelProperty
(
position
=
2
8
,
required
=
true
,
value
=
"上架处理方式[1-等待手动上架|2-直接上架售卖|3-预约定时上架]"
,
example
=
"1"
)
private
String
shelvesHandle
;
private
String
shelvesHandle
;
@ApiModelProperty
(
position
=
2
7
,
required
=
false
,
value
=
"预约上架时间[上架处理方式为3-预约定时上架时需要指定]"
)
@ApiModelProperty
(
position
=
2
9
,
required
=
false
,
value
=
"预约上架时间[上架处理方式为3-预约定时上架时需要指定]"
)
@Pattern
(
regexp
=
LnsRegex
.
Valid
.
DATETIME_FULL
,
message
=
"预约上架时间格式有误"
)
@Pattern
(
regexp
=
LnsRegex
.
Valid
.
DATETIME_FULL
,
message
=
"预约上架时间格式有误"
)
private
String
shelvesTime
;
private
String
shelvesTime
;
@ApiModelProperty
(
position
=
28
,
required
=
false
,
value
=
"商品有效期[YYYY-MM-DD]"
)
@ApiModelProperty
(
position
=
30
,
required
=
false
,
value
=
"商品有效期[YYYY-MM-DD]"
)
@Pattern
(
regexp
=
LnsRegex
.
Valid
.
DATETIME_YMD
,
message
=
"商品有效期格式有误"
)
@Pattern
(
regexp
=
LnsRegex
.
Valid
.
DATETIME_YMD
,
message
=
"商品有效期格式有误"
)
private
String
spuValidity
;
private
String
spuValidity
;
@ApiModelProperty
(
position
=
29
,
required
=
true
,
value
=
"是否虚拟商品[0-否|1-是]"
,
allowableValues
=
"0,1"
,
example
=
"0"
)
@ApiModelProperty
(
position
=
31
,
required
=
true
,
value
=
"是否虚拟商品[0-否|1-是]"
,
allowableValues
=
"0,1"
,
example
=
"0"
)
@Pattern
(
regexp
=
"\\b(0|1)\\b"
,
message
=
"是否虚拟商品参数无效"
)
@Pattern
(
regexp
=
"\\b(0|1)\\b"
,
message
=
"是否虚拟商品参数无效"
)
private
String
virtualFlg
;
private
String
virtualFlg
;
/** ---------------------------- 服务保障 ---------------------------- **/
/**
* ---------------------------- 服务保障 ----------------------------
**/
@ApiModelProperty
(
position
=
3
0
,
required
=
false
,
value
=
"商品服务支持ID列表"
)
@ApiModelProperty
(
position
=
3
2
,
required
=
false
,
value
=
"商品服务支持ID列表"
)
private
List
<
String
>
ssidList
;
private
List
<
String
>
ssidList
;
/** ---------------------------- 专属标签 ---------------------------- **/
/**
* ---------------------------- 专属标签 ----------------------------
**/
@ApiModelProperty
(
position
=
3
1
,
required
=
true
,
value
=
"商品关联音乐人、艺术家、IP列表"
)
@ApiModelProperty
(
position
=
3
3
,
required
=
true
,
value
=
"商品关联音乐人、艺术家、IP列表"
)
private
List
<
String
>
extagList
;
private
List
<
String
>
extagList
;
/**
* 生成SPU
*
* @return GoblinGoodsInfoVo
*/
public
GoblinGoodsInfoVo
initGoodsInfoVo
()
{
public
GoblinGoodsInfoVo
initGoodsInfoVo
()
{
GoblinGoodsInfoVo
vo
=
GoblinGoodsInfoVo
.
getNew
();
GoblinGoodsInfoVo
vo
=
GoblinGoodsInfoVo
.
getNew
();
vo
.
setStoreId
(
this
.
getStoreId
());
vo
.
setStoreId
(
this
.
getStoreId
());
vo
.
setSpuId
(
IDGenerator
.
nextMilliId2
());
if
(
StringUtils
.
isBlank
(
this
.
getSpuId
()))
{
vo
.
setSpuId
(
IDGenerator
.
nextMilliId2
());
}
else
{
vo
.
setSpuId
(
this
.
getSpuId
());
}
vo
.
setSpuNo
(
IDGenerator
.
nextTimeId2
());
vo
.
setSpuNo
(
IDGenerator
.
nextTimeId2
());
vo
.
setName
(
this
.
getName
());
vo
.
setName
(
this
.
getName
());
// vo.setSubtitle(null
);
vo
.
setSubtitle
(
this
.
getSubtitle
()
);
// vo.setSellPrice(BigDecimal.ZERO
);
vo
.
setSellPrice
(
this
.
getSellPrice
()
);
// vo.setPriceGe(BigDecimal.ZERO);
// vo.setPriceGe(BigDecimal.ZERO);
// vo.setPriceLe(BigDecimal.ZERO);
// vo.setPriceLe(BigDecimal.ZERO);
vo
.
setIntro
(
this
.
getIntro
());
vo
.
setIntro
(
this
.
getIntro
());
...
@@ -131,14 +163,29 @@ public class GoblinStoreMgtGoodsAddParam implements Serializable {
...
@@ -131,14 +163,29 @@ public class GoblinStoreMgtGoodsAddParam implements Serializable {
return
vo
;
return
vo
;
}
}
public
void
initGoodsSkuInfoVo
(
GoblinGoodsInfoVo
goodsInfoVo
,
List
<
GoblinGoodsSkuInfoVo
>
vos
)
{
/**
* 生成SKU列表以及SPU规格等信息
*
* @param goodsInfoVo
* @param vos
* @param goodsSpecVos
*/
public
void
initGoodsSkuInfoVo
(
GoblinGoodsInfoVo
goodsInfoVo
,
List
<
GoblinGoodsSkuInfoVo
>
vos
,
List
<
GoblinGoodsSpecVo
>
goodsSpecVos
)
{
List
<
GoblinStoreMgtGoodsAddSkuParam
>
mgtGoodsAddSkuParamList
=
this
.
getSkuParamList
();
List
<
GoblinStoreMgtGoodsAddSkuParam
>
mgtGoodsAddSkuParamList
=
this
.
getSkuParamList
();
int
size
=
mgtGoodsAddSkuParamList
.
size
();
int
size
=
mgtGoodsAddSkuParamList
.
size
();
BigDecimal
priceGe
=
BigDecimal
.
ZERO
,
priceLe
=
BigDecimal
.
ZERO
;
for
(
int
i
=
0
;
i
<
size
;
i
++)
{
for
(
int
i
=
0
;
i
<
size
;
i
++)
{
GoblinStoreMgtGoodsAddSkuParam
addSkuParam
=
mgtGoodsAddSkuParamList
.
get
(
i
);
GoblinStoreMgtGoodsAddSkuParam
addSkuParam
=
mgtGoodsAddSkuParamList
.
get
(
i
);
String
skuId
=
addSkuParam
.
getSkuId
();
GoblinGoodsSkuInfoVo
vo
=
GoblinGoodsSkuInfoVo
.
getNew
();
GoblinGoodsSkuInfoVo
vo
=
GoblinGoodsSkuInfoVo
.
getNew
();
vo
.
setSkuId
(
goodsInfoVo
.
getSpuId
().
concat
(
StringUtils
.
right
(
String
.
valueOf
(
System
.
nanoTime
()),
5
)));
if
(
StringUtils
.
isBlank
(
skuId
))
{
vo
.
setSkuId
(
goodsInfoVo
.
getSpuId
().
concat
(
StringUtils
.
right
(
String
.
valueOf
(
System
.
nanoTime
()),
5
)));
}
else
{
vo
.
setSkuId
(
skuId
);
}
vo
.
setSpuId
(
goodsInfoVo
.
getSpuId
());
vo
.
setSpuId
(
goodsInfoVo
.
getSpuId
());
vo
.
setSkuNo
(
goodsInfoVo
.
getSpuNo
().
concat
(
"-"
).
concat
(
String
.
valueOf
(
i
)));
vo
.
setSkuNo
(
goodsInfoVo
.
getSpuNo
().
concat
(
"-"
).
concat
(
String
.
valueOf
(
i
)));
vo
.
setName
(
goodsInfoVo
.
getName
());
vo
.
setName
(
goodsInfoVo
.
getName
());
...
@@ -147,6 +194,51 @@ public class GoblinStoreMgtGoodsAddParam implements Serializable {
...
@@ -147,6 +194,51 @@ public class GoblinStoreMgtGoodsAddParam implements Serializable {
vo
.
setSkuIsbn
(
addSkuParam
.
getSkuIsbn
());
vo
.
setSkuIsbn
(
addSkuParam
.
getSkuIsbn
());
vo
.
setStock
(
addSkuParam
.
getStock
());
vo
.
setStock
(
addSkuParam
.
getStock
());
vo
.
setSkuStock
(
vo
.
getStock
());
vo
.
setSkuStock
(
vo
.
getStock
());
vo
.
setWarningStock
(
addSkuParam
.
getWarningStock
());
vo
.
setSellPrice
(
addSkuParam
.
getSellPrice
());
vo
.
setPrice
(
addSkuParam
.
getPrice
());
vo
.
setPriceMember
(
addSkuParam
.
getPriceMember
());
vo
.
setWeight
(
addSkuParam
.
getWeight
());
vo
.
setBuyFactor
(
addSkuParam
.
getBuyFactor
());
vo
.
setBuyRoster
(
addSkuParam
.
getBuyRoster
());
vo
.
setBuyLimit
(
addSkuParam
.
getBuyLimit
());
vo
.
setStoreId
(
goodsInfoVo
.
getStoreId
());
vo
.
setSkuValidity
(
DateUtil
.
Formatter
.
yyyyMMddHHmmss
.
parse
(
addSkuParam
.
getSkuValidity
()));
vo
.
setVirtualFlg
(
goodsInfoVo
.
getVirtualFlg
());
vo
.
setStatus
(
"3"
);
// 没有审核流程,默认通过
// vo.setReason();
vo
.
setShelvesStatus
(
"0"
);
vo
.
setSkuNo
(
"0"
);
// vo.setShelvesAt();
vo
.
setCreatedBy
(
goodsInfoVo
.
getCreatedBy
());
vo
.
setCreatedAt
(
goodsInfoVo
.
getCreatedAt
());
// vo.setUpdatedBy();
// vo.setUpdatedAt();
vo
.
setLogisticsTemplate
(
goodsInfoVo
.
getLogisticsTemplate
());
List
<
GoblinGoodsSpecDto
>
skuSpecList
=
addSkuParam
.
getSkuSpecList
();
vo
.
setSkuSpecList
(
skuSpecList
);
vos
.
add
(
vo
);
int
specSize
=
skuSpecList
.
size
();
// SKU包含的规格数量
for
(
int
j
=
0
;
j
<
specSize
;
j
++)
{
GoblinGoodsSpecDto
specDto
=
skuSpecList
.
get
(
j
);
GoblinGoodsSpecValueVo
specValueVo
=
GoblinGoodsSpecValueVo
.
getNew
().
setSpecVname
(
specDto
.
getSpecVname
()).
setSpecVsort
(
0
);
if
(
CollectionUtils
.
isEmpty
(
goodsSpecVos
))
{
// 初始化生成商品规格
ArrayList
<
GoblinGoodsSpecValueVo
>
specValueVos
=
new
ArrayList
<>();
specValueVos
.
add
(
specValueVo
);
goodsSpecVos
.
add
(
GoblinGoodsSpecVo
.
getNew
()
.
setSpecName
(
specDto
.
getSpecName
()).
setSpecSort
(
0
).
setSpecValues
(
specValueVos
));
}
else
{
// 补充规格对应的值
goodsSpecVos
.
get
(
i
).
getSpecValues
().
add
(
specValueVo
);
}
}
}
}
goodsInfoVo
.
setPriceGe
(
priceGe
);
goodsInfoVo
.
setPriceLe
(
priceLe
);
goodsInfoVo
.
setSpecVoList
(
goodsSpecVos
);
}
}
}
}
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/manage/GoblinStoreMgtGoodsAddSkuParam.java
View file @
13171a6d
package
com
.
liquidnet
.
service
.
goblin
.
dto
.
manage
;
package
com
.
liquidnet
.
service
.
goblin
.
dto
.
manage
;
import
com.liquidnet.commons.lang.constant.LnsRegex
;
import
com.liquidnet.service.goblin.dto.GoblinGoodsSpecDto
;
import
com.liquidnet.service.goblin.dto.GoblinGoodsSpecDto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.Data
;
import
javax.validation.constraints.Pattern
;
import
java.io.Serializable
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.util.List
;
import
java.util.List
;
...
@@ -13,26 +15,33 @@ import java.util.List;
...
@@ -13,26 +15,33 @@ import java.util.List;
@Data
@Data
public
class
GoblinStoreMgtGoodsAddSkuParam
implements
Serializable
{
public
class
GoblinStoreMgtGoodsAddSkuParam
implements
Serializable
{
private
static
final
long
serialVersionUID
=
6657596593310537491L
;
private
static
final
long
serialVersionUID
=
6657596593310537491L
;
/** ---------------------------- 规格信息 ---------------------------- **/
@ApiModelProperty
(
position
=
10
,
required
=
false
,
value
=
"单品ID[编辑时必传]"
)
private
String
skuId
;
@ApiModelProperty
(
position
=
11
,
value
=
"单品默认图片的url[256]"
)
@ApiModelProperty
(
position
=
11
,
required
=
true
,
value
=
"单品默认图片的url[256]"
)
private
String
skuPic
;
private
String
skuPic
;
@ApiModelProperty
(
position
=
12
,
value
=
"单品规格信息"
)
@ApiModelProperty
(
position
=
12
,
required
=
true
,
value
=
"单品规格信息"
)
private
List
<
GoblinGoodsSpecDto
>
skuSpecList
;
private
List
<
GoblinGoodsSpecDto
>
skuSpecList
;
@ApiModelProperty
(
position
=
13
,
value
=
"单品价格[20,2]"
)
@ApiModelProperty
(
position
=
13
,
required
=
false
,
value
=
"单品销售价[20,2]"
)
private
BigDecimal
sellPrice
;
@ApiModelProperty
(
position
=
14
,
required
=
true
,
value
=
"单品价格[20,2]"
)
private
BigDecimal
price
;
private
BigDecimal
price
;
@ApiModelProperty
(
position
=
1
4
,
value
=
"单品会员价格[20,2]"
)
@ApiModelProperty
(
position
=
1
5
,
required
=
true
,
value
=
"单品会员价格[20,2]"
)
private
BigDecimal
priceMember
;
private
BigDecimal
priceMember
;
@ApiModelProperty
(
position
=
1
5
,
value
=
"单品的重量[20,2]"
)
@ApiModelProperty
(
position
=
1
6
,
required
=
false
,
value
=
"单品的重量[20,2]"
)
private
BigDecimal
weight
;
private
BigDecimal
weight
;
@ApiModelProperty
(
position
=
1
6
,
value
=
"总库存"
)
@ApiModelProperty
(
position
=
1
7
,
required
=
true
,
value
=
"总库存"
)
private
Integer
stock
;
private
Integer
stock
;
@ApiModelProperty
(
position
=
17
,
value
=
"ISBN,针对CD/图书等[100]"
)
@ApiModelProperty
(
position
=
18
,
required
=
false
,
value
=
"预警库存"
)
private
Integer
warningStock
;
@ApiModelProperty
(
position
=
19
,
required
=
false
,
value
=
"ISBN,针对CD/图书等[100]"
)
private
String
skuIsbn
;
private
String
skuIsbn
;
@ApiModelProperty
(
position
=
18
,
value
=
"购买限制[0-全部用户|1-仅会员|2-指定用户]"
)
@ApiModelProperty
(
position
=
20
,
required
=
true
,
value
=
"购买限制[0-全部用户|1-仅会员|2-指定用户]"
)
private
String
buyFactor
;
private
String
buyFactor
;
@ApiModelProperty
(
position
=
19
,
value
=
"购买限制人员名单[购买限制为2-指定用户时必填]"
)
@ApiModelProperty
(
position
=
21
,
required
=
false
,
value
=
"购买限制人员名单[购买限制为2-指定用户时必填]"
)
private
String
buyRoster
;
private
String
buyRoster
;
@ApiModelProperty
(
position
=
2
0
,
value
=
"限量[0-无限制|X:限购数量]"
)
@ApiModelProperty
(
position
=
2
2
,
required
=
false
,
value
=
"限量[0-无限制|X:限购数量]"
)
private
Integer
buyLimit
;
private
Integer
buyLimit
;
@ApiModelProperty
(
position
=
23
,
required
=
false
,
value
=
"单品有效期[yyyy-MM-dd HH:mm:ss]"
)
@Pattern
(
regexp
=
LnsRegex
.
Valid
.
DATETIME_FULL
,
message
=
"单品有效期格式有误"
)
private
String
skuValidity
;
}
}
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/vo/GoblinGoodsInfoVo.java
View file @
13171a6d
...
@@ -93,6 +93,9 @@ public class GoblinGoodsInfoVo implements Serializable, Cloneable {
...
@@ -93,6 +93,9 @@ public class GoblinGoodsInfoVo implements Serializable, Cloneable {
@ApiModelProperty
(
position
=
55
,
value
=
"活动Id"
)
@ApiModelProperty
(
position
=
55
,
value
=
"活动Id"
)
private
String
marketId
;
private
String
marketId
;
@ApiModelProperty
(
position
=
55
,
value
=
"SPU包含的SKU_ID列表"
)
private
List
<
String
>
skuIdList
;
private
static
final
GoblinGoodsInfoVo
obj
=
new
GoblinGoodsInfoVo
();
private
static
final
GoblinGoodsInfoVo
obj
=
new
GoblinGoodsInfoVo
();
public
static
GoblinGoodsInfoVo
getNew
()
{
public
static
GoblinGoodsInfoVo
getNew
()
{
...
...
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/vo/GoblinGoodsSkuInfoVo.java
View file @
13171a6d
package
com
.
liquidnet
.
service
.
goblin
.
dto
.
vo
;
package
com
.
liquidnet
.
service
.
goblin
.
dto
.
vo
;
import
com.liquidnet.service.goblin.dto.GoblinGoodsSpecDto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -7,6 +8,7 @@ import lombok.Data;
...
@@ -7,6 +8,7 @@ import lombok.Data;
import
java.io.Serializable
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
java.time.LocalDateTime
;
import
java.util.List
;
@ApiModel
(
value
=
"GoblinGoodsSkuInfoVo"
,
description
=
"商品SKU信息"
)
@ApiModel
(
value
=
"GoblinGoodsSkuInfoVo"
,
description
=
"商品SKU信息"
)
@Data
@Data
...
@@ -32,33 +34,35 @@ public class GoblinGoodsSkuInfoVo implements Serializable, Cloneable {
...
@@ -32,33 +34,35 @@ public class GoblinGoodsSkuInfoVo implements Serializable, Cloneable {
private
Integer
skuStock
;
private
Integer
skuStock
;
@ApiModelProperty
(
position
=
19
,
value
=
"预警库存"
)
@ApiModelProperty
(
position
=
19
,
value
=
"预警库存"
)
private
Integer
warningStock
;
private
Integer
warningStock
;
@ApiModelProperty
(
position
=
20
,
value
=
"单品价格[20,2]"
)
@ApiModelProperty
(
position
=
20
,
value
=
"单品销售价[20,2]"
)
private
BigDecimal
sellPrice
;
@ApiModelProperty
(
position
=
21
,
value
=
"单品价格[20,2]"
)
private
BigDecimal
price
;
private
BigDecimal
price
;
@ApiModelProperty
(
position
=
2
1
,
value
=
"单品会员价格[20,2]"
)
@ApiModelProperty
(
position
=
2
2
,
value
=
"单品会员价格[20,2]"
)
private
BigDecimal
priceMember
;
private
BigDecimal
priceMember
;
@ApiModelProperty
(
position
=
2
2
,
value
=
"单品的重量[20,2]"
)
@ApiModelProperty
(
position
=
2
3
,
value
=
"单品的重量[20,2]"
)
private
BigDecimal
weight
;
private
BigDecimal
weight
;
@ApiModelProperty
(
position
=
2
3
,
value
=
"购买限制[0-全部用户|1-仅会员|2-指定用户]"
)
@ApiModelProperty
(
position
=
2
4
,
value
=
"购买限制[0-全部用户|1-仅会员|2-指定用户]"
)
private
String
buyFactor
;
private
String
buyFactor
;
@ApiModelProperty
(
position
=
2
4
,
value
=
"购买限制人员名单[购买限制为2-指定用户时必填]"
)
@ApiModelProperty
(
position
=
2
5
,
value
=
"购买限制人员名单[购买限制为2-指定用户时必填]"
)
private
String
buyRoster
;
private
String
buyRoster
;
@ApiModelProperty
(
position
=
2
5
,
value
=
"限量[0-无限制|X:限购数量]"
)
@ApiModelProperty
(
position
=
2
6
,
value
=
"限量[0-无限制|X:限购数量]"
)
private
Integer
buyLimit
;
private
Integer
buyLimit
;
@ApiModelProperty
(
position
=
2
6
,
value
=
"商品的店铺ID,如果是平台的则为0"
)
@ApiModelProperty
(
position
=
2
7
,
value
=
"商品的店铺ID,如果是平台的则为0"
)
private
String
storeId
;
private
String
storeId
;
@ApiModelProperty
(
position
=
2
7
,
value
=
"单品有效期"
)
@ApiModelProperty
(
position
=
2
8
,
value
=
"单品有效期"
)
private
LocalDateTime
skuValidity
;
private
LocalDateTime
skuValidity
;
@ApiModelProperty
(
position
=
2
8
,
value
=
"是否是虚拟商品[0-否|1-是]"
)
@ApiModelProperty
(
position
=
2
9
,
value
=
"是否是虚拟商品[0-否|1-是]"
)
private
String
virtualFlg
;
private
String
virtualFlg
;
@ApiModelProperty
(
position
=
29
,
value
=
"审核状态[0-初始编辑|1-审核中|2-审核不通过|3-审核通过]"
)
@ApiModelProperty
(
position
=
30
,
value
=
"审核状态[0-初始编辑|1-审核中|2-审核不通过|3-审核通过]"
)
private
String
status
;
private
String
status
;
@ApiModelProperty
(
position
=
3
0
,
value
=
"审核拒绝原因[256]"
)
@ApiModelProperty
(
position
=
3
1
,
value
=
"审核拒绝原因[256]"
)
private
String
reason
;
private
String
reason
;
@ApiModelProperty
(
position
=
3
1
,
value
=
"单品上架状态[0-待上架|1-下架|2-违规|3-上架]"
)
@ApiModelProperty
(
position
=
3
2
,
value
=
"单品上架状态[0-待上架|1-下架|2-违规|3-上架]"
)
private
String
shelvesStatus
;
private
String
shelvesStatus
;
@ApiModelProperty
(
position
=
3
2
,
value
=
"自定义展示[0-默认展示|1-隐藏不可购买]"
)
@ApiModelProperty
(
position
=
3
3
,
value
=
"自定义展示[0-默认展示|1-隐藏不可购买]"
)
private
String
skuAppear
;
private
String
skuAppear
;
@ApiModelProperty
(
position
=
3
3
,
value
=
"上架时间"
)
@ApiModelProperty
(
position
=
3
4
,
value
=
"上架时间"
)
private
LocalDateTime
shelvesAt
;
private
LocalDateTime
shelvesAt
;
@ApiModelProperty
(
position
=
34
,
value
=
"活动Id"
)
@ApiModelProperty
(
position
=
34
,
value
=
"活动Id"
)
private
String
marketId
;
private
String
marketId
;
...
@@ -69,6 +73,9 @@ public class GoblinGoodsSkuInfoVo implements Serializable, Cloneable {
...
@@ -69,6 +73,9 @@ public class GoblinGoodsSkuInfoVo implements Serializable, Cloneable {
@ApiModelProperty
(
position
=
35
,
value
=
"物流模版ID"
)
@ApiModelProperty
(
position
=
35
,
value
=
"物流模版ID"
)
private
String
logisticsTemplate
;
private
String
logisticsTemplate
;
@ApiModelProperty
(
position
=
40
,
value
=
"单品规格信息"
)
private
List
<
GoblinGoodsSpecDto
>
skuSpecList
;
private
static
final
GoblinGoodsSkuInfoVo
obj
=
new
GoblinGoodsSkuInfoVo
();
private
static
final
GoblinGoodsSkuInfoVo
obj
=
new
GoblinGoodsSkuInfoVo
();
public
static
GoblinGoodsSkuInfoVo
getNew
()
{
public
static
GoblinGoodsSkuInfoVo
getNew
()
{
...
...
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/vo/GoblinGoodsSpecValueVo.java
View file @
13171a6d
...
@@ -13,7 +13,17 @@ public class GoblinGoodsSpecValueVo implements Serializable, Cloneable {
...
@@ -13,7 +13,17 @@ public class GoblinGoodsSpecValueVo implements Serializable, Cloneable {
@ApiModelProperty
(
position
=
11
,
value
=
"规格值的名称"
)
@ApiModelProperty
(
position
=
11
,
value
=
"规格值的名称"
)
private
String
specVname
;
private
String
specVname
;
@ApiModelProperty
(
position
=
12
,
value
=
"排序[数值越小排序越前]"
)
@ApiModelProperty
(
position
=
12
,
value
=
"排序[数值越小排序越前]"
)
private
String
specVsort
;
private
int
specVsort
;
public
GoblinGoodsSpecValueVo
setSpecVname
(
String
specVname
)
{
this
.
specVname
=
specVname
;
return
this
;
}
public
GoblinGoodsSpecValueVo
setSpecVsort
(
int
specVsort
)
{
this
.
specVsort
=
specVsort
;
return
this
;
}
private
static
final
GoblinGoodsSpecValueVo
obj
=
new
GoblinGoodsSpecValueVo
();
private
static
final
GoblinGoodsSpecValueVo
obj
=
new
GoblinGoodsSpecValueVo
();
public
static
GoblinGoodsSpecValueVo
getNew
()
{
public
static
GoblinGoodsSpecValueVo
getNew
()
{
...
...
liquidnet-bus-api/liquidnet-service-goblin-api/src/main/java/com/liquidnet/service/goblin/dto/vo/GoblinGoodsSpecVo.java
View file @
13171a6d
...
@@ -14,10 +14,25 @@ public class GoblinGoodsSpecVo implements Serializable, Cloneable {
...
@@ -14,10 +14,25 @@ public class GoblinGoodsSpecVo implements Serializable, Cloneable {
@ApiModelProperty
(
position
=
11
,
value
=
"规格名称"
)
@ApiModelProperty
(
position
=
11
,
value
=
"规格名称"
)
private
String
specName
;
private
String
specName
;
@ApiModelProperty
(
position
=
12
,
value
=
"排序[数值越小排序越前]"
)
@ApiModelProperty
(
position
=
12
,
value
=
"排序[数值越小排序越前]"
)
private
String
specSort
;
private
int
specSort
;
@ApiModelProperty
(
position
=
13
,
value
=
"规格值列表"
)
@ApiModelProperty
(
position
=
13
,
value
=
"规格值列表"
)
private
List
<
GoblinGoodsSpecValueVo
>
specValues
;
private
List
<
GoblinGoodsSpecValueVo
>
specValues
;
public
GoblinGoodsSpecVo
setSpecName
(
String
specName
)
{
this
.
specName
=
specName
;
return
this
;
}
public
GoblinGoodsSpecVo
setSpecSort
(
int
specSort
)
{
this
.
specSort
=
specSort
;
return
this
;
}
public
GoblinGoodsSpecVo
setSpecValues
(
List
<
GoblinGoodsSpecValueVo
>
specValues
)
{
this
.
specValues
=
specValues
;
return
this
;
}
private
static
final
GoblinGoodsSpecVo
obj
=
new
GoblinGoodsSpecVo
();
private
static
final
GoblinGoodsSpecVo
obj
=
new
GoblinGoodsSpecVo
();
public
static
GoblinGoodsSpecVo
getNew
()
{
public
static
GoblinGoodsSpecVo
getNew
()
{
try
{
try
{
...
...
liquidnet-bus-do/liquidnet-service-goblin-do/src/main/java/com/liquidnet/service/goblin/entity/GoblinGoodsSku.java
View file @
13171a6d
...
@@ -42,6 +42,11 @@ public class GoblinGoodsSku implements Serializable {
...
@@ -42,6 +42,11 @@ public class GoblinGoodsSku implements Serializable {
*/
*/
private
String
subtitle
;
private
String
subtitle
;
/**
* 单品销售价
*/
private
BigDecimal
sellPrice
;
/**
/**
* 单品默认图片的url
* 单品默认图片的url
*/
*/
...
...
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/docu/db_ln_goblin_initialdata.sql
View file @
13171a6d
...
@@ -287,6 +287,7 @@ create table goblin_goods_sku
...
@@ -287,6 +287,7 @@ create table goblin_goods_sku
sku_no
varchar
(
45
)
not
null
comment
'单品的编号'
,
sku_no
varchar
(
45
)
not
null
comment
'单品的编号'
,
name
varchar
(
100
)
not
null
comment
'单品的名称'
,
name
varchar
(
100
)
not
null
comment
'单品的名称'
,
subtitle
varchar
(
128
)
null
comment
'单品的副标题'
,
subtitle
varchar
(
128
)
null
comment
'单品的副标题'
,
sell_price
decimal
(
20
,
2
)
null
comment
'单品销售价'
,
sku_pic
varchar
(
256
)
null
comment
'单品默认图片的url'
,
sku_pic
varchar
(
256
)
null
comment
'单品默认图片的url'
,
sku_isbn
varchar
(
50
)
null
comment
'ISBN,针对CD/图书等'
,
sku_isbn
varchar
(
50
)
null
comment
'ISBN,针对CD/图书等'
,
...
...
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/util/ObjectUtil.java
View file @
13171a6d
...
@@ -2,8 +2,7 @@ package com.liquidnet.service.goblin.util;
...
@@ -2,8 +2,7 @@ package com.liquidnet.service.goblin.util;
import
com.liquidnet.service.base.PagedResult
;
import
com.liquidnet.service.base.PagedResult
;
import
com.liquidnet.service.goblin.dto.manage.vo.GoblinStoreMgtGoodsListVo
;
import
com.liquidnet.service.goblin.dto.manage.vo.GoblinStoreMgtGoodsListVo
;
import
com.liquidnet.service.goblin.dto.vo.GoblinGoodsSkuInfoVo
;
import
com.liquidnet.service.goblin.dto.vo.*
;
import
com.liquidnet.service.goblin.dto.vo.GoblinSelfMarketingVo
;
import
com.liquidnet.service.goblin.entity.GoblinFrontBanner
;
import
com.liquidnet.service.goblin.entity.GoblinFrontBanner
;
import
com.mongodb.BasicDBObject
;
import
com.mongodb.BasicDBObject
;
...
@@ -15,6 +14,10 @@ public class ObjectUtil {
...
@@ -15,6 +14,10 @@ public class ObjectUtil {
private
static
final
ArrayList
<
GoblinFrontBanner
>
goblinFrontBannerArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinFrontBanner
>
goblinFrontBannerArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinSelfMarketingVo
>
goblinSelfMarketingVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinSelfMarketingVo
>
goblinSelfMarketingVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinGoodsSkuInfoVo
>
goblinGoodsSkuInfoVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinGoodsSkuInfoVo
>
goblinGoodsSkuInfoVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinGoodsSpecVo
>
goblinGoodsSpecVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinGoodsTagVo
>
goblinGoodsTagVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinGoodsServiceSupportVo
>
goblinGoodsServiceSupportVoArrayList
=
new
ArrayList
<>();
private
static
final
ArrayList
<
GoblinGoodsExtagVo
>
goblinGoodsExtagVoArrayList
=
new
ArrayList
<>();
private
static
final
BasicDBObject
basicDBObject
=
new
BasicDBObject
();
private
static
final
BasicDBObject
basicDBObject
=
new
BasicDBObject
();
...
@@ -34,6 +37,22 @@ public class ObjectUtil {
...
@@ -34,6 +37,22 @@ public class ObjectUtil {
return
(
ArrayList
<
GoblinGoodsSkuInfoVo
>)
goblinGoodsSkuInfoVoArrayList
.
clone
();
return
(
ArrayList
<
GoblinGoodsSkuInfoVo
>)
goblinGoodsSkuInfoVoArrayList
.
clone
();
}
}
public
static
ArrayList
<
GoblinGoodsSpecVo
>
getGoblinGoodsSpecVoArrayList
()
{
return
(
ArrayList
<
GoblinGoodsSpecVo
>)
goblinGoodsSpecVoArrayList
.
clone
();
}
public
static
ArrayList
<
GoblinGoodsTagVo
>
getGoblinGoodsTagVoArrayList
()
{
return
(
ArrayList
<
GoblinGoodsTagVo
>)
goblinGoodsTagVoArrayList
.
clone
();
}
public
static
ArrayList
<
GoblinGoodsServiceSupportVo
>
getGoblinGoodsServiceSupportVoArrayList
()
{
return
(
ArrayList
<
GoblinGoodsServiceSupportVo
>)
goblinGoodsServiceSupportVoArrayList
.
clone
();
}
public
static
ArrayList
<
GoblinGoodsExtagVo
>
getGoblinGoodsExtagVoArrayList
()
{
return
(
ArrayList
<
GoblinGoodsExtagVo
>)
goblinGoodsExtagVoArrayList
.
clone
();
}
public
static
BasicDBObject
cloneBasicDBObject
()
{
public
static
BasicDBObject
cloneBasicDBObject
()
{
return
(
BasicDBObject
)
basicDBObject
.
clone
();
return
(
BasicDBObject
)
basicDBObject
.
clone
();
}
}
...
...
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