/// <summary> /// 包材取消和确认 /// </summary> /// <param name="so"></param> /// <param name="isConfirm"></param> public static void ConfirmSubItem(long so, bool isConfirm) { UFIDA.U9.Cust.GS.FT.SoBomBP.Proxy.ConfirmSuItemBPProxy bp = new SoBomBP.Proxy.ConfirmSuItemBPProxy(); bp.SOKey = so; bp.IsConfirm = isConfirm; bp.Do(); }
private void ConfirmSubItem(bool isConfirm) { UFIDA.U9.Cust.GS.FT.SoBomBP.Proxy.ConfirmSuItemBPProxy bp = new SoBomBP.Proxy.ConfirmSuItemBPProxy(); List <long> ids = new List <long>(); foreach (OrderBomHeadRecord record in this.Model.OrderBomHead.SelectRecords) { bool IsSupplyPlan = record.IsSupplyPlan ?? false; bool isCon = record.ArrirmState ?? false; if (IsSupplyPlan) { continue; } if (isConfirm == true && isCon == true) { continue; } if (isConfirm == false && isCon == false) { continue; } ids.Add(record.ID); } if (ids.Count == 0) { throw new Exception("没有选择有效的数据"); } bp.BOMLineKeyList = ids; bp.IsConfirm = isConfirm; bp.Do(); }