From 9211ec11c112e18cd99e77f889a01110a70031ce Mon Sep 17 00:00:00 2001
From: alielie <alielie@git.com>
Date: 星期一, 24 十一月 2025 17:47:15 +0800
Subject: [PATCH] 优化项目结构

---
 Plugin.TsExecution/SingleControl.xaml.cs |   20 +++++++++-----------
 1 files changed, 9 insertions(+), 11 deletions(-)

diff --git a/Plugin.TsExecution/SingleControl.xaml.cs b/Plugin.TsExecution/SingleControl.xaml.cs
index 293f3f6..8c3aec9 100644
--- a/Plugin.TsExecution/SingleControl.xaml.cs
+++ b/Plugin.TsExecution/SingleControl.xaml.cs
@@ -25,7 +25,6 @@
 
         protected void Set([CallerMemberName] string name = null)
         {
-
             PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(name));
         }
 
@@ -99,6 +98,13 @@
         {
             get { return barcode; }
             set { Set(ref barcode, value); }
+        }
+
+        private string model = string.Empty;
+        public string Model
+        {
+            get { return model; }
+            set { Set(ref model, value); }
         }
 
         private string elapseTime = "00:00:00";
@@ -214,8 +220,8 @@
 
         public SingleControl(int Index, string CountIniPath, int probeWarn)
         {
-            this.CountIniPath = CountIniPath;
             DataContext = this;
+            this.CountIniPath = CountIniPath;
             this.index = Index;
             ProbeWarn = probeWarn;
 
@@ -302,7 +308,7 @@
                     var now = DateTime.Now;
                     var span = now - StepStartTime;
                     StepStartTime = now;
-                    data.ConsumeTime = $"{span.Seconds}s";
+                    data.ConsumeTime = $"{(span.TotalMilliseconds / 1000d).ToString("F2")}s";
                     Datasource.Add(data);
                     table.ScrollIntoView(data);
                 }));
@@ -543,14 +549,6 @@
                 //var modal = scannerVisualModal;
                 //Canvas.SetLeft(modal, (scannerPanel.ActualWidth - scannerVisualModal.ActualWidth) / 2);
                 //Canvas.SetTop(modal, (scannerPanel.ActualHeight - scannerVisualModal.ActualHeight) / 2);
-            }
-        }
-
-        private void TextBlock_MouseDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
-        {
-            DependencyObject parent = VisualTreeHelper.GetParent((DependencyObject)sender);
-            while (parent != null) {
-                parent = VisualTreeHelper.GetParent(parent);
             }
         }
     }

--
Gitblit v1.9.1