Ejemplo n.º 1
0
    private void setddl(string workshop, string eqp)
    {
        //膜的等级
        CRUD.Setdll(ddlFilmLevel, "FilmLevel");
        CRUD.Setdll(ddlWorkshop, "workshop");
        //ddlWorkshop.SelectedIndex = 0;
        ddlWorkshop.ClearSelection();
        ddlWorkshop.Items.FindByValue(workshop).Selected = true;
        ddlEqp.ClearSelection();
        CRUD.SetEqpDDL(ddlEqp, ddlWorkshop.SelectedValue, "M35");//获取UV成型的eqp
        ddlEqp.Items.FindByValue(eqp).Selected = true;

        #region //检验结果======================================================
        FilmCRUD.setDDLQCResult(ddlAppearanceResult);
        FilmCRUD.setDDLQCResult(ddlAvailableWidthResult);
        FilmCRUD.setDDLQCResult(ddlBaigeResult);
        FilmCRUD.setDDLQCResult(ddlBucklingResult);
        FilmCRUD.setDDLQCResult(ddlLinesResult);
        FilmCRUD.setDDLQCResult(ddlMDHazeResult);
        FilmCRUD.setDDLQCResult(ddlParticleResult);
        FilmCRUD.setDDLQCResult(ddlPenetranceResult);
        FilmCRUD.setDDLQCResult(ddlThinknessResult);
        FilmCRUD.setDDLQCResult(ddltxtPencilHardnessResult);
        #endregion
    }
Ejemplo n.º 2
0
    protected void btnEnter_Click(object sender, EventArgs e)
    {
        string originalLot = "";
        //判断是否是UV成型的条码
        string check = CRUD.CheckFilmLabel("UV成型", txtLot.Text);

        if (check != "fail")
        {
            originalLot = check;
        }
        else
        {
            originalLot = txtLot.Text;
        }
        ViewState["originalLot"] = originalLot;
        //查询是否可以过站
        string result = CRUD.QueryStationOfLot(lblWorksiteID.Text, originalLot);

        if (result != "success")
        {
            JScript.Alert(result, this);
            txtLot.Text = "";
            return;
        }
        DataTable lotDt    = CRUD.GetLotBasisInfo(originalLot);
        string    workshop = lotDt.Rows[0]["workshopID"].ToString();

        //膜等级
        //txtFilmLevel.Text = lotDt.Rows[0]["mouldlevel"].ToString();
        setddl(workshop);

        string WO = lotDt.Rows[0]["workorder"].ToString();

        //显示批次长宽信息
        txtPreWidth.Text = lotDt.Rows[0]["mouldwidth"].ToString();
        //txtPreLength.Text = lotDt.Rows[0]["mouldlength"].ToString();
        //=======================前站长度显示改为有效长度 modify by lei.xue on 2017-6-12=================================================
        txtPreLength.Text = lotDt.Rows[0]["validlength"].ToString();
        txtLevel.Text     = lotDt.Rows[0]["filmlevel"].ToString();
        //======================标签宽度改为取有效宽幅 modify by lei.xue on 2017-5-22========================================
        txtValidWidth.Text = lotDt.Rows[0]["validwidth"].ToString();

        //显示工单信息
        SetWOinfo(WO);

        //显示打印标签时间
        string[] LabelTime = FilmCRUD.GetLabelTime(txtLot.Text);
        txtSubsectionDate.Text = LabelTime[0];
        txtPasteFilmDate.Text  = LabelTime[1];
        txtUVCompleteDate.Text = LabelTime[2];


        CRUD.setLabelProcess(lblLotprocess, lblCurrnentWorksite, lblEndProcess, ViewState["originalLot"].ToString(), lblWorksiteID.Text);
    }
