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); } }
/// <summary> /// </summary> /// <param name="pegPart"/> /// <param name="partChangeInfo"/> /// <param name="isRun"/> /// <param name="handled"/> /// <param name="prevReturnValue"/> /// <returns/> public PegPart APPLY_PART_CHANGE_INFO0(PegPart pegPart, object partChangeInfo, bool isRun, ref bool handled, PegPart prevReturnValue) { FabInterBom bom = partChangeInfo as FabInterBom; FabPegPart pp = pegPart.ToFabPegPart(); pp.AddCurrentPlan(bom.Product, bom.CurrentStep); pp.Product = bom.ChangeProduct; pp.InterBom = bom; return(pp); }
public static void AddCurrentPlan(this FabPegPart pp, FabProduct prod, FabStep step) { if (prod == null || step == null) { //TODO : Write Error return; } PlanStep plan = new PlanStep(); plan.Product = prod; plan.Step = step; plan.isDummy = step.IsDummy; pp.AddCurrentPlan(plan); }
internal static Step GetPrevPeggingStep(PegPart pegPart, Step currentStep) { Step prevStep = currentStep.GetDefaultPrevStep(); FabPegPart pp = pegPart.ToFabPegPart(); if (pp.HasInterBom) { prevStep = pp.InterBom.ChangeStep; pp.InterBom = null; } pp.AddCurrentPlan(pp.FabProduct, prevStep as FabStep); return(prevStep); }
internal static Step GetLastPeggingStgep(PegPart pegPart) { FabPegPart pp = pegPart as FabPegPart; FabProduct product = pp.Product as FabProduct; Step step = product.Process.LastStep; pp.AddCurrentPlan(product, step as FabStep); //StepTarget 추가기록 foreach (FabPegTarget pt in pp.PegTargetList) { PegHelper.WriteStepTarget(pt, true, Constants.OUT, true); } return(step); }
public Step GETPREVPEGGINGSTEP(PegPart pegPart, Step currentStep) { if (InputMart.Instance.GlobalParameters.ApplyCellOutPlan == false) { return(null); } FabPegPart pp = pegPart.ToFabPegPart(); if (pp.Current.StepID == "0000") { string stepID = BopHelper.IsArrayShop(pp.FabProduct.ShopID) ? "9900" : "9990"; FabStep step = BopHelper.GetSafeDummyStep(pp.Current.FactoryID, pp.Current.ShopID, stepID); pp.AddCurrentPlan(pp.FabProduct, step); return(step); } return(null); }