店铺管理-店铺配置:打印机设置相关接口

This commit is contained in:
谭凯凯 2024-10-11 14:36:34 +08:00 committed by Tankaikai
parent 713ff653ad
commit b7e9f74912
1 changed files with 3 additions and 2 deletions

View File

@ -106,7 +106,7 @@ public class ShopPrinterServiceImpl extends ServiceImpl<TbPrintMachineMapper, Tb
if (StrUtil.isBlank(dto.getCategoryList())) {
throw new BadRequestException("分类打印选择部分打印时,必须勾选需要部分打印的菜品");
}
if (JSONUtil.isTypeJSONArray(dto.getCategoryList())) {
if (!JSONUtil.isTypeJSONArray(dto.getCategoryList())) {
throw new BadRequestException("传递的部分打印菜品数据不合法");
}
if (StrUtil.isBlank(dto.getCategoryIds())) {
@ -132,7 +132,7 @@ public class ShopPrinterServiceImpl extends ServiceImpl<TbPrintMachineMapper, Tb
if (StrUtil.isBlank(dto.getCategoryList())) {
throw new BadRequestException("分类打印选择部分打印时,必须勾选需要部分打印的菜品");
}
if (JSONUtil.isTypeJSONArray(dto.getCategoryList())) {
if (!JSONUtil.isTypeJSONArray(dto.getCategoryList())) {
throw new BadRequestException("传递的部分打印菜品数据不合法");
}
if (StrUtil.isBlank(dto.getCategoryIds())) {
@ -157,4 +157,5 @@ public class ShopPrinterServiceImpl extends ServiceImpl<TbPrintMachineMapper, Tb
baseMapper.update(null, new LambdaUpdateWrapper<TbPrintMachineEntity>()
.set(TbPrintMachineEntity::getStatus, status).eq(TbPrintMachineEntity::getId, id));
}
}