## 产品添加仓储编号;
This commit is contained in:
parent
d57f12fd94
commit
cf186d98c7
|
@ -293,11 +293,9 @@ public class BdProductController extends BaseController {
|
|||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 查询产品规格
|
||||
*/
|
||||
|
||||
@PostMapping("/get-product-specs")
|
||||
public AjaxResult getProductSpecs(@RequestBody ProductParams productParams) {
|
||||
List<Integer> productIds = productParams.getProductIds();
|
||||
|
@ -358,7 +356,6 @@ public class BdProductController extends BaseController {
|
|||
/**
|
||||
* 查询产品规格(带是否赠品)
|
||||
*/
|
||||
|
||||
@PostMapping("/get-product-specs-gift")
|
||||
public AjaxResult getProductSpecsGift(@RequestBody ProductParams productParams) {
|
||||
List<ProductGiftParam> productGiftList = productParams.getProductGiftList();
|
||||
|
@ -422,7 +419,6 @@ public class BdProductController extends BaseController {
|
|||
/**
|
||||
* 查询产品规格
|
||||
*/
|
||||
|
||||
@PostMapping("/get-product-code-specs")
|
||||
public AjaxResult getProductCodeSpecs(@RequestBody ProductParams productParams) {
|
||||
List<String> productCodes = productParams.getProductCodes();
|
||||
|
@ -473,13 +469,11 @@ public class BdProductController extends BaseController {
|
|||
specsTypeParam.setSpecsList(resultSpecsList);
|
||||
specsTypeParamList.add(specsTypeParam);
|
||||
}
|
||||
|
||||
}
|
||||
productSpecsInfo.setSpecsTypeData(specsTypeParamList);
|
||||
}
|
||||
resultList.add(productSpecsInfo);
|
||||
}
|
||||
|
||||
return AjaxResult.success(resultList);
|
||||
}
|
||||
|
||||
|
|
|
@ -248,4 +248,9 @@ public class ProductParams implements Serializable {
|
|||
*/
|
||||
private Date removalTime;
|
||||
|
||||
/**
|
||||
* 仓储产品编号
|
||||
*/
|
||||
private String wmsCode;
|
||||
|
||||
}
|
||||
|
|
|
@ -102,7 +102,12 @@ public class BdProductServiceImpl extends ServiceImpl<BdProductMapper, BdProduct
|
|||
bdProduct.setPkSupplier(cubasdoc.getPkSupplier());
|
||||
}
|
||||
}
|
||||
if (StringUtils.isEmpty(bdProduct.getWmsCode())) {
|
||||
// 仓储产品编号为空,则默认使用产品编号
|
||||
bdProduct.setWmsCode(bdProduct.getProductCode());
|
||||
}
|
||||
this.save(bdProduct);
|
||||
|
||||
// 生成拓展表
|
||||
BdProductExtend productExtend = BeanUtil.copyProperties(productParams, BdProductExtend.class);
|
||||
productExtend.setPkProduct(bdProduct.getPkId());
|
||||
|
@ -236,6 +241,10 @@ public class BdProductServiceImpl extends ServiceImpl<BdProductMapper, BdProduct
|
|||
if (productParams.getIsPutOn().equals(EYesNo.NO.getIntValue())) {
|
||||
bdProduct.setRemovalTime(DateUtils.currentDateTime());
|
||||
}
|
||||
if (StringUtils.isEmpty(bdProduct.getWmsCode())) {
|
||||
// 仓储产品编号为空,则默认使用产品编号
|
||||
bdProduct.setWmsCode(bdProduct.getProductCode());
|
||||
}
|
||||
this.updateById(bdProduct);
|
||||
// 生成拓展表
|
||||
BdProductExtend productExtend = BeanUtil.copyProperties(productParams, BdProductExtend.class);
|
||||
|
|
|
@ -1,27 +1,14 @@
|
|||
package com.hzs.sale.product.vo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableLogic;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
import com.hzs.common.core.annotation.BigDecimalFormat;
|
||||
import com.hzs.common.core.annotation.Excel;
|
||||
import com.hzs.common.core.web.domain.BaseEntity;
|
||||
import com.hzs.common.domain.sale.product.BdProduct;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @Description:
|
||||
* @Author: yuhui
|
||||
* @Time: 2022/10/28 16:26
|
||||
* @Classname: ProductVo
|
||||
* @PackageName: com.hzs.sale.product.vo
|
||||
*/
|
||||
@Data
|
||||
public class ProductVo implements Serializable {
|
||||
|
||||
|
@ -57,11 +44,9 @@ public class ProductVo implements Serializable {
|
|||
@Excel(name = "产品编码")
|
||||
private String productCode;
|
||||
|
||||
|
||||
/**
|
||||
* 所属分类
|
||||
*/
|
||||
|
||||
private Integer pkClassify;
|
||||
/**
|
||||
* 发货渠道
|
||||
|
@ -184,7 +169,7 @@ public class ProductVo implements Serializable {
|
|||
*/
|
||||
private Integer isMerge;
|
||||
/**
|
||||
*合并发货 翻译
|
||||
* 合并发货 翻译
|
||||
*/
|
||||
@Excel(name = "合并发货")
|
||||
private String isMergeVal;
|
||||
|
@ -199,11 +184,9 @@ public class ProductVo implements Serializable {
|
|||
@Excel(name = "冷链运输")
|
||||
private String isFreshVal;
|
||||
|
||||
|
||||
/**
|
||||
* 是否海运
|
||||
*/
|
||||
|
||||
private Integer isOceanTrans;
|
||||
/**
|
||||
* 是否空运
|
||||
|
@ -213,7 +196,6 @@ public class ProductVo implements Serializable {
|
|||
/**
|
||||
* 是否陆运
|
||||
*/
|
||||
|
||||
private Integer isLandTrans;
|
||||
/**
|
||||
* 运输方式合并 / 分割
|
||||
|
@ -221,11 +203,10 @@ public class ProductVo implements Serializable {
|
|||
@Excel(name = "运输方式")
|
||||
private String typeShippingMerge;
|
||||
|
||||
|
||||
/**
|
||||
* 上下架
|
||||
*/
|
||||
@Excel(name = "上下架状态",readConverterExp = "0=上架,1=下架")
|
||||
@Excel(name = "上下架状态", readConverterExp = "0=上架,1=下架")
|
||||
private Integer isPutOn;
|
||||
/**
|
||||
* 创建人ID
|
||||
|
@ -235,7 +216,7 @@ public class ProductVo implements Serializable {
|
|||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@Excel(name = "创建时间",dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "创建时间", dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date creationTime;
|
||||
|
||||
|
@ -275,7 +256,6 @@ public class ProductVo implements Serializable {
|
|||
*/
|
||||
private String custName;
|
||||
|
||||
|
||||
/**
|
||||
* 产品基本信息名称
|
||||
*/
|
||||
|
@ -297,5 +277,9 @@ public class ProductVo implements Serializable {
|
|||
*/
|
||||
private Integer pkCubasdoc;
|
||||
|
||||
/**
|
||||
* 仓储产品编号
|
||||
*/
|
||||
private String wmsCode;
|
||||
|
||||
}
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
<result column="PRODUCT_ATTR" property="productAttr"/>
|
||||
<result column="SHIPPING_CHANNEL" property="shippingChannel"/>
|
||||
<result column="REPURCHASE_TYPE" property="repurchaseType"/>
|
||||
<result column="WMS_CODE" property="wmsCode"/>
|
||||
<collection property="specsList" ofType="com.hzs.common.domain.sale.classify.BdSpecs">
|
||||
<result column="PK_SPECS_ID" property="pkId"/>
|
||||
<result column="PK_SPECS_TYPE" property="pkSpecsType"/>
|
||||
|
@ -74,6 +75,7 @@
|
|||
<result column="IS_PUT_ON" property="isPutOn"/>
|
||||
<result column="LISTING_TIME" property="listingTime"/>
|
||||
<result column="REMOVAL_TIME" property="removalTime"/>
|
||||
<result column="WMS_CODE" property="wmsCode"/>
|
||||
</resultMap>
|
||||
|
||||
<select id="getLastProductCode" resultType="string">
|
||||
|
|
|
@ -4,10 +4,11 @@ import java.math.BigDecimal;
|
|||
|
||||
import com.baomidou.mybatisplus.annotation.KeySequence;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import java.io.Serializable;
|
||||
|
||||
import com.hzs.common.core.web.domain.BaseEntity;
|
||||
import lombok.Data;
|
||||
|
@ -15,12 +16,7 @@ import lombok.EqualsAndHashCode;
|
|||
import lombok.experimental.Accessors;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 邮费详情设置
|
||||
* </p>
|
||||
*
|
||||
* @author hzs
|
||||
* @since 2022-09-01
|
||||
* 产品详情
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
|
@ -168,5 +164,10 @@ public class BdProduct extends BaseEntity {
|
|||
@TableField("REMOVAL_TIME")
|
||||
private Date removalTime;
|
||||
|
||||
/**
|
||||
* 仓储产品编号
|
||||
*/
|
||||
@TableField("WMS_CODE")
|
||||
private String wmsCode;
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue