ソースを参照

自动测试结果存入

ltwork 1 年間 前
コミット
dd78af836c

+ 3 - 3
BlankApp1/BlankApp1/App.config

@@ -4,9 +4,9 @@
 		<!--连接字符串 SQL Server-->
 		<add key="MySql" value="Data Source=localhost;Database=plc_point_db2;User Id='root';Password='521125';port=3306;charset=utf8mb4;"/>
 	    <!--1表示欧姆龙PLC,2表示为三菱PLC-->
-		<add key="PLCType" value="1"/>
-		<add key="PLCIp" value="192.168.250.1"/>
-		<add key="PLCPort" value="9600"/>
+		<add key="PLCType" value="2"/>
+		<add key="PLCIp" value="192.168.3.39"/>
+		<add key="PLCPort" value="6000"/>
 		<add key="DelayTime" value="20"/>
 		<add key="LongDelayTime" value="60"/>
 	

+ 7 - 0
BlankApp1/BlankApp1/ViewModels/BusinessManageViewModel/AutoTestViewModel.cs

@@ -1065,9 +1065,13 @@ namespace PLCTool.ViewModels.BusinessManageViewModel
                     });
                     ProVisibility = Visibility.Hidden;
                     //弹出确认的对话框
+                    string finalJsonStr = ModelToJsonToStr(SelectOutJudge, OutSelectLogic, OutDetail, OutConList);
+                    //json字符串
+                    bizTestRecordDtlDto.JudgementResultFinal = finalJsonStr;
                     MessageBoxResult boxResult = MessageBox.Show(OutDetail, "确认", MessageBoxButton.OKCancel, MessageBoxImage.Information);
                     if (boxResult == MessageBoxResult.OK)
                     {
+                        
                         bizTestRecordDtlDto.JudgementResult = "通过";
                         StepIndex = 3;
                     }
@@ -1097,6 +1101,9 @@ namespace PLCTool.ViewModels.BusinessManageViewModel
                                 }
                             });
                             ProVisibility = Visibility.Hidden;
+                            string finalJsonStr2 = ModelToJsonToStr(SelectOutJudge, OutSelectLogic, OutDetail, OutConList);
+                            //json字符串
+                            bizTestRecordDtlDto.JudgementResultFinal = finalJsonStr2;
                             bizTestRecordDtlDto.JudgementResult = "通过";
                             StepIndex = 3;
                             break;