修改打印逻辑
This commit is contained in:
parent
6732e8905d
commit
5b14a4f342
|
|
@ -253,12 +253,7 @@ public class DataService {
|
||||||
}
|
}
|
||||||
|
|
||||||
List<TbPrintMachineWithBLOBs> bloBsList = tbPrintMachineMapper.selectByShopId(tbShopInfo.getId().toString());
|
List<TbPrintMachineWithBLOBs> bloBsList = tbPrintMachineMapper.selectByShopId(tbShopInfo.getId().toString());
|
||||||
|
if(Objects.nonNull(bloBsList)&&ObjectUtil.isNotEmpty(bloBsList)){
|
||||||
if (ObjectUtil.isEmpty(bloBsList) || bloBsList.size() <= 0) {
|
|
||||||
log.error("此店铺没有对应的打印机设备");
|
|
||||||
return Result.fail(CodeEnum.printmachinenoexsit);
|
|
||||||
}
|
|
||||||
|
|
||||||
bloBsList.parallelStream().forEach(it-> {
|
bloBsList.parallelStream().forEach(it-> {
|
||||||
|
|
||||||
if (!"network".equals(it.getConnectionType())) {
|
if (!"network".equals(it.getConnectionType())) {
|
||||||
|
|
@ -355,7 +350,7 @@ public class DataService {
|
||||||
String voiceJson = "{\"bizType\":\"2\",\"content\":\"您有一笔新的订单,请及时处理\"}";
|
String voiceJson = "{\"bizType\":\"2\",\"content\":\"您有一笔新的订单,请及时处理\"}";
|
||||||
PrinterUtils.printTickets(voiceJson, 1, 1, it.getAddress(), PrinterUtils.handoverprintData(handoverInfo));
|
PrinterUtils.printTickets(voiceJson, 1, 1, it.getAddress(), PrinterUtils.handoverprintData(handoverInfo));
|
||||||
});
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue