Esempio n. 1
0
        /// <summary>
        /// 添加不合格信息
        /// </summary>
        public override void AddQuaniltyData()
        {
            string code = Convert.ToString(setNameTxt.Tag);

            if (code.Length > 3)
            {
                SortedList setBarCodes = new SortedList();
                string     areaNum     = "2";
                Dictionary <string, string> procedureInfo = ProcedureData.Instance.GetProcedureData(PdCode);
                if (procedureInfo != null && procedureInfo.Count > 0)
                {
                    if (procedureInfo.ContainsKey("pd_Type"))
                    {
                        areaNum = procedureInfo["pd_Type"];
                    }
                }
                setBarCodes.Add(1, code);
                Dictionary <string, string> data = new Dictionary <string, string>();
                data.Add("SetName", setNameTxt.Text);
                data.Add("SetCode", Convert.ToString(setNameTxt.Tag));
                data.Add("SetId", _setId);
                HCSSM_statistics_quality_new qualityDialog = new HCSSM_statistics_quality_new();
                qualityDialog.Area      = areaNum;
                qualityDialog.ErrorType = 0;
                qualityDialog.Data      = data;
                //qualityDialog.BarCodeList = setBarCodes;
                qualityDialog.ShowDialog();
            }
        }
        private void statisisInfoBtn_Click(object sender, EventArgs e)
        {
            Dictionary <string, string>  data          = new Dictionary <string, string>();
            HCSSM_statistics_quality_new qualityDialog = new HCSSM_statistics_quality_new();

            data.Add("SetName", txtOrderName.Text);
            data.Add("SetCode", txtOrderNum.Text);
            data.Add("SetId", Convert.ToString(txtOrderNum.Tag));
            qualityDialog.Data = data;
            qualityDialog.Area = "3";
            qualityDialog.ShowDialog();
        }
Esempio n. 3
0
        public virtual void AddQuaniltyData()
        {
            DataGridView setDataGrid = CnasUtilityTools.FindControl <DataGridView>(this, "setDataGrid");
            SortedList   setBarCodes = new SortedList();
            string       areaNum     = "2";
            Dictionary <string, string> procedureInfo = ProcedureData.Instance.GetProcedureData(PdCode);

            if (procedureInfo != null && procedureInfo.Count > 0)
            {
                if (procedureInfo.ContainsKey("pd_Type"))
                {
                    areaNum = procedureInfo["pd_Type"];
                }
            }
            try
            {
                if (setDataGrid != null && setDataGrid.SelectedRows != null && setDataGrid.SelectedRows.Count > 0 && setDataGrid.SelectedRows[0].Tag is DataRow)
                {
                    TextBox machinTxt = CnasUtilityTools.FindControl <TextBox>(this, "machineTxt");

                    DataRow rowData = setDataGrid.SelectedRows[0].Tag as DataRow;

                    Dictionary <string, string> data = new Dictionary <string, string>();
                    data.Add("SetName", rowData.Table.Columns.Contains("ca_name") ? Convert.ToString(rowData["ca_name"]) : string.Empty);
                    data.Add("SetCode", rowData.Table.Columns.Contains("bar_code") ? Convert.ToString(rowData["bar_code"]) : string.Empty);
                    data.Add("SetId", rowData.Table.Columns.Contains("id") ? Convert.ToString(rowData["id"]) : string.Empty);
                    data.Add("DevId", machinTxt != null ? Convert.ToString(machinTxt.Tag) : string.Empty);
                    data.Add("DevName", machinTxt != null ? machinTxt.Text : string.Empty);
                    HCSSM_statistics_quality_new qualityDialog = new HCSSM_statistics_quality_new();
                    qualityDialog.Area = areaNum;
                    if (WorkflowServer.Unload_container_wf.Contains(string.Format("{0},", PdCode)))
                    {
                        qualityDialog.ErrorType = WorkflowServer.Release_sterilizer_wf.Contains(string.Format("{0},", PdCode)) ? 2 : 1;
                    }

                    qualityDialog.Data = data;
                    qualityDialog.ShowDialog();
                }
            }
            catch (Exception)
            {
            }
        }