From 53d582ad41d8450b21045b2d862a532ecc57a9ba Mon Sep 17 00:00:00 2001 From: kazelee <1847801760@qq.com> Date: 星期一, 26 五月 2025 17:29:57 +0800 Subject: [PATCH] 抽检移库基本测完,添加TCP模拟测试输送线产品下线的逻辑 --- api/ApiModel.cs | 42 +++++++++++++++--------------------------- 1 files changed, 15 insertions(+), 27 deletions(-) diff --git a/api/ApiModel.cs b/api/ApiModel.cs index 9f65d18..5a5ac90 100644 --- a/api/ApiModel.cs +++ b/api/ApiModel.cs @@ -28,20 +28,6 @@ } /// <summary> - /// 鏋勫缓 <see cref="SimpleResult"/> 寮傚父杩斿洖鍊硷紝閫夋嫨鎵撳嵃寮傚父鏃ュ織淇℃伅锛堥粯璁ゆ墦鍗帮級 - /// </summary> - /// <param name="ex"></param> - /// <param name="exCode"></param> - /// <param name="pringLog"></param> - /// <returns></returns> - public static SimpleResult BuildSimpleEx(Exception ex, int exCode = 1, bool pringLog = true) { - if (pringLog) { - LogHelper.InfoEx(ex); - } - return new SimpleResult { resultCode = exCode, resultMsg = ex.Message }; - } - - /// <summary> /// HostToAGV 涓婃姤浠诲姟鐘舵� /// </summary> public class AgvTaskState { @@ -69,7 +55,7 @@ public class SafetyInteractionInfo { - public int station_id { get; set; } + //public int station_id { get; set; } /// <summary> /// 璇锋眰涓婄嚎/涓嬬嚎鐨勭殑绔欏彴搴撲綅鍚嶇О锛屼緥濡倃ork6銆亀ork8 @@ -80,7 +66,7 @@ /// 璇锋眰鐮� /// </summary> public string apply_code { get; set; } - public string task_no { set; get; } + //public string task_no { set; get; } } /// <summary> @@ -89,6 +75,10 @@ public class ReturnResult { public int ResultCode { get; set; } public string ResultMsg { get; set; } + } + + public static ReturnResult NewReturnResult(int code, string message) { + return new ReturnResult { ResultCode = code, ResultMsg = message }; } public class orderStatusReportParme { @@ -153,13 +143,10 @@ /// 杩斿洖缁橤Z /// </summary> public class GzResult { - public int resultCode { get; set; } public string msg { get; set; } public int orderID { get; set; } } - - } @@ -172,7 +159,8 @@ /// <summary> /// 鐗╂枡缂栫爜 /// </summary> - public string s_item_code { get; set; } + [JsonProperty("s_item_code")] + public string ItemCode { get; set; } ///// <summary> ///// 鐗╂枡鍚嶇О ///// </summary> @@ -181,20 +169,23 @@ /// <summary> /// 鎵规鍙� /// </summary> - public string s_batch { get; set; } + [JsonProperty("s_batch")] + public string BatchNo { get; set; } /// <summary> /// 鐗╂枡瑙勬牸 /// </summary> - + [JsonProperty("s_spec")] public string s_spec { get; set; } /// <summary> /// 鏁伴噺 /// </summary> + [JsonProperty("n_num")] public int n_num { get; set; } /// <summary> /// 璧风偣璐т綅淇℃伅 /// </summary> - public string s_start_loc { get; set; } + [JsonProperty("s_start_loc")] + public string StartLoc { get; set; } } /// <summary> /// 绌烘墭/绌虹鍏ュ簱缁戝畾(PDA)鏁版嵁绫�@@ -559,10 +550,7 @@ public string Data { get; set; } } - public static WmsResult MesResultBuilder(int code, string message = "", bool printLog = true) { - if (printLog && string.IsNullOrEmpty(message)) { - LogHelper.Info(message); - } + public static WmsResult NewWmsResult(int code, string message = "", bool printLog = true) { return new WmsResult { Result = code, Success = code == 0, // 浠呭綋code=0鏃讹紝success=true -- Gitblit v1.9.1