消息发送

This commit is contained in:
2026-04-16 15:25:42 +08:00
parent 75b2db320f
commit 7511cb0ba8
3 changed files with 8 additions and 4 deletions

View File

@@ -79,7 +79,11 @@ public class PrintMqListener {
@RabbitListener(queues = {"${spring.profiles.active}-" + RabbitConstants.Queue.OTHER_PRINT_QUEUE})
public void otherPrint(Long shopId, Object o, String printTypeEnum) {
public void otherPrint(String data) {
JSONObject jsonObject = JSONObject.parseObject(data);
Long shopId = jsonObject.getLong("shopId");
Object o = jsonObject.getObject("data", Object.class);
String printTypeEnum = jsonObject.getString("printTypeEnum");
PrinterHandler.PrintTypeEnum typeEnum = PrinterHandler.PrintTypeEnum.valueOf(printTypeEnum);
SysPrintData sysPrintData = new SysPrintData();
sysPrintData.setShopId(shopId);