|
|
|
@ -75,6 +75,17 @@ namespace Myshipping.Application.EDI
|
|
|
|
|
return new KeyValuePair<bool, string>(false, "海关航次不能为空");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//2023年7月12日,下货纸为冻柜,需填写温度和通风,危险品需填写等级和编号
|
|
|
|
|
if (order.CARGOID == "R" && (string.IsNullOrEmpty(order.TEMPSET) || string.IsNullOrEmpty(order.REEFERF)))
|
|
|
|
|
{
|
|
|
|
|
return new KeyValuePair<bool, string>(false, "冻柜的温度和通风必须填写");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (order.CARGOID == "D" && (string.IsNullOrEmpty(order.DUNNO) || string.IsNullOrEmpty(order.DCLASS)))
|
|
|
|
|
{
|
|
|
|
|
return new KeyValuePair<bool, string>(false, "危险品的等级和编号必须填写");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var fileOpt = App.GetOptions<BookingAttachOptions>();
|
|
|
|
|
if (string.IsNullOrEmpty(fileOpt.basePath))
|
|
|
|
|
{
|
|
|
|
@ -412,7 +423,7 @@ namespace Myshipping.Application.EDI
|
|
|
|
|
repBookingFile.Insert(attFile);
|
|
|
|
|
|
|
|
|
|
//发送邮件
|
|
|
|
|
var sendResult = await MailSendHelper.SendMail(userMail, title, "", order.YARDCONTRACTEMAIL,new KeyValuePair<string, byte[]>(ediFileName, msResult.GetBuffer()));
|
|
|
|
|
var sendResult = await MailSendHelper.SendMail(userMail, title, "", order.YARDCONTRACTEMAIL, new KeyValuePair<string, byte[]>(ediFileName, msResult.GetBuffer()));
|
|
|
|
|
if (!sendResult.Key)
|
|
|
|
|
{
|
|
|
|
|
return new KeyValuePair<bool, string>(false, sendResult.Value);
|
|
|
|
|