callm 1 viikko sitten
vanhempi
commit
5c3031223b

+ 60 - 6
UAS_MES_ZKLH/FunctionCode/Query/Query_Barcodeio.Designer.cs

@@ -48,11 +48,15 @@
             this.PrintBarCode = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
             this.DP_NAME = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SearchTextBox();
             this.dataGridViewTextBoxColumn7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.label1 = new System.Windows.Forms.Label();
+            this.de_kind = new System.Windows.Forms.ComboBox();
             this.choose = new System.Windows.Forms.DataGridViewCheckBoxColumn();
+            this.detno = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.de_code = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.de_name = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.de_spec = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.de_currentcentername = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.de_kind1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.de_startdate = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.lm_id = new System.Windows.Forms.DataGridViewTextBoxColumn();
             ((System.ComponentModel.ISupportInitialize)(this.DGV)).BeginInit();
@@ -75,10 +79,12 @@
             this.DGV.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
             this.DGV.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
             this.choose,
+            this.detno,
             this.de_code,
             this.de_name,
             this.de_spec,
             this.de_currentcentername,
+            this.de_kind1,
             this.de_startdate,
             this.lm_id});
             this.DGV.Location = new System.Drawing.Point(26, 79);
@@ -92,7 +98,7 @@
             // 
             this.label2.AutoSize = true;
             this.label2.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label2.Location = new System.Drawing.Point(545, 15);
+            this.label2.Location = new System.Drawing.Point(939, 16);
             this.label2.Margin = new System.Windows.Forms.Padding(6, 0, 6, 0);
             this.label2.Name = "label2";
             this.label2.Size = new System.Drawing.Size(114, 41);
@@ -103,7 +109,7 @@
             // 
             this.label3.AutoSize = true;
             this.label3.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label3.Location = new System.Drawing.Point(1130, 15);
+            this.label3.Location = new System.Drawing.Point(1459, 16);
             this.label3.Margin = new System.Windows.Forms.Padding(6, 0, 6, 0);
             this.label3.Name = "label3";
             this.label3.Size = new System.Drawing.Size(82, 41);
@@ -188,16 +194,16 @@
             // 
             this.PrintLabel.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
             this.PrintLabel.FormattingEnabled = true;
-            this.PrintLabel.Location = new System.Drawing.Point(1249, 18);
+            this.PrintLabel.Location = new System.Drawing.Point(1551, 19);
             this.PrintLabel.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
             this.PrintLabel.Name = "PrintLabel";
-            this.PrintLabel.Size = new System.Drawing.Size(388, 32);
+            this.PrintLabel.Size = new System.Drawing.Size(244, 32);
             this.PrintLabel.TabIndex = 225;
             this.PrintLabel.SelectedIndexChanged += new System.EventHandler(this.PrintLabel_SelectedIndexChanged);
             // 
             // PrinterList
             // 
-            this.PrinterList.Location = new System.Drawing.Point(698, 21);
+            this.PrinterList.Location = new System.Drawing.Point(1067, 19);
             this.PrinterList.Margin = new System.Windows.Forms.Padding(8);
             this.PrinterList.Name = "PrinterList";
             this.PrinterList.Size = new System.Drawing.Size(388, 50);
@@ -210,7 +216,7 @@
             this.PrintBarCode.DownImage = ((System.Drawing.Image)(resources.GetObject("PrintBarCode.DownImage")));
             this.PrintBarCode.Image = null;
             this.PrintBarCode.IsShowBorder = true;
-            this.PrintBarCode.Location = new System.Drawing.Point(1678, 14);
+            this.PrintBarCode.Location = new System.Drawing.Point(1836, 15);
             this.PrintBarCode.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
             this.PrintBarCode.MoveImage = ((System.Drawing.Image)(resources.GetObject("PrintBarCode.MoveImage")));
             this.PrintBarCode.Name = "PrintBarCode";
@@ -252,6 +258,32 @@
             this.dataGridViewTextBoxColumn7.Name = "dataGridViewTextBoxColumn7";
             this.dataGridViewTextBoxColumn7.Width = 200;
             // 
+            // label1
+            // 
+            this.label1.AutoSize = true;
+            this.label1.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.label1.Location = new System.Drawing.Point(512, 14);
+            this.label1.Margin = new System.Windows.Forms.Padding(6, 0, 6, 0);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(146, 41);
+            this.label1.TabIndex = 227;
+            this.label1.Text = "设备种类";
+            // 
+            // de_kind
+            // 
+            this.de_kind.FormattingEnabled = true;
+            this.de_kind.Items.AddRange(new object[] {
+            "机械设备",
+            "办公设备",
+            "运输设备",
+            "检测设备",
+            "其他"});
+            this.de_kind.Location = new System.Drawing.Point(690, 22);
+            this.de_kind.Name = "de_kind";
+            this.de_kind.Size = new System.Drawing.Size(226, 32);
+            this.de_kind.TabIndex = 228;
+            this.de_kind.SelectedIndexChanged += new System.EventHandler(this.de_kind_SelectedIndexChanged);
+            // 
             // choose
             // 
             this.choose.HeaderText = "勾选";
@@ -259,6 +291,14 @@
             this.choose.Name = "choose";
             this.choose.Width = 80;
             // 
