mirror of
https://gitee.com/gz-yami/mall4j.git
synced 2026-03-22 01:17:15 +08:00
删除无用的注释
This commit is contained in:
@@ -77,10 +77,6 @@ public class CategoryServiceImpl extends ServiceImpl<CategoryMapper, Category> i
|
||||
// 先删除后增加
|
||||
deleteBrandsAndAttributes(category.getCategoryId());
|
||||
insertBrandsAndAttributes(category);
|
||||
// 如果以前有图片,并且图片与现在不同,则删除以前的图片
|
||||
// if (StrUtil.isNotBlank(dbCategory.getPic()) && !dbCategory.getPic().equals(category.getPic())) {
|
||||
// attachFileService.deleteFile(dbCategory.getPic());
|
||||
// }
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -90,9 +86,6 @@ public class CategoryServiceImpl extends ServiceImpl<CategoryMapper, Category> i
|
||||
categoryMapper.deleteById(categoryId);
|
||||
|
||||
deleteBrandsAndAttributes(categoryId);
|
||||
// if (StrUtil.isNotBlank(category.getPic())) {
|
||||
// attachFileService.deleteFile(category.getPic());
|
||||
// }
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -46,23 +46,6 @@ public class ShopDetailServiceImpl extends ServiceImpl<ShopDetailMapper, ShopDet
|
||||
public void updateShopDetail(ShopDetail shopDetail,ShopDetail dbShopDetail) {
|
||||
// 更新除数据库中的信息,再删除图片
|
||||
shopDetailMapper.updateById(shopDetail);
|
||||
// if (!Objects.equals(dbShopDetail.getShopLogo(), shopDetail.getShopLogo())) {
|
||||
// // 删除logo
|
||||
// attachFileService.deleteFile(shopDetail.getShopLogo());
|
||||
// }
|
||||
// // 店铺图片
|
||||
// String shopPhotos = shopDetail.getShopPhotos();
|
||||
// String[] shopPhotoArray =StrUtil.isBlank(shopPhotos)?new String[]{}: shopPhotos.split(",");
|
||||
//
|
||||
// // 数据库中的店铺图片
|
||||
// String dbShopPhotos = dbShopDetail.getShopPhotos();
|
||||
// String[] dbShopPhotoArray =StrUtil.isBlank(dbShopPhotos)?new String[]{}: dbShopPhotos.split(",");
|
||||
// for (String dbShopPhoto : dbShopPhotoArray) {
|
||||
// // 如果新插入的图片中没有旧数据中的图片,则删除旧数据中的图片
|
||||
// if (!ArrayUtil.contains(shopPhotoArray, dbShopPhoto)) {
|
||||
// attachFileService.deleteFile(dbShopPhoto);
|
||||
// }
|
||||
// }
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user