yangle
2024-04-12 9ca639ab65944c2c4970ae20308a4d0cecd85d74
Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-API
1个文件已修改
52 ■■■■ 已修改文件
WarM/条码打印/Gy_BarCodeBill.cs 52 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WarM/ÌõÂë´òÓ¡/Gy_BarCodeBill.cs
@@ -438,6 +438,16 @@
                PrintQtyCtl = oSystemParameter.omodel.BarCode_PrintQtyCtl;
                UpdatePrintQtyCtl = oSystemParameter.omodel.BarCode_UpdatePrintQtyCtl;
            }
            //系统参数,有源单生成条码,生成条码数量可否超源单数量控制(N为不可超源单数量)
            if (SourceQtyCtl == "N")
            {
                //系统参数为不可超源单数量时,再次判断用户权限是否可超源单数量
                //判断权限
                if (ClsPub.Security_Log(ModRightNameSourceQty, 3, false, ClsPub.CurUserName))
                {
                    SourceQtyCtl = "Y";
                }
            }
            cmbHWorksNumber.Items.Clear();
            if (CampanyName == "飞龙") //系统参数  å®¢æˆ·å®šåˆ¶åŒ–名称
@@ -591,16 +601,6 @@
        //单据完整性判断          æœªå®Œæˆ
        private bool Sub_AllowSave()
        {
            //系统参数,有源单生成条码,生成条码数量可否超源单数量控制(N为不可超源单数量)
            if (SourceQtyCtl=="N")
            {
                //系统参数为不可超源单数量时,再次判断用户权限是否可超源单数量
                //判断权限
                if (ClsPub.Security_Log(ModRightNameSourceQty, 3, false, ClsPub.CurUserName))
                {
                    SourceQtyCtl = "Y";
                }
            }
            //明细表是否为零行
            bool b = false;
            for (int i = 0; i < grdMain.RowCount; i++)
@@ -2244,7 +2244,17 @@
            if (cmbSourceBillType.Text.Trim() == "生产订单")
            {
                string sWhere = " and HOrgID =" + HOrgID.ToString();
                string sWhere = "";
                //系统参数,生成条码数量可否超源单数量控制(N为不可超源单数量)
                if (SourceQtyCtl == "N")
                {
                    sWhere = " and HOrgID =" + HOrgID.ToString() + " and ä»»åŠ¡æ•°é‡>0";
                }
                else
                {
                    sWhere = " and HOrgID =" + HOrgID.ToString();
                }
                DAL.Cls_S_IFCLD_ICMOList oIFCLD_ICMOList = new DAL.Cls_S_IFCLD_ICMOList();
                if (oIFCLD_ICMOList.Refresh(sWhere))  //选择原单
                {
@@ -2398,7 +2408,8 @@
                    grdMain.Rows.Add();
                    grdMain.Rows[i].Cells[HTagCol].Value = "*";
                    //得到信息
                    Ds = oCn.RunProcReturn("select * from h_v_IFCLD_ICMOList where hmainid=" + oSelectRow.BillMainID + " and hsubid=" + oSelectRow.BillSubID, "h_v_IFCLD_ICMOList");
                    Ds = oCn.RunProcReturn("exec h_p_Gy_BarCodeBill_ICMOBillList " + oSelectRow.BillMainID.ToString() + "," + oSelectRow.BillSubID.ToString() + ",'" + SourceQtyCtl + "'", "h_p_Gy_BarCodeBill_ICMOBillList");
                    //Ds = oCn.RunProcReturn("select * from h_v_IFCLD_ICMOList where hmainid=" + oSelectRow.BillMainID + " and hsubid=" + oSelectRow.BillSubID, "h_v_IFCLD_ICMOList");
                    //写入信息
                    Sub_WriteInForm(Ds.Tables[0], i);
                }
@@ -3481,6 +3492,22 @@
                if (cmbSourceBillType.Text.Trim() == "生产订单")
                {
                    DAL.Cls_S_IFCLD_ICMOList oIFCLD_ICMOList = new DAL.Cls_S_IFCLD_ICMOList();
                    //系统参数,生成条码数量可否超源单数量控制(N为不可超源单数量)
                    if (SourceQtyCtl == "N")
                    {
                        if (oIFCLD_ICMOList.RefreshBySourceBillNo(" Where å•据号 like '%" + txtHSourceBillNo.Text + "' and HOrgID =" + sHOrgID.ToString() + " and ä»»åŠ¡æ•°é‡>0"))  //选择原单
                        {
                            FillSelectData(oIFCLD_ICMOList.oBillSelectColl);
                            txtHSourceBillNo.Text = "";
                        }
                        else
                        {
                            MessageBox.Show("未查询到任务数据,请确认所选组织、源单类型与源单单号是否正确!");
                            return;
                        }
                    }
                    else
                    {
                    if (oIFCLD_ICMOList.RefreshBySourceBillNo(" Where å•据号 like '%" + txtHSourceBillNo.Text + "' and HOrgID =" + sHOrgID.ToString()))  //选择原单
                    {
                        FillSelectData(oIFCLD_ICMOList.oBillSelectColl);
@@ -3492,6 +3519,7 @@
                        return;
                    }
                }
                }
                else if (cmbSourceBillType.Text.Trim() == "生产汇报单")
                {
                    DAL.Cls_S_IF_ICMOReportBillList oIF_ICMOReportBillList = new DAL.Cls_S_IF_ICMOReportBillList();