Klosszhu 2 years ago
parent
commit
dae1e57944

+ 13 - 0
Fine.OPCDaExcelImport/Form1.Designer.cs

@@ -45,6 +45,7 @@ namespace Fine.OPCDaExcelImport
             this.button8 = new System.Windows.Forms.Button();
             this.button8 = new System.Windows.Forms.Button();
             this.textBox1 = new System.Windows.Forms.TextBox();
             this.textBox1 = new System.Windows.Forms.TextBox();
             this.label1 = new System.Windows.Forms.Label();
             this.label1 = new System.Windows.Forms.Label();
+            this.button9 = new System.Windows.Forms.Button();
             this.SuspendLayout();
             this.SuspendLayout();
             // 
             // 
             // SelectBtn
             // SelectBtn
@@ -196,11 +197,22 @@ namespace Fine.OPCDaExcelImport
             this.label1.TabIndex = 15;
             this.label1.TabIndex = 15;
             this.label1.Text = "API地址:";
             this.label1.Text = "API地址:";
             // 
             // 
+            // button9
+            // 
+            this.button9.Location = new System.Drawing.Point(742, 346);
+            this.button9.Name = "button9";
+            this.button9.Size = new System.Drawing.Size(81, 63);
+            this.button9.TabIndex = 16;
+            this.button9.Text = "Get测试";
+            this.button9.UseVisualStyleBackColor = true;
+            this.button9.Click += new System.EventHandler(this.button9_Click);
+            // 
             // Form1
             // Form1
             // 
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.ClientSize = new System.Drawing.Size(835, 652);
             this.ClientSize = new System.Drawing.Size(835, 652);
+            this.Controls.Add(this.button9);
             this.Controls.Add(this.label1);
             this.Controls.Add(this.label1);
             this.Controls.Add(this.textBox1);
             this.Controls.Add(this.textBox1);
             this.Controls.Add(this.button8);
             this.Controls.Add(this.button8);
@@ -242,6 +254,7 @@ namespace Fine.OPCDaExcelImport
         private System.Windows.Forms.Button button8;
         private System.Windows.Forms.Button button8;
         private System.Windows.Forms.TextBox textBox1;
         private System.Windows.Forms.TextBox textBox1;
         private System.Windows.Forms.Label label1;
         private System.Windows.Forms.Label label1;
+        private System.Windows.Forms.Button button9;
     }
     }
 }
 }
 
 

+ 61 - 0
Fine.OPCDaExcelImport/Form1.cs

@@ -671,5 +671,66 @@ namespace Fine.OPCDaExcelImport
                 }
                 }
             }
             }
         }
         }
+
+        private void button9_Click(object sender, EventArgs e)
+        {
+            Init.InitAllDirectoryCfg();
+            var api= Init.newConfig.Where(a => a.APIName.StartsWith("L5KYPJL") && a.Method == "get"&&!a.Params.Exists(b=>b.keys.Exists(c=>c.CheckTagName.Contains("JK"))));
+            HttpMethods http = new HttpMethods();
+            foreach (var item in api)
+            {
+                
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+                Task.Factory.StartNew(() =>
+                {
+                    ;
+                    http.HttpGet($"http://127.0.0.1:9011/api/{item.APIName}");
+                });
+            }
+        }
     }
     }
 }
 }

+ 0 - 0
Fine.OPCDaExcelImport/obj/Debug/build.force