wangxy пре 5 дана
родитељ
комит
bac386ee56

+ 191 - 60
fs-service/src/main/java/com/fs/hisStore/domain/FsStoreProductScrm.java

@@ -1,6 +1,7 @@
 package com.fs.hisStore.domain;
 
 import java.math.BigDecimal;
+import java.time.LocalDate;
 import java.util.List;
 
 import com.baomidou.mybatisplus.annotation.FieldStrategy;
@@ -18,173 +19,250 @@ import lombok.EqualsAndHashCode;
  */
 @EqualsAndHashCode(callSuper = true)
 @Data
-public class FsStoreProductScrm extends BaseEntity
-{
+public class FsStoreProductScrm extends BaseEntity {
     private static final long serialVersionUID = 1L;
 
-    /** 商品id */
+    /**
+     * 商品id
+     */
     private Long productId;
 
-    /** 商品图片 */
+    /**
+     * 商品图片
+     */
     @Excel(name = "商品图片")
     private String image;
 
     @TableField(strategy = FieldStrategy.IGNORED)
     private String video;
 
-    /** 轮播图 */
+    /**
+     * 轮播图
+     */
     @Excel(name = "轮播图")
     private String sliderImage;
 
-    /** 商品名称 */
+    /**
+     * 商品名称
+     */
     @Excel(name = "商品名称")
     private String productName;
 
-    /** 商品简介 */
+    /**
+     * 商品简介
+     */
     @Excel(name = "商品简介")
     private String productInfo;
 
-    /** 关键字 */
+    /**
+     * 关键字
+     */
     @Excel(name = "关键字")
     private String keyword;
 
-    /** 产品条码(一维码) */
+    /**
+     * 产品条码(一维码)
+     */
     @Excel(name = "产品条码", readConverterExp = "一=维码")
     private String barCode;
 
-    /** 分类id */
+    /**
+     * 分类id
+     */
     @Excel(name = "分类id")
     private Long cateId;
 
-    /** 商品价格 */
+    /**
+     * 商品价格
+     */
     @Excel(name = "商品价格")
     private BigDecimal price;
 
-    /** 会员价格 */
+    /**
+     * 会员价格
+     */
     @Excel(name = "会员价格")
     private BigDecimal vipPrice;
 
-    /** 市场价 */
+    /**
+     * 市场价
+     */
     @Excel(name = "市场价")
     private BigDecimal otPrice;
 
     @Excel(name = "市场价")
     private BigDecimal agentPrice;
 
-    /** 邮费 */
+    /**
+     * 邮费
+     */
     @Excel(name = "邮费")
     private BigDecimal postage;
 
-    /** 单位名 */
+    /**
+     * 单位名
+     */
     @Excel(name = "单位名")
     private String unitName;
 
-    /** 排序 */
+    /**
+     * 排序
+     */
     @Excel(name = "排序")
     private Long sort;
 
-    /** 销量 */
+    /**
+     * 销量
+     */
     @Excel(name = "销量")
     private Long sales;
 
-    /** 库存 */
+    /**
+     * 库存
+     */
     @Excel(name = "库存")
     private Long stock;
 
-    /** 状态(0:未上架,1:上架) */
+    /**
+     * 状态(0:未上架,1:上架)
+     */
     @Excel(name = "状态", dictType = "store_product_is_show", readConverterExp = "0=:未上架,1:上架")
     private Integer isShow;
 
-    /** 是否热卖 */
+    /**
+     * 是否热卖
+     */
     @Excel(name = "是否热卖")
     private Integer isHot;
 
-    /** 是否优惠 */
+    /**
+     * 是否优惠
+     */
     @Excel(name = "是否优惠")
     private Integer isBenefit;
 
-    /** 是否精品 */
+    /**
+     * 是否精品
+     */
     @Excel(name = "是否精品")
     private Integer isBest;
 
-    /** 是否新品 */
+    /**
+     * 是否新品
+     */
     @Excel(name = "是否新品")
     private Integer isNew;
 
     @Excel(name = "是否在商品展示")
     private Integer isDisplay;
 
-    /** 产品描述 */
+    /**
+     * 产品描述
+     */
     @Excel(name = "产品描述")
     private String description;
 
-    /** 是否包邮 */
+    /**
+     * 是否包邮
+     */
     @Excel(name = "是否包邮")
     private Integer isPostage;
 
-    /** 是否删除 */
+    /**
+     * 是否删除
+     */
     @Excel(name = "是否删除")
     private Integer isDel;
 
-    /** 获得积分 */
+    /**
+     * 获得积分
+     */
     @Excel(name = "获得积分")
     private BigDecimal giveIntegral;
 
-    /** 成本价 */
+    /**
+     * 成本价
+     */
     @Excel(name = "成本价")
     private BigDecimal cost;
 
-    /** 是否优品推荐 */
+    /**
+     * 是否优品推荐
+     */
     @Excel(name = "是否优品推荐")
     private Integer isGood;
 
-    /** 浏览量 */
+    /**
+     * 浏览量
+     */
     @Excel(name = "浏览量")
     private Long browse;
 
-    /** 产品二维码地址(用户小程序海报) */
+    /**
+     * 产品二维码地址(用户小程序海报)
+     */
     @Excel(name = "产品二维码地址(用户小程序海报)")
     private String codePath;
 
-    /** 运费模板ID */
+    /**
+     * 运费模板ID
+     */
     @Excel(name = "运费模板ID")
     private Integer tempId;
 
-    /** 规格 0单 1多 */
+    /**
+     * 规格 0单 1多
+     */
     @Excel(name = "规格 0单 1多")
     private Integer specType;
 
-    /** 是开启积分兑换 */
+    /**
+     * 是开启积分兑换
+     */
     @Excel(name = "是开启积分兑换")
     private Integer isIntegral;
 
-    /** 需要多少积分兑换 只在开启积分兑换时生效 */
+    /**
+     * 需要多少积分兑换 只在开启积分兑换时生效
+     */
     @Excel(name = "需要多少积分兑换 只在开启积分兑换时生效")
     private Long integral;
 
-    /** 商品类型:1非处方 2处方 */
+    /**
+     * 商品类型:1非处方 2处方
+     */
     @Excel(name = "商品类型:1非处方 2处方", dictType = "store_product_type")
     private Integer productType;
 
-    /** 国药准字 */
+    /**
+     * 国药准字
+     */
     @Excel(name = "国药准字")
     private String prescribeCode;
 
-    /** 规格 */
+    /**
+     * 规格
+     */
     @Excel(name = "规格")
     private String prescribeSpec;
 
-    /** 生产厂家 */
+    /**
+     * 生产厂家
+     */
     @Excel(name = "生产厂家")
     private String prescribeFactory;
 
-    /** 处方名 */
+    /**
+     * 处方名
+     */
     @Excel(name = "处方名")
     private String prescribeName;
 
     private Integer tuiCateId;
 
-    /** 指定企业 */
+    /**
+     * 指定企业
+     */
     private String companyIds;
 
     private Long storeId;
@@ -192,67 +270,99 @@ public class FsStoreProductScrm extends BaseEntity
     @TableField(exist = false)
     private Long[] storeIds;
 
-    /** 药品展示图 */
+    /**
+     * 药品展示图
+     */
     @Excel(name = "药品展示图")
     private String drugImage;
 
-    /** 药品注册证书编号 */
+    /**
+     * 药品注册证书编号
+     */
     @Excel(name = "药品注册证书编号")
     private String drugRegCertNo;
 
-    /** 通用名称 */
+    /**
+     * 通用名称
+     */
     @Excel(name = "通用名称")
     private String commonName;
 
-    /** 剂型 */
+    /**
+     * 剂型
+     */
     @Excel(name = "剂型")
     private String dosageForm;
 
-    /** 单价 */
+    /**
+     * 单价
+     */
     @Excel(name = "单价")
     private String unitPrice;
 
-    /** 批号 */
+    /**
+     * 批号
+     */
     @Excel(name = "批号")
     private String batchNumber;
 
-    /** 上市许可持有人 */
+    /**
+     * 上市许可持有人
+     */
     @Excel(name = "上市许可持有人")
     private String mah;
 
-    /** 上市许可持有人地址 */
+    /**
+     * 上市许可持有人地址
+     */
     @Excel(name = "上市许可持有人地址")
     private String mahAddress;
 
-    /** 生产企业 */
+    /**
+     * 生产企业
+     */
     @Excel(name = "生产企业")
     private String manufacturer;
 
-    /** 生产企业地址 */
+    /**
+     * 生产企业地址
+     */
     @Excel(name = "生产企业地址")
     private String manufacturerAddress;
 
-    /** 功能主治 */
+    /**
+     * 功能主治
+     */
     @Excel(name = "功能主治")
     private String indications;
 
-    /** 用法用量 */
+    /**
+     * 用法用量
+     */
     @Excel(name = "用法用量")
     private String dosage;
 
-    /** 不良反应 */
+    /**
+     * 不良反应
+     */
     @Excel(name = "不良反应")
     private String adverseReactions;
 
-    /** 禁忌 */
+    /**
+     * 禁忌
+     */
     @Excel(name = "禁忌")
     private String contraindications;
 
-    /** 注意事项 */
+    /**
+     * 注意事项
+     */
     @Excel(name = "注意事项")
     private String precautions;
 
-    /** 审核状态(0未审核1审核通过2审核退回) */
+    /**
+     * 审核状态(0未审核1审核通过2审核退回)
+     */
     @Excel(name = "审核状态(0未审核1审核通过2审核退回)")
     private String isAudit;
 
@@ -303,7 +413,9 @@ public class FsStoreProductScrm extends BaseEntity
     private Integer isPrescribe;
 
 
-    /** 品牌 */
+    /**
+     * 品牌
+     */
     @Excel(name = "品牌")
     private String brand;
 
@@ -318,7 +430,7 @@ public class FsStoreProductScrm extends BaseEntity
 
     /**
      * 交易类型
-     * **/
+     **/
     @TableField(exist = false)
     private Integer transactionStatus;
 
@@ -329,7 +441,26 @@ public class FsStoreProductScrm extends BaseEntity
 
     /**
      * 说明书
-     * **/
+     **/
     private String instructionManual;
 
+    /**
+     * 审核说明(0 首营 1非首映)
+     */
+    private String reviewAudit;
+
+    /**
+     * 首营弹资质上传证明
+     */
+    private String qualificationCertificate;
+
+    /**
+     * 首营弹资质开始时间
+     */
+    private LocalDate  qualificationCertificateStart;
+    /**
+     * 首营弹资质结束时间
+     */
+    private  LocalDate  qualificationCertificateEnd;
+
 }

+ 21 - 0
fs-service/src/main/java/com/fs/hisStore/param/FsStoreProductAddEditParam.java

@@ -7,6 +7,7 @@ import lombok.Data;
 
 import java.io.Serializable;
 import java.math.BigDecimal;
+import java.time.LocalDate;
 import java.util.List;
 
 /**
@@ -272,4 +273,24 @@ public class FsStoreProductAddEditParam implements Serializable
      * **/
     private String instructionManual;
 
+    /**
+     * 审核说明(0 首营 1非首映)
+     */
+    private String reviewAudit;
+
+    /**
+     * 首营弹资质上传证明
+     */
+    private String qualificationCertificate;
+
+    /**
+     * 首营弹资质开始时间
+     */
+    private String qualificationCertificateStart;
+    /**
+     * 首营弹资质结束时间
+     */
+    private  String  qualificationCertificateEnd;
+
+
 }

