diff --git a/ICSSoft.ERP.WebAPI/ICSSoft.DataProject/PurchaseReceiveDoc.cs b/ICSSoft.ERP.WebAPI/ICSSoft.DataProject/PurchaseReceiveDoc.cs index b673ba0..947ec54 100644 --- a/ICSSoft.ERP.WebAPI/ICSSoft.DataProject/PurchaseReceiveDoc.cs +++ b/ICSSoft.ERP.WebAPI/ICSSoft.DataProject/PurchaseReceiveDoc.cs @@ -555,23 +555,7 @@ EXEC PROC_Update_PO_RdRecord01 @ID= @ID1 throw new Exception("生成采购入库单表体失败!异常:" + ex.Message + ";SQL:\r\n" + sql, ex); } #endregion - #region 更新[采购到货单子表]PU_ArrivalVouchs 合格品入库数量20211019 - sql = @"UPDATE PU_ArrivalVouchs SET fValidInQuan=ISNULL(fValidInQuan,0)+@iQty WHERE Autoid=@Autoid"; - cmd.CommandText = sql; - cmd.Parameters.Clear(); - cmd.Parameters.Add(new SqlParameter("@iQty", body.Quantity)); - cmd.Parameters.Add(new SqlParameter("@Autoid", body.DNDetailID)); - try - { - log.Info("PU_Autoid:" + body.DNDetailID); - cmd.ExecuteNonQuery(); - } - catch (Exception ex) - { - log.Error("回写采购到货单子表合格品入库数量失败:Autoid:" + body.DNDetailID + ";异常:" + ex.Message); - throw new Exception("程序异常,请联系开发人员!"); - } - #endregion + #region 更新[采购订单子表]PO_PODetails累计到货数量和累计到货金额 //sql = @"Update a set iReceivedQTY =isnull(iReceivedQTY ,0)+ @iQty,iReceivedMoney=isnull(iReceivedMoney,0)+@iMoney FROM dbo.PO_Podetails a where a.ID='" + body.iPOsID + "'"; @@ -591,7 +575,7 @@ EXEC PROC_Update_PO_RdRecord01 @ID= @ID1 cmd.Parameters.Add(new SqlParameter("@ID", body.PODetailID)); try { - log.Info("iPOsID:" + body.PODetailID); + log.Info("ID:" + body.PODetailID); int i = cmd.ExecuteNonQuery(); } catch (Exception ex)