章政 6 gadi atpakaļ
vecāks
revīzija
a372a7844d

+ 23 - 40
UAS-出货标签管理(泽天)/UAS_出货标签管理.Designer.cs

@@ -28,7 +28,6 @@
         /// </summary>
         private void InitializeComponent()
         {
-            this.components = new System.ComponentModel.Container();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
             System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(UAS_出货标签打印));
             this.pi_inoutno_label = new System.Windows.Forms.Label();
@@ -38,8 +37,7 @@
             this.pib_id = new System.Windows.Forms.Label();
             this.pi_cardcode = new System.Windows.Forms.Label();
             this.Fresh = new System.Windows.Forms.LinkLabel();
-            this.RefreshDBConnect = new System.Windows.Forms.Timer(this.components);
-            this.GetGridOnly = new System.Windows.Forms.CheckBox();
+            this.RefreshDBConnect = new System.Windows.Forms.Timer();
             this.dataGridViewCheckBoxColumn1 = new System.Windows.Forms.DataGridViewCheckBoxColumn();
             this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
@@ -66,7 +64,7 @@
             this.dataGridViewTextBoxColumn21 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.dataGridViewTextBoxColumn22 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.dataGridViewTextBoxColumn23 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.MidSource = new System.Windows.Forms.BindingSource(this.components);
+            this.MidSource = new System.Windows.Forms.BindingSource();
             this.ChooseAll = new System.Windows.Forms.Button();
             this.ExportFileDialog = new System.Windows.Forms.FolderBrowserDialog();
             this.AttachInfo = new System.Windows.Forms.Button();
@@ -251,19 +249,6 @@
             this.RefreshDBConnect.Interval = 10000;
             this.RefreshDBConnect.Tick += new System.EventHandler(this.RefreshDBConnect_Tick);
             // 