+ 123 - 131
fs-service/src/main/java/com/fs/hisStore/service/impl/FsStoreProductScrmServiceImpl.java

@@ -62,8 +62,7 @@ import org.springframework.transaction.annotation.Transactional;
 @Service
 @Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
 @Slf4j
-public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
-{
+public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService {
     @Autowired
     private FsStoreProductScrmMapper fsStoreProductMapper;
     @Autowired
@@ -111,8 +110,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
      * @return 商品
      */
     @Override
-    public FsStoreProductScrm selectFsStoreProductById(Long productId)
-    {
+    public FsStoreProductScrm selectFsStoreProductById(Long productId) {
         return fsStoreProductMapper.selectFsStoreProductById(productId);
     }
 
@@ -123,8 +121,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
      * @return 商品
      */
     @Override
-    public List<FsStoreProductScrm> selectFsStoreProductList(FsStoreProductScrm fsStoreProduct)
-    {
+    public List<FsStoreProductScrm> selectFsStoreProductList(FsStoreProductScrm fsStoreProduct) {
         return fsStoreProductMapper.selectFsStoreProductList(fsStoreProduct);
     }
 
@@ -135,8 +132,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
      * @return 结果
      */
     @Override
-    public int insertFsStoreProduct(FsStoreProductScrm fsStoreProduct)
-    {
+    public int insertFsStoreProduct(FsStoreProductScrm fsStoreProduct) {
         fsStoreProduct.setCreateTime(DateUtils.getNowDate());
         fsStoreProductMapper.insertFsStoreProduct(fsStoreProduct);
         storeAuditLogUtil.addOperLog(fsStoreProduct.getProductId());
@@ -150,8 +146,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
      * @return 结果
      */
     @Override
-    public int updateFsStoreProduct(FsStoreProductScrm fsStoreProduct)
-    {
+    public int updateFsStoreProduct(FsStoreProductScrm fsStoreProduct) {
         fsStoreProduct.setUpdateTime(DateUtils.getNowDate());
         storeAuditLogUtil.addOperLog(fsStoreProduct.getProductId());
         FsStoreProductScrm oldFsStoreProduct = fsStoreProductMapper.selectFsStoreProductById(fsStoreProduct.getProductId());
@@ -162,7 +157,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                     Map<String, Object> diff = getDiff(oldFsStoreProduct, fsStoreProduct);
                     Set<String> diff_columns = diff.keySet();
                     JSONArray productColumns = configUtil.generateConfigByKey("medicalMall.func.switch").getJSONArray("productColumns");
-                    if(com.fs.common.utils.StringUtils.isNotEmpty(productColumns)){
+                    if (com.fs.common.utils.StringUtils.isNotEmpty(productColumns)) {
                         //判断diff_columns是否在productColumns中,不是则将isAudit设置为0
                         for (String column : diff_columns) {
                             if (!productColumns.contains(column)) {
@@ -170,7 +165,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                                 break;
                             }
                         }
-                    }else{
+                    } else {
                         fsStoreProduct.setIsAudit("0");
                     }
                 }
@@ -217,8 +212,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
      * @return 结果
      */
     @Override
-    public int deleteFsStoreProductByIds(Long[] productIds)
-    {
+    public int deleteFsStoreProductByIds(Long[] productIds) {
         storeAuditLogUtil.addBatchAuditArray(productIds, "", "");
         return fsStoreProductMapper.deleteFsStoreProductByIds(productIds);
     }
@@ -230,8 +224,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
      * @return 结果
      */
     @Override
-    public int deleteFsStoreProductById(Long productId)
-    {
+    public int deleteFsStoreProductById(Long productId) {
         return fsStoreProductMapper.deleteFsStoreProductById(productId);
     }
 
@@ -240,20 +233,20 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
         List<FsStoreProductListVO> fsStoreProductListVOS = fsStoreProductMapper.selectFsStoreProductListVO(fsStoreProduct);
 
         for (FsStoreProductListVO item : fsStoreProductListVOS) {
-            if(StringUtils.isNotBlank(item.getCompanyIds())){
+            if (StringUtils.isNotBlank(item.getCompanyIds())) {
                 List<String> companyNameList = new ArrayList<>();
                 String[] split = item.getCompanyIds().split(",");
 
                 for (String companyId : split) {
-                    if(StringUtils.isNotBlank(companyId)) {
+                    if (StringUtils.isNotBlank(companyId)) {
                         String companyName = companyCacheService.selectCompanyNameById(Long.valueOf(companyId));
                         companyNameList.add(companyName);
                     }
                 }
-                item.setCompanyName(String.join(",",companyNameList));
+                item.setCompanyName(String.join(",", companyNameList));
             }
             //店铺名称
-            if(StringUtils.isNotEmpty(item.getStoreId()))
+            if (StringUtils.isNotEmpty(item.getStoreId()))
                 item.setStoreName(fsStoreScrmService.selectFsStoreByStoreId(Long.parseLong(item.getStoreId())).getStoreName());
         }
 
@@ -265,7 +258,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
         List<FsStoreProductListVO> fsStoreProductListVOS = fsStoreProductMapper.selectFsStoreProductBarCodeListVO(fsStoreProduct);
 
         for (FsStoreProductListVO item : fsStoreProductListVOS) {
-            if(StringUtils.isNotBlank(item.getCompanyIds())){
+            if (StringUtils.isNotBlank(item.getCompanyIds())) {
                 List<String> companyNameList = new ArrayList<>();
                 String[] split = item.getCompanyIds().split(",");
 
@@ -273,14 +266,14 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                     String companyName = companyCacheService.selectCompanyNameById(Long.valueOf(companyId));
                     companyNameList.add(companyName);
                 }
-                item.setCompanyName(String.join(",",companyNameList));
+                item.setCompanyName(String.join(",", companyNameList));
             }
         }
         return fsStoreProductListVOS;
     }
 
     @Override
-    public Map<String, Object> getFormatAttr(Long productId, String jsonStr,Long[] stores) {
+    public Map<String, Object> getFormatAttr(Long productId, String jsonStr, Long[] stores) {
         JSONObject jsonObject = JSON.parseObject(jsonStr);
         Map<String, Object> resultMap = new LinkedHashMap<>(3);
         if (jsonObject == null || jsonObject.get("attrs") == null || jsonObject.getJSONArray("attrs").isEmpty()) {
@@ -346,13 +339,13 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
             valueMap.put("brokerageThree", 0);
             valueMap.put("integral", 0);
             if (productId > 0) {
-                FsStoreProductAttrValueScrm attrValueMap=new FsStoreProductAttrValueScrm();
+                FsStoreProductAttrValueScrm attrValueMap = new FsStoreProductAttrValueScrm();
                 attrValueMap.setProductId(productId);
                 attrValueMap.setSku(sku);
                 List<FsStoreProductAttrValueScrm> values = fsStoreProductAttrValueMapper.selectFsStoreProductAttrValueList(attrValueMap);
-                if (values != null&&values.size()==1) {
-                    valueMap.put("id",values.get(0).getId());
-                    valueMap.put("sku",values.get(0).getSku());
+                if (values != null && values.size() == 1) {
+                    valueMap.put("id", values.get(0).getId());
+                    valueMap.put("sku", values.get(0).getSku());
                     valueMap.put("image", values.get(0).getImage());
                     valueMap.put("price", values.get(0).getPrice());
                     valueMap.put("cost", values.get(0).getCost());
@@ -381,9 +374,9 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
     @Override
     @Transactional
     public R addOrEdit(FsStoreProductAddEditParam param) {
-        ProductAttrCountDto countDto=computedProductCount(param.getValues());
-        FsStoreProductScrm product=new FsStoreProductScrm();
-        BeanUtils.copyProperties(param,product);
+        ProductAttrCountDto countDto = computedProductCount(param.getValues());
+        FsStoreProductScrm product = new FsStoreProductScrm();
+        BeanUtils.copyProperties(param, product);
         product.setPrice(countDto.getMinPrice());
         product.setOtPrice(countDto.getMinOtPrice());
         product.setCost(countDto.getMinCost());
@@ -395,35 +388,42 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
         product.setStoreId(storeId);
         product.setIsDrug(param.getIsDrug().toString());
         product.setInstructionManual(param.getInstructionManual());
-
+        product.setReviewAudit(param.getReviewAudit());
+        product.setQualificationCertificate(param.getQualificationCertificate());
+        if (param.getQualificationCertificateStart() != null) {
+            product.setQualificationCertificateStart(LocalDate.parse(param.getQualificationCertificateStart()));
+        }
+        if (param.getQualificationCertificateEnd() != null) {
+            product.setQualificationCertificateEnd(LocalDate.parse(param.getQualificationCertificateEnd()));
+        }
         //获取商品编码
-        if(!param.getValues().isEmpty()){
-            if(param.getValues().get(0).getBarCode() != null){
+        if (!param.getValues().isEmpty()) {
+            if (param.getValues().get(0).getBarCode() != null) {
                 product.setBarCode(param.getValues().get(0).getBarCode());
             }
         }
         //校验店铺资质信息
         //获取店铺
         FsStoreScrm store = fsStoreScrmService.selectFsStoreByStoreId(product.getStoreId());
-        if(store == null || 1 != store.getStatus()){
+        if (store == null || 1 != store.getStatus()) {
             return R.error("店铺不存在或未启用");
-        }else{
+        } else {
             //验证资质
-            switch (product.getProductType()){
+            switch (product.getProductType()) {
                 case 1://非处方
                     break;
                 case 2://处方
-                    if(StringUtils.isEmpty(store.getDrugLicense()) || "".equals(store.getDrugLicense()) ||  LocalDate.now().isAfter(store.getDrugLicenseExpiryEnd())){
+                    if (StringUtils.isEmpty(store.getDrugLicense()) || "".equals(store.getDrugLicense()) || LocalDate.now().isAfter(store.getDrugLicenseExpiryEnd())) {
                         return R.error("店铺药品资质为空或已过期,请完善后再添加");
                     }
                     break;
                 case 3://食品
-                    if(StringUtils.isEmpty(store.getFoodLicense()) || "".equals(store.getFoodLicense()) ||  LocalDate.now().isAfter(store.getFoodLicenseExpiryEnd())){
+                    if (StringUtils.isEmpty(store.getFoodLicense()) || "".equals(store.getFoodLicense()) || LocalDate.now().isAfter(store.getFoodLicenseExpiryEnd())) {
                         return R.error("店铺食品资质为空或已过期,请完善后再添加");
                     }
                     break;
                 case 4://器械
-                    if(StringUtils.isEmpty(store.getMedicalDevice3()) || "".equals(store.getMedicalDevice3()) ||  LocalDate.now().isAfter(store.getMedicalDevice3ExpiryEnd())){
+                    if (StringUtils.isEmpty(store.getMedicalDevice3()) || "".equals(store.getMedicalDevice3()) || LocalDate.now().isAfter(store.getMedicalDevice3ExpiryEnd())) {
                         return R.error("店铺器械资质为空或已过期,请完善后再添加");
                     }
                     break;
@@ -432,11 +432,11 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
             }
         }
 
-        if("纯正堂".equals(cloudHostProper.getCompanyName())){
+        if ("纯正堂".equals(cloudHostProper.getCompanyName())) {
             product.setIsAudit("1");
         }
 
-        if(param.getProductId() != null && param.getProductId() > 0){
+        if (param.getProductId() != null && param.getProductId() > 0) {
             FsStoreProductScrm oldFsStoreProduct = fsStoreProductMapper.selectFsStoreProductById(product.getProductId());
             Boolean isAudit = configUtil.generateConfigByKey("medicalMall.func.switch").getBoolean("isAudit");
             try {
@@ -445,7 +445,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                         Map<String, Object> diff = getDiff(oldFsStoreProduct, product);
                         Set<String> diff_columns = diff.keySet();
                         JSONArray productColumns = configUtil.generateConfigByKey("medicalMall.func.switch").getJSONArray("productColumns");
-                        if(com.fs.common.utils.StringUtils.isNotEmpty(productColumns)){
+                        if (com.fs.common.utils.StringUtils.isNotEmpty(productColumns)) {
                             //判断diff_columns是否在productColumns中,不是则将isAudit设置为0
                             for (String column : diff_columns) {
                                 if (!productColumns.contains(column)) {
@@ -453,7 +453,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                                     break;
                                 }
                             }
-                        }else{
+                        } else {
                             product.setIsAudit("0");
                         }
                     }
@@ -467,15 +467,14 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                         .value("规格")
                         .detail(ListUtil.toList("默认"))
                         .build();
-                List<ProductArrtDTO> items=new ArrayList<>();
+                List<ProductArrtDTO> items = new ArrayList<>();
                 items.add(fromatDetailDto);
                 param.getValues().get(0).setSku("默认");
-                addProductAttr(product.getProductId(),items,param.getValues(),storeId);
+                addProductAttr(product.getProductId(), items, param.getValues(), storeId);
             } else {
-                addProductAttr(product.getProductId(),param.getItems(),param.getValues(),storeId);
+                addProductAttr(product.getProductId(), param.getItems(), param.getValues(), storeId);
             }
-        }
-        else{
+        } else {
             fsStoreProductMapper.insertFsStoreProduct(product);
         }
         storeAuditLogUtil.addOperLog(product.getProductId());
@@ -484,52 +483,52 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                     .value("规格")
                     .detail(ListUtil.toList("默认"))
                     .build();
-            List<ProductArrtDTO> items=new ArrayList<>();
+            List<ProductArrtDTO> items = new ArrayList<>();
             items.add(fromatDetailDto);
             param.getValues().get(0).setSku("默认");
-            addProductAttr(product.getProductId(),items,param.getValues(),storeId);
+            addProductAttr(product.getProductId(), items, param.getValues(), storeId);
         } else {
-            addProductAttr(product.getProductId(),param.getItems(),param.getValues(),storeId);
+            addProductAttr(product.getProductId(), param.getItems(), param.getValues(), storeId);
         }
         return R.ok();
     }
 
 
-    private void addProductAttr(Long productId, List<ProductArrtDTO> items, List<FsStoreProductAttrValueScrm> values,Long storeId){
+    private void addProductAttr(Long productId, List<ProductArrtDTO> items, List<FsStoreProductAttrValueScrm> values, Long storeId) {
         //清空attr
         fsStoreProductAttrMapper.clear(productId);
         //清空values
         //查出商品属性所有ID;
-        List<FsStoreProductAttrValueScrm> attrValues=fsStoreProductAttrValueMapper.selectFsStoreProductAttrValueByProductId(productId);
+        List<FsStoreProductAttrValueScrm> attrValues = fsStoreProductAttrValueMapper.selectFsStoreProductAttrValueByProductId(productId);
         fsStoreProductAttrValueMapper.deleteFsStoreProductAttrValueByProductId(productId);
         //写入attr
-        for(ProductArrtDTO vo:items){
-            FsStoreProductAttrScrm attr=new FsStoreProductAttrScrm();
+        for (ProductArrtDTO vo : items) {
+            FsStoreProductAttrScrm attr = new FsStoreProductAttrScrm();
             attr.setProductId(productId);
             attr.setAttrName(vo.getValue());
             attr.setAttrValues(StringUtils.join(vo.getDetail(), ","));
             fsStoreProductAttrMapper.insertFsStoreProductAttr(attr);
         }
-        Map<String,Object> map = new LinkedHashMap<>();
-        map.put("attr",items);
+        Map<String, Object> map = new LinkedHashMap<>();
+        map.put("attr", items);
         // map.put("value",values);
 
-        for(FsStoreProductAttrValueScrm val: values){
+        for (FsStoreProductAttrValueScrm val : values) {
             //更新套餐商品属性ID  获取套餐
-            Long id=val.getId();
-            if(val.getDetail()!=null){
+            Long id = val.getId();
+            if (val.getDetail() != null) {
                 List<String> stringList = new ArrayList<>(val.getDetail().values());
                 Collections.sort(stringList);
-                val.setSku(StrUtil.join(",",stringList));
+                val.setSku(StrUtil.join(",", stringList));
             }
             val.setProductId(productId);
             val.setStoreId(storeId);
             fsStoreProductAttrValueMapper.insertFsStoreProductAttrValue(val);
-            if(attrValues!=null&&attrValues.size()>0){
-                for(FsStoreProductAttrValueScrm attrValue:attrValues){
-                    if(attrValue.getId().equals(id)){
-                        fsStoreProductGroupMapper.updateProducts(attrValue.getId(),val.getId());
-                        fsStoreProductPackageMapper.updateProducts(attrValue.getId(),val.getId());
+            if (attrValues != null && attrValues.size() > 0) {
+                for (FsStoreProductAttrValueScrm attrValue : attrValues) {
+                    if (attrValue.getId().equals(id)) {
+                        fsStoreProductGroupMapper.updateProducts(attrValue.getId(), val.getId());
+                        fsStoreProductPackageMapper.updateProducts(attrValue.getId(), val.getId());
                     }
                 }
             }
@@ -709,9 +708,8 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
     }
 
 
-
     private ProductAttrCountDto computedProductCount(List<FsStoreProductAttrValueScrm> values) {
-        BigDecimal val=new BigDecimal(0);
+        BigDecimal val = new BigDecimal(0);
         //取最小价格
         BigDecimal minPrice = values
                 .stream()
@@ -764,35 +762,34 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
     }
 
 
-
     @Override
     public List<FsStoreProductListQueryVO> selectFsStoreProductListQuery(FsStoreProductQueryParam param) {
         SysConfig config = configService.selectConfigByConfigKey("medicalMall.func.switch");
         MedicalMallConfig medicalMallConfig = JSON.parseObject(config.getConfigValue(), MedicalMallConfig.class);
         boolean stores = medicalMallConfig != null && medicalMallConfig.isStores();
-        param.setIsStores(stores?1:0);
+        param.setIsStores(stores ? 1 : 0);
         return fsStoreProductMapper.selectFsStoreProductListQuery(param);
     }
 
     @Override
-    public FsStoreProductQueryVO selectFsStoreProductByIdQuery(Long productId,String storeId) {
+    public FsStoreProductQueryVO selectFsStoreProductByIdQuery(Long productId, String storeId) {
         SysConfig config = configService.selectConfigByConfigKey("medicalMall.func.switch");
         MedicalMallConfig medicalMallConfig = JSON.parseObject(config.getConfigValue(), MedicalMallConfig.class);
-        return fsStoreProductMapper.selectFsStoreProductByIdQuery(productId,storeId,medicalMallConfig);
+        return fsStoreProductMapper.selectFsStoreProductByIdQuery(productId, storeId, medicalMallConfig);
     }
 
     @Override
     public void decProductStock(Long productId, Long productAttrValueId, Integer cartNum) {
         //处理属性sku
-        fsStoreProductAttrValueMapper.decProductAttrStock(productAttrValueId,cartNum);
-        fsStoreProductMapper.decProductAttrStock(productId,cartNum);
+        fsStoreProductAttrValueMapper.decProductAttrStock(productAttrValueId, cartNum);
+        fsStoreProductMapper.decProductAttrStock(productId, cartNum);
 
     }
 
     @Override
     public void incProductStock(Long num, Long productId, Long productAttrValueId) {
         //处理属性sku
-        if (productAttrValueId!=null) {
+        if (productAttrValueId != null) {
             attrValueService.incProductAttrStock(num, productId, productAttrValueId);
         }
         //先处理商品库存
@@ -824,7 +821,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
     public List<FsStoreProductListQueryVO> selectFsStoreProductGoodQuery(int count) {
         SysConfig config = configService.selectConfigByConfigKey("medicalMall.func.switch");
         MedicalMallConfig medicalMallConfig = JSON.parseObject(config.getConfigValue(), MedicalMallConfig.class);
-        return fsStoreProductMapper.selectFsStoreProductGoodQuery(count,medicalMallConfig);
+        return fsStoreProductMapper.selectFsStoreProductGoodQuery(count, medicalMallConfig);
     }
 
     @Override
@@ -848,7 +845,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
 
     @Override
     public Long selectFsStoreProductCount(int type, Long companyId) {
-        return fsStoreProductMapper.selectFsStoreProductCompanyCount(type,companyId);
+        return fsStoreProductMapper.selectFsStoreProductCompanyCount(type, companyId);
     }
 
     @Override
@@ -870,19 +867,17 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
     @Override
     public String importStoreProduct(List<FsStoreProductExportVO> list, boolean updateSupport) {
         storeAuditLogUtil.generateOperId();
-        if (com.fs.common.utils.StringUtils.isNull(list) || list.size() == 0)
-        {
+        if (com.fs.common.utils.StringUtils.isNull(list) || list.size() == 0) {
             throw new CustomException("导入商品数据不能为空!");
         }
         int successNum = 0;
         int failureNum = 0;
         StringBuilder successMsg = new StringBuilder();
         StringBuilder failureMsg = new StringBuilder();
-        for (FsStoreProductExportVO productVO : list){
-            try
-            {
+        for (FsStoreProductExportVO productVO : list) {
+            try {
                 FsStoreProductScrm product = BeanCopyUtils.copy(productVO, FsStoreProductScrm.class);
-                if (product.getBarCode()==null || product.getBarCode()==""){
+                if (product.getBarCode() == null || product.getBarCode() == "") {
                     throw new CustomException("商品编号为空");
                 }
                 this.insertFsStoreProduct(product);
@@ -890,36 +885,36 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                         .value("规格")
                         .detail(ListUtil.toList("默认"))
                         .build();
-                List<ProductArrtDTO> items=new ArrayList<>();
+                List<ProductArrtDTO> items = new ArrayList<>();
                 items.add(formatDetailDto);
                 FsStoreProductAttrValueScrm p = new FsStoreProductAttrValueScrm();
                 p.setProductId(product.getProductId());
                 p.setSku("默认");
                 p.setStock(product.getStock().intValue());
-                if (product.getStock()==null){
+                if (product.getStock() == null) {
                     p.setStock(0);
                 }
                 p.setSales(product.getSales().intValue());
-                if (product.getSales()==null){
+                if (product.getSales() == null) {
                     p.setStock(0);
                 }
                 p.setPrice(product.getPrice());
-                if (product.getPrice()==null){
+                if (product.getPrice() == null) {
                     p.setPrice(new BigDecimal(0));
                 }
                 p.setImage(product.getImage());
                 p.setCost(product.getCost());
-                if (product.getCost()==null){
+                if (product.getCost() == null) {
                     p.setCost(new BigDecimal(0));
                 }
                 p.setBarCode(product.getBarCode());
                 p.setGroupBarCode(product.getBarCode());
                 p.setOtPrice(product.getOtPrice());
-                if (product.getOtPrice()==null){
+                if (product.getOtPrice() == null) {
                     p.setOtPrice(new BigDecimal(0));
                 }
                 p.setWeight(productVO.getWeight());
-                if (productVO.getWeight()==null){
+                if (productVO.getWeight() == null) {
                     p.setWeight(new BigDecimal(0));
                 }
 
@@ -938,23 +933,18 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                 fsStoreProductAttrMapper.insertFsStoreProductAttr(attr);
                 successNum++;
                 successMsg.append("<br/>" + successNum + "、商品 " + product.getProductName() + " 导入成功");
-            }
-            catch (Exception e)
-            {
+            } catch (Exception e) {
 
                 failureNum++;
-                String msg = "<br/>" + failureNum + "、商品 " + productVO.getProductName()  + " 导入失败:";
+                String msg = "<br/>" + failureNum + "、商品 " + productVO.getProductName() + " 导入失败:";
                 failureMsg.append(msg + e.getMessage());
             }
 
         }
-        if (failureNum > 0)
-        {
+        if (failureNum > 0) {
             failureMsg.insert(0, "很抱歉,导入失败!共 " + failureNum + " 条数据格式不正确,错误如下:");
             throw new CustomException(failureMsg.toString());
-        }
-        else
-        {
+        } else {
             successMsg.insert(0, "恭喜您,数据已全部导入成功!共 " + successNum + " 条,数据如下:");
         }
         return successMsg.toString();
@@ -962,7 +952,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
 
     @Override
     public void batchModify(ModifyMoreDTO modifyMoreDTO) {
-        storeAuditLogUtil.addBatchAuditList(modifyMoreDTO.getProductId(),"",null);
+        storeAuditLogUtil.addBatchAuditList(modifyMoreDTO.getProductId(), "", null);
         fsStoreProductMapper.batchModify(modifyMoreDTO);
     }
 
@@ -982,7 +972,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
         StringBuilder failureMsg = new StringBuilder();
 
         //存储商品Id
-        List<Long> jstProductIds=new LinkedList<>();
+        List<Long> jstProductIds = new LinkedList<>();
         for (FsStoreProductExcelVO productVO : productList) {
             try {
 
@@ -1076,17 +1066,17 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                 Integer erpOpen = sysConfig.getErpOpen();
                 if (erpOpen == null || erpOpen == 0) {
                     //不作操作
-                } else{
+                } else {
                     //判断erp类型
                     Integer erpType = sysConfig.getErpType();
                     if (erpType == null) {
                         //不作操作
-                    }else if (erpType == 3) {
+                    } else if (erpType == 3) {
                         ErpGoods params = new ErpGoods();
                         params.setStoreProductId(product.getProductId());
                         //瀚智OMS 维护添加商品
                         hzOMSErpGoodsService.addGoodsScrm(params);
-                    }else if(erpType == 5){
+                    } else if (erpType == 5) {
                         jstProductIds.add(product.getProductId());
                     }
                 }
@@ -1099,7 +1089,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
         }
 
         //验证聚水潭商品Id
-        if(!jstProductIds.isEmpty()){
+        if (!jstProductIds.isEmpty()) {
             //同步聚水潭商品
             ErpGoods params = new ErpGoods();
             params.setProductIdList(jstProductIds);
@@ -1142,7 +1132,7 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
     @Transactional
     public void batchAudit(ProductAuditDTO auditDTO) {
         fsStoreProductMapper.batchAudit(auditDTO);
-        storeAuditLogUtil.addBatchAuditList(auditDTO.getProductIds(),auditDTO.getReason(),auditDTO.getAttachImage());
+        storeAuditLogUtil.addBatchAuditList(auditDTO.getProductIds(), auditDTO.getReason(), auditDTO.getAttachImage());
     }
 
     @Override
@@ -1151,9 +1141,10 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
     }
 
     @Override
-    public List<FsStoreProductActivityListVO> selectFsStoreProductByIdsAudit(String productIds) {SysConfig config = configService.selectConfigByConfigKey("medicalMall.func.switch");
+    public List<FsStoreProductActivityListVO> selectFsStoreProductByIdsAudit(String productIds) {
+        SysConfig config = configService.selectConfigByConfigKey("medicalMall.func.switch");
         MedicalMallConfig medicalMallConfig = JSON.parseObject(config.getConfigValue(), MedicalMallConfig.class);
-        return fsStoreProductMapper.selectFsStoreProductByIdsAudit(productIds,medicalMallConfig);
+        return fsStoreProductMapper.selectFsStoreProductByIdsAudit(productIds, medicalMallConfig);
     }
 
     @Override
@@ -1161,10 +1152,10 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
     public R bulkCopyFsStoreProductByIds(Long[] productIds) {
         storeAuditLogUtil.addBatchAuditArray(productIds, "", "");
         List<FsStoreProductScrm> list = fsStoreProductMapper.bulkCopyFsStoreProductByIds(productIds);
-        if(list != null && !list.isEmpty()){
+        if (list != null && !list.isEmpty()) {
             for (FsStoreProductScrm product : list) {
                 List<FsStoreProductAttrValueScrm> param = fsStoreProductAttrValueMapper.selectFsStoreProductAttrValueByProductId(product.getProductId());
-                if(!("益善缘".equals(cloudHostProper.getCompanyName()))) {
+                if (!("益善缘".equals(cloudHostProper.getCompanyName()))) {
                     //获取店铺
                     FsStoreScrm store = fsStoreScrmService.selectFsStoreByStoreId(product.getStoreId());
                     if (store == null || 1 != store.getStatus()) {
@@ -1205,10 +1196,10 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                             .value("规格")
                             .detail(ListUtil.toList("默认"))
                             .build();
-                    List<ProductArrtDTO> items=new ArrayList<>();
+                    List<ProductArrtDTO> items = new ArrayList<>();
                     items.add(fromatDetailDto);
                     param.get(0).setSku("默认");
-                    addProductAttr(product.getProductId(),items,param,product.getStoreId());
+                    addProductAttr(product.getProductId(), items, param, product.getStoreId());
                 } else {
                     List<FsStoreProductAttrScrm> items = fsStoreProductAttrMapper.selectFsStoreProductAttrByProductId(product.getProductId());
 
@@ -1216,33 +1207,33 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
                     fsStoreProductAttrMapper.clear(fsStoreProductId);
                     //清空values
                     //查出商品属性所有ID;
-                    List<FsStoreProductAttrValueScrm> attrValues=fsStoreProductAttrValueMapper.selectFsStoreProductAttrValueByProductId(fsStoreProductId);
+                    List<FsStoreProductAttrValueScrm> attrValues = fsStoreProductAttrValueMapper.selectFsStoreProductAttrValueByProductId(fsStoreProductId);
                     fsStoreProductAttrValueMapper.deleteFsStoreProductAttrValueByProductId(fsStoreProductId);
 
                     //写入attr
-                    for(FsStoreProductAttrScrm vo:items){
+                    for (FsStoreProductAttrScrm vo : items) {
                         vo.setProductId(fsStoreProductId);
                         fsStoreProductAttrMapper.insertFsStoreProductAttr(vo);
                     }
-                    Map<String,Object> map = new LinkedHashMap<>();
-                    map.put("attr",items);
+                    Map<String, Object> map = new LinkedHashMap<>();
+                    map.put("attr", items);
                     // map.put("value",values);
 
-                    for(FsStoreProductAttrValueScrm val: param){
+                    for (FsStoreProductAttrValueScrm val : param) {
                         //更新套餐商品属性ID  获取套餐
-                        Long id=val.getId();
-                        if(val.getDetail()!=null){
+                        Long id = val.getId();
+                        if (val.getDetail() != null) {
                             List<String> stringList = new ArrayList<>(val.getDetail().values());
                             Collections.sort(stringList);
-                            val.setSku(StrUtil.join(",",stringList));
+                            val.setSku(StrUtil.join(",", stringList));
                         }
                         val.setProductId(fsStoreProductId);
                         fsStoreProductAttrValueMapper.insertFsStoreProductAttrValue(val);
-                        if(attrValues!=null && !attrValues.isEmpty()){
-                            for(FsStoreProductAttrValueScrm attrValue:attrValues){
-                                if(attrValue.getId().equals(id)){
-                                    fsStoreProductGroupMapper.updateProducts(attrValue.getId(),val.getId());
-                                    fsStoreProductPackageMapper.updateProducts(attrValue.getId(),val.getId());
+                        if (attrValues != null && !attrValues.isEmpty()) {
+                            for (FsStoreProductAttrValueScrm attrValue : attrValues) {
+                                if (attrValue.getId().equals(id)) {
+                                    fsStoreProductGroupMapper.updateProducts(attrValue.getId(), val.getId());
+                                    fsStoreProductPackageMapper.updateProducts(attrValue.getId(), val.getId());
                                 }
                             }
                         }
@@ -1263,22 +1254,23 @@ public class FsStoreProductScrmServiceImpl implements IFsStoreProductScrmService
     public R instructionsViewable(FsStoreCartCountParam param) {
         //判断商品是否存在
         FsStoreProductScrm productScrm = fsStoreProductMapper.selectFsStoreProductById(param.getProductId());
-        if(productScrm == null || productScrm.getProductType() == null){
+        if (productScrm == null || productScrm.getProductType() == null) {
             return R.error("商品数据不存在,或类型异常!");
-        }else if(productScrm.getProductType() != 2){
-           return R.ok().put("data",true);
+        } else if (productScrm.getProductType() != 2) {
+            return R.ok().put("data", true);
         }
-        return R.ok().put("data",fsStoreProductMapper.instructionsViewable(param) > 0);
+        return R.ok().put("data", fsStoreProductMapper.instructionsViewable(param) > 0);
     }
 
     @Override
     public List<Map<String, String>> getStoreProductColumns() {
-        List<Map<String, String> > list = fsStoreProductMapper.getStoreProductColumns();
+        List<Map<String, String>> list = fsStoreProductMapper.getStoreProductColumns();
         List<Map<String, String>> result = new ArrayList<>();
         for (Map<String, String> column : list) {
             Map<String, String> camelCaseColumn = new HashMap<>();
             String columnName = column.get("colName");
-            String camelCaseName = com.fs.common.utils.StringUtils.toCamelCase(columnName);;
+            String camelCaseName = com.fs.common.utils.StringUtils.toCamelCase(columnName);
+            ;
             camelCaseColumn.put("colName", camelCaseName);
             camelCaseColumn.put("colComment", column.get("colComment"));
             result.add(camelCaseColumn);

+ 21 - 0
fs-service/src/main/java/com/fs/hisStore/vo/FsStoreProductListVO.java

@@ -119,4 +119,25 @@ public class FsStoreProductListVO  implements Serializable
     // 同步药品状态 推送状态 0推送中1成功2失
     private Byte pushStatus;
 
+    /**
+     * 审核说明(0 首营 1非首映)
+     */
+    private String reviewAudit;
+
+    /**
+     * 首营弹资质上传证明
+     */
+    private String qualificationCertificate;
+
+    /**
+     * 首营弹资质开始时间
+     */
+    private String qualificationCertificateStart;
+    /**
+     * 首营弹资质结束时间
+     */
+    private  String  qualificationCertificateEnd;
+
+
+
 }

+ 13 - 1
fs-service/src/main/resources/mapper/hisStore/FsStoreProductScrmMapper.xml

@@ -79,7 +79,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
                integral, product_type, prescribe_code, prescribe_spec, prescribe_factory, prescribe_name,
                is_display,tui_cate_id,company_ids,is_drug,drug_image,drug_reg_cert_no,common_name,dosage_form,
                unit_price,batch_number,mah,mah_address,manufacturer,manufacturer_address,indications,dosage,
-               adverse_reactions,contraindications,precautions,is_audit,store_id,instruction_manual
+               adverse_reactions,contraindications,precautions,is_audit,store_id,instruction_manual,review_audit,qualification_certificate,qualification_certificate_start,qualification_certificate_end
                from fs_store_product_scrm
     </sql>
 
@@ -257,6 +257,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isAudit != null and isAudit != ''">is_audit ,</if>
             <if test="storeId != null and storeId != ''">store_id ,</if>
             <if test="instructionManual != null and instructionManual != ''">instruction_manual ,</if>
+            <if test="reviewAudit != null and reviewAudit != ''">review_audit ,</if>
+            <if test="qualificationCertificate != null and qualificationCertificate != ''">qualification_certificate ,</if>
+            <if test="qualificationCertificateStart != null">qualification_certificate_start ,</if>
+            <if test="qualificationCertificateEnd != null">qualification_certificate_end ,</if>
          </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="image != null and image != ''">#{image},</if>
@@ -322,6 +326,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isAudit != null and isAudit != ''">#{isAudit} ,</if>
             <if test="storeId != null and storeId != ''">#{storeId} ,</if>
             <if test="instructionManual != null and instructionManual != ''">#{instructionManual} ,</if>
+            <if test="reviewAudit != null and reviewAudit != ''">#{reviewAudit} ,</if>
+            <if test="qualificationCertificate != null and qualificationCertificate != ''">#{qualificationCertificate} ,</if>
+            <if test="qualificationCertificateStart != null">#{qualificationCertificateStart} ,</if>
+            <if test="qualificationCertificateEnd != null ">#{qualificationCertificateEnd} ,</if>
          </trim>
     </insert>
 
@@ -391,6 +399,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isAudit != null and isAudit != ''">is_audit = #{isAudit} ,</if>
             <if test="storeId != null and storeId != ''">store_id = #{storeId} ,</if>
             <if test="instructionManual != null and instructionManual != ''">instruction_manual = #{instructionManual} ,</if>
+            <if test="reviewAudit != null and reviewAudit != ''">review_audit = #{reviewAudit} ,</if>
+            <if test="qualificationCertificate != null and qualificationCertificate != ''">qualification_certificate = #{qualificationCertificate} ,</if>
+            <if test="qualificationCertificateStart != null and qualificationCertificateStart != ''">qualification_certificate_start = #{qualificationCertificateStart} ,</if>
+            <if test="qualificationCertificateEnd != null and qualificationCertificateEnd != ''">qualification_certificate_end = #{qualificationCertificateEnd} ,</if>
         </trim>
         where product_id = #{productId}
     </update>