打印机问题

打印设备shopId问题
This commit is contained in:
2026-04-16 09:45:05 +08:00
parent ce2136b3cb
commit 2b3b76f6ef
9 changed files with 370 additions and 316 deletions

View File

@@ -22,6 +22,7 @@ public class PrintMachineServiceImpl extends ServiceImpl<PrintMachineMapper, Pri
@Override
public boolean add(Long shopId, PrintMachine dto) {
dto.setShopId(shopId);
//分类打印选择部分打印时必传JsonArray字符串数据 如:[{"id":125,"name":"意式咖啡"},{"id":127,"name":"饮品"}]
if ("1".equals(dto.getClassifyPrint())) {
if (StrUtil.isBlank(dto.getCategoryIds()) || dto.getCategoryIds().length() < 3) {
@@ -38,6 +39,7 @@ public class PrintMachineServiceImpl extends ServiceImpl<PrintMachineMapper, Pri
@Override
public Boolean edit(Long shopId, PrintMachine printerEditDTO) {
printerEditDTO.setShopId(shopId);
if ("1".equals(printerEditDTO.getClassifyPrint())) {
if (StrUtil.isBlank(printerEditDTO.getCategoryIds()) || printerEditDTO.getCategoryIds().length() < 3) {
throw new CzgException("分类打印选择部分打印时,必须勾选需要部分打印的菜品");