修改派车增加VGM

master
jianghaiqing 2 months ago
parent bd98d8b687
commit e72f530739

@ -836,15 +836,19 @@ namespace Myshipping.Application.EDI.VOLTA
} }
else ISSUETYPE = "EXP"; else ISSUETYPE = "EXP";
*/ */
if (bill.ISSUETYPE == "ORIGINAL")
{ if (InttrEdi.filetype == "E" || string.IsNullOrWhiteSpace(bill.ISSUETYPE))
ISSUETYPE = "ORI";
}
else if (bill.ISSUETYPE == "TELEX")
{ {
ISSUETYPE = "TER"; if (bill.ISSUETYPE == "ORIGINAL")
{
ISSUETYPE = "ORI";
}
else if (bill.ISSUETYPE == "TELEX")
{
ISSUETYPE = "TER";
}
else ISSUETYPE = "EXP";
} }
else ISSUETYPE = "EXP";
//if (new string[] { "ORI", "TER", "EXP" }.Contains(bill.ISSUETYPE)) //if (new string[] { "ORI", "TER", "EXP" }.Contains(bill.ISSUETYPE))
//{ //{

@ -136,6 +136,10 @@ namespace Myshipping.Application.Entity
/// </summary> /// </summary>
[Description("备注")] [Description("备注")]
public string REMARK { get; set; } public string REMARK { get; set; }
/// <summary>
/// VGM
/// </summary>
[Description("VGM")]
public decimal? VGM { get; set; }
} }
} }

@ -140,5 +140,10 @@ namespace Myshipping.Application.Entity
/// </summary> /// </summary>
[Description("备注")] [Description("备注")]
public string REMARK { get; set; } public string REMARK { get; set; }
/// <summary>
/// VGM
/// </summary>
[Description("VGM")]
public decimal? VGM { get; set; }
} }
} }

