Browse Source

调整接口

master
lilili 2 years ago
parent
commit
e7faaebb54
  1. 8
      ICSSoft.WMS.WebAPI/ICSSoft.DataProject/ICSManufactureService.cs
  2. 8
      ICSSoft.WMS.WebAPI/ICSSoft.DataProject/ICSOutsourcingService.cs
  3. 7
      ICSSoft.WMS.WebAPI/ICSSoft.DataProject/ICSPurchaseService.cs
  4. 6
      ICSSoft.WMS.WebAPI/ICSSoft.DataProject/ICSSubmitService.cs

8
ICSSoft.WMS.WebAPI/ICSSoft.DataProject/ICSManufactureService.cs

@ -249,20 +249,20 @@ namespace ICSSoft.DataProject
/// <param name="Quantity"></param>
/// <param name="WorkPoint"></param>
/// <param name="cmd"></param>
public static void MOApplyHG(string TransCode, string WorkPoint, SqlCommand cmd, Dictionary<string, string> language, string quantity)
public static void MOApplyHG(string TransCode, string WorkPoint, SqlCommand cmd, Dictionary<string, string> language)
{
try
{
decimal iquantity = Convert.ToDecimal(quantity);
string sql = @"IF EXISTS (SELECT ID FROM ICSMOApply WHERE IssueQuantity=Quantity AND ApplyCode='{0}' and WorkPoint='{1}' )
BEGIN
RAISERROR('" + language.GetNameByCode("WMSAPIInfo472") + @"',16,1);
RETURN
END;
UPDATE ICSMOApply set IssueQuantity=IssueQuantity+{2}
UPDATE ICSMOApply set IssueQuantity=Quantity
WHERE ApplyCode='{0}' and WorkPoint='{1}'";
sql = string.Format(sql, TransCode, WorkPoint, iquantity);
sql = string.Format(sql, TransCode, WorkPoint);
if (!DBHelper.ExecuteNonQuery(sql, cmd))
{

8
ICSSoft.WMS.WebAPI/ICSSoft.DataProject/ICSOutsourcingService.cs

@ -213,20 +213,20 @@ namespace ICSSoft.DataProject
/// <param name="Quantity"></param>
/// <param name="WorkPoint"></param>
/// <param name="cmd"></param>
public static void OOApplyHG(string TransCode, string WorkPoint, SqlCommand cmd, Dictionary<string, string> language, string quantity)
public static void OOApplyHG(string TransCode, string WorkPoint, SqlCommand cmd, Dictionary<string, string> language)
{
try
{
decimal iquantity = Convert.ToDecimal(quantity);
string sql = @"IF EXISTS (SELECT ID FROM ICSOApply WHERE IssueQuantity=Quantity AND ApplyCode='{0}' and WorkPoint='{1}')
BEGIN
RAISERROR('" + language.GetNameByCode("WMSAPIInfo472") + @"',16,1);
RETURN
END;
UPDATE ICSOApply set IssueQuantity=IssueQuantity+{2}
UPDATE ICSOApply set IssueQuantity=Quantity
WHERE ApplyCode='{0}' and WorkPoint='{1}'";
sql = string.Format(sql, TransCode, WorkPoint, iquantity);
sql = string.Format(sql, TransCode, WorkPoint);
if (!DBHelper.ExecuteNonQuery(sql, cmd))
{

7
ICSSoft.WMS.WebAPI/ICSSoft.DataProject/ICSPurchaseService.cs

@ -903,20 +903,19 @@ namespace ICSSoft.DataProject
/// <param name="Quantity"></param>
/// <param name="WorkPoint"></param>
/// <param name="cmd"></param>
public static void PurchaseReceiveDoctNegativeHG(string TransCode, string WorkPoint, SqlCommand cmd, Dictionary<string, string> language, string quantity)
public static void PurchaseReceiveDoctNegativeHG(string TransCode, string WorkPoint, SqlCommand cmd, Dictionary<string, string> language)
{
try
{
decimal iquantity = Convert.ToDecimal(quantity);
string sql = @" IF EXISTS (SELECT ID FROM ICSDeliveryNotice WHERE RCVQuantity=Quantity AND DNCode='{0}' AND WorkPoint='{1}' )
BEGIN
RAISERROR('" + language.GetNameByCode("WMSAPIInfo471") + @"',16,1);
RETURN
END;
UPDATE ICSDeliveryNotice SET RCVQuantity=RCVQuantity={2}
UPDATE ICSDeliveryNotice SET RCVQuantity=Quantity
WHERE DNCode='{0}' AND WorkPoint='{1}'";
sql = string.Format(sql, TransCode, WorkPoint, iquantity);
sql = string.Format(sql, TransCode, WorkPoint);
if (!DBHelper.ExecuteNonQuery(sql, cmd))
{

6
ICSSoft.WMS.WebAPI/ICSSoft.DataProject/ICSSubmitService.cs

@ -3474,7 +3474,7 @@ namespace ICSSoft.DataProject
{
BusinessCode = TransTypeEnum.PurchaseReceiveDoctNegative.GetDescription<DBValue>();
//更新源头单据数量
ICSPurchaseService.PurchaseReceiveDoctNegativeHG(JsonData.DATA.EXP_ORDINI[0].ORD_ORDINE, JsonData.DATA.EXP_ORDINI[0].ORD_CLIENTE, cmd, language, itemInfo.STO_QTAR);
ICSPurchaseService.PurchaseReceiveDoctNegativeHG(JsonData.DATA.EXP_ORDINI[0].ORD_ORDINE, JsonData.DATA.EXP_ORDINI[0].ORD_CLIENTE, cmd, language);
//出库
printTable = ICSWareHouseLotInfoService.WareHouseLotInfoDownHG(Identification, JsonData.DATA.EXP_ORDINI[0].ORD_ORDINE, JsonData.DATA.EXP_ORDINI_RIGHE_STO[0].STO_EXE_OPERATORE
, JsonData.DATA.EXP_ORDINI[0].ORD_CLIENTE, "3", TransTypeEnum.PurchaseReceiveDoctNegative.GetDescription<DBValue>(), cmd, language);
@ -3485,7 +3485,7 @@ namespace ICSSoft.DataProject
{
BusinessCode = TransTypeEnum.MOApply.GetDescription<DBValue>();
//更新源头单据数量
ICSManufactureService.MOApplyHG(JsonData.DATA.EXP_ORDINI[0].ORD_ORDINE, JsonData.DATA.EXP_ORDINI[0].ORD_CLIENTE, cmd, language, itemInfo.STO_QTAR);
ICSManufactureService.MOApplyHG(JsonData.DATA.EXP_ORDINI[0].ORD_ORDINE, JsonData.DATA.EXP_ORDINI[0].ORD_CLIENTE, cmd, language);
//出库
printTable = ICSWareHouseLotInfoService.WareHouseLotInfoDownHG(Identification, JsonData.DATA.EXP_ORDINI[0].ORD_ORDINE, JsonData.DATA.EXP_ORDINI_RIGHE_STO[0].STO_EXE_OPERATORE
, JsonData.DATA.EXP_ORDINI[0].ORD_CLIENTE, "3", TransTypeEnum.MOApply.GetDescription<DBValue>(), cmd, language, MergeID);
@ -3496,7 +3496,7 @@ namespace ICSSoft.DataProject
{
BusinessCode = TransTypeEnum.OOApply.GetDescription<DBValue>();
//更新源头单据数量
ICSOutsourcingService.OOApplyHG(JsonData.DATA.EXP_ORDINI[0].ORD_ORDINE, JsonData.DATA.EXP_ORDINI[0].ORD_CLIENTE, cmd, language, itemInfo.STO_QTAR);
ICSOutsourcingService.OOApplyHG(JsonData.DATA.EXP_ORDINI[0].ORD_ORDINE, JsonData.DATA.EXP_ORDINI[0].ORD_CLIENTE, cmd, language);
//出库
printTable = ICSWareHouseLotInfoService.WareHouseLotInfoDownHG(Identification, JsonData.DATA.EXP_ORDINI[0].ORD_ORDINE, JsonData.DATA.EXP_ORDINI_RIGHE_STO[0].STO_EXE_OPERATORE
, JsonData.DATA.EXP_ORDINI[0].ORD_CLIENTE, "3", TransTypeEnum.OOApply.GetDescription<DBValue>(), cmd, language, MergeID);

Loading…
Cancel
Save