From dbae9c048fa0cd67c2e1161e5b6b693f87064154 Mon Sep 17 00:00:00 2001 From: wells.liu <wells.liu@broconcentric.com> Date: 星期三, 01 七月 2020 17:53:15 +0800 Subject: [PATCH] Merge branch 'master' of http://gitblit.broconcentric.com:8088/r/M071 --- src/Bro.Common.Model/Model/MonitorSet.cs | 63 ++++++++++++++++++++++++++----- 1 files changed, 52 insertions(+), 11 deletions(-) diff --git a/src/Bro.Common.Model/Model/MonitorSet.cs b/src/Bro.Common.Model/Model/MonitorSet.cs index 74d5a8f..50f977a 100644 --- a/src/Bro.Common.Model/Model/MonitorSet.cs +++ b/src/Bro.Common.Model/Model/MonitorSet.cs @@ -11,6 +11,7 @@ using System.Linq; using System.Windows.Forms; using System.Windows.Forms.Design; +using static Bro.Common.Helper.EnumHelper; namespace Bro.Common.Model { @@ -61,6 +62,10 @@ [Description("鐩戝惉璋冪敤鎻忚堪")] [DisplayName("鐩戝惉鍚嶇О")] public string Name { get; set; } = ""; + + [Browsable(false)] + [JsonIgnore] + public ProcessResponse Response { get; set; } = new ProcessResponse(); [Browsable(false)] public string DisplayText @@ -120,10 +125,10 @@ public class MonitorSet : SimpleMonitorSet { /// <summary> - /// 鐩戝惉鍦板潃绱㈠紩 鎸夌収PLC鐩戝惉鍦板潃浠�0寮�濮嬬殑绱㈠紩 + /// 鐩戝惉鍦板潃绱㈠紩 鎸夌収鐩戝惉鍦板潃浠�0寮�濮嬬殑绱㈠紩 /// </summary> [Category("鐩戝惉璁剧疆")] - [Description("鐩戝惉鍦板潃绱㈠紩 鎸夌収PLC鐩戝惉鍦板潃浠�0寮�濮嬬殑绱㈠紩")] + [Description("鐩戝惉鍦板潃绱㈠紩 鎸夌収鐩戝惉鍦板潃浠�0寮�濮嬬殑绱㈠紩")] [DisplayName("瑙﹀彂绱㈠紩")] public int TriggerIndex { get; set; } = -1; @@ -136,16 +141,16 @@ public int TriggerValue { get; set; } = -1; /// <summary> - /// 浼犲叆鏁版嵁鍦板潃鐨勭储寮� 鎸夌収PLC鐩戝惉鍦板潃浠�0寮�濮嬬殑绱㈠紩闆嗗悎 + /// 浼犲叆鏁版嵁鍦板潃鐨勭储寮� 鎸夌収鐩戝惉鍦板潃浠�0寮�濮嬬殑绱㈠紩闆嗗悎 /// </summary> [Category("鐩戝惉璁剧疆")] - [Description("浼犲叆鏁版嵁鍦板潃鐨勭储寮� 鎸夌収PLC鐩戝惉鍦板潃浠�0寮�濮嬬殑绱㈠紩")] + [Description("浼犲叆鏁版嵁鍦板潃鐨勭储寮� 鎸夌収鐩戝惉鍦板潃浠�0寮�濮嬬殑绱㈠紩")] [DisplayName("浼犲叆鏁版嵁绱㈠紩")] [TypeConverter(typeof(SimpleCollectionConvert<int>))] public List<int> InputDataIndex { get; set; } = new List<int>(); /// <summary> - /// 鏁版嵁鍦板潃 瀹為檯PLC瀵勫瓨鍣ㄧ殑鍦板潃锛屼緥濡� 40012 + /// 鏁版嵁鍦板潃 瀹為檯瀵勫瓨鍣ㄧ殑鍦板潃锛屼緥濡� 40012 /// </summary> [Category("鍥炰紶璁剧疆")] [Description("鍥炰紶鏁版嵁鍦板潃 瀹為檯PLC瀵勫瓨鍣ㄧ殑鍦板潃,10杩涘埗锛屼緥濡� 40012")] @@ -153,16 +158,12 @@ public int ReplyDataAddress { get; set; } = -1; /// <summary> - /// 閫氱煡鍦板潃 瀹為檯PLC瀵勫瓨鍣ㄧ殑鍦板潃锛屼緥濡� 40012 + /// 閫氱煡鍦板潃 瀹為檯瀵勫瓨鍣ㄧ殑鍦板潃锛屼緥濡� 40012 /// </summary> [Category("鍥炰紶璁剧疆")] - [Description("閫氱煡鍦板潃 瀹為檯PLC瀵勫瓨鍣ㄧ殑鍦板潃,10杩涘埗锛屼緥濡� 40012")] + [Description("閫氱煡鍦板潃 瀹為檯瀵勫瓨鍣ㄧ殑鍦板潃,10杩涘埗锛屼緥濡� 40012")] [DisplayName("閫氱煡鍦板潃")] public int NoticeAddress { get; set; } = -1; - - [Browsable(false)] - [JsonIgnore] - public ProcessResponse Response { get; set; } = new ProcessResponse(); public MonitorSet() { } @@ -176,6 +177,46 @@ } } + /// <summary> + /// 杩愬姩鏉垮崱鐩戝惉閰嶇疆瀵硅薄 + /// </summary> + public class MotionCardMonitorSet : SimpleMonitorSet + { + /// <summary> + /// 鐩戝惉绫诲瀷 + /// </summary> + [Category("鐩戝惉璁剧疆")] + [DisplayName("鐩戝惉绫诲瀷")] + [Description("鐩戝惉杩愬姩鏉垮崱 IO 绫诲瀷锛圛N OUT锛�")] + public IOModel MonitorIOModel { get; set; } + + /// <summary> + /// 鐩戝惉鍦板潃绱㈠紩 + /// </summary> + [Category("鐩戝惉璁剧疆")] + [Description("鐩戝惉鍦板潃绱㈠紩")] + [DisplayName("瑙﹀彂绱㈠紩")] + public int TriggerIndex { get; set; } = -1; + + /// <summary> + /// 瑙﹀彂鍊� + /// </summary> + [Category("鐩戝惉璁剧疆")] + [Description("瑙﹀彂鍊硷紝璁剧疆涓�-999鏃跺彉鍖栧嵆瑙﹀彂")] + [DisplayName("瑙﹀彂鍊�")] + public int TriggerValue { get; set; } = -1; + + /// <summary> + /// 鐩戝惉鍥炰紶 + /// </summary> + [Category("鍥炰紶璁剧疆")] + [DisplayName("鐩戝惉鍥炰紶")] + [Description("鐩戝惉杩愬姩鏉垮崱锛屽苟寰�鎸囧畾鐨処O鍐欏叆鏁版嵁")] + [TypeConverter(typeof(CollectionCountConvert))] + [Editor(typeof(IOItem), typeof(UITypeEditor))] + public List<IOItem> ReplyIODatas { get; set; } = new List<IOItem>(); + } + public class IOperationConfigEditor : UITypeEditor { public override UITypeEditorEditStyle GetEditStyle(System.ComponentModel.ITypeDescriptorContext context) -- Gitblit v1.8.0