From 612f93dba4a45edea9d0300a1977e66fe7ce355f Mon Sep 17 00:00:00 2001 From: yxj <1qaz@123> Date: 星期五, 26 八月 2022 16:41:15 +0800 Subject: [PATCH] WEBAPI采购入库上传方法增加递入组织、制单人 --- WorkM/流转卡管理/MES_StationEntrustInBill.cs | 50 +++++++++++++++++++++++++++++++------------------- 1 files changed, 31 insertions(+), 19 deletions(-) diff --git "a/WorkM/\346\265\201\350\275\254\345\215\241\347\256\241\347\220\206/MES_StationEntrustInBill.cs" "b/WorkM/\346\265\201\350\275\254\345\215\241\347\256\241\347\220\206/MES_StationEntrustInBill.cs" index 16a10b8..dbc2232 100644 --- "a/WorkM/\346\265\201\350\275\254\345\215\241\347\256\241\347\220\206/MES_StationEntrustInBill.cs" +++ "b/WorkM/\346\265\201\350\275\254\345\215\241\347\256\241\347\220\206/MES_StationEntrustInBill.cs" @@ -525,8 +525,18 @@ if (BillStatus == DBUtility.ClsPub.Enum_BillStatus.BillStatus_Modify) BillNew.omodel.HInterID = BillOld.omodel.HInterID; //涓荤被璧嬪�� - BillNew.omodel.HYear = 2011; - BillNew.omodel.HPeriod = 1; + //鍒ゆ柇浼氳鏈熸槸鍚﹀悎鐞� + string s = ""; + int sYear = 0; + int sPeriod = 0; + if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(DBUtility.ClsPub.isDate(this.txtHStationInTime.Text), ref sYear, ref sPeriod, ref s) == false) + { + MessageBox.Show(s, "鎻愮ず"); + return false; + } + // + BillNew.omodel.HYear = sYear; + BillNew.omodel.HPeriod = sPeriod; BillNew.omodel.HBillNo = this.txtHBillNo.Text.Trim(); BillNew.omodel.HInnerBillNo = this.txtHInnerBillNo.Text.Trim(); BillNew.omodel.HICMOBillNo = this.txtHICMOBillNo.Text.Trim(); @@ -1182,6 +1192,7 @@ if (e.KeyCode == Keys.Enter) { cmdOK.Select(); + txtHWWWorkOrderBillNo.Focus(); } } @@ -1332,23 +1343,23 @@ MessageBox.Show("娌℃湁褰曞叆娴佽浆鍗″彿鎴栬�呮祦姘村彿"); return; } - //鏍规嵁宸ュ彿鑾峰彇濮斿宸ュ崟 鍙婂唴鐮侊紝瀛愬唴鐮� - SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); - DataSet ds; - ds = oCn.RunProcReturn("exec h_p_WW_GetWWWorkBillInfoByNo '" + txtHWWWorkOrderBillNo.Text + "'," + lngBillKey.ToString() + "," + lngBillSubKey.ToString(), "h_p_WW_GetWWWorkBillInfoByNo"); - if (ds == null) - { - MessageBox.Show("娌℃湁鎵惧埌瀵瑰簲鐨勫澶栧伐鍗曪紒"); - return; - } - if (ds.Tables[0].Rows.Count > 0) - { - txtHWWWorkOrderBillNo.Text = DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HBillNo"]); - lngBillKey_WW = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HInterID"]); - lngBillSubKey_WW = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HEntryID"]); - txtHWWWorkOrderBillNo.Enabled = false; - } - + ////鏍规嵁宸ュ彿鑾峰彇濮斿宸ュ崟 鍙婂唴鐮侊紝瀛愬唴鐮� + //SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); + //DataSet ds; + //ds = oCn.RunProcReturn("exec h_p_WW_GetWWWorkBillInfoByNo '" + txtHWWWorkOrderBillNo.Text + "'," + lngBillKey.ToString() + "," + lngBillSubKey.ToString(), "h_p_WW_GetWWWorkBillInfoByNo"); + //if (ds == null) + //{ + // MessageBox.Show("娌℃湁鎵惧埌瀵瑰簲鐨勫澶栧伐鍗曪紒"); + // return; + //} + //if (ds.Tables[0].Rows.Count > 0) + //{ + // txtHWWWorkOrderBillNo.Text = DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HBillNo"]); + // lngBillKey_WW = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HInterID"]); + // lngBillSubKey_WW = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HEntryID"]); + // txtHWWWorkOrderBillNo.Enabled = false; + //} + txtHRemark.Focus(); } } @@ -1472,5 +1483,6 @@ { this.Sub_AddBill(); } + } } \ No newline at end of file -- Gitblit v1.9.1