Ejemplo n.º 3
0
    protected void btnMouldLot_Click(object sender, EventArgs e)
    {
        //模具编号
        string MouldLot = "";

        #region 判断条码是否有效
        if (txtMouldLot.Text.Length > 3)
        {
            //外发或资产条码是否打印 条码第四位判断:W或Z
            if (txtMouldLot.Text.Substring(3, 1).ToString() == "W")
            {
                if (CRUD.CheckMouldLabel("W", txtMouldLot.Text) == "fail")
                {
                    JScript.Alert("该条码为打印!", this);
                    return;
                }
            }
            else if (txtMouldLot.Text.Substring(3, 1).ToString() == "Z")
            {
                if (CRUD.CheckMouldLabel("Z", txtMouldLot.Text) == "fail")
                {
                    JScript.Alert("该条码未打印!", this);
                    return;
                }
            }

            MouldLot = txtMouldLot.Text.Substring(0, 3).ToString();
        }
        else
        {
            MouldLot = txtMouldLot.Text;
        }

        #endregion
        DataTable dt     = null;
        string    result = FilmCRUD.GetMouldInfo(MouldLot, "M20", ref dt);
        if (result == "success")
        {
            for (int i = 0; i < dt.Rows.Count; i++)
            {
                if (dt.Rows[i]["paratype"].ToString() == "Haze")
                {
                    txtHaze.Text = dt.Rows[i]["paraid"].ToString();
                }
            }
        }
        else
        {
            JScript.Alert("该模具未完成喷砂站点", this);
        }
    }
Ejemplo n.º 4
0
    protected void btnEnter_Click(object sender, EventArgs e)
    {
        //判断是否是UV成型的条码
        //string check = CRUD.CheckFilmLabel("UV成型", txtLot.Text);
        //if (check == "fail")
        //{
        //    JScript.Alert("条码未打印", this);
        //    return;
        //}
        string originalLot = txtLot.Text;

        ViewState["originalLot"] = originalLot;

        //查询是否可以过站
        string result = CRUD.QueryStationOfLot(lblWorksiteID.Text, originalLot);

        if (result != "success")
        {
            JScript.Alert(result, this);
            txtLot.Text = "";
            return;
        }

        DataTable lotDt = CRUD.GetLotBasisInfo(originalLot);

        //string workshop = lotDt.Rows[0]["workshopID"].ToString();
        //膜等级
        txtFilmLevel.Text = lotDt.Rows[0]["filmlevel"].ToString();
        ////查询UV成型站的eqp信息 add by lei.xue on 2017-2-21
        //lotDt = null;
        //lotDt = CRUD.getStationInfo(originalLot, "M50");

        string UVCompleteEqp = lotDt.Rows[0]["eqpid"].ToString();
        string workshop      = lotDt.Rows[0]["workshopid"].ToString();

        setddl(workshop, UVCompleteEqp);

        //string WO = lotDt.Rows[0]["workorder"].ToString();
        #region 批次流程

        //查询批次流程
        CRUD.setLabelProcess(lblLotprocess, lblCurrnentWorksite, lblEndProcess, originalLot, lblWorksiteID.Text);
        #endregion

        //检查流程是否包含分条站点
        if (FilmCRUD.QuerySubsectionFlowID(txtLot.Text) == "fail")
        {
            CbxChangeFlow.Enabled = false;
        }
    }
Ejemplo n.º 5
0
    private void setddl(string workshop, string eqp)
    {
        //膜的等级
        CRUD.Setdll(ddlFilmLevel, "FilmLevel");
        CRUD.Setdll(ddlWorkshop, "workshop");
        //ddlWorkshop.SelectedIndex = 0;
        ddlWorkshop.ClearSelection();
        ddlWorkshop.Items.FindByValue(workshop).Selected = true;
        ddlEqp.ClearSelection();
        CRUD.SetEqpDDL(ddlEqp, ddlWorkshop.SelectedValue, "M55");//获取贴膜成型的eqp
        ddlEqp.Items.FindByValue(eqp).Selected = true;

        #region //检验结果======================================================
        FilmCRUD.setDDLQCResult(ddlAppearanceResult);

        #endregion
    }
