alielie
2026-06-15 f08871fe7d148d667f2f11f80f64de71a0d9504c
Plugin.BurnIn/DataTable.xaml.cs
@@ -1,4 +1,5 @@
using HMI.Base;
using HMI.Core.Manager;
using HMI.Core.Setting;
using HMI.Core.Util;
using HMI.LogUtil;
@@ -584,12 +585,12 @@
                GetSingleCell(cellIndex).SetInfos(new Info
                {
                    step = values[0],
                    value = values[1],
                    limitUp = values[2],
                    limitDown = values[3],
                    unit = values[4],
                    result = values[5],
                    updateTime = values[6]
                    value = values[2],
                    unit = values[3],
                    limitUp = values[4],
                    limitDown = values[5],
                    result = values[6],
                    updateTime = values[7]
                });
            });
            //session.Send("1");
@@ -599,17 +600,10 @@
        {
            infoTable.UpdateNumber(infoTable.okCount + ok, infoTable.ngCount + ng);
            if (ParamSetting.ProbeByModel)
            {
            }
            else
            {
                IniFileHelper.WriteIniData($"Oven_{index}", "Pass", infoTable.okCount.ToString(),
            IniFileHelper.WriteIniData($"Oven_{index}", "Pass", infoTable.okCount.ToString(),
                   this.CountIniPath);
                IniFileHelper.WriteIniData($"Oven_{index}", "Fail", infoTable.ngCount.ToString(),
                    this.CountIniPath);
            }
            IniFileHelper.WriteIniData($"Oven_{index}", "Fail", infoTable.ngCount.ToString(),
                this.CountIniPath);
        }
        /// <summary>
@@ -883,5 +877,52 @@
            string key = $"StationHMI.UUTHMI[{this.index}].Abort";
            parent.executionWrapper?.SetStationGlobalValue(key, 0, true);
        }
        private void MenuItem_Click(object sender, RoutedEventArgs e)
        {
            string manualDebugSeq = ParameterManager.GetCommonParameterByName("ManualDebugSeqPath")?.Value;
            if (string.IsNullOrEmpty(manualDebugSeq))
            {
                MsgBoxHelper2.Error("请先设置手动调试序列路径[ManualDebugSeqPath]!");
                return;
            }
            string modelPath = parent.testModelFile;
            var win = new ManualDebugWindow(manualDebugSeq, modelPath, true, cells, mainGrid.Columns)
            {
                CellCount = cells.Length,
                Title = $"{this.title}手动调试",
                Owner = Window.GetWindow(this),
                OvenIndex = this.index,
                OvenName = this.title,
                CellName = this.title,
                CellIndex = -1
            };
            win.ShowDialog();
        }
        private void ContextMenu_Closed(object sender, RoutedEventArgs e)
        {
            this.ContextMenu = null;
        }
        private void control_PreviewMouseRightButtonDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
        {
            if (!parent.inManualDebugMode)
            {
                return;
            }
            ContextMenu contextMenu = new ContextMenu();
            contextMenu.Closed += ContextMenu_Closed;
            var item = new MenuItem
            {
                IsCheckable = false,
                Name = "manualDebugItem",
                Header = this.lang("手动调试"),
            };
            item.Click += MenuItem_Click;
            contextMenu.Items.Add(item);
            this.ContextMenu = contextMenu;
        }
    }
}