ch
2022-05-30 f9ef44a67fbf73f073efe65600bc25e204fde04f
PlanM/¼Æ»®¹ÜÀí/Gy_RoutingBill.cs
@@ -91,6 +91,7 @@
        public const Int16 HTechnologyParameterCol = 59;
        public const Int16 HPicNumCol = 60;
        public const Int16 HProcCheckNoteCol = 61;
        public const Int16 HProcWorkNumCol = 62;
        //
        public  string ModName = "3301";
@@ -843,6 +844,12 @@
            this.txtHAddSourceRate.Text = BillOld.omodel.HAddSourceRate.ToString();
            this.txtHDelSourceRate.Text = BillOld.omodel.HDelSourceRate.ToString();
            this.textHPicNumVer.Text = BillOld.omodel.HPicNumVer.ToString();
            this.textHPicNumAssemble.Text = BillOld.omodel.HPicNumAssemble.ToString();
            this.textHMaterTexture.Text = BillOld.omodel.HMaterTexture.ToString();
            this.textHProductNum.Text = BillOld.omodel.HProductNum.ToString();
            this.textHVerNum.Text = BillOld.omodel.HVerNum.ToString();
            //加载表体
            int i = 0;
            foreach (Model.ClsGy_RoutingBillSub oSub in BillOld.DetailColl)
@@ -953,6 +960,7 @@
                grdMain.Rows[i].Cells[HWorkQty_SCol].Value = oSub.HWorkQty_S.ToString();
                grdMain.Rows[i].Cells[HSubStdEmpQty_SCol].Value = oSub.HSubStdEmpQty_S.ToString();
                grdMain.Rows[i].Cells[HMouldNoCol].Value = oSub.HMouldNo;
                grdMain.Rows[i].Cells[HProcWorkNumCol].Value = oSub.HProcWorkNum;
                grdMain.Rows[i].Cells[HChangeMouldCol].Value = oSub.HChangeMould.ToString();
                grdMain.Rows[i].Cells[HPackStdCol].Value = oSub.HPackStd;
                grdMain.Rows[i].Cells[HPackCol].Value = oSub.HPack;
@@ -1034,6 +1042,7 @@
            if (BillStatus ==DBUtility.ClsPub.Enum_BillStatus.BillStatus_Modify)
                BillNew.omodel.HInterID = BillOld.omodel.HInterID;
            //主类赋值
            BillNew.omodel.HPRDORGID = DBUtility.ClsPub.HOrgID;  //组织
            BillNew.omodel.HYear = 2011;
            BillNew.omodel.HPeriod = 1;
            BillNew.omodel.HBillNo = this.txtHBillNo.Text.Trim();  //在赋值类前就处理好字符串和数字
@@ -1057,7 +1066,13 @@
            BillNew.omodel.HStdSourceQty = ClsPub.isSingle(this.txtHStdSourceQty.Text);
            BillNew.omodel.HAddSourceRate = ClsPub.isSingle(this.txtHAddSourceRate.Text);
            BillNew.omodel.HDelSourceRate = ClsPub.isSingle(this.txtHDelSourceRate.Text);
            BillNew.omodel.HPicNumVer = ClsPub.isStrNull(this.textHPicNumVer.Text);
            BillNew.omodel.HPicNumAssemble = ClsPub.isStrNull(this.textHPicNumAssemble.Text);
            BillNew.omodel.HMaterTexture = ClsPub.isStrNull(this.textHMaterTexture.Text);
            BillNew.omodel.HProductNum = ClsPub.isStrNull(this.textHProductNum.Text);
            BillNew.omodel.HVerNum = ClsPub.isStrNull(this.textHVerNum.Text);
            //明细类赋值
            BillNew.DetailColl=new List<Model.ClsGy_RoutingBillSub>();
            for (i = 0; i <= grdMain.RowCount - 1; i++)