Ejemplo n.º 6
0
    protected void btnEnter_Click(object sender, EventArgs e)
    {
        //查询是否可以过站
        string result = CRUD.QueryStationOfLot(lblWorksiteID.Text, txtLot.Text);

        if (result != "success")
        {
            JScript.Alert(result, this);
            txtLot.Text = "";
            return;
        }

        DataTable lotDt    = CRUD.GetLotBasisInfo(txtLot.Text);
        string    workshop = lotDt.Rows[0]["workshopID"].ToString();

        setddl(workshop);

        string WO = lotDt.Rows[0]["workorder"].ToString();

        CRUD.setLabelProcess(lblLotprocess, lblCurrnentWorksite, lblEndProcess, txtLot.Text, lblWorksiteID.Text);


        FilmCRUD.GetPreLengthAndWidth(txtPreLength, txtPreWidth, txtLot.Text, lblWorksiteID.Text, WO, "");
    }
Ejemplo n.º 7
0
    protected void btnSaveClose_Click(object sender, EventArgs e)
    {
        #region//分批条码改为可以手动输入,判断条码是否已经存在 add by lei.xue on 2017-11-8
        string strExistSubLot = FilmCRUD.ExistSublot(txtLot.Text, txtLabelInfo.Text);
        if (strExistSubLot == "success")
        {
            JScript.Alert("该分批条码已经存在", this);
            return;
        }
        #endregion

        //插入basis表 , 更新母批剩余数量 ,子批flowidno为当点站
        string SplitLength = "";
        if (cbxSplit.Checked == true)
        {
            SplitLength = txtSplitLength.Text;
        }
        else
        {
            //母批直接分批的时候改为分批长度取剩余长度 modify by lei.xue on 2017-8-19
            //SplitLength = txtPreLength.Text;
            SplitLength = txtRestLength.Text;
        }
        LotBasisDatalist dl = new LotBasisDatalist();
        DataTable        dt = (DataTable)ViewState["lotDt"];
        dl.flowid          = dt.Rows[0]["flowid"].ToString();
        dl.workshopid      = ddlWorkshop.SelectedValue;
        dl.lottype         = "Film";
        dl.status          = "Active";
        dl.createuser      = System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString();
        dl.currentflowidno = (Convert.ToInt32(dt.Rows[0]["flowidno"].ToString()) + 1).ToString(); //流程编号加1
        dl.factoryid       = "";
        dl.workorder       = ViewState["WO"].ToString();
        dl.reworkorder     = "";
        dl.lotid           = txtLabelInfo.Text;
        dl.lotcount        = dt.Rows[0]["lotcount"].ToString();
        dl.ProcessComplete = "N";
        dl.UVCompleteLotid = txtLot.Text;
        dl.length          = SplitLength;    //txtSplitLength.Text;
        //================剩余长度和宽度为母批的有效长度和宽度modify by lei.xue on 2017-6-1=============
        dl.restlength = txtValidLength.Text; //SplitLength;//txtSplitLength.Text;
        dl.width      = txtPreWidth.Text;
        dl.restwidth  = txtValidWidth.Text;  //txtPreWidth.Text;
        dl.Filmlevel  = "A";
        //增加贴膜设备编号 add by lei.xue on 2017-2-22
        dl.eqpid = ddlEqp.SelectedValue;
        //增加有效幅宽 add by lei.xue on 2017-4-19
        dl.validwidth = txtValidWidth.Text;
        //增加有效长度 add by lei.xue on 2017-6-11
        dl.validlength = txtValidLength.Text;
        string result = CreateMouldLot.InsertLot(dl);
        if (result != "success")
        {
            JScript.Alert(result, this);
            return;
        }

        //插入分批记录到分批表
        dl.sublotid = txtLabelInfo.Text;
        dl.lotid    = txtLot.Text;
        string resultsplit = PasteFilm.InsertSplitLot(dl);

        //更新母批剩余数量
        Decimal rest    = Convert.ToDecimal(txtRestLength.Text) - Convert.ToDecimal(SplitLength);//txtSplitLength.Text );
        string  strRest = PasteFilm.UpdateParentQty(ViewState["originalLot"].ToString(), rest.ToString(), "Length");
        if (strRest != "success")
        {
            JScript.Alert("更新母批剩余数量失败!", this);
            return;
        }

        if (result != "success" || resultsplit != "success")
        {
            JScript.Alert("创建贴膜条码失败!", this);
            return;
        }

        //子批过站记录 add by lei.xue on 2017-4-26=========================================
        string strWipinfo = PasteFilm.FilmCheckOut(txtLabelInfo.Text, ddlEqp.SelectedValue, ddlWorkshop.SelectedValue, lblWorksiteID.Text, System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString());
        if (strWipinfo == "fail")
        {
            JScript.Alert("子批过站记录失败!", this);
            return;
        }
        ClientScript.RegisterStartupScript(ClientScript.GetType(), "myscript", "<script>PrintLabel('" + txtLabelInfo.Text + "','../Product/PasteFilm.aspx','" + txtProductType.Text + "');</script>");
        //JScript.Alert("创建贴膜条码成功!", this);
    }
