Merge branch 'master' of http://101.37.171.70:10101/r/YqnMes
| | |
| | | whereBuilder.Append(" and d.FNUMBER like ''%"+textBox1.Text+"%''");
|
| | | if (!string.IsNullOrEmpty(textBox2.Text))
|
| | | whereBuilder.Append(" and b.FLOT_TEXT like ''%"+textBox2.Text+"%''");
|
| | | if (comboBox1.Text != "å
¨é¨")
|
| | | {
|
| | | if(comboBox1.Text=="åæ ¼å")
|
| | | {
|
| | | whereBuilder.Append(" and c.HProdLev=''''");
|
| | | }
|
| | | else
|
| | | {
|
| | | whereBuilder.Append(" and c.HProdLev=''" + comboBox1.Text + "''");
|
| | | }
|
| | | |
| | | }
|
| | | if(comboBox1.Text!="å
¨é¨")
|
| | | whereBuilder.Append(" and c.HProdLev=''" + comboBox1.Text+"''");
|
| | | if (!string.IsNullOrEmpty(textBox4.Text))
|
| | | whereBuilder.Append(" and g.HName like ''%"+textBox4.Text+"%''");
|
| | | if (!string.IsNullOrEmpty(textBox5.Text))
|
| | |
| | | this.lbldj = new System.Windows.Forms.Label(); |
| | | this.lblCaption = new System.Windows.Forms.Label(); |
| | | this.Tool = new System.Windows.Forms.ToolStrip(); |
| | | this.yl = new System.Windows.Forms.ToolStripButton(); |
| | | this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator(); |
| | | this.cx = new System.Windows.Forms.ToolStripButton(); |
| | | this.toolStripSeparator2 = new System.Windows.Forms.ToolStripSeparator(); |
| | | this.tc = new System.Windows.Forms.ToolStripButton(); |
| | | this.toolStripSeparator9 = new System.Windows.Forms.ToolStripSeparator(); |
| | | this.comboBox1 = new System.Windows.Forms.ComboBox(); |
| | | this.label8 = new System.Windows.Forms.Label(); |
| | | this.yl = new System.Windows.Forms.ToolStripButton(); |
| | | this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator(); |
| | | ((System.ComponentModel.ISupportInitialize)(this.grdMain)).BeginInit(); |
| | | this.groupBox1.SuspendLayout(); |
| | | this.pPic.SuspendLayout(); |
| | |
| | | this.grdMain.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; |
| | | this.grdMain.Dock = System.Windows.Forms.DockStyle.Fill; |
| | | this.grdMain.Location = new System.Drawing.Point(0, 232); |
| | | this.grdMain.Margin = new System.Windows.Forms.Padding(4); |
| | | this.grdMain.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); |
| | | this.grdMain.Name = "grdMain"; |
| | | this.grdMain.ReadOnly = true; |
| | | this.grdMain.RowHeadersWidth = 51; |
| | |
| | | // groupBox1 |
| | | // |
| | | this.groupBox1.BackColor = System.Drawing.Color.Lavender; |
| | | this.groupBox1.Controls.Add(this.comboBox1); |
| | | this.groupBox1.Controls.Add(this.label8); |
| | | this.groupBox1.Controls.Add(this.dateTimePicker2); |
| | | this.groupBox1.Controls.Add(this.dateTimePicker1); |
| | | this.groupBox1.Controls.Add(this.label9); |
| | |
| | | this.groupBox1.Controls.Add(this.label4); |
| | | this.groupBox1.Dock = System.Windows.Forms.DockStyle.Top; |
| | | this.groupBox1.Location = new System.Drawing.Point(0, 103); |
| | | this.groupBox1.Margin = new System.Windows.Forms.Padding(4); |
| | | this.groupBox1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); |
| | | this.groupBox1.Name = "groupBox1"; |
| | | this.groupBox1.Padding = new System.Windows.Forms.Padding(4); |
| | | this.groupBox1.Padding = new System.Windows.Forms.Padding(4, 4, 4, 4); |
| | | this.groupBox1.Size = new System.Drawing.Size(1277, 129); |
| | | this.groupBox1.TabIndex = 56; |
| | | this.groupBox1.TabStop = false; |
| | |
| | | // textBox2 |
| | | // |
| | | this.textBox2.Location = new System.Drawing.Point(628, 75); |
| | | this.textBox2.Margin = new System.Windows.Forms.Padding(4); |
| | | this.textBox2.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); |
| | | this.textBox2.Name = "textBox2"; |
| | | this.textBox2.Size = new System.Drawing.Size(172, 25); |
| | | this.textBox2.TabIndex = 16; |
| | |
| | | // textBox1 |
| | | // |
| | | this.textBox1.Location = new System.Drawing.Point(365, 75); |
| | | this.textBox1.Margin = new System.Windows.Forms.Padding(4); |
| | | this.textBox1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); |
| | | this.textBox1.Name = "textBox1"; |
| | | this.textBox1.Size = new System.Drawing.Size(172, 25); |
| | | this.textBox1.TabIndex = 14; |
| | |
| | | // txtHBillNo |
| | | // |
| | | this.txtHBillNo.Location = new System.Drawing.Point(96, 76); |
| | | this.txtHBillNo.Margin = new System.Windows.Forms.Padding(4); |
| | | this.txtHBillNo.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); |
| | | this.txtHBillNo.Name = "txtHBillNo"; |
| | | this.txtHBillNo.Size = new System.Drawing.Size(172, 25); |
| | | this.txtHBillNo.TabIndex = 12; |
| | |
| | | this.pPic.Controls.Add(this.lblCaption); |
| | | this.pPic.Dock = System.Windows.Forms.DockStyle.Top; |
| | | this.pPic.Location = new System.Drawing.Point(0, 62); |
| | | this.pPic.Margin = new System.Windows.Forms.Padding(4); |
| | | this.pPic.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); |
| | | this.pPic.Name = "pPic"; |
| | | this.pPic.Size = new System.Drawing.Size(1277, 41); |
| | | this.pPic.TabIndex = 55; |
| | |
| | | this.panel1.Controls.Add(this.lbldj); |
| | | this.panel1.Dock = System.Windows.Forms.DockStyle.Right; |
| | | this.panel1.Location = new System.Drawing.Point(1096, 0); |
| | | this.panel1.Margin = new System.Windows.Forms.Padding(4); |
| | | this.panel1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); |
| | | this.panel1.Name = "panel1"; |
| | | this.panel1.Size = new System.Drawing.Size(181, 41); |
| | | this.panel1.TabIndex = 7; |
| | |
| | | this.Tool.TabIndex = 54; |
| | | this.Tool.Text = "toolStrip1"; |
| | | // |
| | | // yl |
| | | // |
| | | this.yl.AutoSize = false; |
| | | this.yl.Image = ((System.Drawing.Image)(resources.GetObject("yl.Image"))); |
| | | this.yl.ImageAlign = System.Drawing.ContentAlignment.BottomCenter; |
| | | this.yl.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; |
| | | this.yl.ImageTransparentColor = System.Drawing.Color.Magenta; |
| | | this.yl.Name = "yl"; |
| | | this.yl.Size = new System.Drawing.Size(35, 42); |
| | | this.yl.Text = "å¼åº"; |
| | | this.yl.TextAlign = System.Drawing.ContentAlignment.BottomCenter; |
| | | this.yl.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText; |
| | | this.yl.Click += new System.EventHandler(this.yl_Click); |
| | | // |
| | | // toolStripSeparator1 |
| | | // |
| | | this.toolStripSeparator1.Name = "toolStripSeparator1"; |
| | | this.toolStripSeparator1.Size = new System.Drawing.Size(6, 62); |
| | | // |
| | | // cx |
| | | // |
| | | this.cx.AutoSize = false; |
| | |
| | | this.toolStripSeparator9.Name = "toolStripSeparator9"; |
| | | this.toolStripSeparator9.Size = new System.Drawing.Size(6, 62); |
| | | // |
| | | // comboBox1 |
| | | // yl |
| | | // |
| | | this.comboBox1.FormattingEnabled = true; |
| | | this.comboBox1.Items.AddRange(new object[] { |
| | | "å
¨é¨", |
| | | "å·²æ£éª", |
| | | "æªæ£éª"}); |
| | | this.comboBox1.Location = new System.Drawing.Point(907, 75); |
| | | this.comboBox1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); |
| | | this.comboBox1.Name = "comboBox1"; |
| | | this.comboBox1.Size = new System.Drawing.Size(172, 23); |
| | | this.comboBox1.TabIndex = 35; |
| | | this.yl.AutoSize = false; |
| | | this.yl.Image = ((System.Drawing.Image)(resources.GetObject("yl.Image"))); |
| | | this.yl.ImageAlign = System.Drawing.ContentAlignment.BottomCenter; |
| | | this.yl.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; |
| | | this.yl.ImageTransparentColor = System.Drawing.Color.Magenta; |
| | | this.yl.Name = "yl"; |
| | | this.yl.Size = new System.Drawing.Size(35, 42); |
| | | this.yl.Text = "å¼åº"; |
| | | this.yl.TextAlign = System.Drawing.ContentAlignment.BottomCenter; |
| | | this.yl.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText; |
| | | this.yl.Click += new System.EventHandler(this.yl_Click); |
| | | // |
| | | // label8 |
| | | // toolStripSeparator1 |
| | | // |
| | | this.label8.AutoSize = true; |
| | | this.label8.Location = new System.Drawing.Point(818, 80); |
| | | this.label8.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); |
| | | this.label8.Name = "label8"; |
| | | this.label8.Size = new System.Drawing.Size(82, 15); |
| | | this.label8.TabIndex = 34; |
| | | this.label8.Text = "æ£éªç¶åµï¼"; |
| | | this.toolStripSeparator1.Name = "toolStripSeparator1"; |
| | | this.toolStripSeparator1.Size = new System.Drawing.Size(6, 62); |
| | | // |
| | | // Gy_BarCodeMain |
| | | // |
| | |
| | | private System.Windows.Forms.Label label11; |
| | | private System.Windows.Forms.ToolStripButton yl; |
| | | private System.Windows.Forms.ToolStripSeparator toolStripSeparator1; |
| | | private System.Windows.Forms.ComboBox comboBox1; |
| | | private System.Windows.Forms.Label label8; |
| | | } |
| | | } |
| | |
| | | InitializeComponent(); |
| | | dateTimePicker1.Text = DateTime.Now.AddDays(-7).ToString(); |
| | | dateTimePicker2.Text = DateTime.Now.ToString(); |
| | | comboBox1.SelectedItem = "å
¨é¨"; |
| | | oWeb.Url = SCM.ClsPub1.WEBSURL; |
| | | } |
| | | public frmBillQueryCondition_Base frmCondition; |
| | |
| | | whereBuilder.Append(" and e.FNUMBER like ''%"+textBox1.Text+"%''"); |
| | | if (!string.IsNullOrEmpty(textBox2.Text)) |
| | | whereBuilder.Append(" and c.HMaterName like ''%"+textBox2.Text+"%''"); |
| | | if (comboBox1.Text == "å·²æ£éª") |
| | | whereBuilder.Append(" and c.HMaterName is not null"); |
| | | else if(comboBox1.Text=="æªæ£éª") |
| | | whereBuilder.Append(" and c.HMaterName is null"); |
| | | var execSql = "exec "+ViewName+" '"+whereBuilder+"'"; |
| | | DataSet DSet = oWeb.getDataSetBySQL(execSql, ViewName, ref DBUtility.ClsPub.sExeReturnInfo); |
| | | //çæé¦è¡æ é¢ |
| | |
| | | using System;
|
| | | using System;
|
| | | using System.Collections.Generic;
|
| | | using System.ComponentModel;
|
| | | using System.Data;
|
| | |
| | | oWeb.Url = SCM.ClsPub1.WEBSURL;
|
| | | //
|
| | | frmCondition = new frmBillQueryCondition_Base();
|
| | | this.Text = ModCaption; |
| | | this.Text = ModCaption;
|
| | | oSumGrid.ogrdMain = grdSub; //åå§å new
|
| | | oSumGrid.oGridsum = grdSum;
|
| | | initGrid();
|
| | |
| | | cmbFQMB.Items.Add(this.Text);
|
| | | cmbFQMB.SelectedIndex = 0;
|
| | |
|
| | | if(DBUtility.ClsPub.CurUserName.ToLower()=="admin")
|
| | | if (DBUtility.ClsPub.CurUserName.ToLower() == "admin")
|
| | | {
|
| | | txtHDQQty.ReadOnly = false;
|
| | | txtHKSQty.ReadOnly = false;
|
| | |
| | | //æ¶é´æ§ä»¶
|
| | | private void timer1_Tick(object sender, EventArgs e)
|
| | | {
|
| | | timer1.Enabled=false;
|
| | | timer1.Enabled = false;
|
| | | Sub_ClearBill();
|
| | | }
|
| | |
|
| | |
| | | {
|
| | | timer2.Enabled = false;
|
| | | //
|
| | | if (ClsIni.ReadIni("COMINFO", "txtPortName", DBUtility.ClsPub.AppPath + @"/HXERP.ini").Contains("æ²¡ææ¾å°")==false)
|
| | | if (ClsIni.ReadIni("COMINFO", "txtPortName", DBUtility.ClsPub.AppPath + @"/HXERP.ini").Contains("æ²¡ææ¾å°") == false)
|
| | | {
|
| | | txtPortName.Text = ClsIni.ReadIni("COMINFO", "txtPortName", DBUtility.ClsPub.AppPath + @"/HXERP.ini");
|
| | | txtBaudRate.Text = ClsIni.ReadIni("COMINFO", "txtBaudRate", DBUtility.ClsPub.AppPath + @"/HXERP.ini");
|
| | |
| | | txtHSYQty.Text = oTable.Rows[0]["æªçææ¡ç æ°é"].ToString();
|
| | | txtHKSQty.Text = lblHNowQty.Text;
|
| | | txtHDQQty.Text = lblHNowQty.Text;
|
| | | if (DBUtility.ClsPub.isDoule(txtHDQQty.Text) - DBUtility.ClsPub.isDoule(txtHKSQty.Text)>0)
|
| | | if (DBUtility.ClsPub.isDoule(txtHDQQty.Text) - DBUtility.ClsPub.isDoule(txtHKSQty.Text) > 0)
|
| | | {
|
| | | txtHSJQty.Text = DBUtility.ClsPub.isDoule(DBUtility.ClsPub.isDoule(txtHDQQty.Text) - DBUtility.ClsPub.isDoule(txtHKSQty.Text), 1);
|
| | | }
|
| | |
| | | DisplayMain();
|
| | | //DisplaySub();
|
| | | }
|
| | | catch(Exception e)
|
| | | catch (Exception e)
|
| | | {
|
| | | MessageBox.Show("读å失败ï¼" + e.Message);
|
| | | }
|
| | |
| | | string sSql = "";
|
| | | string sWhere = "";
|
| | | //è¿æ»¤æ¡ä»¶
|
| | | sSql = " exec h_p_Sc_ICMOReportToBarCode_All '" + HSourceBillTypeID + "'," + HSourceInterID.ToString() + "," + HSourceEntryID.ToString(); |
| | | sSql = " exec h_p_Sc_ICMOReportToBarCode_All '" + HSourceBillTypeID + "'," + HSourceInterID.ToString() + "," + HSourceEntryID.ToString();
|
| | | //
|
| | | DSet = oWeb.getDataSetBySQL(sSql, "h_p_Sc_ICMOReportToBarCode_All", ref DBUtility.ClsPub.sExeReturnInfo);
|
| | | //çæé¦è¡æ é¢
|
| | |
| | | return;
|
| | | }
|
| | | //
|
| | | if (DSet.Tables[0].Rows.Count>0)
|
| | | if (DSet.Tables[0].Rows.Count > 0)
|
| | | {
|
| | | grdMain.DataSource = DSet.Tables[0].DefaultView;
|
| | | }
|
| | |
| | | ClsPub1.DisplayGrid(grdSub, this.Name + "grdSub", s, FrCol);
|
| | | /////////////////////////////
|
| | | txtHRelationQty.Text = DBUtility.ClsPub.isDoule(DSet.Tables[2].Rows[0]["å
³èæ°é"], 1);
|
| | | if(DBUtility.ClsPub.isDoule(txtHSumQty.Text) - DBUtility.ClsPub.isDoule(txtHRelationQty.Text)>=0)
|
| | | if (DBUtility.ClsPub.isDoule(txtHSumQty.Text) - DBUtility.ClsPub.isDoule(txtHRelationQty.Text) >= 0)
|
| | | {
|
| | | txtHSYQty.Text = DBUtility.ClsPub.isDoule(DBUtility.ClsPub.isDoule(txtHSumQty.Text) - DBUtility.ClsPub.isDoule(txtHRelationQty.Text), 1);
|
| | | }
|
| | |
| | | string sWhere = "";
|
| | | //è¿æ»¤æ¡ä»¶
|
| | | sSql = " exec h_p_Sc_ICMOReportToBarCode_Sub '" + HSourceBillTypeID + "'," + HSourceInterID.ToString() + "," + HSourceEntryID.ToString();
|
| | | |
| | |
|
| | | //
|
| | | DSet = oWeb.getDataSetBySQL(sSql, "h_p_Sc_ICMOReportToBarCode_Sub", ref DBUtility.ClsPub.sExeReturnInfo);
|
| | | //çæé¦è¡æ é¢
|
| | |
| | |
|
| | | //é¢è§
|
| | | int CurRows = 0;
|
| | | |
| | |
|
| | | |
| | | |
| | |
|
| | | |
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | | #endregion
|
| | |
|
| | |
| | | if (oDept.RefreshView(sWhere))
|
| | | {
|
| | | this.txtHDeptID.Text = oDept.oModel.HName;
|
| | | this.txtHDeptID.Tag = oDept.oModel.HItemID.ToString(); |
| | | this.txtHDeptID.Tag = oDept.oModel.HItemID.ToString();
|
| | | }
|
| | | else
|
| | | {
|
| | | this.txtHDeptID.Text = ""; |
| | | this.txtHDeptID.Text = "";
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | // cmdHSaveBill.Enabled = true;
|
| | | // return false;
|
| | | //}
|
| | | if (DBUtility.ClsPub.isLong(txtHEmpID.Tag) == 0 || DBUtility.ClsPub.isLong(txtHEmpID2.Tag) == 0 ) |
| | | if (DBUtility.ClsPub.isLong(txtHEmpID.Tag) == 0 || DBUtility.ClsPub.isLong(txtHEmpID2.Tag) == 0)
|
| | | {
|
| | | MessageBox.Show("èå1æè
èå2没æéæ©ï¼");
|
| | | cmdHSaveBill.Enabled = true;
|
| | | return false;
|
| | | }
|
| | | if (DBUtility.ClsPub.isLong(txtHGroupID.Tag) == 0 )
|
| | | if (DBUtility.ClsPub.isLong(txtHGroupID.Tag) == 0)
|
| | | {
|
| | | MessageBox.Show("çç»æ²¡æéæ©ï¼");
|
| | | cmdHSaveBill.Enabled = true;
|
| | | return false;
|
| | | }
|
| | | |
| | |
|
| | |
|
| | | //æ ¹æ®æºå çææ¡å½¢ç å¹¶ä¿å妿°æ®åº
|
| | | HNumber = DBUtility.ClsPub.isStrNull(txtHMaterName.Tag);
|
| | |
| | | else if (sType == "Sample")
|
| | | {
|
| | | sTMNumber = HNumber + ";" + DBUtility.ClsPub.isStrNull(txtHBatchNo.Text) + "B";
|
| | | txtHCheckerResult.Text = "";
|
| | | }
|
| | | else
|
| | | {
|
| | | sTMNumber = HNumber + ";" + DBUtility.ClsPub.isStrNull(txtHBatchNo.Text);
|
| | | txtHCheckerResult.Text = "";
|
| | | }
|
| | | //sTMNumber = HNumber + ";" + DBUtility.ClsPub.isStrNull(txtHBatchNo.Text);
|
| | |
|
| | |
| | | + ",'" + HPressModel + "','" + HCusModel + "','" + HMaterialModel + "','" + HColor + "','" + sDate + "'"
|
| | | + ",'" + HLogo + "','" + HPackageSize + "'," + HMaterialJQty.ToString() + "," + HMaterialMQty.ToString() + ",'" + HCustomBatchNo + "'"
|
| | | + ", " + HOrgID.ToString() + "," + HOrgID.ToString() + ",'" + HBeginDate.ToShortDateString() + "','" + HSeOrderBillNo + "','" + HGBBarCode + "'"
|
| | | + ",'" + POOrderBillNo + "'" + "," + DBUtility.ClsPub.isLong(txtHSourceID.Tag) |
| | | + ",'" + HMaterName + "','" + HMaterModel + "','" + HPinfan + "'," + HAuxPropID.ToString() + ",'" + HMTONo + "','" + txtHReasonList.Text + "','"+ HRemark + "')";
|
| | | + ",'" + POOrderBillNo + "'" + "," + DBUtility.ClsPub.isLong(txtHSourceID.Tag)
|
| | | + ",'" + HMaterName + "','" + HMaterModel + "','" + HPinfan + "'," + HAuxPropID.ToString() + ",'" + HMTONo + "','" + txtHReasonList.Text + "','" + HRemark + "')";
|
| | | oWeb.getRunProc(sSQLMul, ref DBUtility.ClsPub.sExeReturnInfo);
|
| | |
|
| | | |
| | |
|
| | | //å·æ°çé¢
|
| | | DisplayMain();
|
| | | //DisplaySub();
|
| | |
| | | {
|
| | | Report.Print(false);
|
| | | }
|
| | | |
| | |
|
| | | Thread.Sleep(500);
|
| | |
|
| | | if (HSourceBillType != "çäº§æ±æ¥å")
|
| | |
| | | private void Sub_SetReport(string sOpenTmp)
|
| | | {
|
| | | //å¤æè¡æ°
|
| | | |
| | |
|
| | | Report = new GridppReport();
|
| | | Report.LoadFromFile(DBUtility.ClsPub.AppPath + @"\" + sOpenTmp + ".grf"); //here .
|
| | | Report.BeforePostRecord += new _IGridppReportEvents_BeforePostRecordEventHandler(ReportBeforePostRecord);
|
| | |
| | | Report.FieldByName("ç»å").AsString = ClsPub.isStrNull(txtHEmpID.Text) + ";" + ClsPub.isStrNull(txtHEmpID2.Text) + ";" + ClsPub.isStrNull(txtHEmpID3.Text);
|
| | | Report.FieldByName("æ°é").AsString = ClsPub.isStrNull(txtHSJQty.Text);
|
| | | Report.FieldByName("æ§ç©æç¼ç ").AsString = ClsPub.isStrNull(txtHOldMaterNumber.Text);
|
| | | Report.FieldByName("ä¸è¯åå ").AsString = ClsPub.isStrNull(txtHCheckerResult.Text);
|
| | | //Report.FieldByName("æºååå·").AsString = ClsPub.isStrNull(grdSub.Rows[CurRows].Cells[HSourceBillNoCol].Value);
|
| | | //Report.FieldByName("éå®è®¢åå·").AsString = ClsPub.isStrNull(grdSub.Rows[CurRows].Cells[HSeOrderBillNo2Col].Value);
|
| | | //Report.FieldByName("ç产车é´").AsString = ClsPub.isStrNull(grdSub.Rows[CurRows].Cells[HDeptName2Col].Value);
|
| | |
| | | {
|
| | | if (!ComDevice.IsOpen)
|
| | | {
|
| | | |
| | |
|
| | | try
|
| | | {
|
| | | ComDevice.PortName = txtPortName.Text;
|
| | |
| | | default:
|
| | | break;
|
| | | }
|
| | | |
| | |
|
| | | ComDevice.DataBits = int.Parse(txtDataBits.Text);
|
| | | switch (cmbStopBits.SelectedItem.ToString())
|
| | | {
|
| | |
| | | default:
|
| | | break;
|
| | | }
|
| | | |
| | | ComDevice.Open(); |
| | |
|
| | | ComDevice.Open();
|
| | | lblComStatus.Text = "串å£ç¶æï¼å¼å¯";
|
| | | timer3.Enabled = true;
|
| | | }
|
| | | catch (Exception ex)
|
| | | {
|
| | | MessageBox.Show("æå¼ä¸²å£å¤±è´¥ï¼" + ex.Message, "é误", MessageBoxButtons.OK, MessageBoxIcon.Error); |
| | | MessageBox.Show("æå¼ä¸²å£å¤±è´¥ï¼" + ex.Message, "é误", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
| | | return;
|
| | | }
|
| | | }
|
| | |
| | | {
|
| | | if (!ComDevice.IsOpen)
|
| | | {
|
| | | |
| | |
|
| | | }
|
| | | else
|
| | | {
|
| | | try
|
| | | {
|
| | | ComDevice.Close(); |
| | | ComDevice.Close();
|
| | | lblComStatus.Text = "串å£ç¶æï¼å
³é";
|
| | | timer3.Enabled = false;
|
| | | }
|
| | | catch (Exception ex)
|
| | | {
|
| | | MessageBox.Show(ex.Message, "é误", MessageBoxButtons.OK, MessageBoxIcon.Error); |
| | | MessageBox.Show(ex.Message, "é误", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
| | | return;
|
| | | }
|
| | | }
|
| | |
| | | //è®¾å¤æ¸
é¶
|
| | | private void cmdHSetZero_Click(object sender, EventArgs e)
|
| | | {
|
| | | cmdHSetZero.Enabled=false;
|
| | | cmdHSetZero.Enabled = false;
|
| | | byte[] sendData = strToHexByte(txtHSend0.Text);
|
| | | SendData(sendData);
|
| | | txtHSJQty.Text = "0";
|
| | |
| | | }
|
| | |
|
| | |
|
| | | /// <summary>
|
| | | /// <summary>
|
| | | /// åéæ°æ®
|
| | | /// </summary>
|
| | | /// <param name="sender"></param>
|
| | | /// <param name="data"></param>
|
| | | public bool SendData(byte[] data)
|
| | | { |
| | | {
|
| | | if (ComDevice.IsOpen)
|
| | | {
|
| | | try
|
| | |
| | | }
|
| | | catch (Exception ex)
|
| | | {
|
| | | MessageBox.Show(ex.Message, "é误", MessageBoxButtons.OK, MessageBoxIcon.Error); |
| | | MessageBox.Show(ex.Message, "é误", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
| | | }
|
| | | finally
|
| | | {
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | MessageBox.Show("䏲壿ªæå¼", "é误", MessageBoxButtons.OK, MessageBoxIcon.Error); |
| | | MessageBox.Show("䏲壿ªæå¼", "é误", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
| | | }
|
| | | return false;
|
| | | }
|
| | |
| | | // {
|
| | | // newStr = strArr[4];
|
| | | // }
|
| | | |
| | |
|
| | | // }
|
| | | // if (string.IsNullOrEmpty(newStr))
|
| | | // {
|
| | |
| | | if (strArr[4] != "00")
|
| | | {
|
| | | char[] bw = strArr[4].ToCharArray();
|
| | | if(bw[0]=='0')
|
| | | if (bw[0] == '0')
|
| | | {
|
| | | newStr = bw[1].ToString();
|
| | | }
|
| | |
| | | {
|
| | | newStr = strArr[4];
|
| | | }
|
| | | |
| | |
|
| | | }
|
| | | if (string.IsNullOrEmpty(newStr))
|
| | | {
|
| | |
| | | {
|
| | | newStr += strArr[5];
|
| | | }
|
| | | if (strArr[6] != "00"&&newStr=="00")
|
| | | if (strArr[6] != "00" && newStr == "00")
|
| | | {
|
| | | //newStr = $"0.{strArr[6]}";
|
| | | newStr = "0." + strArr[6];
|
| | | }
|
| | | if(strArr[6]!="00"&&newStr!="00")
|
| | | if (strArr[6] != "00" && newStr != "00")
|
| | | {
|
| | | //newStr += $".{strArr[6]}";
|
| | | newStr = newStr + "." + strArr[6];
|
| | |
| | |
|
| | |
|
| | | //å°å½åæ° åç±³ 转å为 ç±³
|
| | | double NewQty = DBUtility.ClsPub.isDoule(newStr) ;
|
| | | double NewQty = DBUtility.ClsPub.isDoule(newStr);
|
| | | if (NewQty <= 0)
|
| | | {
|
| | | newStr = "0";
|
| | |
| | | lblHRelQty.Text = txtHSJQty.Text;
|
| | | }
|
| | | else
|
| | | { |
| | | {
|
| | | txtHSJQty.Text = DBUtility.ClsPub.isDoule(DBUtility.ClsPub.isDoule(txtHDQQty.Text), 1); //å®é
ç±³æ°= å½åç±³æ°-å¼å§ç±³æ°
|
| | | lblHRelQty.Text = txtHSJQty.Text; |
| | | lblHRelQty.Text = txtHSJQty.Text;
|
| | | }
|
| | | }
|
| | | |
| | |
|
| | | //å é¤éä¸çè¡æ°
|
| | | private void btnFQSH_Click(object sender, EventArgs e)
|
| | | {
|
| | |
| | | if (lngBillKey == 0)
|
| | | return;
|
| | | try
|
| | | { |
| | | {
|
| | | oWeb.getRunProc("Delete from Gy_BarCodeBill where HItemID=" + lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo);
|
| | | oWeb.getRunProc("insert into System_log values(GETDATE(),'" + DBUtility.ClsPub.CurUserName + "','" + DBUtility.ClsPub.CurUserName + "','å 餿¡ç ï¼" + DBUtility.ClsPub.isStrNull(grdMain.SelectedRows[i].Cells[Fun_GetCol("æ¡å½¢ç ")].Value) + "' ,'WMSç³»ç»','','å é¤')", ref DBUtility.ClsPub.sExeReturnInfo);
|
| | | |
| | |
|
| | | }
|
| | | catch (Exception e)
|
| | | {
|
| | |
| | | }
|
| | |
|
| | | private void cmdHSaveInfo_Click(object sender, EventArgs e)
|
| | | { |
| | | {
|
| | | ClsIni.WriteIni("COMINFO", "txtPortName", DBUtility.ClsPub.isStrNull(txtPortName.Text), DBUtility.ClsPub.AppPath + @"/HXERP.ini");
|
| | | ClsIni.WriteIni("COMINFO", "txtBaudRate", DBUtility.ClsPub.isStrNull(txtBaudRate.Text), DBUtility.ClsPub.AppPath + @"/HXERP.ini");
|
| | | ClsIni.WriteIni("COMINFO", "cmbParity", DBUtility.ClsPub.isStrNull(cmbParity.Text), DBUtility.ClsPub.AppPath + @"/HXERP.ini");
|
| | |
| | | ClsIni.WriteIni("COMINFO", "txtHSend0", DBUtility.ClsPub.isStrNull(txtHSend0.Text), DBUtility.ClsPub.AppPath + @"/HXERP.ini");
|
| | | ClsIni.WriteIni("COMINFO", "txtHSend", DBUtility.ClsPub.isStrNull(txtHSend.Text), DBUtility.ClsPub.AppPath + @"/HXERP.ini");
|
| | | ClsIni.WriteIni("COMINFO", "txtHSourceID", DBUtility.ClsPub.isStrNull(txtHSourceID.Text), DBUtility.ClsPub.AppPath + @"/HXERP.ini");
|
| | | ClsIni.WriteIni("COMINFO", "txtHSourceIDTag", DBUtility.ClsPub.isStrNull(txtHSourceID.Tag), DBUtility.ClsPub.AppPath + @"/HXERP.ini"); |
| | | ClsIni.WriteIni("COMINFO", "txtHSourceIDTag", DBUtility.ClsPub.isStrNull(txtHSourceID.Tag), DBUtility.ClsPub.AppPath + @"/HXERP.ini");
|
| | | }
|
| | |
|
| | | private void btnBLHB_Click(object sender, EventArgs e)
|
| | |
| | | {
|
| | | txtHReasonList.Text = "";
|
| | | txtHReasonList.Text = oGy_BadReasonList.txtHBadReason.Text;
|
| | | txtHCheckerResult.Text = "";
|
| | | txtHCheckerResult.Text = oGy_BadReasonList.txtHBadReason.Text;
|
| | | if (SaveBadReasonBill())
|
| | | {
|
| | | MessageBox.Show("ä¿åä¸è¯åå æåï¼");
|
| | |
| | | txtHReasonList.Text = "";
|
| | | return false;
|
| | | }
|
| | | catch(Exception e1)
|
| | | catch (Exception e1)
|
| | | {
|
| | | MessageBox.Show(e1.Message);
|
| | | return false;
|
| | |
| | | {
|
| | | txtHReasonList.Text = "";
|
| | | txtHReasonList.Text = oGy_BadReasonList.txtHBadReason.Text;
|
| | | txtHCheckerResult.Text = "";
|
| | | txtHCheckerResult.Text = oGy_BadReasonList.txtHBadReason.Text;
|
| | | oGy_BadReasonList = null;
|
| | | if (SaveBill("SaveDown"))
|
| | | {
|
| | |
| | | MessageBox.Show("ä¿åä¸è¯åå 失败ï¼" + DBUtility.ClsPub.sExeReturnInfo);
|
| | | }
|
| | | }
|
| | | |
| | |
|
| | | }
|
| | |
|
| | | private void cmdHGroupID_Click(object sender, EventArgs e)
|
| | | {
|
| | | SCM.ClsIF_Group_View oGroup= new SCM.ClsIF_Group_View();
|
| | | SCM.ClsIF_Group_View oGroup = new SCM.ClsIF_Group_View();
|
| | | string sWhere = "";
|
| | | if (oGroup.RefreshView(sWhere))
|
| | | {
|
| | |
| | | this.label12 = new System.Windows.Forms.Label(); |
| | | this.button4 = new System.Windows.Forms.Button(); |
| | | this.timer3 = new System.Windows.Forms.Timer(this.components); |
| | | this.txtHCheckerResult = new System.Windows.Forms.TextBox(); |
| | | this.label33 = new System.Windows.Forms.Label(); |
| | | this.Tool.SuspendLayout(); |
| | | ((System.ComponentModel.ISupportInitialize)(this.grdPrint)).BeginInit(); |
| | | ((System.ComponentModel.ISupportInitialize)(this.grdSum)).BeginInit(); |
| | |
| | | ((System.ComponentModel.ISupportInitialize)(this.grdEmp)).BeginInit(); |
| | | this.groupBox4.SuspendLayout(); |
| | | this.panel1.SuspendLayout(); |
| | | ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit(); |
| | | this.splitContainer1.Panel1.SuspendLayout(); |
| | | this.splitContainer1.Panel2.SuspendLayout(); |
| | | this.splitContainer1.SuspendLayout(); |
| | |
| | | // tabPage4 |
| | | // |
| | | this.tabPage4.BackColor = System.Drawing.Color.Lavender; |
| | | this.tabPage4.Controls.Add(this.label33); |
| | | this.tabPage4.Controls.Add(this.txtHCheckerResult); |
| | | this.tabPage4.Controls.Add(this.label15); |
| | | this.tabPage4.Controls.Add(this.cmbHOrgID); |
| | | this.tabPage4.Controls.Add(this.label3); |
| | |
| | | this.timer3.Interval = 300; |
| | | this.timer3.Tick += new System.EventHandler(this.timer3_Tick); |
| | | // |
| | | // txtHCheckerResult |
| | | // |
| | | this.txtHCheckerResult.Font = new System.Drawing.Font("å®ä½", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); |
| | | this.txtHCheckerResult.ImeMode = System.Windows.Forms.ImeMode.NoControl; |
| | | this.txtHCheckerResult.Location = new System.Drawing.Point(795, 96); |
| | | this.txtHCheckerResult.Name = "txtHCheckerResult"; |
| | | this.txtHCheckerResult.ReadOnly = true; |
| | | this.txtHCheckerResult.Size = new System.Drawing.Size(166, 30); |
| | | this.txtHCheckerResult.TabIndex = 151; |
| | | // |
| | | // label33 |
| | | // |
| | | this.label33.AutoSize = true; |
| | | this.label33.Font = new System.Drawing.Font("å®ä½", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); |
| | | this.label33.ForeColor = System.Drawing.Color.Black; |
| | | this.label33.Location = new System.Drawing.Point(714, 102); |
| | | this.label33.Name = "label33"; |
| | | this.label33.Size = new System.Drawing.Size(72, 16); |
| | | this.label33.TabIndex = 152; |
| | | this.label33.Text = "ä¸è¯æ¸
å"; |
| | | // |
| | | // Sc_ICMOReportToBarCode |
| | | // |
| | | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); |
| | |
| | | this.panel1.ResumeLayout(false); |
| | | this.splitContainer1.Panel1.ResumeLayout(false); |
| | | this.splitContainer1.Panel2.ResumeLayout(false); |
| | | ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).EndInit(); |
| | | this.splitContainer1.ResumeLayout(false); |
| | | this.tabControl1.ResumeLayout(false); |
| | | this.tabPage1.ResumeLayout(false); |
| | |
| | | private System.Windows.Forms.TextBox txtHEmpID3; |
| | | private System.Windows.Forms.Button cmdZero; |
| | | private System.Windows.Forms.Button cmdSaveAndDown2; |
| | | private System.Windows.Forms.Label label33; |
| | | private System.Windows.Forms.TextBox txtHCheckerResult; |
| | | } |
| | | } |
| | |
| | | <value>2.0</value> |
| | | </resheader> |
| | | <resheader name="reader"> |
| | | <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> |
| | | <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> |
| | | </resheader> |
| | | <resheader name="writer"> |
| | | <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> |
| | | <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> |
| | | </resheader> |
| | | <metadata name="Tool.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> |
| | | <metadata name="Tool.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> |
| | | <value>17, 17</value> |
| | | </metadata> |
| | | <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /> |
| | | <assembly alias="System.Drawing" name="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /> |
| | | <data name="Tool.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> |
| | | <value> |
| | | /9j/4AAQSkZJRgABAQEASABIAAD/4QSARXhpZgAATU0AKgAAAAgABwESAAMAAAABAAEAAAEaAAUAAAAB |
| | |
| | | AAAASUVORK5CYII= |
| | | </value> |
| | | </data> |
| | | <metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> |
| | | <metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> |
| | | <value>102, 16</value> |
| | | </metadata> |
| | | <metadata name="timer2.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> |
| | | <metadata name="timer2.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> |
| | | <value>191, 16</value> |
| | | </metadata> |
| | | <data name="cmdHEmp3.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> |
| | |
| | | FIYcEAA7 |
| | | </value> |
| | | </data> |
| | | <metadata name="timer3.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> |
| | | <metadata name="timer3.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> |
| | | <value>292, 16</value> |
| | | </metadata> |
| | | <metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> |
| | | <metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> |
| | | <value>39</value> |
| | | </metadata> |
| | | </root> |
| | |
| | | public const Int16 HJiaYeLXCol = 71; |
| | | public const Int16 HJiaYeLCol = 72; |
| | | public const Int16 POOrderBillNoCol = 73; |
| | | public const Int16 HMaker = 74; |
| | | |
| | | public Int16 HSelectCol = 0; |
| | | public Int16 HSno2Col = 1; |
| | |
| | | { |
| | | grdMain.RowCount = 0; |
| | | grdSub.RowCount = 0; |
| | | grdMain.ColumnCount = 75; //æ»åæ° |
| | | grdMain.ColumnCount = 74; //æ»åæ° |
| | | ClsPub1.initGridFst(grdMain, this.Name); |
| | | grdMain.Columns[HSnoCol].HeaderText = "åºå·"; |
| | | grdMain.Columns[HMainIDCol].HeaderText = "æºå主ID"; |
| | |
| | | grdMain.Columns[HJiaYeLXCol].HeaderText = "å¶å·æ¶²ç±»å"; |
| | | grdMain.Columns[HJiaYeLCol].HeaderText = "å æ¶²é"; |
| | | grdMain.Columns[POOrderBillNoCol].HeaderText = "éè´è®¢åå·"; |
| | | grdMain.Columns[HMaker].HeaderText = "å¶å人"; |
| | | //// |
| | | //æ ¼å¼å éèå |
| | | grdMain.Columns[HTagCol].Visible = false; |
| | |
| | | grdMain.Rows[i].Cells[HRemarkCol].Value = oTable.Rows[0]["夿³¨"].ToString(); |
| | | grdMain.Rows[i].Cells[HMTONoCol].Value = oTable.Rows[0]["计åè·è¸ªå·"].ToString(); |
| | | grdMain.Rows[i].Cells[HMinQtyCol].Value = oTable.Rows[0]["æå°å
è£
æ°"].ToString(); |
| | | grdMain.Rows[i].Cells[HMaker].Value = ClsPub.CurUserName; |
| | | |
| | | if (CampanyName == "å£é¾") //ç³»ç»åæ° å®¢æ·å®å¶ååç§° |
| | | { |
| | |
| | | <value>2.0</value> |
| | | </resheader> |
| | | <resheader name="reader"> |
| | | <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> |
| | | <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> |
| | | </resheader> |
| | | <resheader name="writer"> |
| | | <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> |
| | | <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> |
| | | </resheader> |
| | | </root> |