jingh
2021-10-05 11be9ad27a077230e30446e00442010534dc744b
增加不良清单列表
3个文件已修改
3个文件已添加
5600 ■■■■■ 已修改文件
DAL/仓库管理/ClsKf_ProductInBill.cs 116 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
LMES/ClsShowMod.cs 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WorkM/WorkM.csproj 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WorkM/流转卡管理/MES_StationOutBillList_Bad.cs 693 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WorkM/流转卡管理/MES_StationOutBillList_Bad.designer.cs 673 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WorkM/流转卡管理/MES_StationOutBillList_Bad.resx 4101 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
DAL/²Ö¿â¹ÜÀí/ClsKf_ProductInBill.cs
@@ -440,7 +440,123 @@
        }
        public bool AddBill_StationOut_Bad(string sHSourceType, Pub_Class.ClsXt_SystemParameterMain oSystemParameterMain,ref string sErrMsg)
        {
            //上传前必填项判断
            try
            {
                DataSet Ds;
                if (oSystemParameterMain.WMS_CampanyName == "杭州智见" || oSystemParameterMain.WMS_CampanyName == "杭州斯莫尔") //系统参数  å®¢æˆ·å®šåˆ¶åŒ–名称     ç©ºç™½ä¸ºé€šç”¨
                {
                }
                else
                {
                    oCn.BeginTran();
                }
                //生成出入库单据
                //插入子表
                oCn.RunProc("EXEC h_p_Kf_ProductInBillSub_Insert_StationOutBad " + omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "','" + sHSourceType + "'");
                //插入主表
                oCn.RunProc("Insert Into Kf_ICStockBillMain   " +
                "(HBillType,HBillSubType,HInterID,HBillNo,HDate,HMainSourceBillType" +
                ",HYear,HPeriod,HRemark,HMaker,HMakeDate" +
                ",HSupID,HWHID,HSCWHID,HEmpID,HManagerID,HSecManagerID" +
                ",HKeeperID,HDeptID,HExplanation,HInnerBillNo,HRedBlueFlag" +
                ") " +
                " values('1202','1202'," + omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "',convert(varchar(10),getdate(),120),'" + omodel.HMainSourceBillType + "'" +
                ", " + omodel.HYear.ToString() + "," + omodel.HPeriod.ToString() + ",'" + omodel.HRemark + "','" + omodel.HMaker + "',convert(varchar(10),getdate(),120)" +
                ", " + omodel.HSupID.ToString() + "," + omodel.HWHID.ToString() + "," + omodel.HSCWHID.ToString() + "," + omodel.HEmpID.ToString() + "," + omodel.HManagerID.ToString() + "," + omodel.HSecManagerID.ToString() +
                ", " + omodel.HKeeperID.ToString() + "," + omodel.HDeptID.ToString() + ",'" + omodel.HExplanation + "','" + omodel.HInnerBillNo + "'," + DBUtility.ClsPub.BoolToString(omodel.HRedBlueFlag) +
                ") ");
                //新增K3子表、主表
                oCn.RunProc("exec h_p_IFK3_ToERP_ProductInBill_Insert_New " + omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "'," + omodel.HBillerID.ToString() + ",'" + sHSourceType + "'");
                //更新关联数量
                if (sHSourceType == "3710")         //生产任务单
                {
                    oCn.RunProc("exec h_p_Sc_UpDateRelation_ICMOToProductIn_Add " + omodel.HInterID.ToString());
                    //回填K3关联数量
                    oCn.RunProc("exec h_p_IFK3_ToERP_ProductInBill_UpdateBillRelateData_ICMO_New " + omodel.HInterID.ToString());
                }
                else    //无源单
                {
                    //回填K3关联数量
                    oCn.RunProc("exec h_p_IFK3_ToERP_ProductInBill_UpdateBillRelateData_New " + omodel.HInterID.ToString());
                }
                //判断库存更新控制状态(0为审核改变库存,1为保存改变库存)
                DataSet DS = oCn.RunProcReturn("exec h_p_IFK3_SaveUpdateStock ", "h_p_IFK3_SaveUpdateStock");
                if (DS == null || DS.Tables[1].Rows.Count == 0)
                {
                    sErrMsg = "判断库存更新控制状态,未知错误!";
                    if (oSystemParameterMain.WMS_CampanyName == "杭州智见" || oSystemParameterMain.WMS_CampanyName == "杭州斯莫尔") //系统参数  å®¢æˆ·å®šåˆ¶åŒ–名称     ç©ºç™½ä¸ºé€šç”¨
                    {
                    }
                    else
                    {
                        oCn.RollBack();
                    }
                    return false;
                }
                else
                {
                    if (DBUtility.ClsPub.isLong(DS.Tables[1].Rows[0][0]) == 1)
                    {
                        //更新K3库存
                        oCn.RunProc("exec h_p_IFK3_ToERP_ProductInBill_UpdateStock_New " + omodel.HInterID.ToString());
                        oCn.RunProc("exec h_p_IFK3_ToERP_ProductInBill_UpdateOrderStock_New " + omodel.HInterID.ToString());
                        //审核单据
                        if (oSystemParameterMain.Kf_ProductInBill_AutoCheck == "Y") //系统参数  è‡ªåŠ¨å®¡æ ¸
                        {
                            //审核单据
                            oCn.RunProc("Update Kf_ICStockBillMain Set HChecker='" + omodel.HMaker + "',HCheckDate=convert(varchar(10),getdate(),120) where HInterID= " + omodel.HInterID.ToString());
                            //审核K3单据
                            oCn.RunProc("exec h_p_IFK3_ToERP_ProductInBill_Check_New " + omodel.HInterID.ToString() + "," + omodel.HBillerID.ToString());
                        }
                    }
                    else
                    {
                        //审核单据
                        if (oSystemParameterMain.Kf_ProductInBill_AutoCheck == "Y") //系统参数  è‡ªåŠ¨å®¡æ ¸
                        {
                            //审核单据
                            oCn.RunProc("Update Kf_ICStockBillMain Set HChecker='" + omodel.HMaker + "',HCheckDate=convert(varchar(10),getdate(),120) where HInterID= " + omodel.HInterID.ToString());
                            //审核K3单据
                            oCn.RunProc("exec h_p_IFK3_ToERP_ProductInBill_Check_New " + omodel.HInterID.ToString() + "," + omodel.HBillerID.ToString());
                            //更新K3库存
                            oCn.RunProc("exec h_p_IFK3_ToERP_ProductInBill_UpdateStock_New " + omodel.HInterID.ToString());
                            oCn.RunProc("exec h_p_IFK3_ToERP_ProductInBill_UpdateOrderStock_New " + omodel.HInterID.ToString());
                        }
                    }
                }
                sErrMsg = "新增单据成功!";
                if (oSystemParameterMain.WMS_CampanyName == "杭州智见" || oSystemParameterMain.WMS_CampanyName == "杭州斯莫尔") //系统参数  å®¢æˆ·å®šåˆ¶åŒ–名称     ç©ºç™½ä¸ºé€šç”¨
                {
                }
                else
                {
                    oCn.Commit();
                }
                return true;
            }
            catch (Exception e)
            {
                sErrMsg = "生成产品入库单失败!" + e.Message;
                if (oSystemParameterMain.WMS_CampanyName == "杭州智见" || oSystemParameterMain.WMS_CampanyName == "杭州斯莫尔") //系统参数  å®¢æˆ·å®šåˆ¶åŒ–名称     ç©ºç™½ä¸ºé€šç”¨
                {
                }
                else
                {
                    oCn.RollBack();
                }
                return false;
            }
        }