+            // detno
+            // 
+            this.detno.DataPropertyName = "detno";
+            this.detno.HeaderText = "序号";
+            this.detno.MinimumWidth = 10;
+            this.detno.Name = "detno";
+            this.detno.Width = 200;
+            // 
             // de_code
             // 
             this.de_code.DataPropertyName = "de_code";
@@ -295,6 +335,14 @@
             this.de_currentcentername.ReadOnly = true;
             this.de_currentcentername.Width = 200;
             // 
+            // de_kind1
+            // 
+            this.de_kind1.DataPropertyName = "de_kind";
+            this.de_kind1.HeaderText = "设备类型";
+            this.de_kind1.MinimumWidth = 10;
+            this.de_kind1.Name = "de_kind1";
+            this.de_kind1.Width = 200;
+            // 
             // de_startdate
             // 
             this.de_startdate.DataPropertyName = "de_startdate";
@@ -318,6 +366,8 @@
             this.AutoScaleDimensions = new System.Drawing.SizeF(12F, 24F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.ClientSize = new System.Drawing.Size(1960, 1075);
+            this.Controls.Add(this.de_kind);
+            this.Controls.Add(this.label1);
             this.Controls.Add(this.ChooseAll);
             this.Controls.Add(this.PrintLabel);
             this.Controls.Add(this.label2);
@@ -358,11 +408,15 @@
         private System.Windows.Forms.Label label3;
         private CustomControl.ComBoxWithFocus.PrinterCombox PrinterList;
         private System.Windows.Forms.Button ChooseAll;
+        private System.Windows.Forms.Label label1;
+        private System.Windows.Forms.ComboBox de_kind;
         private System.Windows.Forms.DataGridViewCheckBoxColumn choose;
+        private System.Windows.Forms.DataGridViewTextBoxColumn detno;
         private System.Windows.Forms.DataGridViewTextBoxColumn de_code;
         private System.Windows.Forms.DataGridViewTextBoxColumn de_name;
         private System.Windows.Forms.DataGridViewTextBoxColumn de_spec;
         private System.Windows.Forms.DataGridViewTextBoxColumn de_currentcentername;
+        private System.Windows.Forms.DataGridViewTextBoxColumn de_kind1;
         private System.Windows.Forms.DataGridViewTextBoxColumn de_startdate;
         private System.Windows.Forms.DataGridViewTextBoxColumn lm_id;
     }

+ 13 - 2
UAS_MES_ZKLH/FunctionCode/Query/Query_Barcodeio.cs

@@ -44,6 +44,7 @@ namespace UAS_MES_NEW.Query
             DP_NAME.Condition = "1=1";
             DP_NAME.DbChange += Ma_code_DbChange;
 
+
             InitPrint = new Thread(InPrint);
             SetLoadingWindow stw = new SetLoadingWindow(InitPrint, "初始化打印程序");
             BaseUtil.SetFormCenter(stw);
@@ -91,7 +92,7 @@ namespace UAS_MES_NEW.Query
 
         private void LoadGridData()
         {
-            DataTable dt = (DataTable)dh.ExecuteSql("select de_code,de_name,de_spec,de_currentcentername,to_char(de_startdate,'yyyy-mm-dd')de_startdate from device  where de_currentcentername='" + DP_NAME.Text + "' order by de_currentcentername", "select");
+            DataTable dt = (DataTable)dh.ExecuteSql("select rownum detno,de_kind,de_code,de_name,de_spec,de_currentcentername,to_char(de_startdate,'yyyy-mm-dd')de_startdate from device  where de_currentcentername like '%" + DP_NAME.Text + "%' and de_kind like '%" + de_kind.Text + "%' order by de_currentcentername", "select");
             BaseUtil.FillDgvWithDataTable(DGV, dt);
         }
 
@@ -121,7 +122,7 @@ namespace UAS_MES_NEW.Query
                 {
                     string barcode = DGV.Rows[i].Cells["de_code"].Value.ToString();
                     string ErrorMessage = "";
-                    if (!Print.BarTender(Tag.ToString(),  engine, PrintLabel.Text, PrintLabel.SelectedValue.ToString(), PrinterList.Text, barcode, int.Parse("1"), DP_NAME.Text, "", "自定义", "0", out ErrorMessage))
+                    if (!Print.BarTender(Tag.ToString(), engine, PrintLabel.Text, PrintLabel.SelectedValue.ToString(), PrinterList.Text, barcode, int.Parse("1"), DP_NAME.Text, "", "自定义", "0", out ErrorMessage))
                     {
 
                     }
@@ -159,5 +160,15 @@ namespace UAS_MES_NEW.Query
                 AllChecked = true;
             }
         }
+
+        private void de_kind_UserControlTextChanged(object sender, EventArgs e)
+        {
+
+        }
+
+        private void de_kind_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            LoadGridData() ;
+        }
     }
 }

+ 6 - 0
UAS_MES_ZKLH/FunctionCode/Query/Query_Barcodeio.resx

@@ -123,6 +123,9 @@
   <metadata name="choose.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
+  <metadata name="detno.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
   <metadata name="de_code.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
@@ -135,6 +138,9 @@
   <metadata name="de_currentcentername.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
+  <metadata name="de_kind1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
   <metadata name="de_startdate.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>