-            // GetGridOnly
-            // 
-            this.GetGridOnly.AutoSize = true;
-            this.GetGridOnly.Font = new System.Drawing.Font("微软雅黑", 7.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.GetGridOnly.Location = new System.Drawing.Point(350, 189);
-            this.GetGridOnly.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
-            this.GetGridOnly.Name = "GetGridOnly";
-            this.GetGridOnly.Size = new System.Drawing.Size(77, 20);
-            this.GetGridOnly.TabIndex = 82;
-            this.GetGridOnly.Text = "仅获取表格";
-            this.GetGridOnly.UseVisualStyleBackColor = true;
-            this.GetGridOnly.Visible = false;
-            // 
             // dataGridViewCheckBoxColumn1
             // 
             this.dataGridViewCheckBoxColumn1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
@@ -890,7 +875,7 @@
             // 
             this.label18.AutoSize = true;
             this.label18.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label18.Location = new System.Drawing.Point(64, 122);
+            this.label18.Location = new System.Drawing.Point(62, 120);
             this.label18.Name = "label18";
             this.label18.Size = new System.Drawing.Size(13, 17);
             this.label18.TabIndex = 90;
@@ -924,7 +909,7 @@
             // 
             this.label16.AutoSize = true;
             this.label16.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label16.Location = new System.Drawing.Point(63, 59);
+            this.label16.Location = new System.Drawing.Point(61, 57);
             this.label16.Name = "label16";
             this.label16.Size = new System.Drawing.Size(13, 17);
             this.label16.TabIndex = 87;
@@ -958,7 +943,7 @@
             // 
             this.label12.AutoSize = true;
             this.label12.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label12.Location = new System.Drawing.Point(6, 89);
+            this.label12.Location = new System.Drawing.Point(4, 87);
             this.label12.Name = "label12";
             this.label12.Size = new System.Drawing.Size(56, 17);
             this.label12.TabIndex = 77;
@@ -968,7 +953,7 @@
             // 
             this.label7.AutoSize = true;
             this.label7.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label7.Location = new System.Drawing.Point(4, 27);
+            this.label7.Location = new System.Drawing.Point(2, 25);
             this.label7.Name = "label7";
             this.label7.Size = new System.Drawing.Size(56, 17);
             this.label7.TabIndex = 76;
@@ -1232,14 +1217,14 @@
             this.SingleLabelPrinter.Location = new System.Drawing.Point(7, 63);
             this.SingleLabelPrinter.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
             this.SingleLabelPrinter.Name = "SingleLabelPrinter";
-            this.SingleLabelPrinter.Size = new System.Drawing.Size(159, 30);
+            this.SingleLabelPrinter.Size = new System.Drawing.Size(159, 25);
             this.SingleLabelPrinter.TabIndex = 40;
             // 
             // SingleLabelPrint
             // 
             this.SingleLabelPrint.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
             this.SingleLabelPrint.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.SingleLabelPrint.Location = new System.Drawing.Point(54, 177);
+            this.SingleLabelPrint.Location = new System.Drawing.Point(87, 177);
             this.SingleLabelPrint.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.SingleLabelPrint.Name = "SingleLabelPrint";
             this.SingleLabelPrint.Size = new System.Drawing.Size(68, 26);
@@ -1254,7 +1239,7 @@
             this.SingleLabelAutoPrint.Checked = true;
             this.SingleLabelAutoPrint.CheckState = System.Windows.Forms.CheckState.Checked;
             this.SingleLabelAutoPrint.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.SingleLabelAutoPrint.Location = new System.Drawing.Point(5, 92);
+            this.SingleLabelAutoPrint.Location = new System.Drawing.Point(9, 93);
             this.SingleLabelAutoPrint.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.SingleLabelAutoPrint.Name = "SingleLabelAutoPrint";
             this.SingleLabelAutoPrint.Size = new System.Drawing.Size(75, 21);
@@ -1312,7 +1297,7 @@
             // 
             this.label2.AutoSize = true;
             this.label2.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label2.Location = new System.Drawing.Point(7, 122);
+            this.label2.Location = new System.Drawing.Point(5, 120);
             this.label2.Name = "label2";
             this.label2.Size = new System.Drawing.Size(32, 17);
             this.label2.TabIndex = 92;
@@ -1335,7 +1320,7 @@
             // 
             this.label5.AutoSize = true;
             this.label5.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label5.Location = new System.Drawing.Point(7, 155);
+            this.label5.Location = new System.Drawing.Point(5, 153);
             this.label5.Name = "label5";
             this.label5.Size = new System.Drawing.Size(32, 17);
             this.label5.TabIndex = 50;
@@ -1347,13 +1332,13 @@
             this.MidLabelPrinter.Location = new System.Drawing.Point(6, 63);
             this.MidLabelPrinter.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
             this.MidLabelPrinter.Name = "MidLabelPrinter";
-            this.MidLabelPrinter.Size = new System.Drawing.Size(158, 30);
+            this.MidLabelPrinter.Size = new System.Drawing.Size(158, 25);
             this.MidLabelPrinter.TabIndex = 41;
             // 
             // MidLabelPrint
             // 
             this.MidLabelPrint.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.MidLabelPrint.Location = new System.Drawing.Point(83, 178);
+            this.MidLabelPrint.Location = new System.Drawing.Point(86, 179);
             this.MidLabelPrint.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.MidLabelPrint.Name = "MidLabelPrint";
             this.MidLabelPrint.Size = new System.Drawing.Size(68, 26);
@@ -1368,7 +1353,7 @@
             this.MidLabelAutoPrint.Checked = true;
             this.MidLabelAutoPrint.CheckState = System.Windows.Forms.CheckState.Checked;
             this.MidLabelAutoPrint.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.MidLabelAutoPrint.Location = new System.Drawing.Point(4, 89);
+            this.MidLabelAutoPrint.Location = new System.Drawing.Point(8, 92);
             this.MidLabelAutoPrint.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.MidLabelAutoPrint.Name = "MidLabelAutoPrint";
             this.MidLabelAutoPrint.Size = new System.Drawing.Size(75, 21);
@@ -1411,7 +1396,7 @@
             // LogingOut
             // 
             this.LogingOut.AutoSize = true;
-            this.LogingOut.Location = new System.Drawing.Point(101, 7);
+            this.LogingOut.Location = new System.Drawing.Point(99, 5);
             this.LogingOut.Name = "LogingOut";
             this.LogingOut.Size = new System.Drawing.Size(42, 21);
             this.LogingOut.TabIndex = 77;
@@ -1437,7 +1422,7 @@
             // 
             this.label10.AutoSize = true;
             this.label10.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label10.Location = new System.Drawing.Point(9, 148);
+            this.label10.Location = new System.Drawing.Point(7, 146);
             this.label10.Name = "label10";
             this.label10.Size = new System.Drawing.Size(32, 17);
             this.label10.TabIndex = 90;
@@ -1447,7 +1432,7 @@
             // 
             this.label6.AutoSize = true;
             this.label6.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label6.Location = new System.Drawing.Point(9, 114);
+            this.label6.Location = new System.Drawing.Point(7, 112);
             this.label6.Name = "label6";
             this.label6.Size = new System.Drawing.Size(32, 17);
             this.label6.TabIndex = 87;
@@ -1459,7 +1444,7 @@
             this.OutBoxPrinter.Location = new System.Drawing.Point(8, 63);
             this.OutBoxPrinter.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
             this.OutBoxPrinter.Name = "OutBoxPrinter";
-            this.OutBoxPrinter.Size = new System.Drawing.Size(158, 30);
+            this.OutBoxPrinter.Size = new System.Drawing.Size(158, 25);
             this.OutBoxPrinter.TabIndex = 82;
             // 
             // OutboxCapacity
@@ -1527,7 +1512,6 @@
             this.Controls.Add(this.AttachInfo);
             this.Controls.Add(this.groupBoxWithBorder1);
             this.Controls.Add(this.ChooseAll);
-            this.Controls.Add(this.GetGridOnly);
             this.Controls.Add(this.Fresh);
             this.Controls.Add(this.pi_cardcode);
             this.Controls.Add(this.pib_id);
@@ -1553,18 +1537,18 @@
             ((System.ComponentModel.ISupportInitialize)(this.MidSource)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.GridPrcode)).EndInit();
