internal static void PrePareTargetbyCell_InTarget(MergedPegPart mg) { List <PegPart> list = new List <PegPart>(mg.Items); foreach (FabPegPart pp in list) { string arrayCode = CellCodeMaster.GetArrayCode(pp.Product.ProductID); string cfCode = CellCodeMaster.GetCfCode(pp.Product.ProductID); var arrayProd = BopHelper.FindProduct(Constants.ArrayShop, arrayCode); var cfProd = BopHelper.FindProduct(Constants.CF, cfCode); if (arrayProd == null || cfProd == null) { ErrHist.WriteIf(string.Format("BuildFabOutTarget{0}", pp.Product.ProductID), ErrCategory.PEGGING, ErrLevel.ERROR, pp.Current.Step.FactoryID, pp.Current.Step.ShopID, Constants.NULL_ID, pp.Product.ProductID, Constants.NULL_ID, Constants.NULL_ID, Constants.NULL_ID, pp.Current.ShopID, "NOT FOUND PRODUCT", string.Format("Do not build TFT OutTarget") ); mg.Items.Remove(pp); continue; } FabStep arrayStep = BopHelper.GetSafeDummyStep(pp.Current.FactoryID, Constants.ArrayShop, "0000"); FabStep cfStep = BopHelper.GetSafeDummyStep(pp.Current.FactoryID, Constants.CfShop, "0000"); FabPegPart cfPP = PegMaster.CreateCellBankPegPart(pp, cfProd); cfPP.AddCurrentPlan(cfProd, cfStep); pp.AddCurrentPlan(arrayProd, arrayStep); pp.Product = arrayProd; foreach (FabPegTarget pt in pp.PegTargetList) { pt.TargetKey = PegHelper.CreateTargetKey(pt.TargetKey, arrayProd.ProductID.Substring(0, 2)); } mg.Items.Add(cfPP); } }
private static void AddOut(OutInfo info) { var outProfiles = InOutProfileMaster.OutProfiles; var key = LcdHelper.CreateKey(info.ProductID, info.ProductVersion, info.OwnerType); FabOutProfile op; if (outProfiles.TryGetValue(key, out op) == false) { op = CreateHelper.CreateFabOutProfile(info); outProfiles.Add(key, op); //set matched cell info op.CellCodeList = CellCodeMaster.GetCellCodeList(info.ProductID); } AddInfo(op.Infos, info); }