diff --git a/Myshipping.Application/Service/BookingOrder/BookingMSKAPIService.cs b/Myshipping.Application/Service/BookingOrder/BookingMSKAPIService.cs
index 357a909d..8a88f75d 100644
--- a/Myshipping.Application/Service/BookingOrder/BookingMSKAPIService.cs
+++ b/Myshipping.Application/Service/BookingOrder/BookingMSKAPIService.cs
@@ -440,6 +440,8 @@ namespace Myshipping.Application.Service.BookingOrder
var id = InnerSave(model, isSendApi: true).GetAwaiter().GetResult();
+ result.id = id;
+
MSKAPIBookingResultDto resultInfo = null;
_logger.LogInformation($"开始请求MSK API订舱,JSON={JSON.Serialize(bookingDto)}");
@@ -504,12 +506,17 @@ namespace Myshipping.Application.Service.BookingOrder
throw Oops.Bah(resultInfo.msg);
}
+
+ result.succ = true;
}
catch (Exception ex)
{
_logger.LogError($"MSK API订舱异常,req={JSON.Serialize(model)} 原因:{ex.Message}");
- throw Oops.Bah($"MSK API订舱失败,{ex.Message}");
+ //throw Oops.Bah($"MSK API订舱失败,{ex.Message}");
+
+ result.succ = false;
+ result.msg = $"MSK API订舱失败,{ex.Message}";
}
return result;
diff --git a/Myshipping.Application/Service/BookingOrder/Dto/MSKBookingResultDto.cs b/Myshipping.Application/Service/BookingOrder/Dto/MSKBookingResultDto.cs
index e22a5af5..7f75101f 100644
--- a/Myshipping.Application/Service/BookingOrder/Dto/MSKBookingResultDto.cs
+++ b/Myshipping.Application/Service/BookingOrder/Dto/MSKBookingResultDto.cs
@@ -11,5 +11,24 @@ namespace Myshipping.Application
///
public class MSKBookingResultDto
{
+ ///
+ /// 是否成功 true=成功 false=失败
+ ///
+ public bool succ { get; set; } = false;
+
+ ///
+ /// 状态 0-成功
+ ///
+ public int status { get; set; } = 0;
+
+ ///
+ /// 返回消息
+ ///
+ public string msg { get; set; }
+
+ ///
+ /// 马士基API订舱主键
+ ///
+ public Nullable id { get; set; }
}
}