Ejemplo n.º 8
0
    private void CheckPackage()
    {
        string originalLot = "";
        //判断是否是UV成型的条码
        string check = CRUD.CheckFilmLabel("UV成型", txtLot.Text);

        if (check != "fail")
        {
            originalLot = check;
        }
        else
        {
            originalLot = txtLot.Text;
        }
        ViewState["originalLot"] = originalLot;

        DataTable lotDt = CRUD.GetLotBasisInfo(originalLot);

        if (lotDt.Rows.Count == 0)
        {
            JScript.Alert("未找到条码信息", this);
            return;
        }
        string isPackage = lotDt.Rows[0]["package"].ToString();

        if (isPackage != "Y")
        {
            JScript.Alert("批次未包装", this);
            return;
        }
        string workshop = lotDt.Rows[0]["workshopID"].ToString();
        //膜等级
        //txtFilmLevel.Text = lotDt.Rows[0]["mouldlevel"].ToString();
        //setddl(workshop);

        string WO = lotDt.Rows[0]["workorder"].ToString();

        //显示批次长宽信息
        txtPreWidth.Text = lotDt.Rows[0]["mouldwidth"].ToString();
        //前站长度改为有效长度 modify by lei.xue on 2017-10-19
        //txtPreLength.Text = lotDt.Rows[0]["mouldlength"].ToString();
        txtPreLength.Text = lotDt.Rows[0]["validlength"].ToString();
        txtLevel.Text     = lotDt.Rows[0]["filmlevel"].ToString();

        //增加有效幅宽
        txtValidWidth.Text = lotDt.Rows[0]["validwidth"].ToString();

        lotDt = null;
        lotDt = Package.GetPackaInfo(originalLot);
        if (lotDt.Rows.Count > 0)
        {
            txtPinHao.Text              = lotDt.Rows[0]["PinHao"].ToString();
            txtAfterPackageWeight.Text  = lotDt.Rows[0]["AfterPackageWeight"].ToString();
            txtBeforePackageWeight.Text = lotDt.Rows[0]["BeforePackageWeight"].ToString();
        }
        else
        {
            JScript.Alert("未查询到品号", this);
        }
        //显示打印标签时间
        string[] LabelTime = FilmCRUD.GetLabelTime(txtLot.Text);
        txtSubsectionDate.Text = LabelTime[0];
        txtPasteFilmDate.Text  = LabelTime[1];
        txtUVCompleteDate.Text = LabelTime[2];
        //显示工单信息
        SetWOinfo(WO);
        //批次已过站点
        string WorksiteIDOfLot = CRUD.GetWorksite(originalLot);
        //查询批次流程
        string    strFlow = "";
        DataTable dt      = CRUD.GetWorkflow(originalLot);

        for (int i = 0; i < dt.Rows.Count; i++)
        {
            if (WorksiteIDOfLot == dt.Rows[i]["worksiteID"].ToString())
            {
                strFlow = strFlow + "[" + dt.Rows[i]["worksitename"].ToString() + "]" + "->";
            }
            else
            {
                strFlow = strFlow + dt.Rows[i]["worksitename"].ToString() + "->";
            }
        }
        if (strFlow != "")
        {
            strFlow = strFlow.Remove((strFlow).Length - 2, 2);
        }
        lblLotprocess.Text = strFlow;
    }