-            this.groupBoxWithBorder1.ResumeLayout(true);
+            this.groupBoxWithBorder1.ResumeLayout(false);
             this.groupBoxWithBorder1.PerformLayout();
             ((System.ComponentModel.ISupportInitialize)(this.LabelInf)).EndInit();
-            this.SingleLabel.ResumeLayout(true);
+            this.SingleLabel.ResumeLayout(false);
             this.SingleLabel.PerformLayout();
-            this.MidLabel.ResumeLayout(true);
+            this.MidLabel.ResumeLayout(false);
             this.MidLabel.PerformLayout();
             ((System.ComponentModel.ISupportInitialize)(this.MidboxCapacity)).EndInit();
-            this.OutBoxLabel.ResumeLayout(true);
+            this.OutBoxLabel.ResumeLayout(false);
             this.OutBoxLabel.PerformLayout();
             ((System.ComponentModel.ISupportInitialize)(this.OutboxCapacity)).EndInit();
-            this.ResumeLayout(true);
+            this.ResumeLayout(false);
             this.PerformLayout();
 
         }
@@ -1620,7 +1604,6 @@
         private System.Windows.Forms.LinkLabel Fresh;
         private System.Windows.Forms.LinkLabel LogingOut;
         private System.Windows.Forms.Timer RefreshDBConnect;
-        private System.Windows.Forms.CheckBox GetGridOnly;
         private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn16;
         private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn17;
         private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn18;

+ 4 - 24
UAS-出货标签管理(泽天)/UAS_出货标签管理.cs

@@ -171,14 +171,7 @@ namespace UAS_LabelMachine
 
         private void LabelFormClose(object sender, EventArgs e)
         {
-            if (GetGridOnly.Checked)
                 GetInOutInfAndLabelFile();
-            else
-            {
-                GetGridOnly.Checked = true;
-                GetInOutInfAndLabelFile();
-                GetGridOnly.Checked = false;
-            }
         }
 
         //输入框Enter事件
@@ -498,11 +491,7 @@ namespace UAS_LabelMachine
             SingleLabelCombox.DisplayMember = "cl_labelname";
             SingleLabelCombox.ValueMember = "cl_labelurl";
             SingleLabelCombox.DataSource = dt;
