예제 #1
0
        /// <summary>
        /// 获取SN编码类型
        /// </summary>
        /// <param name="_sn"></param>
        /// <returns></returns>
        public Maticsoft.Model.E_PigtailType Get_PigtailType(string _sn)
        {
            Maticsoft.DAL.User_3D_Test_Good _M_User_3D = new User_3D_Test_Good();
            Maticsoft.Model.E_PigtailType   _Type;
            DataSet temds = _M_User_3D.GetList("SN IN " + _sn + "");

            if (temds.Tables[0].Rows.Count != 0)
            {
                string _temType = temds.Tables[0].Rows[0]["Type"].ToString();
                if (_temType != "")
                {
                    string te = "";
                    if (_temType.Length >= 3)
                    {
                        te = _temType.Substring(0, 3);
                    }
                    if (te == "APC")
                    {
                        _Type = Model.E_PigtailType.APC;
                    }
                    else
                    {
                        _Type = Model.E_PigtailType.PC;
                    }
                }
                else
                {
                    _Type = Model.E_PigtailType._Null;
                }
                return(_Type);
            }
            else
            {
                return(Model.E_PigtailType._Null);
            }
        }
예제 #2
0
파일: SPC.cs 프로젝트: radtek/EicMcp
        //获取指定日期的数据
        private DataSet GetData_SPC(string _Parameter, string _date)
        {
            Maticsoft.DAL.User_3D_Test_Good  _M_GetTestData = new User_3D_Test_Good();
            Maticsoft.DAL.User_JDS_Test_Good _M_ExfoData    = new User_JDS_Test_Good();

            //APC 3D数据
            if (_Parameter == Maticsoft.Model.E_Generate.APC_Angle.ToString() ||
                _Parameter == Maticsoft.Model.E_Generate.APC_Curvature.ToString() ||
                _Parameter == Maticsoft.Model.E_Generate.APC_Spherucak.ToString() ||
                _Parameter == Maticsoft.Model.E_Generate.APC_Offset.ToString()
                )
            {
                return(_M_GetTestData.Get_SPC(_date, "APC"));
            }
            //PC 3D数据
            else if (_Parameter == Maticsoft.Model.E_Generate.PC_Curvature.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.PC_Spherucak.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.PC_Offset.ToString()
                     )
            {
                return(_M_GetTestData.Get_SPC(_date, "PC"));
            }
            //Exfo测试数据 1300
            else if (_Parameter == Maticsoft.Model.E_Generate.IL_1300nm.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.RL_1300nm.ToString())
            {
                return(_M_ExfoData.Get_SPC("1300nm", _date));
            }
            //Exfo测试数据 1300
            else if (_Parameter == Maticsoft.Model.E_Generate.IL_1310nm.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.RL_1310nm.ToString())
            {
                return(_M_ExfoData.Get_SPC("1310nm", _date));
            }
            //Exfo测试数据 1300
            else if (_Parameter == Maticsoft.Model.E_Generate.IL_1550nm.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.RL_1550nm.ToString())
            {
                return(_M_ExfoData.Get_SPC("1550nm", _date));
            }
            //Exfo测试数据 1300
            else if (_Parameter == Maticsoft.Model.E_Generate.IL_850nm.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.RL_850nm.ToString())
            {
                return(_M_ExfoData.Get_SPC("850nm", _date));
            }
            //Adapter 测试 SPC
            else if (_Parameter == Maticsoft.Model.E_Generate.Adapter_Test.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.Adapter_Testfour0.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.Adapter_Testfour90.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.Adapter_Testfour180.ToString() ||
                     _Parameter == Maticsoft.Model.E_Generate.Adapter_Testfour270.ToString()
                     )
            {
                Maticsoft.DAL.AdapterTestData _M_adaTestdata = new AdapterTestData();
                return(_M_adaTestdata.Get_SPC(_date));
            }

            //MPO_EXFO数据
            else if (_Parameter == "MPO_Il_850nm" || _Parameter == "MPO_Il_1310nm" || _Parameter == "MPO_Refl_850nm" || _Parameter == "MPO_Refl_1310nm") //JDS数据
            {
                if (_Parameter == "MPO_Il_850nm" || _Parameter == "MPO_Refl_850nm")
                {
                    Maticsoft.DAL.User_JDS_Test_Good ujs = new User_JDS_Test_Good();
                    return(ujs.Get_MPO_SPC("850nm", _date));
                }
                else
                {
                    Maticsoft.DAL.User_JDS_Test_Good ujs = new User_JDS_Test_Good();
                    return(ujs.Get_MPO_SPC("1310nm", _date));
                }
            }

            //MPO_3D数据 APC
            else if (_Parameter == "MPO_YEndFaceAngle_APC")
            {
                _Parameter = "YEndFaceAngle";
                Maticsoft.DAL.MultiFiber _MultiFiber = new MultiFiber();
                return(_MultiFiber.GetList(_Parameter, _date, "8")); //APC
            }
            // MPO_3D 数据
            else
            {
                _Parameter = Get_Parameter(_Parameter);
                Maticsoft.DAL.MultiFiber _MultiFiber = new MultiFiber();
                return(_MultiFiber.GetList(_Parameter, _date, "0")); //PC
            }
        }