This commit is contained in:
张怡蓉
2025-10-17 15:01:47 +08:00
parent b8ddd204ac
commit 1f9fe24ee6

View File

@@ -68,6 +68,12 @@ public class BasProductServiceImpl implements IBasProductService
@Override @Override
public int insertBasProduct(BasProduct basProduct) public int insertBasProduct(BasProduct basProduct)
{ {
BasProduct basProduct1 = basProductMapper.selectBasProductByProductId(basProduct.getProductId());
if(basProduct1 != null){
return 0;
}
basProduct.setProductGuid(basProduct.getProductId()); basProduct.setProductGuid(basProduct.getProductId());
basProduct.setSpare3(DateUtil.format(new Date(), "yyyy-MM-dd HH:mm:ss")); basProduct.setSpare3(DateUtil.format(new Date(), "yyyy-MM-dd HH:mm:ss"));
//获取当前系统登录用户名 //获取当前系统登录用户名
@@ -85,6 +91,10 @@ public class BasProductServiceImpl implements IBasProductService
@Override @Override
public int updateBasProduct(BasProduct basProduct) public int updateBasProduct(BasProduct basProduct)
{ {
BasProduct basProduct1 = basProductMapper.selectBasProductByProductId(basProduct.getProductId());
if(basProduct1!=null){
return 0;
}
return basProductMapper.updateBasProduct(basProduct); return basProductMapper.updateBasProduct(basProduct);
} }