@@ -1111,6 +1126,7 @@
                    oSub.HProcID_S = DBUtility.ClsPub.isLong(grdMain.Rows[i].Cells[HProcID_SCol].Value);
                    oSub.HCenterID_S = DBUtility.ClsPub.isLong(grdMain.Rows[i].Cells[HCenterID_SCol].Value);
                    oSub.HMouldNo = DBUtility.ClsPub.isStrNull(grdMain.Rows[i].Cells[HMouldNoCol].Value);
                    oSub.HProcWorkNum = DBUtility.ClsPub.isStrNull(grdMain.Rows[i].Cells[HProcWorkNumCol].Value);
                    oSub.HPackStd = DBUtility.ClsPub.isStrNull(grdMain.Rows[i].Cells[HPackStdCol].Value);
                    oSub.HPack = DBUtility.ClsPub.isStrNull(grdMain.Rows[i].Cells[HPackCol].Value);
                    oSub.HPutArea = DBUtility.ClsPub.isStrNull(grdMain.Rows[i].Cells[HPutAreaCol].Value);
@@ -1153,6 +1169,8 @@
                    oSub.HStdFlag = DBUtility.ClsPub.isBool(grdMain.Rows[i].Cells[HStdFlagCol].Value);
                    oSub.HAutoTrunFlag = DBUtility.ClsPub.isBool(grdMain.Rows[i].Cells[HAutoTrunFlagCol].Value);
                    oSub.HProcType = DBUtility.ClsPub.isStrNull(grdMain.Rows[i].Cells[HProcTypeCol].Value);
                    oSub.HProcWorkNum = DBUtility.ClsPub.isStrNull(grdMain.Rows[i].Cells[HProcWorkNumCol].Value);
                    if (DBUtility.ClsPub.isSingle(grdMain.Rows[i].Cells[HPassRateCol].Value) > 0)
                    {
                        oSub.HPassRate = DBUtility.ClsPub.isSingle(grdMain.Rows[i].Cells[HPassRateCol].Value);
@@ -1225,7 +1243,7 @@
        private void initGrid()
        {
            //
            grdMain.ColumnCount = 62;                       //总列数
            grdMain.ColumnCount = 63;                       //总列数
            DBUtility.Xt_BaseBillFun.initGridFst(grdMain, this.Name);
            //
            grdMain.RowsDefaultCellStyle.WrapMode = DataGridViewTriState.True;
@@ -1301,6 +1319,7 @@
            grdMain.Columns[HTechnologyParameterCol].HeaderText = "工艺参数";
            grdMain.Columns[HPicNumCol].HeaderText = "图纸编号";
            grdMain.Columns[HProcCheckNoteCol].HeaderText = "本工序确认记录";
            grdMain.Columns[HProcWorkNumCol].HeaderText = "程序号";
            //格式化 
            grdMain.Columns[HTagCol].Visible = false;                           
            //隐藏列
@@ -1344,6 +1363,7 @@
                            "," + HWorkQty_SCol.ToString() +
                            "," + HSubStdEmpQty_SCol.ToString() +
                            "," + HMouldNoCol.ToString() +
                            "," + HProcWorkNumCol.ToString() +
                            "," + HChangeMouldCol.ToString() +
                            "," + HPackStdCol.ToString() +
                            "," + HPackCol.ToString() +
@@ -1558,6 +1578,8 @@
                                    grdMain.Rows[sRow].Cells[HProcNameCol].Value = oProc.oModel.HName;
                                    grdMain.Rows[sRow].Cells[HTimeUnitCol].Value = "小时";
                                    grdMain.Rows[sRow].Cells[HUnitTimeCol].Value = "1";
                                    grdMain.Rows[sRow].Cells[HPassRateCol].Value = "100";
                                    grdMain.Rows[sRow].Cells[HWorkQtyCol].Value = "1";
                                    if (oProc.GetInfoByID(oProc.oModel.HItemID))
                                    {
                                        grdMain.Rows[sRow].Cells[HProcCheckNoteCol].Value = oProc.omodel.HProcCheckNote.ToString();