测试环境

This commit is contained in:
haozq 2025-09-15 16:41:51 +08:00
parent 4418e0d341
commit 07d569c99e
1 changed files with 7 additions and 2 deletions

View File

@ -185,12 +185,17 @@ public class ProductServiceImpl implements ProductService {
productCase.setUpdateUser(SecurityUtils.getUserId().toString());
List<MultipartFile> multipartFileList=map.get(i+"");
productCase.setProductId(product.getId());
int nums=mapper.updateProductCase(productCase);
int nums=0;
if(StringUtils.isNotEmpty(productCase.getId())){
nums=mapper.updateProductCase(productCase);
}else{
nums=mapper.addProductCase(productCase);
}
if(nums<1){
return AjaxResult.error("产品案例修改失败");
}else{
//如果有修改图片的
if(StringUtils.isNotEmpty(proList)){
if(StringUtils.isNotEmpty(multipartFileList)){
AjaxResult ajaxResult=uploadFile(multipartFileList,"tb_product_case",productCase.getId(),"产品案例");
if(ajaxResult.isError()){
return ajaxResult;