!459 新建商品时商品分类状态判断错误

Merge pull request !459 from LiZhongShi/master
pull/2/head
芋道源码 2023-04-22 11:16:27 +00:00 committed by Gitee
commit a2ca746f0a
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 1 additions and 1 deletions

View File

@ -100,7 +100,7 @@ public class ProductCategoryServiceImpl implements ProductCategoryService {
if (category == null) {
throw exception(CATEGORY_NOT_EXISTS);
}
if (Objects.equals(category.getStatus(), CommonStatusEnum.ENABLE.getStatus())) {
if (Objects.equals(category.getStatus(), CommonStatusEnum.DISABLE.getStatus())) {
throw exception(CATEGORY_DISABLED, category.getName());
}
}