From c9ab562cef6fd2359c082e2db9496de501af236a Mon Sep 17 00:00:00 2001 From: hutongqing <hutongqing@hnkhzn.com> Date: 星期四, 19 十二月 2024 10:22:28 +0800 Subject: [PATCH] Create 厂内物流调度控制系统RCS-2000 V3.2 对外任务接口文档.pdf --- 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_DTO/MES/MesResponseContent.cs | 46 ++++++++++++++++++++++++---------------------- 1 files changed, 24 insertions(+), 22 deletions(-) diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_DTO/MES/MesResponseContent.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_DTO/MES/MesResponseContent.cs" index 9ed0fd6..b64c5e2 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_DTO/MES/MesResponseContent.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_DTO/MES/MesResponseContent.cs" @@ -7,13 +7,16 @@ namespace WIDESEA_DTO { + /// <summary> + /// + /// </summary> [ModelValidate] public class MesResponseContent { /// <summary> /// /// </summary> - public bool bSucc { get; set; } + public bool BSucc { get; set; } /// <summary> /// /// </summary> @@ -26,29 +29,28 @@ /// /// </summary> public DateTime DataTime { get; set; } - /// <summary> - /// - /// </summary> - public content Content { get; set; } - public class content + public static MesResponseContent Instance { - /// <summary> - /// - /// </summary> - public string Code { get; set; } - /// <summary> - /// - /// </summary> - public string Name { get; set; } - /// <summary> - /// - /// </summary> - public string ShortName { get; set; } - /// <summary> - /// - /// </summary> - public string Contacts { get; set; } + get { return new MesResponseContent(); } } + + public MesResponseContent OK(string message = null) + { + BSucc = true; + StrCode = "0000"; + StrMsg = message == null ? "鎵ц鎴愬姛" : message; + return this; + } + + public MesResponseContent Error(string message = null) + { + BSucc = false; + StrCode = "404"; + StrMsg = message == null ? "鎵ц澶辫触" : message; + return this; + } + public Content Content { get; set; } } + } -- Gitblit v1.9.3