From 4c7f2d26fd6041d32f4e291559bc443671493246 Mon Sep 17 00:00:00 2001
From: chengsc <11752@DESKTOP-DS49RCP>
Date: 星期四, 19 六月 2025 16:52:45 +0800
Subject: [PATCH] 修改问题

---
 Admin.NET/WCS.Application/PLC/PLCService.cs |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/Admin.NET/WCS.Application/PLC/PLCService.cs b/Admin.NET/WCS.Application/PLC/PLCService.cs
index d748ee3..0177093 100644
--- a/Admin.NET/WCS.Application/PLC/PLCService.cs
+++ b/Admin.NET/WCS.Application/PLC/PLCService.cs
@@ -9,6 +9,7 @@
 using Furion.Logging;
 using IoTClient;
 using NewLife.Reflection;
+using Newtonsoft.Json;
 using Org.BouncyCastle.Ocsp;
 using SixLabors.ImageSharp.ColorSpaces;
 using WCS.Application.Entity;
@@ -1436,10 +1437,11 @@
                     new {type = "SITE" , code = modTask.StartLocate},
                     new { type = "PILE_COUNT", code = modTask.Qty }
                 };
+                
                 taskModel.targetRoute.Add(new targetRoute() { 
                     seq = 0,
                     type = "MIX_CONDITION",
-                    code = code.ToString() // "[{\"type":\"SITE", code = modTask.StartLocate },new { type = "PILE_COUNT", code = modTask.Qty }]"
+                    code = JsonConvert.SerializeObject(code) // "[{\"type":\"SITE", code = modTask.StartLocate },new { type = "PILE_COUNT", code = modTask.Qty }]"
 
 
                 });

--
Gitblit v1.8.0