From 538f1f0db8d02103d040b96a489b1a5803750a11 Mon Sep 17 00:00:00 2001
From: dengjunjie <dengjunjie@hnkhzn.com>
Date: 星期五, 23 二月 2024 11:02:57 +0800
Subject: [PATCH] 项目优化

---
 代码管理/PCS/WCS_Server/WIDESEA_WCS/Jobs/equipment/GantryJob.cs |  111 -------------------------------------------------------
 1 files changed, 0 insertions(+), 111 deletions(-)

diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/PCS/WCS_Server/WIDESEA_WCS/Jobs/equipment/GantryJob.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/PCS/WCS_Server/WIDESEA_WCS/Jobs/equipment/GantryJob.cs"
index 71a8d36..51d5974 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/PCS/WCS_Server/WIDESEA_WCS/Jobs/equipment/GantryJob.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/PCS/WCS_Server/WIDESEA_WCS/Jobs/equipment/GantryJob.cs"
@@ -45,117 +45,6 @@
             gantry.QueryWheeldata(client);
             gantry.QueryOrder(client);
             gantry.Layofflevel(client);
-            gantry.Stupidproofmeasure(client);
-        }
-
-        #region
-        static List<MachineDB> MachineDBs = new List<MachineDB>();
-        static List<WheelDataDB> wheelDataDBs = new List<WheelDataDB>();
-        private void DoAction(PLCClient client)
-        {
-            try
-            {
-                VOLContext Context = new VOLContext();
-                Idt_plcinfoheadRepository repository = new dt_plcinfoheadRepository(Context);
-                Idt_plcinfodetailRepository plcRepository = new dt_plcinfodetailRepository(Context);
-
-                var plc = repository.FindFirst(x => x.plcinfo_name == client.PLCName);
-                var numbers = plcRepository.Find(x => x.plcdetail_iotype == plc.plcinfo_iotyep).GroupBy(x => x.plcdetail_number).ToList();
-                foreach (var number in numbers)
-                {
-                    if (number.Key.Contains("杈婇亾涓嬫枡"))
-                    {
-                        PropertyInfo[] propertyInfos = typeof(WheelDataDB).GetProperties();//鑾峰彇鎵�鏈夊睘鎬�
-                        WheelDataDB dBItem = wheelDataDBs.Where(x => x.R_Name == number.Key).FirstOrDefault();
-                        if (dBItem == null)
-                        {
-                            dBItem = new();
-                            dBItem.OnReadSignal += HandleReadSignal;
-                            wheelDataDBs.Add(dBItem);
-                        }
-                        List<dt_plcinfodetail> details = plcRepository.Find(x => x.plcdetail_iotype == plc.plcinfo_iotyep && x.plcdetail_number == number.Key).ToList();
-                        for (int i = 0; i < propertyInfos.Length; i++)
-                        {
-                            if (i == 0)
-                            {
-                                dBItem.R_Name = number.Key;
-                            }
-                            else
-                            {
-                                object readData = DBExtension.Read(details.Where(x => x.plcdetail_name == propertyInfos[i].Name).FirstOrDefault(), client);
-                                if (readData != null) { }
-                                object obj = propertyInfos[i].GetValue(dBItem);
-                                if (obj != readData)
-                                    propertyInfos[i].SetValue(dBItem, readData);
-                            }
-                        }
-                    }
-                    else
-                    {
-
-                        PropertyInfo[] propertyInfos = typeof(MachineDB).GetProperties();//鑾峰彇鎵�鏈夊睘鎬�
-                        MachineDB dBItem = MachineDBs.Where(x => x.R_Name == number.Key).FirstOrDefault();
-                        if (dBItem == null)
-                        {
-                            dBItem = new();
-                            dBItem.OnReadSignal += HandleReadSignal;
-                            MachineDBs.Add(dBItem);
-                        }
-                        List<dt_plcinfodetail> details = plcRepository.Find(x => x.plcdetail_iotype == plc.plcinfo_iotyep && x.plcdetail_number == number.Key).ToList();
-                        for (int i = 0; i < propertyInfos.Length; i++)
-                        {
-                            if (i == 0)
-                            {
-                                dBItem.R_Name = number.Key;
-                            }
-                            else
-                            {
-                                object readData = DBExtension.Read(details.Where(x => x.plcdetail_name == propertyInfos[i].Name).FirstOrDefault(), client);
-                                if (readData != null) { }
-                                object obj = propertyInfos[i].GetValue(dBItem);
-                                if (obj != readData)
-                                    propertyInfos[i].SetValue(dBItem, readData);
-                            }
-                        }
-                    }
-                }
-            }
-            catch (Exception ex)
-            {
-
-                throw;
-            }
-        }
-        #endregion
-        public void HandleReadSignal(string type, MachineDB DBItem)
-        {
-            switch (type)
-            {
-                case OperationType.OperationType_Record:
-
-                    break;
-                case OperationType.OperationType_Processor:
-
-                    break;
-                case OperationType.OperationType_WheelData:
-
-                    break;
-            }
-        }
-        public void HandleReadSignal(string type, WheelDataDB DBItem)
-        {
-            switch (type)
-            {
-                case OperationType.OperationType_Record:
-
-                    break;
-                case OperationType.OperationType_Processor:
-
-                    break;
-                case OperationType.OperationType_WheelData:
-
-                    break;
-            }
         }
     }
 }

--
Gitblit v1.9.3