@ -7022,21 +7022,30 @@ namespace Myshipping.Application
if (ediRouteEnum == EDIRouteEnum.NULL) if (ediRouteEnum == EDIRouteEnum.NULL)
throw Oops.Bah($"当前船公司没有对应的请求路由配置"); throw Oops.Bah($"当前船公司没有对应的请求路由配置");
//这里船公司VOL的单子不能走此通道发送
if (ediRouteEnum == EDIRouteEnum.VOL)
{
var isVOLTASIExport = App.Configuration["IsVOLTASIExport"];
if (!string.IsNullOrWhiteSpace(isVOLTASIExport)) var allowMblStart = App.Configuration["VOLTASIExportStart"].Split(new char[] { ',' });
{
if (isVOLTASIExport == "1") //if (!order.MBLNO.StartsWith("VOL") && !order.MBLNO.StartsWith("FCS") && !order.MBLNO.StartsWith("REL") && !order.MBLNO.StartsWith("SLS"))
throw Oops.Bah($"当前船公司VOL不能执行标准发送"); if (allowMblStart.Any(a => order.MBLNO.StartsWith(a)))
} {
else //VOL、FCS、REL,SLS
{ throw Oops.Bah($"当前船公司{order.CARRIERID} 提单号开头({(string.Join("", allowMblStart.ToArray()))})不能执行标准发送");
throw Oops.Bah($"当前船公司VOL不能执行标准发送");
}
} }
////这里船公司VOL的单子不能走此通道发送
//if (ediRouteEnum == EDIRouteEnum.VOL)
//{
// var isVOLTASIExport = App.Configuration["IsVOLTASIExport"];
// if (!string.IsNullOrWhiteSpace(isVOLTASIExport))
// {
// if (isVOLTASIExport == "1")
// throw Oops.Bah($"当前船公司VOL不能执行标准发送");
// }
// else
// {
// throw Oops.Bah($"当前船公司VOL不能执行标准发送");
// }
//}
//集装箱型 //集装箱型
@ -11806,12 +11815,12 @@ namespace Myshipping.Application
*/ */
string batchNo = IDGen.NextID().ToString(); string batchNo = IDGen.NextID().ToString();
var isVOLTASIExport = App.Configuration["IsVOLTASIExport"]; //var isVOLTASIExport = App.Configuration["IsVOLTASIExport"];
if(!string.IsNullOrWhiteSpace(isVOLTASIExport) && isVOLTASIExport == "0") //if(!string.IsNullOrWhiteSpace(isVOLTASIExport) && isVOLTASIExport == "0")
{ //{
throw Oops.Bah("配置IsVOLTASIExport=0不弹出窗口"); // throw Oops.Bah("配置IsVOLTASIExport=0不弹出窗口");
} //}
_logger.LogInformation("批次={no}获取请求VOLTA截单详情 {msg}", batchNo, JSON.Serialize(model)); _logger.LogInformation("批次={no}获取请求VOLTA截单详情 {msg}", batchNo, JSON.Serialize(model));
@ -11833,8 +11842,11 @@ namespace Myshipping.Application
_logger.LogInformation("批次={no}提取订单信息完成", batchNo); _logger.LogInformation("批次={no}提取订单信息完成", batchNo);
if (!order.CARRIERID.Equals("VOL", StringComparison.OrdinalIgnoreCase) && !order.CARRIERID.Equals("FCS", StringComparison.OrdinalIgnoreCase) var allowCarrier = App.Configuration["VOLTASIExportCarrier"].Split(new char[] { ',' });
&& !order.CARRIERID.Equals("SLS", StringComparison.OrdinalIgnoreCase)) //if (!order.CARRIERID.Equals("VOL", StringComparison.OrdinalIgnoreCase) && !order.CARRIERID.Equals("FCS", StringComparison.OrdinalIgnoreCase)
// && !order.CARRIERID.Equals("SLS", StringComparison.OrdinalIgnoreCase))
if (allowCarrier.Contains(order.CARRIERID))
{ {
throw Oops.Bah("当前订单的船公司不是VOL(沃尔塔航运)不能发送VOLTA截单EDI"); throw Oops.Bah("当前订单的船公司不是VOL(沃尔塔航运)不能发送VOLTA截单EDI");
} }
@ -11842,9 +11854,13 @@ namespace Myshipping.Application
if (string.IsNullOrWhiteSpace(order.MBLNO)) if (string.IsNullOrWhiteSpace(order.MBLNO))
throw Oops.Bah($"提单号不能为空"); throw Oops.Bah($"提单号不能为空");
if (!order.MBLNO.StartsWith("VOL") && !order.MBLNO.StartsWith("FCS") && !order.MBLNO.StartsWith("REL") && !order.MBLNO.StartsWith("SLS")) var allowMblStart = App.Configuration["VOLTASIExportStart"].Split(new char[] { ',' });
//if (!order.MBLNO.StartsWith("VOL") && !order.MBLNO.StartsWith("FCS") && !order.MBLNO.StartsWith("REL") && !order.MBLNO.StartsWith("SLS"))
if (!allowMblStart.Any(a => order.MBLNO.StartsWith(a)))
{ {
throw Oops.Bah($"只支持提单号开头是VOL、FCS、REL,SLS发送截单"); //VOL、FCS、REL,SLS
throw Oops.Bah($"只支持提单号开头是({(string.Join("", allowMblStart.ToArray()))})发送截单");
} }
bool isSeaLead = false; bool isSeaLead = false;

@ -108,5 +108,10 @@ namespace Myshipping.Application
/// 司机电话 /// 司机电话
/// </summary> /// </summary>
public string CarDriverTel { get; set; } public string CarDriverTel { get; set; }
/// <summary>
/// VGM
/// </summary>
public Nullable<decimal> VGM { get; set; }
} }
} }

@ -143,5 +143,7 @@
"EmailNoticeUrl": "http://47.104.73.97:8801/mail/send", "EmailNoticeUrl": "http://47.104.73.97:8801/mail/send",
"EmailNoticeDefaultUser": "jianghaiqing@myshipping.net", "EmailNoticeDefaultUser": "jianghaiqing@myshipping.net",
"BookingAmendModifyWebApiUrl": "http://localhost:5110/api/TaskBookingAmendmentParser/ModifyBookingAmendmentFile", "BookingAmendModifyWebApiUrl": "http://localhost:5110/api/TaskBookingAmendmentParser/ModifyBookingAmendmentFile",
"IsVOLTASIExport": "0" "IsVOLTASIExport": "0",
"VOLTASIExportCarrier": "SLS,REL",
"VOLTASIExportStart": "SLS,REL"
} }
Loading…
Cancel
Save