LMES/ClsShowMod.cs
@@ -5189,6 +5189,13 @@
            {
                switch (gnsy.ToLower())
                {
                    case "mes_stationoutbilllist_bad":
                        MES_StationOutBillList_Bad oMES_StationOutBillList_Bad = new MES_StationOutBillList_Bad();
                        oMES_StationOutBillList_Bad.MdiParent = oMain;
                        oMES_StationOutBillList_Bad.ModCaption = gnmc;
                        oMES_StationOutBillList_Bad.Show();
                        oMainForm.AddTabPage(oMES_StationOutBillList_Bad);
                        break;
                    case "sc_prodwiptotalreport":
                        Sc_ProdWIPTotalReport oSc_ProdWIPTotalReport = new Sc_ProdWIPTotalReport();
                        oSc_ProdWIPTotalReport.MdiParent = oMain;
WorkM/WorkM.csproj
@@ -359,6 +359,12 @@
    <Compile Include="流转卡管理\MES_StationOutBill.designer.cs">
      <DependentUpon>MES_StationOutBill.cs</DependentUpon>
    </Compile>
    <Compile Include="流转卡管理\MES_StationOutBillList_Bad.cs">
      <SubType>Form</SubType>
    </Compile>
    <Compile Include="流转卡管理\MES_StationOutBillList_Bad.designer.cs">
      <DependentUpon>MES_StationOutBillList_Bad.cs</DependentUpon>
    </Compile>
    <Compile Include="流转卡管理\MES_StationOutBillList.cs">
      <SubType>Form</SubType>
    </Compile>
@@ -987,6 +993,10 @@
      <DependentUpon>MES_StationOutBill.cs</DependentUpon>
      <SubType>Designer</SubType>
    </EmbeddedResource>
    <EmbeddedResource Include="流转卡管理\MES_StationOutBillList_Bad.resx">
      <DependentUpon>MES_StationOutBillList_Bad.cs</DependentUpon>
      <SubType>Designer</SubType>
    </EmbeddedResource>
    <EmbeddedResource Include="流转卡管理\MES_StationOutBillList.resx">
      <DependentUpon>MES_StationOutBillList.cs</DependentUpon>
      <SubType>Designer</SubType>
WorkM/Á÷ת¿¨¹ÜÀí/MES_StationOutBillList_Bad.cs
New file
@@ -0,0 +1,693 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using gregn6Lib;
using SQLHelper;
using DBUtility;
using System.IO;
using System.Reflection;
namespace WorkM
{
    public partial class MES_StationOutBillList_Bad : Form
    {
        public MES_StationOutBillList_Bad()
        {
            InitializeComponent();
        }
        public DBUtility.frmBillQueryCondition_New frmCondition;
        public string ViewName = "h_v_MES_StationOutBillList_Bad";
        public string ModCaption = "工序出站汇报不良品列表";
        public const string ModName = "3791";
        public const string ModRightName = "MES_StationOutBill";
        public const string ModRightNameEdit = ModRightName + "_Edit";
        public const string ModRightNameCheck = ModRightName + "_Check";
        public const string ModRightNameClose = ModRightName + "_Close";
        public const string ModRightNameDelete = ModRightName + "_Delete";
        DAL.ClsSc_StationOutBill oBill = new DAL.ClsSc_StationOutBill();
        public MES_StationOutBill oFrm;
        Pub_Class.ClsGridListSum oSumGrid = new Pub_Class.ClsGridListSum();
        public string sDlgWhere = "";  //外窗体递入
        //
        private void initGrid()
        {
            DBUtility.Xt_BaseBillFun.initGridList(grdMain,this.Name);
        }
        //
        private void Display()
        {
            ClsCN SubCn = new ClsCN();
            DataSet DSet;
            string sSql = "";
            string sWhere = "";
            if (frmCondition.SqlStr.Trim().Length == 0)
            {
                sSql = "Select top 5000 * from " + ViewName + " Where 1=1 " + sWhere + sDlgWhere + " order by hmainid desc ";
            }
            else
            {
                sSql = frmCondition.SqlStr + sWhere + sDlgWhere + " order by hmainid desc ";
            }
            //
            DSet = SubCn.RunProcReturn(sSql, ViewName, ref DBUtility.ClsPub.sExeReturnInfo);
            //生成首行标题
            if (DSet == null)
            {
                MessageBox.Show("没有返回任何结果,请在过滤框中点击【恢复】按钮,尝试再次查询!" + DBUtility.ClsPub.sExeReturnInfo);
                return;
            }
            //释放冻结
            DBUtility.Xt_BaseBillFun.CancelFrozenCol(grdMain);
            //
            grdMain.DataSource = DSet.Tables[0].DefaultView;
            //设置合计列
            string sTotalCol = "";
            sTotalCol = DBUtility.Gy_BaseFun.GetTotalCols(DSet);
            string[] sT;
            sT = sTotalCol.Split(Convert.ToChar(","));
            oSumGrid.BuildTotalCols(sT);
            //
            //冻结
            int FrCol = DBUtility.ClsPub.isInt(frmCondition.txtFrozenCol.Text);
            string s = frmCondition.cmbHComplete.Text;
            DBUtility.Xt_BaseBillFun.DisplayGrid(grdMain, this.Name, s, FrCol);
            //画线
            GraphLine();
            Total();
            //
        }
        //
        private void timer1_Tick(object sender, EventArgs e)
        {
            timer1.Enabled=false;
            initGrid();
            Display();
        }
        private void tc_Click(object sender, EventArgs e)
        {
            this.Close();
        }
        private void sx_Click(object sender, EventArgs e)
        {
            timer1.Enabled = true;
        }
        private void dj_Click(object sender, EventArgs e)
        {
            Sub_ShowBill();
        }
        //显示单据
        private void Sub_ShowBill()
        {
            Int64 lngBillKey = 0;
            if (grdMain.CurrentRow == null)
                return;
            lngBillKey =DBUtility.ClsPub.isLong(grdMain.Rows[grdMain.CurrentRow.Index].Cells[Fun_GetCol("hmainid")].Value);
            if (lngBillKey == 0)
                return;
            DAL.ClsSc_StationOutBill oBill = new DAL.ClsSc_StationOutBill();
            if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))
            {
                oFrm = new MES_StationOutBill();
                oFrm.BillStatus = DBUtility.ClsPub.Enum_BillStatus.BillStatus_View;
                oFrm.BillOld = oBill;
                oFrm.ShowDialog();
                if (oFrm.BillChange)
                {
                    if (MessageBox.Show("单据列表已经发生变化,是否刷新", "提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Question) == DialogResult.OK)
                    {
                        timer1.Enabled = true;
                    }
                }
            }
            else
            {
                MessageBox.Show("单据未找到", "提示");
            }
            oBill = null;
        }
        //
        private Int32 Fun_GetCol(string sCol)
        {
            return DBUtility.Xt_BaseBillFun.Fun_GetCol(sCol, grdMain);
        }
        //
        private void MES_StationOutBillList_Bad_Load(object sender, EventArgs e)
        {
            //
            frmCondition = new frmBillQueryCondition_New();
            this.Text = ModCaption;
            lblCaption.Text = ModCaption;
            oSumGrid.ogrdMain = grdMain;  //初始化 new
            oSumGrid.oGridsum = grdSum;
            initGrid();
        }
        private void grdMain_DblClick(object sender, EventArgs e)
        {
            Sub_ShowBill();
        }
        private void cx_Click(object sender, EventArgs e)
        {
            frmCondition = new frmBillQueryCondition_New();
            SetCondition(frmCondition, ViewName, this.Name);
            frmCondition.ShowDialog();
            if (frmCondition.Tag.ToString() == "OK")
            {
                Display();
            }
        }
        public void SetCondition(frmBillQueryCondition_New frmCondition, string ViewName, string Name)
        {
            frmCondition.Tag = "";
            frmCondition.ViewName = ViewName;
            frmCondition.ModName = Name;
        }
        private void xz_Click(object sender, EventArgs e)
        {
            //
            MES_StationOutBill oMES_StationOutBill = new MES_StationOutBill();
            oMES_StationOutBill.BillStatus = DBUtility.ClsPub.Enum_BillStatus.BillStatus_AddNew;
            oMES_StationOutBill.ModCaption = "工序出站汇报不良品清单";
            oMES_StationOutBill.ShowDialog();
        }
        private void sc_Click(object sender, EventArgs e)
        {
            Sub_DeleteBill();
        }
        //删除
        private void Sub_DeleteBill()
        {
            //编辑权限
            if (!DBUtility.ClsPub.Security_Log(ModRightNameDelete, 1, true, DBUtility.ClsPub.CurUserName))
            {
                return;
            }
            //
            Int64 lngBillKey = 0;
            if (grdMain.CurrentRow == null)
                return;
            lngBillKey = DBUtility.ClsPub.isLong(grdMain.Rows[grdMain.CurrentRow.Index].Cells[Fun_GetCol("hmainid")].Value);
            if (lngBillKey == 0)
                return;
            DAL.ClsSc_StationOutBill  oBill = new DAL.ClsSc_StationOutBill();
            if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))
            {
                if (MessageBox.Show("确定要删除当前单据?", "提示", MessageBoxButtons.OKCancel)==DialogResult.OK)
                {
                    if (oBill.omodel.HMaker != ClsPub.CurUserName && (ClsPub.CurUserName != "admin" && ClsPub.CurUserName != "Admin"))
                    {
                        MessageBox.Show("只能删除本人的单据!", "提示");
                        return;
                    }
                    string c = "";
                    SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
                    DataSet ds;
                    //判断生产订单是否已结案,要求计划手工反结案  åˆ¤æ–­æ˜¯å¦å­˜åœ¨ ç›¸åŒå•据号 çš„入库单 , ä¸‹é“工序是否进站
                    ds = oCn.RunProcReturn("exec h_p_MES_StationOutBill_DelCtrl  '" + oBill.omodel.HBillNo + "'", "h_p_MES_StationOutBill_DelCtrl");
                    if (ds == null)
                    {
                        MessageBox.Show("判断关联失败!");
                        return;
                    }
                    if (ds.Tables[0].Rows.Count > 0 && Pub_Class.ClsPub.isInt(ds.Tables[0].Rows[0][0]) == 2)
                    {
                        MessageBox.Show(Pub_Class.ClsPub.isStrNull(ds.Tables[0].Rows[0][1]));
                        return;
                    }
                    //if (oBill.DeleteCheck(oBill.omodel.HInterID,"出站单", ref c) == false)
                    //{
                    //    MessageBox.Show(c, "提示");
                    //    return;
                    //}
                    //if (oBill.omodel.HChecker != "")
                    //{
                    //    MessageBox.Show("单据已经审核,不能删除!", "提示");
                    //    return;
                    //}
                    //if (!oBill.DeleteBill(oBill.omodel.HInterID, ref DBUtility.ClsPub.sExeReturnInfo))
                    //写入删除日志
                    string WorkList = "删除出站单:" + oBill.omodel.HBillNo;
                    //BLL.ClsPub_BLL.System_Log_DropAdd(WorkList);
                    if (!oBill.DeleteBill(oBill.omodel.HInterID, oBill.omodel.HProcExchInterID, oBill.omodel.HProcExchEntryID, ref DBUtility.ClsPub.sExeReturnInfo))
                    {
                        MessageBox.Show(DBUtility.ClsPub.sExeReturnInfo, "提示");
                        return;
                    }
                    else
                    {
                        Display();
                    }
                }
            }
            else
            {
                MessageBox.Show("单据未找到", "提示");
            }
        }
        private void timer2_Tick(object sender, EventArgs e)
        {
            timer2.Enabled = false;
            frmCondition = new frmBillQueryCondition_New();
            SetCondition(frmCondition, ViewName, this.Name);
            frmCondition.ShowDialog();
            if (frmCondition.Tag.ToString() == "OK")
            {
                timer1.Enabled = true;
            }
        }
        private void bclk_Click(object sender, EventArgs e)
        {
            //保存列宽
            DBUtility.Xt_BaseBillFun.SaveGrid(grdMain, this.Name);
        }
        private void mrlk_Click(object sender, EventArgs e)
        {
            DBUtility.Xt_BaseBillFun.DefaultGridView(grdMain, this.Name);
        }
        //
        private void GraphLine()
        {
            int MainIDCol = Fun_GetCol("hmainid");
            int SubIDCol = Fun_GetCol("hsubid");
            string s = frmCondition.cmbHComplete.Text;
            long n=0;
            DBUtility.Xt_BaseBillFun.GraphLine(grdMain, MainIDCol, SubIDCol, s,ref n);
            //显示
            lbldj.Text = "查询出 " + n.ToString() + " å¼ å•据";
            lbljl.Text = "共有 " + grdMain.RowCount.ToString() + " æ¡è®°å½•";
        }
        //审核
        private void sh_Click(object sender, EventArgs e)
        {
            this.Sub_CheckBill();
        }
        //审核单据
        private void Sub_CheckBill()
        {
            //审核权限
            if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, true, DBUtility.ClsPub.CurUserName))
            {
                return;
            }
            //
            Int64 lngBillKey = 0;
            if (grdMain.CurrentRow == null)
                return;
            lngBillKey = DBUtility.ClsPub.isLong(grdMain.Rows[grdMain.CurrentRow.Index].Cells[Fun_GetCol("hmainid")].Value);
            if (lngBillKey == 0)
                return;
            DAL.ClsSc_StationOutBill oBill = new DAL.ClsSc_StationOutBill();
            //查看是否已审核,关闭,作废
            if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))
            {
                if (oBill.omodel.HChecker.Trim() != "")
                {
                    MessageBox.Show("单据已审核!不能再次审核", "提示");
                    return;
                }
            }
            else
            {
                MessageBox.Show("单据不存在!原因:" + DBUtility.ClsPub.sExeReturnInfo, "提示");
                return;
            }
            //审核
            if (oBill.CheckBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo) == true)
            {
                MessageBox.Show("审核成功!", "提示");
                return;
            }
            else
            {
                MessageBox.Show("审核失败!原因:" + DBUtility.ClsPub.sExeReturnInfo, "提示");
                return;
            }
        }
        //反审单据
        private void Sub_AbandonCheck()
        {
            //审核权限
            if (!DBUtility.ClsPub.Security_Log(ModRightNameCheck, 1, true,DBUtility.ClsPub.CurUserName))
            {
                return;
            }
            //
            Int64 lngBillKey = 0;
            if (grdMain.CurrentRow == null)
                return;
            lngBillKey = DBUtility.ClsPub.isLong(grdMain.Rows[grdMain.CurrentRow.Index].Cells[Fun_GetCol("hmainid")].Value);
            if (lngBillKey == 0)
                return;
            DAL.ClsSc_StationOutBill oBill = new DAL.ClsSc_StationOutBill();
            //查看是否已审核,关闭,作废
            if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))
            {
                if (oBill.omodel.HChecker.Trim() == "")
                {
                    MessageBox.Show("单据未审核!不需要反审核!", "提示");
                    return;
                }
            }
            else
            {
                MessageBox.Show("单据不存在!原因:" + DBUtility.ClsPub.sExeReturnInfo, "提示");
                return;
            }
            //反审核
            if (oBill.AbandonCheck(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo) == true)
            {
                MessageBox.Show("反审核成功!", "提示");
                return;
            }
            else
            {
                MessageBox.Show("反审核失败!原因:" + DBUtility.ClsPub.sExeReturnInfo, "提示");
                return;
            }
        }
        //反审核
        private void qsh_Click(object sender, EventArgs e)
        {
            Sub_AbandonCheck();
        }
        private void GraphicsGrid()
        {
            DBUtility.Xt_BaseBillFun.GraphicsGrid(grdMain);
        }
        #region  //打印设置
        GridppReport Report;
        //预览
        private void yl_Click(object sender, EventArgs e)
        {
            //选择打印模板
            BLL.Gy_OpenTmp oFrm = new BLL.Gy_OpenTmp();
            oFrm.sBillName = ModName;
            oFrm.sBillModel = ModCaption;
            oFrm.ShowDialog();
            if (oFrm.OKTag == Pub_Class.ClsPub.Enum_OKTag.OKTag_OK)
            {
                //
                Sub_SetReport(oFrm.sOpenTmp);
                Report.PrintPreview(true);
            }
        }
        private void Sub_SetReport(string sOpenTmp)
        {
            //判断行数
            for (int i = 0; i < grdMain.Rows.Count; i++)
            {
                grdMain.Rows[i].Cells[0].Value = "";
            }
            for (int i = 0; i < grdMain.SelectedRows.Count; i++)
            {
                grdMain.Rows[grdMain.SelectedRows[i].Index].Cells[0].Value = "*";
            }
            //
            //
            Report = new GridppReport();
            Report.LoadFromFile(DBUtility.ClsPub.AppPath + @"\" + sOpenTmp + ".grf");  //here .
            Report.FetchRecord += new _IGridppReportEvents_FetchRecordEventHandler(ReportFetchRecordByDataTable);
        }
        private void ReportFetchRecordByDataTable()
        {
            DataTable dt = new DataTable();
            BLL.Utility.FillRecordToReport_Sel(Report, grdMain, dt, Fun_GetCol("选择"));
        }
        #endregion
        //
        private void grdMain_Paint(object sender, PaintEventArgs e)
        {
            GraphicsGrid();
        }
        //合计 new
        private void Total()
        {
            if (grdMain.Rows.Count > 0 &&  grdMain.ColumnCount>0)
            {
                oSumGrid.SetGridsum();
                //oSumGrid.Total();
                oSumGrid.TotalAll();
            }
        }
        //合计 new
        private void grdMain_ColumnWidthChanged(object sender, DataGridViewColumnEventArgs e)
        {
            Total();
        }
        //合计 new
        private void grdMain_CellMouseUp(object sender, DataGridViewCellMouseEventArgs e)
        {
            //Total();
        }
        //引出EXCEL
        private void dc_Click(object sender, EventArgs e)
        {
            //DBUtility.Gy_BaseFun.DataToExcel(this.Text, grdMain);
            DataGridViewToExcel2();
        }
        private void txtHBillNo_KeyDown(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Enter)
            {
                Sub_FastQuery();
            }
        }
        //快速过滤
        private void Sub_FastQuery()
        {
            string sFastSQL = "";
            //LOT号
            if (txtHBillNo.Text.Trim() != "")
            {
                sFastSQL = sFastSQL + " and æµè½¬å¡å· like '%" + txtHBillNo.Text + "%'";
            }
            //工作中心
            if (txtHCenterID.Text.Trim() != "")
            {
                sFastSQL = sFastSQL + " and (工作中心 like '%" + txtHCenterID.Text + "%' or å·¥ä½œä¸­å¿ƒä»£ç  like '%" + txtHCenterID.Text + "%') ";
            }
            //订单跟踪号
            if (txtHOrderProcNO.Text.Trim() != "")
            {
                sFastSQL = sFastSQL + " and (订单跟踪号 like '%" + txtHOrderProcNO.Text + "%'  ) ";
            }
            //同步状态
            if(cmbHStatus.Text.Trim()=="未同步")
            {
                sFastSQL = sFastSQL + " and (同步状态='" + cmbHStatus.Text.Trim() + "'  ) ";
            }
            if (cmbHStatus.Text.Trim() == "已同步")
            {
                sFastSQL = sFastSQL + " and (同步状态='" + cmbHStatus.Text.Trim() + "'  ) ";
            }
            sDlgWhere = sFastSQL;
            Display();
        }
        private void DataGridViewToExcel2()
        {
            SaveFileDialog saveFileDialog = new SaveFileDialog();
            saveFileDialog.Filter = "Execl文件(*.xls)|*.xls";
            saveFileDialog.FilterIndex = 0;
            saveFileDialog.RestoreDirectory = true;
            saveFileDialog.CreatePrompt = true;
            saveFileDialog.Title = "数据视图导出EXCEL文件";
            saveFileDialog.ShowDialog();
            if (saveFileDialog.FileName == "")
            {
                return;
            }
            Stream myStream;
            myStream = saveFileDialog.OpenFile();
            StreamWriter sw = new StreamWriter(myStream, System.Text.Encoding.GetEncoding("gb2312"));
            string str = "";
            DateTime start = DateTime.Now;
            try
            {
                //写标题
                for (int i = 0; i < grdMain.ColumnCount; i++)
                {
                    if (i > 0)
                    {
                        str += "\t";
                    }
                    str += grdMain.Columns[i].HeaderText;
                }
                sw.WriteLine(str);
                //写内容
                for (int j = 0; j < grdMain.Rows.Count; j++)
                {
                    string tempStr = "";
                    for (int k = 0; k < grdMain.Columns.Count; k++)
                    {
                        if (k > 0)
                        {
                            tempStr += "\t";
                        }
                        if (grdMain.Rows[j].Cells[k].Value == null)
                        {
                            tempStr += string.Empty;
                        }
                        else
                        {
                            tempStr += grdMain.Rows[j].Cells[k].Value.ToString();
                        }
                    }
                    sw.WriteLine(tempStr);
                }
                sw.Close();
                myStream.Close();
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
            finally
            {
                sw.Close();
                myStream.Close();
            }
            MessageBox.Show("将此工作表导出为excel共耗时:" + DateTime.Now.Subtract(start).TotalMilliseconds.ToString() + "毫秒");
        }
        private void txtHCenterID_KeyDown(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Enter)
            {
                Sub_FastQuery();
            }
        }
        private void grdMain_Scroll(object sender, ScrollEventArgs e)
        {
            if (e.ScrollOrientation == ScrollOrientation.HorizontalScroll)
            {
                Total();
            }
        }
        private void txtHOrderProcNO_KeyDown(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Enter)
            {
                Sub_FastQuery();
            }
        }
        private void bzd_Click(object sender, EventArgs e)
        {
            //根据选中的数据生成包装单
            int MainIDCol =  Fun_GetCol("hmainid");
            int SubIDCol = Fun_GetCol("hsubid");
            int BillNoCol = Fun_GetCol("单据号");
            DAL.ClsKf_ProductInBill oClsKf_ProductInBill ;
            //获取系统参数
            Pub_Class.ClsXt_SystemParameter oSystemParameter = new Pub_Class.ClsXt_SystemParameter();
            if (oSystemParameter.ShowBill(ref DBUtility.ClsPub.sExeReturnInfo) == false)
            {
                MessageBox.Show("获取系统参数失败! " + DBUtility.ClsPub.sExeReturnInfo);
                return;
            }
            //判断会计期是否合理
            string s = "";
            int sYear = 0;
            int sPeriod = 0;
            if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(DateTime.Today, ref sYear, ref sPeriod, ref s) == false)
            {
                MessageBox.Show("会计期间有错误! " + DBUtility.ClsPub.sExeReturnInfo);
                return;
            }
            Int64 n = 0;
            //循环 é€‰ä¸­è¡Œ
            for (int i = 0; i < grdMain.SelectedRows.Count; i++)
            {
                oClsKf_ProductInBill = new DAL.ClsKf_ProductInBill();
                oClsKf_ProductInBill.omodel.HYear = sYear;
                oClsKf_ProductInBill.omodel.HPeriod = sPeriod;
                oClsKf_ProductInBill.omodel.HInterID = ClsPub.isLong(grdMain.Rows[grdMain.SelectedRows[i].Index].Cells[MainIDCol].Value);
                oClsKf_ProductInBill.omodel.HDate = DateTime.Today;
                oClsKf_ProductInBill.omodel.HBillNo = ClsPub.isStrNull(grdMain.Rows[grdMain.SelectedRows[i].Index].Cells[BillNoCol].Value);
                oClsKf_ProductInBill.omodel.HDeptID = 0;
                oClsKf_ProductInBill.omodel.HEmpID = 0;
                oClsKf_ProductInBill.omodel.HSecManagerID = 0;
                oClsKf_ProductInBill.omodel.HKeeperID = 0;
                oClsKf_ProductInBill.omodel.HRemark = "不良品同步";
                oClsKf_ProductInBill.omodel.HMaker =  DBUtility.ClsPub.CurUserName;
                oClsKf_ProductInBill.omodel.HWHID = 0;
                oClsKf_ProductInBill.omodel.HSupID = 0;
                oClsKf_ProductInBill.omodel.HExplanation = "";
                if(oClsKf_ProductInBill.AddBill_StationOut_Bad("3710", oSystemParameter.omodel, ref DBUtility.ClsPub.sExeReturnInfo))
                {
                    n++;
                }
                else
                {
                    MessageBox.Show("同步单据失败!"+ DBUtility.ClsPub.sExeReturnInfo);
                }
                //休眠5秒
                System.Threading.Thread.Sleep(5000);
                //
            }
            //
            if (n > 0)
            {
                MessageBox.Show("同步单据完毕!一共有" + n.ToString() + "张入库单!");
            }
        }
        private void eXCELToolStripMenuItem_Click(object sender, EventArgs e)
        {
            DBUtility.Gy_BaseFun.DataToExcel(this.Text, grdMain);
        }
        private void cSVToolStripMenuItem_Click(object sender, EventArgs e)
        {
            DBUtility.Gy_BaseFun.DataGridViewToExcel2(grdMain, this.Text, this.Text);
        }
        private void cmbHStatus_SelectedIndexChanged(object sender, EventArgs e)
        {
            Sub_FastQuery();
        }
    }
}
WorkM/Á÷ת¿¨¹ÜÀí/MES_StationOutBillList_Bad.designer.cs
New file
@@ -0,0 +1,673 @@
namespace WorkM
{
    partial class MES_StationOutBillList_Bad
    {
        /// <summary>
        /// å¿…需的设计器变量。
        /// </summary>
        private System.ComponentModel.IContainer components = null;
        /// <summary>
        /// æ¸…理所有正在使用的资源。
        /// </summary>
        /// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
        protected override void Dispose(bool disposing)
        {
            if (disposing && (components != null))
            {
                components.Dispose();
            }
            base.Dispose(disposing);
        }
        #region Windows çª—体设计器生成的代码
        /// <summary>
        /// è®¾è®¡å™¨æ”¯æŒæ‰€éœ€çš„æ–¹æ³• - ä¸è¦
        /// ä½¿ç”¨ä»£ç ç¼–辑器修改此方法的内容。
        /// </summary>
        private void InitializeComponent()
        {
            this.components = new System.ComponentModel.Container();
            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MES_StationOutBillList_Bad));
            this.pPic = new System.Windows.Forms.Panel();
            this.cmbHStatus = new System.Windows.Forms.ComboBox();
            this.label4 = new System.Windows.Forms.Label();
            this.label3 = new System.Windows.Forms.Label();
            this.txtHOrderProcNO = new System.Windows.Forms.TextBox();
            this.label2 = new System.Windows.Forms.Label();
            this.txtHCenterID = new System.Windows.Forms.TextBox();
            this.label1 = new System.Windows.Forms.Label();
            this.txtHBillNo = new System.Windows.Forms.TextBox();
            this.panel1 = new System.Windows.Forms.Panel();
            this.lbljl = new System.Windows.Forms.Label();
            this.lbldj = new System.Windows.Forms.Label();
            this.lblCaption = new System.Windows.Forms.Label();
            this.Tool = new System.Windows.Forms.ToolStrip();
            this.toolStripDropDownButton1 = new System.Windows.Forms.ToolStripDropDownButton();
            this.eXCELToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
            this.cSVToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
            this.dc = new System.Windows.Forms.ToolStripButton();
            this.yl = new System.Windows.Forms.ToolStripButton();
            this.toolStripSeparator2 = new System.Windows.Forms.ToolStripSeparator();
            this.cx = new System.Windows.Forms.ToolStripButton();
            this.sx = new System.Windows.Forms.ToolStripButton();
            this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator();
            this.xz = new System.Windows.Forms.ToolStripButton();
            this.dj = new System.Windows.Forms.ToolStripButton();
            this.sc = new System.Windows.Forms.ToolStripButton();
            this.toolStripSeparator5 = new System.Windows.Forms.ToolStripSeparator();
            this.sh = new System.Windows.Forms.ToolStripButton();
            this.qsh = new System.Windows.Forms.ToolStripButton();
            this.toolStripSeparator6 = new System.Windows.Forms.ToolStripSeparator();
            this.bzd = new System.Windows.Forms.ToolStripButton();
            this.toolStripSeparator4 = new System.Windows.Forms.ToolStripSeparator();
            this.tc = new System.Windows.Forms.ToolStripButton();
            this.toolStripSeparator3 = new System.Windows.Forms.ToolStripSeparator();
            this.toolStripSeparator9 = new System.Windows.Forms.ToolStripSeparator();
            this.mrlk = new System.Windows.Forms.ToolStripButton();
            this.toolStripSeparator7 = new System.Windows.Forms.ToolStripSeparator();
            this.bclk = new System.Windows.Forms.ToolStripButton();
            this.toolStripSeparator8 = new System.Windows.Forms.ToolStripSeparator();
            this.timer1 = new System.Windows.Forms.Timer(this.components);
            this.timer2 = new System.Windows.Forms.Timer(this.components);
            this.grdMain = new System.Windows.Forms.DataGridView();
            this.grdPrint = new System.Windows.Forms.DataGridView();
            this.grdSum = new System.Windows.Forms.DataGridView();
            this.pPic.SuspendLayout();
            this.panel1.SuspendLayout();
            this.Tool.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(this.grdMain)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(this.grdPrint)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(this.grdSum)).BeginInit();
            this.SuspendLayout();
            //
            // pPic
            //
            this.pPic.BackColor = System.Drawing.Color.White;
            this.pPic.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("pPic.BackgroundImage")));
            this.pPic.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
            this.pPic.Controls.Add(this.cmbHStatus);
            this.pPic.Controls.Add(this.label4);
            this.pPic.Controls.Add(this.label3);
            this.pPic.Controls.Add(this.txtHOrderProcNO);
            this.pPic.Controls.Add(this.label2);
            this.pPic.Controls.Add(this.txtHCenterID);
            this.pPic.Controls.Add(this.label1);
            this.pPic.Controls.Add(this.txtHBillNo);
            this.pPic.Controls.Add(this.panel1);
            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.Name = "pPic";
            this.pPic.Size = new System.Drawing.Size(1661, 66);
            this.pPic.TabIndex = 15;
            //
            // cmbHStatus
            //
            this.cmbHStatus.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
            this.cmbHStatus.FormattingEnabled = true;
            this.cmbHStatus.Items.AddRange(new object[] {
            "未同步",
            "已同步",
            "全部"});
            this.cmbHStatus.Location = new System.Drawing.Point(461, 15);
            this.cmbHStatus.Name = "cmbHStatus";
            this.cmbHStatus.Size = new System.Drawing.Size(121, 23);
            this.cmbHStatus.TabIndex = 20;
            this.cmbHStatus.SelectedIndexChanged += new System.EventHandler(this.cmbHStatus_SelectedIndexChanged);
            //
            // label4
            //
            this.label4.AutoSize = true;
            this.label4.BackColor = System.Drawing.Color.Transparent;
            this.label4.Location = new System.Drawing.Point(374, 19);
            this.label4.Name = "label4";
            this.label4.Size = new System.Drawing.Size(67, 15);
            this.label4.TabIndex = 19;
            this.label4.Text = "同步状态";
            //
            // label3
            //
            this.label3.AutoSize = true;
            this.label3.BackColor = System.Drawing.Color.Transparent;
            this.label3.Location = new System.Drawing.Point(759, 53);
            this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
            this.label3.Name = "label3";
            this.label3.Size = new System.Drawing.Size(97, 15);
            this.label3.TabIndex = 18;
            this.label3.Text = "订单跟踪号:";
            this.label3.Visible = false;
            //
            // txtHOrderProcNO
            //
            this.txtHOrderProcNO.Location = new System.Drawing.Point(865, 48);
            this.txtHOrderProcNO.Margin = new System.Windows.Forms.Padding(4);
            this.txtHOrderProcNO.Name = "txtHOrderProcNO";
            this.txtHOrderProcNO.Size = new System.Drawing.Size(215, 25);
            this.txtHOrderProcNO.TabIndex = 17;
            this.txtHOrderProcNO.Visible = false;
            this.txtHOrderProcNO.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txtHOrderProcNO_KeyDown);
            //
            // label2
            //
            this.label2.AutoSize = true;
            this.label2.BackColor = System.Drawing.Color.Transparent;
            this.label2.Location = new System.Drawing.Point(630, 19);
            this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
            this.label2.Name = "label2";
            this.label2.Size = new System.Drawing.Size(82, 15);
            this.label2.TabIndex = 14;
            this.label2.Text = "工作中心:";
            //
            // txtHCenterID
            //
            this.txtHCenterID.Location = new System.Drawing.Point(720, 15);
            this.txtHCenterID.Margin = new System.Windows.Forms.Padding(4);
            this.txtHCenterID.Name = "txtHCenterID";
            this.txtHCenterID.Size = new System.Drawing.Size(215, 25);
            this.txtHCenterID.TabIndex = 15;
            this.txtHCenterID.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txtHCenterID_KeyDown);
            //
            // label1
            //
            this.label1.AutoSize = true;
            this.label1.Location = new System.Drawing.Point(944, 19);
            this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
            this.label1.Name = "label1";
            this.label1.Size = new System.Drawing.Size(82, 15);
            this.label1.TabIndex = 8;
            this.label1.Text = "流转卡号:";
            //
            // txtHBillNo
            //
            this.txtHBillNo.Location = new System.Drawing.Point(1034, 15);
            this.txtHBillNo.Margin = new System.Windows.Forms.Padding(4);
            this.txtHBillNo.Name = "txtHBillNo";
            this.txtHBillNo.Size = new System.Drawing.Size(215, 25);
            this.txtHBillNo.TabIndex = 9;
            this.txtHBillNo.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txtHBillNo_KeyDown);
            //
            // panel1
            //
            this.panel1.Controls.Add(this.lbljl);
            this.panel1.Controls.Add(this.lbldj);
            this.panel1.Dock = System.Windows.Forms.DockStyle.Right;
            this.panel1.Location = new System.Drawing.Point(1398, 0);
            this.panel1.Margin = new System.Windows.Forms.Padding(4);
            this.panel1.Name = "panel1";
            this.panel1.Size = new System.Drawing.Size(263, 66);
            this.panel1.TabIndex = 7;
            //
            // lbljl
            //
            this.lbljl.AutoSize = true;
            this.lbljl.Location = new System.Drawing.Point(32, 38);
            this.lbljl.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
            this.lbljl.Name = "lbljl";
            this.lbljl.Size = new System.Drawing.Size(15, 15);
            this.lbljl.TabIndex = 1;
            this.lbljl.Text = " ";
            //
            // lbldj
            //
            this.lbldj.AutoSize = true;
            this.lbldj.Location = new System.Drawing.Point(32, 15);
            this.lbldj.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
            this.lbldj.Name = "lbldj";
            this.lbldj.Size = new System.Drawing.Size(0, 15);
            this.lbldj.TabIndex = 0;
            //
            // lblCaption
            //
            this.lblCaption.AutoSize = true;
            this.lblCaption.BackColor = System.Drawing.Color.Transparent;
            this.lblCaption.Cursor = System.Windows.Forms.Cursors.No;
            this.lblCaption.Font = new System.Drawing.Font("宋体", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
            this.lblCaption.Location = new System.Drawing.Point(16, 19);
            this.lblCaption.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
            this.lblCaption.Name = "lblCaption";
            this.lblCaption.Size = new System.Drawing.Size(264, 27);
            this.lblCaption.TabIndex = 4;
            this.lblCaption.Text = "工序汇报不良品列表";
            this.lblCaption.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            //
            // Tool
            //
            this.Tool.AutoSize = false;
            this.Tool.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("Tool.BackgroundImage")));
            this.Tool.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
            this.Tool.ImageScalingSize = new System.Drawing.Size(22, 22);
            this.Tool.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.toolStripDropDownButton1,
            this.dc,
            this.yl,
            this.toolStripSeparator2,
            this.cx,
            this.sx,
            this.toolStripSeparator1,
            this.xz,
            this.dj,
            this.sc,
            this.toolStripSeparator5,
            this.sh,
            this.qsh,
            this.toolStripSeparator6,
            this.bzd,
            this.toolStripSeparator4,
            this.tc,
            this.toolStripSeparator3,
            this.toolStripSeparator9,
            this.mrlk,
            this.toolStripSeparator7,
            this.bclk,
            this.toolStripSeparator8});
            this.Tool.Location = new System.Drawing.Point(0, 0);
            this.Tool.Name = "Tool";
            this.Tool.Padding = new System.Windows.Forms.Padding(0);
            this.Tool.Size = new System.Drawing.Size(1661, 62);
            this.Tool.Stretch = true;
            this.Tool.TabIndex = 16;
            this.Tool.Text = "toolStrip1";
            //
            // toolStripDropDownButton1
            //
            this.toolStripDropDownButton1.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.eXCELToolStripMenuItem,
            this.cSVToolStripMenuItem});
            this.toolStripDropDownButton1.Image = ((System.Drawing.Image)(resources.GetObject("toolStripDropDownButton1.Image")));
            this.toolStripDropDownButton1.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.toolStripDropDownButton1.ImageTransparentColor = System.Drawing.Color.Magenta;
            this.toolStripDropDownButton1.Name = "toolStripDropDownButton1";
            this.toolStripDropDownButton1.Size = new System.Drawing.Size(53, 59);
            this.toolStripDropDownButton1.Text = "引出";
            this.toolStripDropDownButton1.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.toolStripDropDownButton1.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            //
            // eXCELToolStripMenuItem
            //
            this.eXCELToolStripMenuItem.Name = "eXCELToolStripMenuItem";
            this.eXCELToolStripMenuItem.Size = new System.Drawing.Size(136, 26);
            this.eXCELToolStripMenuItem.Text = "EXCEL";
            this.eXCELToolStripMenuItem.Click += new System.EventHandler(this.eXCELToolStripMenuItem_Click);
            //
            // cSVToolStripMenuItem
            //
            this.cSVToolStripMenuItem.Name = "cSVToolStripMenuItem";
            this.cSVToolStripMenuItem.Size = new System.Drawing.Size(136, 26);
            this.cSVToolStripMenuItem.Text = "CSV";
            this.cSVToolStripMenuItem.Click += new System.EventHandler(this.cSVToolStripMenuItem_Click);
            //
            // dc
            //
            this.dc.AutoSize = false;
            this.dc.Image = ((System.Drawing.Image)(resources.GetObject("dc.Image")));
            this.dc.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.dc.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.dc.ImageTransparentColor = System.Drawing.Color.White;
            this.dc.Name = "dc";
            this.dc.Size = new System.Drawing.Size(36, 47);
            this.dc.Text = "引出";
            this.dc.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.dc.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.dc.Click += new System.EventHandler(this.dc_Click);
            //
            // 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(36, 47);
            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);
            //
            // toolStripSeparator2
            //
            this.toolStripSeparator2.Name = "toolStripSeparator2";
            this.toolStripSeparator2.Size = new System.Drawing.Size(6, 62);
            //
            // cx
            //
            this.cx.AutoSize = false;
            this.cx.Image = ((System.Drawing.Image)(resources.GetObject("cx.Image")));
            this.cx.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.cx.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.cx.ImageTransparentColor = System.Drawing.Color.White;
            this.cx.Name = "cx";
            this.cx.Size = new System.Drawing.Size(36, 47);
            this.cx.Text = "查询";
            this.cx.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.cx.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.cx.Click += new System.EventHandler(this.cx_Click);
            //
            // sx
            //
            this.sx.AutoSize = false;
            this.sx.Image = ((System.Drawing.Image)(resources.GetObject("sx.Image")));
            this.sx.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.sx.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.sx.ImageTransparentColor = System.Drawing.Color.Magenta;
            this.sx.Name = "sx";
            this.sx.Size = new System.Drawing.Size(36, 47);
            this.sx.Text = "刷新";
            this.sx.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.sx.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.sx.Click += new System.EventHandler(this.sx_Click);
            //
            // toolStripSeparator1
            //
            this.toolStripSeparator1.Name = "toolStripSeparator1";
            this.toolStripSeparator1.Size = new System.Drawing.Size(6, 62);
            //
            // xz
            //
            this.xz.AutoSize = false;
            this.xz.Image = ((System.Drawing.Image)(resources.GetObject("xz.Image")));
            this.xz.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.xz.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.xz.ImageTransparentColor = System.Drawing.Color.Magenta;
            this.xz.Name = "xz";
            this.xz.Size = new System.Drawing.Size(36, 47);
            this.xz.Text = "新增";
            this.xz.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.xz.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.xz.Visible = false;
            this.xz.Click += new System.EventHandler(this.xz_Click);
            //
            // dj
            //
            this.dj.AutoSize = false;
            this.dj.Image = ((System.Drawing.Image)(resources.GetObject("dj.Image")));
            this.dj.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.dj.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.dj.ImageTransparentColor = System.Drawing.Color.White;
            this.dj.Name = "dj";
            this.dj.Size = new System.Drawing.Size(36, 47);
            this.dj.Text = "单据";
            this.dj.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.dj.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.dj.Visible = false;
            this.dj.Click += new System.EventHandler(this.dj_Click);
            //
            // sc
            //
            this.sc.AutoSize = false;
            this.sc.Image = ((System.Drawing.Image)(resources.GetObject("sc.Image")));
            this.sc.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.sc.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.sc.ImageTransparentColor = System.Drawing.Color.Magenta;
            this.sc.Name = "sc";
            this.sc.Size = new System.Drawing.Size(36, 47);
            this.sc.Text = "删除";
            this.sc.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.sc.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.sc.Visible = false;
            this.sc.Click += new System.EventHandler(this.sc_Click);
            //
            // toolStripSeparator5
            //
            this.toolStripSeparator5.Name = "toolStripSeparator5";
            this.toolStripSeparator5.Size = new System.Drawing.Size(6, 62);
            this.toolStripSeparator5.Visible = false;
            //
            // sh
            //
            this.sh.AutoSize = false;
            this.sh.Image = ((System.Drawing.Image)(resources.GetObject("sh.Image")));
            this.sh.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.sh.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.sh.ImageTransparentColor = System.Drawing.Color.Magenta;
            this.sh.Name = "sh";
            this.sh.Size = new System.Drawing.Size(36, 47);
            this.sh.Text = "审核";
            this.sh.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.sh.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.sh.Visible = false;
            this.sh.Click += new System.EventHandler(this.sh_Click);
            //
            // qsh
            //
            this.qsh.AutoSize = false;
            this.qsh.Image = ((System.Drawing.Image)(resources.GetObject("qsh.Image")));
            this.qsh.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.qsh.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.qsh.ImageTransparentColor = System.Drawing.Color.Magenta;
            this.qsh.Name = "qsh";
            this.qsh.Size = new System.Drawing.Size(36, 47);
            this.qsh.Text = "反审";
            this.qsh.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.qsh.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.qsh.Visible = false;
            this.qsh.Click += new System.EventHandler(this.qsh_Click);
            //
            // toolStripSeparator6
            //
            this.toolStripSeparator6.Name = "toolStripSeparator6";
            this.toolStripSeparator6.Size = new System.Drawing.Size(6, 62);
            //
            // bzd
            //
            this.bzd.AutoSize = false;
            this.bzd.Image = ((System.Drawing.Image)(resources.GetObject("bzd.Image")));
            this.bzd.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.bzd.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.bzd.ImageTransparentColor = System.Drawing.Color.White;
            this.bzd.Name = "bzd";
            this.bzd.Size = new System.Drawing.Size(36, 47);
            this.bzd.Text = "入库";
            this.bzd.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.bzd.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.bzd.ToolTipText = "入库";
            this.bzd.Click += new System.EventHandler(this.bzd_Click);
            //
            // toolStripSeparator4
            //
            this.toolStripSeparator4.Name = "toolStripSeparator4";
            this.toolStripSeparator4.Size = new System.Drawing.Size(6, 62);
            //
            // tc
            //
            this.tc.AutoSize = false;
            this.tc.Image = ((System.Drawing.Image)(resources.GetObject("tc.Image")));
            this.tc.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.tc.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.tc.ImageTransparentColor = System.Drawing.Color.White;
            this.tc.Name = "tc";
            this.tc.Size = new System.Drawing.Size(36, 47);
            this.tc.Text = "退出";
            this.tc.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.tc.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.tc.Click += new System.EventHandler(this.tc_Click);
            //
            // toolStripSeparator3
            //
            this.toolStripSeparator3.Name = "toolStripSeparator3";
            this.toolStripSeparator3.Size = new System.Drawing.Size(6, 62);
            //
            // toolStripSeparator9
            //
            this.toolStripSeparator9.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right;
            this.toolStripSeparator9.Name = "toolStripSeparator9";
            this.toolStripSeparator9.Size = new System.Drawing.Size(6, 62);
            //
            // mrlk
            //
            this.mrlk.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right;
            this.mrlk.Image = ((System.Drawing.Image)(resources.GetObject("mrlk.Image")));
            this.mrlk.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.mrlk.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.mrlk.ImageTransparentColor = System.Drawing.Color.White;
            this.mrlk.Name = "mrlk";
            this.mrlk.Size = new System.Drawing.Size(73, 59);
            this.mrlk.Text = "默认列宽";
            this.mrlk.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.mrlk.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.mrlk.Click += new System.EventHandler(this.mrlk_Click);
            //
            // toolStripSeparator7
            //
            this.toolStripSeparator7.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right;
            this.toolStripSeparator7.Name = "toolStripSeparator7";
            this.toolStripSeparator7.Size = new System.Drawing.Size(6, 62);
            //
            // bclk
            //
            this.bclk.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right;
            this.bclk.Image = ((System.Drawing.Image)(resources.GetObject("bclk.Image")));
            this.bclk.ImageAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.bclk.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
            this.bclk.ImageTransparentColor = System.Drawing.Color.White;
            this.bclk.Name = "bclk";
            this.bclk.Size = new System.Drawing.Size(73, 59);
            this.bclk.Text = "保存列宽";
            this.bclk.TextAlign = System.Drawing.ContentAlignment.BottomCenter;
            this.bclk.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
            this.bclk.Click += new System.EventHandler(this.bclk_Click);
            //
            // toolStripSeparator8
            //
            this.toolStripSeparator8.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right;
            this.toolStripSeparator8.Name = "toolStripSeparator8";
            this.toolStripSeparator8.Size = new System.Drawing.Size(6, 62);
            //
            // timer1
            //
            this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
            //
            // timer2
            //
            this.timer2.Enabled = true;
            this.timer2.Tick += new System.EventHandler(this.timer2_Tick);
            //
            // grdMain
            //
            this.grdMain.AllowUserToAddRows = false;
            this.grdMain.AllowUserToDeleteRows = false;
            this.grdMain.BackgroundColor = System.Drawing.SystemColors.InactiveCaption;
            this.grdMain.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
            this.grdMain.Dock = System.Windows.Forms.DockStyle.Fill;
            this.grdMain.Location = new System.Drawing.Point(0, 128);
            this.grdMain.Margin = new System.Windows.Forms.Padding(4);
            this.grdMain.Name = "grdMain";
            this.grdMain.ReadOnly = true;
            this.grdMain.RowHeadersWidth = 51;
            this.grdMain.RowTemplate.Height = 23;
            this.grdMain.Size = new System.Drawing.Size(1661, 512);
            this.grdMain.TabIndex = 19;
            this.grdMain.CellMouseUp += new System.Windows.Forms.DataGridViewCellMouseEventHandler(this.grdMain_CellMouseUp);
            this.grdMain.ColumnWidthChanged += new System.Windows.Forms.DataGridViewColumnEventHandler(this.grdMain_ColumnWidthChanged);
            this.grdMain.Scroll += new System.Windows.Forms.ScrollEventHandler(this.grdMain_Scroll);
            this.grdMain.Paint += new System.Windows.Forms.PaintEventHandler(this.grdMain_Paint);
            this.grdMain.DoubleClick += new System.EventHandler(this.grdMain_DblClick);
            //
            // grdPrint
            //
            this.grdPrint.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
            this.grdPrint.Location = new System.Drawing.Point(1029, 182);
            this.grdPrint.Margin = new System.Windows.Forms.Padding(4);
            this.grdPrint.Name = "grdPrint";
            this.grdPrint.RowHeadersWidth = 51;
            this.grdPrint.RowTemplate.Height = 23;
            this.grdPrint.Size = new System.Drawing.Size(33, 30);
            this.grdPrint.TabIndex = 8;
            this.grdPrint.Visible = false;
            //
            // grdSum
            //
            this.grdSum.AllowUserToAddRows = false;
            this.grdSum.AllowUserToDeleteRows = false;
            this.grdSum.BackgroundColor = System.Drawing.SystemColors.Control;
            this.grdSum.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
            this.grdSum.Dock = System.Windows.Forms.DockStyle.Bottom;
            this.grdSum.Location = new System.Drawing.Point(0, 640);
            this.grdSum.Margin = new System.Windows.Forms.Padding(4);
            this.grdSum.Name = "grdSum";
            this.grdSum.ReadOnly = true;
            this.grdSum.RowHeadersWidth = 51;
            this.grdSum.RowTemplate.Height = 23;
            this.grdSum.ScrollBars = System.Windows.Forms.ScrollBars.None;
            this.grdSum.Size = new System.Drawing.Size(1661, 24);
            this.grdSum.TabIndex = 47;
            //
            // MES_StationOutBillList_Bad
            //
            this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.ClientSize = new System.Drawing.Size(1661, 664);
            this.Controls.Add(this.grdMain);
            this.Controls.Add(this.grdSum);
            this.Controls.Add(this.pPic);
            this.Controls.Add(this.Tool);
            this.Controls.Add(this.grdPrint);
            this.Margin = new System.Windows.Forms.Padding(4);
            this.Name = "MES_StationOutBillList_Bad";
            this.Text = "工序汇报不良品列表";
            this.WindowState = System.Windows.Forms.FormWindowState.Maximized;
            this.Load += new System.EventHandler(this.MES_StationOutBillList_Bad_Load);
            this.pPic.ResumeLayout(false);
            this.pPic.PerformLayout();
            this.panel1.ResumeLayout(false);
            this.panel1.PerformLayout();
            this.Tool.ResumeLayout(false);
            this.Tool.PerformLayout();
            ((System.ComponentModel.ISupportInitialize)(this.grdMain)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(this.grdPrint)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(this.grdSum)).EndInit();
            this.ResumeLayout(false);
        }
        #endregion
        private System.Windows.Forms.Panel pPic;
        private System.Windows.Forms.Label lblCaption;
        private System.Windows.Forms.ToolStrip Tool;
        private System.Windows.Forms.ToolStripButton yl;
        private System.Windows.Forms.ToolStripSeparator toolStripSeparator2;
        private System.Windows.Forms.ToolStripButton cx;
        private System.Windows.Forms.ToolStripSeparator toolStripSeparator1;
        private System.Windows.Forms.ToolStripButton tc;
        private System.Windows.Forms.ToolStripSeparator toolStripSeparator3;
        public System.Windows.Forms.Timer timer1;
        private System.Windows.Forms.ToolStripButton sx;
        private System.Windows.Forms.ToolStripButton dj;
        private System.Windows.Forms.ToolStripButton xz;
        private System.Windows.Forms.ToolStripButton sc;
        private System.Windows.Forms.ToolStripSeparator toolStripSeparator4;
        private System.Windows.Forms.Timer timer2;
        private System.Windows.Forms.ToolStripSeparator toolStripSeparator9;
        private System.Windows.Forms.ToolStripButton mrlk;
        private System.Windows.Forms.ToolStripSeparator toolStripSeparator7;
        private System.Windows.Forms.ToolStripButton bclk;
        private System.Windows.Forms.ToolStripSeparator toolStripSeparator8;
        private System.Windows.Forms.ToolStripSeparator toolStripSeparator5;
        private System.Windows.Forms.ToolStripButton sh;
        private System.Windows.Forms.ToolStripButton qsh;
        private System.Windows.Forms.DataGridView grdMain;
        private System.Windows.Forms.Panel panel1;
        private System.Windows.Forms.Label lbljl;
        private System.Windows.Forms.Label lbldj;
        private System.Windows.Forms.DataGridView grdPrint;
        private System.Windows.Forms.DataGridView grdSum;
        private System.Windows.Forms.ToolStripButton dc;
        private System.Windows.Forms.Label label1;
        private System.Windows.Forms.TextBox txtHBillNo;
        private System.Windows.Forms.Label label2;
        private System.Windows.Forms.TextBox txtHCenterID;
        private System.Windows.Forms.TextBox txtHOrderProcNO;
        private System.Windows.Forms.Label label3;
        private System.Windows.Forms.ToolStripSeparator toolStripSeparator6;
        private System.Windows.Forms.ToolStripButton bzd;
        private System.Windows.Forms.ToolStripDropDownButton toolStripDropDownButton1;
        private System.Windows.Forms.ToolStripMenuItem eXCELToolStripMenuItem;
        private System.Windows.Forms.ToolStripMenuItem cSVToolStripMenuItem;
        private System.Windows.Forms.ComboBox cmbHStatus;
        private System.Windows.Forms.Label label4;
    }
}
WorkM/Á÷ת¿¨¹ÜÀí/MES_StationOutBillList_Bad.resx
New file
Diff too large