diff --git a/B3SheepButcherManage/BL/Bill/WeightBillBL/WeightBillBL.cs b/B3SheepButcherManage/BL/Bill/WeightBillBL/WeightBillBL.cs index 38469eb..253079a 100644 --- a/B3SheepButcherManage/BL/Bill/WeightBillBL/WeightBillBL.cs +++ b/B3SheepButcherManage/BL/Bill/WeightBillBL/WeightBillBL.cs @@ -96,16 +96,14 @@ namespace BWP.B3SheepButcherManage.BL { statPay.MoneyCountMethod = dmo.MoneyCountMethod.Value; } - if (dmo.WeighAbnormalRecording.Count > 0) + foreach (var abnormal in dmo.WeighAbnormalRecording) { - foreach (var abnormal in dmo.WeighAbnormalRecording) - { - var exception = new StatPay_Exception(); - exception.RewardItem_ID = abnormal.RewardItem_ID; - // exception.Price = abnormal; - exception.Money = (decimal?)abnormal.Abnormal_Money; - statPay.ExceptionDetails.Add(exception); - } + var exception = new StatPay_Exception(); + exception.RewardItem_ID = abnormal.RewardItem_ID; + exception.Number = abnormal.Number; + exception.Price = abnormal.Price; + exception.Money = abnormal.Abnormal_Money; + statPay.ExceptionDetails.Add(exception); } bl.Insert(statPay); @@ -173,7 +171,7 @@ namespace BWP.B3SheepButcherManage.BL var updatedom = new DQUpdateDom(typeof(WeightBill_Record)); updatedom.Where.Conditions.Add(DQCondition.EQ("ID", weighDetailID)); - long weightid = InnerBLUtil.GetDmoPropertyByID(Session, typeof(WeightBill_Record), "WeightBill_ID", weighDetailID); + long weightid = InnerBLUtil.GetDmoPropertyByID(Session, typeof(WeightBill_Record), "WeightBill_ID", weighDetailID); updatedom.Columns.Add(new DQUpdateColumn("PlanNumber", planNumber));//已计划头数 updatedom.Columns.Add(new DQUpdateColumn("ButcherNumber", butcherNumber)); //已屠宰