Ejemplo n.º 9
0
    protected void btnSaveClose_Click(object sender, EventArgs e)
    {
        //string result = UVComplete.FilmCheckOut(txtLot.Text,
        //                      txtLabelInfo.Text,
        //                      ddlEqp.SelectedValue,
        //                      ddlWorkshop.SelectedValue,
        //                      lblWorksiteID.Text,
        //                      System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
        //                      txtPreLength.Text,
        //                      txtPreWidth.Text,
        //                      txtRestLength.Text,
        //                      txtSplitLength.Text,
        //                      txtMouldLot.Text,
        //                      txtDKWidth.Text,
        //                      txtMouldStructure.Text,
        //                      txtMouldPitch.Text,
        //                      ddlGlueType.SelectedValue
        //                      );

        //if (result == "success")
        //{
        //    JScript.Alert("UV成型过站成功!", this);
        //    //ClearInfo();
        //    //打印标签调用前台方法
        //    //ClientScript.RegisterStartupScript(ClientScript.GetType(), "myscript", "<script>PrintLabel();</script>");
        //    ClientScript.RegisterStartupScript(ClientScript.GetType(), "myscript", "<script>PrintLabel('" + txtLabelInfo.Text + "','../Product/UVComplete.aspx');</script>");
        //    return;
        //}
        //else
        //{
        //    JScript.Alert("UV成型过站失败!", this);
        //    return;
        //}

        #region//分批条码改为手动输入,判断条码是否已经存在 add by lei.xue on 2017-4-18
        string strExistSubLot = FilmCRUD.ExistSublot(txtLot.Text, txtLabelInfo.Text);
        if (strExistSubLot == "success")
        {
            JScript.Alert("该分批条码已经存在", this);
            return;
        }
        #endregion

        #region//插入basis表 , 更新母批剩余数量 ,子批flowidno为当点站===========================================

        //==============不分批子批长度取母批的长度 modify by lei.xue on 2017-5-28==================================
        string SplitLength = "";
        if (cbxSplit.Checked == true)
        {
            SplitLength = txtSplitLength.Text;
        }
        else
        {
            //母批直接分批的时候改为分批长度取剩余长度 modify by lei.xue on 2017-8-19
            //SplitLength = txtPreLength.Text;
            SplitLength = txtRestLength.Text;
        }

        LotBasisDatalist dl = new LotBasisDatalist();
        DataTable        dt = (DataTable)ViewState["lotDt"];
        dl.flowid          = dt.Rows[0]["flowid"].ToString();
        dl.workshopid      = ddlWorkshop.SelectedValue;
        dl.lottype         = "Film";
        dl.status          = "Active";
        dl.createuser      = System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString();
        dl.currentflowidno = (Convert.ToInt32(dt.Rows[0]["flowidno"].ToString()) + 1).ToString(); //流程编号加1
        dl.factoryid       = "";
        dl.workorder       = ViewState["WO"].ToString();
        dl.reworkorder     = "";
        dl.lotid           = txtLabelInfo.Text;
        dl.lotcount        = dt.Rows[0]["lotcount"].ToString();
        dl.ProcessComplete = "N";
        //dl.UVCompleteLotid = txtLot.Text;
        dl.length = SplitLength;             //txtSplitLength.Text;
        //================剩余长度和宽度为母批的有效长度和宽度modify by lei.xue on 2017-6-1=============
        dl.restlength = txtValidLength.Text; //SplitLength;//txtSplitLength.Text;
        dl.width      = txtPreWidth.Text;
        dl.restwidth  = txtValidWidth.Text;  //txtPreWidth.Text;
        dl.Filmlevel  = "A";

        dl.eqpid = ddlEqp.SelectedValue;
        //增加有效幅宽 add by lei.xue on 2017-4-18=================================================
        dl.validwidth = txtValidWidth.Text;
        //================增加有效长度 add by lei.xue on 2017-5-28=================================
        dl.validlength = txtValidLength.Text;
        string result = CreateMouldLot.InsertLot(dl);
        if (result != "success")
        {
            JScript.Alert(result, this);
            return;
        }
        #endregion
        #region//插入分批记录到分批表===============================================================
        dl.sublotid = txtLabelInfo.Text;
        dl.lotid    = txtLot.Text;
        string resultsplit = PasteFilm.InsertSplitLot(dl);
        #endregion

        #region//更新母批剩余数量===================================================================
        Decimal rest    = Convert.ToDecimal(txtRestLength.Text) - Convert.ToDecimal(SplitLength);
        string  strRest = PasteFilm.UpdateParentQty(txtLot.Text, rest.ToString(), "Length");
        if (strRest != "success")
        {
            JScript.Alert("更新母批剩余数量失败!", this);
            return;
        }
        #endregion
        #region//记录绑定的模具信息和胶水规格 modify by lei.xue on 2017-3-27================================
        string resultWipInfo = UVComplete.FilmCheckOut(txtLabelInfo.Text,
                                                       "",
                                                       ddlEqp.SelectedValue,
                                                       ddlWorkshop.SelectedValue,
                                                       lblWorksiteID.Text,
                                                       System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
                                                       txtMouldLot.Text,
                                                       txtDKWidth.Text,
                                                       txtMouldStructure.Text,
                                                       txtMouldPitch.Text,
                                                       ddlGlueType.SelectedValue
                                                       );
        if (strRest != "success")
        {
            JScript.Alert("记录绑定的模具信息和胶水规格失败!", this);
            return;
        }
        #endregion
        if (result != "success" || resultsplit != "success")
        {
            JScript.Alert("创建UV成型条码失败!", this);
            return;
        }
        //ClientScript.RegisterStartupScript(ClientScript.GetType(), "myscript", "<script>PrintLabel('" + txtLabelInfo.Text + "','../Product/UVComplete.aspx');</script>");
        ClientScript.RegisterStartupScript(ClientScript.GetType(), "myscript", "<script>PrintLabel('" + txtLabelInfo.Text + "','../Product/UVComplete.aspx','" + txtProductType.Text + "');</script>");
    }
