啊鑫
2025-07-10 bcb2bae4c85c5a7d576116ff9ae2a0c6d0011565
MES.Service/service/WomcaaWWManager.cs
@@ -60,6 +60,7 @@
        }
        var orUpdate = base.Insert(mesWomcaa);
        var baOrUpdate = _womcabWWManager.InsertRange(mesWomcabs);
        db.Ado.CommitTran();
        if (orUpdate && baOrUpdate)
        {
            //定义输入参数
@@ -75,11 +76,11 @@
            if (result == 1)
            {
                //存储过程失败则事务进行回滚
                db.Ado.RollbackTran();
                //db.Ado.RollbackTran();
                throw new Exception(message);
            }
            // 提交事务
            db.Ado.CommitTran();
            //db.Ado.CommitTran();
            return true;
        }
        throw new NotImplementedException("插入或更新失败");
@@ -97,7 +98,7 @@
        }
        var orUpdate = base.Insert(mesWomcaa);
        var baOrUpdate = _womcabWWManager.InsertRange(mesWomcabss);
        db.Ado.CommitTran();
        if (orUpdate && baOrUpdate)
        {
            //定义输入参数
@@ -113,11 +114,11 @@
            if (result == 1)
            {
                //存储过程失败则事务进行回滚
                db.Ado.RollbackTran();
                //db.Ado.RollbackTran();
                throw new Exception(message);
            }
            // 提交事务
            db.Ado.CommitTran();
            //db.Ado.CommitTran();
            return true;
        }
@@ -252,7 +253,7 @@
                Denominator = Convert.ToDecimal(dto.FDenominator),
                SCRAPQTY = Convert.ToDecimal(dto.FFixScrapQty),
                SCRAPRATE = Convert.ToDecimal(dto.FScrapRate),
                SalesOrder = dto.FXSHTBH,
                SalesOrder = dto.F_WWC_TEXT,
            };
            var entity = Db.Queryable<Womcab>().Where(s => s.Erpid == womcab.Erpid).Single();