-            if (SingleLabelCombox.Text != "")
-            {
-                if (!SingleLabelCombox.SelectedValue.ToString().Contains("System.Data.DataRowView"))
-                    SingleReport.Load(SingleLabelCombox.SelectedValue.ToString());
-            }
+          
             sql.Clear();
             sql.Append("select to_char(nvl(cl_date,sysdate),'YYYY-MM-DD HH24:Mi:SS') cl_date,cl_labelurl,cl_labelname,cl_isdefault,la_id||'#'||cl_labelurl||'#'||to_char(cl_date,'YYYY-MM-DD HH24:Mi:SS')  la_id,cl_custcode from customerlabel left join prodinout on pi_cardcode=cl_custcode ");
             sql.Append("left join customer on cu_code=cl_custcode left join label on la_code=CL_LABELCODE where ((pi_cardcode='" + pi_cardcode.Text + "' ");
@@ -511,11 +500,7 @@ namespace UAS_LabelMachine
             MidLabelCombox.DisplayMember = "cl_labelname";
             MidLabelCombox.ValueMember = "cl_labelurl";
             MidLabelCombox.DataSource = dt;
-            if (MidLabelCombox.Text != "")
-            {
-                if (!MidLabelCombox.SelectedValue.ToString().Contains("System.Data.DataRowView"))
-                    MidReport.Load(MidLabelCombox.SelectedValue.ToString());
-            }
+          
             sql.Clear();
             sql.Append("select to_char(nvl(cl_date,sysdate),'YYYY-MM-DD HH24:Mi:SS') cl_date,cl_labelurl,cl_labelname,cl_isdefault,la_id||'#'||cl_labelurl||'#'||to_char(cl_date,'YYYY-MM-DD HH24:Mi:SS')  la_id,cl_custcode from customerlabel left join prodinout on pi_cardcode=cl_custcode ");
             sql.Append("left join customer on cu_code=cl_custcode left join label on la_code=CL_LABELCODE where ((pi_cardcode='" + pi_cardcode.Text + "' ");
@@ -524,12 +509,7 @@ namespace UAS_LabelMachine
             OutBoxCombox.DisplayMember = "cl_labelname";
             OutBoxCombox.ValueMember = "cl_labelurl";
             OutBoxCombox.DataSource = dt;
-            if (OutBoxCombox.Text != "")
-            {
-                if (!OutBoxCombox.SelectedValue.ToString().Contains("System.Data.DataRowView"))
-                    OutReport.Load(OutBoxCombox.SelectedValue.ToString());
-            }
-            FootReport.Load(@"\\10.2.10.238\PRINTE\FASTREPORT\唛头.frx");
+          
             ComBoxClickChangeLabelDoc = true;
         }
 
@@ -562,7 +542,6 @@ namespace UAS_LabelMachine
                     pi_date.Text = dt.Rows[0]["pi_date"].ToString();
                     PI_ID = dt.Rows[0]["pi_id"].ToString();
                     OutBoxNum_Click(new object(), new EventArgs());
-                    LoadGridData(sender, e);
                     LoadPrcodeData();
                     //获取条码规则
                     GetBarCodeRule(out Prefix, out Suffix, out MaxNum, out NumLength, out Radix);
@@ -1586,6 +1565,7 @@ namespace UAS_LabelMachine
 
         private void PrintFooter_Click(object sender, EventArgs e)
         {
+            FootReport.Load(@"\\10.2.10.238\PRINTE\FASTREPORT\唛头.frx");
             DataTable dt = (DataTable)dh.ExecuteSql("select pib_outboxcode2,max(pib_id) pib_id from prodiobarcode where pib_inoutno='" + pi_inoutno.Text + "' group by pib_outboxcode2 order by to_number(pib_outboxcode2)", "select");
             string SQL = "select pib_outboxcode2||'/'||(select max(to_number(pib_outboxcode2)) from prodiobarcode where pib_inoutno='" + pi_inoutno.Text + "') from prodiobarcode  where pib_id=";
             for (int i = 0; i < dt.Rows.Count; i++)