Ejemplo n.º 10
0
    protected void btnSaveClose_Click(object sender, EventArgs e)
    {
        //string result = CRUD.FilmCheckOut(ViewState["originalLot"].ToString(), txtLot.Text, ddlEqp.SelectedValue, ddlWorkshop.SelectedValue,
        //                    lblWorksiteID.Text,
        //                    System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
        //                    ddlFilmLevel.SelectedValue);
        //string resultLevel = "";
        //if (cbxUpdateLevel.Checked == true)
        //{
        //    resultLevel = CRUD.updateFilmLevel(txtFilmLevel.Text,
        //                                              ddlFilmLevel.SelectedValue,
        //                                              ViewState["originalLot"].ToString(),
        //                                              System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
        //                                              lblWorksiteID.Text
        //                                              );
        //}
        string strCheck     = ""; //存放检验结果变量
        string strFilmLevel = ""; //模具等级变量
        string result       = CRUD.FilmCheckOut(ViewState["originalLot"].ToString(), txtLot.Text, ddlEqp.SelectedValue, ddlWorkshop.SelectedValue,
                                                lblWorksiteID.Text,
                                                System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
                                                ddlFilmLevel.SelectedValue);
        string resultLevel = "";

        if (cbxUpdateLevel.Checked == true)//膜检验结果为NG
        {
            strCheck     = "NG";
            strFilmLevel = ddlFilmLevel.SelectedValue;
            resultLevel  = CRUD.updateFilmLevel(txtFilmLevel.Text,
                                                ddlFilmLevel.SelectedValue,
                                                ViewState["originalLot"].ToString(),
                                                System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
                                                lblWorksiteID.Text
                                                );
        }
        else
        {
            strCheck     = "OK";
            strFilmLevel = txtFilmLevel.Text;
        }

        #region//检验项目=====================================================================================
        AGCoatingQCDatalist Datalist = new AGCoatingQCDatalist();

        //外观
        //1外观左
        Datalist.appearanceleft = txtAppearanceLeft.Text;
        //2外观右
        Datalist.appearanceright  = txtAppearanceRight.Text;
        Datalist.appearanceresult = ddlAvailableWidthResult.SelectedValue;
        //可用宽幅
        Datalist.availablewidth       = txtAvailableWidth.Text;
        Datalist.availablewidthresult = ddlAvailableWidthResult.SelectedValue;
        //纹路
        Datalist.lines       = txtLines.Text;
        Datalist.linesresult = ddlLinesResult.Text;
        //正面保护膜张力
        Datalist.FrontTension       = txtFrontTension.Text;
        Datalist.FrontTensionResult = ddlFrontTensionResult.Text;
        //背面保护膜张力
        Datalist.BackTension       = txtBackTension.Text;
        Datalist.BackTensionResult = ddlBackTensionResult.Text;
        //点线
        Datalist.dotline       = txtDotLine.Text;
        Datalist.dotlineResult = ddlDotLineResult.Text;

        //string QCResult = AGCoatingCheck.CheckInfo(txtLot.Text,
        //                                  ddlEqp.SelectedValue,
        //                                  lblWorksiteID.Text,
        //                                  strCheck,
        //                                  System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
        //                                  strFilmLevel,
        //                                  Datalist
        //                                  );
        string QCResult = PasteFilmCheck.CheckInfo(txtLot.Text,
                                                   ddlEqp.SelectedValue,
                                                   lblWorksiteID.Text,
                                                   strCheck,
                                                   System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
                                                   strFilmLevel,
                                                   Datalist
                                                   );
        if (QCResult == "fail")
        {
            JScript.Alert("记录检验项目失败", this);
            return;
        }
        #endregion
        //跳分条流程
        if (CbxChangeFlow.Checked == true)
        {
            string UpdataFlow = "";
            UpdataFlow = FilmCRUD.QuerySubsectionFlowID(txtLot.Text);
            string resultFlow = CRUD.ChangLotWorkflow(UpdataFlow, txtLot.Text);
            if (resultFlow != "success")
            {
                JScript.Alert("变更产品流程出错!", this);
                return;
            }
        }

        if (result == "success" && resultLevel != "fail")
        {
            //JScript.Alert("UV成型检验过站成功!", this);
            JScript.AlertAndRedirect("贴膜检验过站成功!", "PasteFilmCheck.aspx", this);
            //ClearInfo();
            return;
        }
        else
        {
            JScript.Alert("贴膜检验过站失败!", this);
            return;
        }
    }
Ejemplo n.º 11
0
    protected void btnSaveClose_Click(object sender, EventArgs e)
    {
        //string result = CRUD.FilmCheckOut(ViewState["originalLot"].ToString(), txtLot.Text, ddlEqp.SelectedValue, ddlWorkshop.SelectedValue,
        //                    lblWorksiteID.Text,
        //                    System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
        //                    ddlFilmLevel.SelectedValue);
        //string resultLevel = "";
        //if (cbxUpdateLevel.Checked == true)
        //{
        //    resultLevel = CRUD.updateFilmLevel(txtFilmLevel.Text,
        //                                              ddlFilmLevel.SelectedValue,
        //                                              ViewState["originalLot"].ToString(),
        //                                              System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
        //                                              lblWorksiteID.Text
        //                                              );
        //}
        string strCheck     = ""; //存放检验结果变量
        string strFilmLevel = ""; //模具等级变量
        string result       = CRUD.FilmCheckOut(ViewState["originalLot"].ToString(), txtLot.Text, ddlEqp.SelectedValue, ddlWorkshop.SelectedValue,
                                                lblWorksiteID.Text,
                                                System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
                                                ddlFilmLevel.SelectedValue);
        string resultLevel = "";

        if (cbxUpdateLevel.Checked == true)//膜检验结果为NG
        {
            strCheck     = "NG";
            strFilmLevel = ddlFilmLevel.SelectedValue;
            resultLevel  = CRUD.updateFilmLevel(txtFilmLevel.Text,
                                                ddlFilmLevel.SelectedValue,
                                                ViewState["originalLot"].ToString(),
                                                System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
                                                lblWorksiteID.Text
                                                );
        }
        else
        {
            strCheck     = "OK";
            strFilmLevel = txtFilmLevel.Text;
        }

        #region//检验项目=====================================================================================
        AGCoatingQCDatalist Datalist = new AGCoatingQCDatalist();
        //厚度
        Datalist.thinknessleft   = txtThinknessLeft.Text;
        Datalist.thinknessmiddle = txtThinknessMiddle.Text;
        Datalist.thinknessright  = txtThinknessRight.Text;
        Datalist.thinknessresult = ddlThinknessResult.SelectedValue;
        //翘曲变形
        Datalist.buckling       = txtBuckling.Text;
        Datalist.bucklingresult = ddlBucklingResult.SelectedValue;
        //MD雾度
        Datalist.MDhaze       = txtMDHaze.Text;
        Datalist.MDhazeresult = ddlMDHazeResult.SelectedValue;
        //MD穿透率
        Datalist.MDpenetration       = txtPenetrance.Text;
        Datalist.MDpenetrationresult = ddlPenetranceResult.SelectedValue;
        //增加TD雾度和穿透率 add by lei.xue on 2017-4-18==========================================
        //TD雾度
        Datalist.TDhaze       = txtTDHaze.Text;
        Datalist.TDhazeresult = ddlTDHazeResult.SelectedValue;
        //TD穿透率
        Datalist.TDpenetration       = txtTDPenetrance.Text;
        Datalist.TDpenetrationresult = ddlTDPenetranceResult.SelectedValue;
        //外观
        //1外观左
        Datalist.appearanceleft = txtAppearanceLeft.Text;
        //2外观右
        Datalist.appearanceright  = txtAppearanceRight.Text;
        Datalist.appearanceresult = ddlAvailableWidthResult.SelectedValue;
        //可用宽幅
        Datalist.availablewidth       = txtAvailableWidth.Text;
        Datalist.availablewidthresult = ddlAvailableWidthResult.SelectedValue;
        //纹路
        Datalist.lines       = txtLines.Text;
        Datalist.linesresult = ddlLinesResult.Text;
        //高低差
        //1dH
        Datalist.HeightDifferenceDH = txtHeightDifferenceDH.Text;
        //2Rz
        Datalist.HeightDifferenceRz     = txtHeightDifferenceRZ.Text;
        Datalist.HeightDifferenceResult = ddlHeightDifferenceResult.SelectedValue;
        //百格
        Datalist.baige       = txtBaige.Text;
        Datalist.baigeresult = ddlBaigeResult.SelectedValue;
        //铅笔硬度正面
        Datalist.pencilhardnessFront       = txtPencilHardnessFront.Text;
        Datalist.pencilhardnessFrontresult = ddlPencilHardnessFrontResult.SelectedValue;
        //铅笔硬度背面
        Datalist.pencilhardnessBack       = txtPencilHardnessBack.Text;
        Datalist.pencilhardnessBackresult = ddlPencilHardnessBackResult.SelectedValue;
        //辉度增益比
        Datalist.brilliancy       = txtBrilliancy.Text;
        Datalist.brilliancyResult = ddlBrilliancyResult.SelectedValue;

        //string QCResult = AGCoatingCheck.CheckInfo(txtLot.Text,
        //                                  ddlEqp.SelectedValue,
        //                                  lblWorksiteID.Text,
        //                                  strCheck,
        //                                  System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
        //                                  strFilmLevel,
        //                                  Datalist
        //                                  );
        string QCResult = UVCompleteCheck.CheckInfo(txtLot.Text,
                                                    ddlEqp.SelectedValue,
                                                    lblWorksiteID.Text,
                                                    strCheck,
                                                    System.Web.HttpContext.Current.Request.Cookies["userID"].Value.ToString(),
                                                    strFilmLevel,
                                                    Datalist
                                                    );
        if (QCResult == "fail")
        {
            JScript.Alert("记录检验项目失败", this);
            return;
        }
        #endregion
        //跳分条流程
        if (CbxChangeFlow.Checked == true)
        {
            string UpdataFlow = "";
            UpdataFlow = FilmCRUD.QuerySubsectionFlowID(txtLot.Text);
            string resultFlow = CRUD.ChangLotWorkflow(UpdataFlow, txtLot.Text);
            if (resultFlow != "success")
            {
                JScript.Alert("变更产品流程出错!", this);
                return;
            }
        }
        if (result == "success" && resultLevel != "fail")
        {
            //JScript.Alert("UV成型检验过站成功!", this);
            JScript.AlertAndRedirect("UV成型检验过站成功!", "UVCompleteCheck.aspx", this);
            //ClearInfo();
            return;
        }
        else
        {
            JScript.Alert("UV成型检验过站失败!", this);
            return;
        }
    }