zhangxiaofeng 8 months ago
commit 66d9f8b323

@ -451,5 +451,85 @@ namespace Myshipping.Application.Entity
/// 最后BookingCancellation接收时间
/// </summary>
public Nullable<DateTime> LST_RECV_BK_CANCEL_DATE { get; set; }
/// <summary>
/// 船期ID
/// </summary>
public string CARRIER_PRODUCT_ID { get; set; }
/// <summary>
/// 是否不使用船期表订舱
/// </summary>
public bool IS_SEND_NO_SCHEDULE { get; set; }
/// <summary>
/// 收货地国家名称
/// </summary>
public string PLACERECEIPT_COUNTRY_NAME { get; set; }
/// <summary>
/// 收货地行政名称
/// </summary>
public string PLACERECEIPT_REGION_NAME { get; set; }
/// <summary>
/// 用户录入收货地城市英文名称
/// </summary>
public string USER_PLACERECEIPT_CITY { get; set; }
/// <summary>
/// 用户录入收货地UN地点代码
/// </summary>
public string USER_PLACERECEIPT_UNLOC_CODE { get; set; }
/// <summary>
/// 用户录入收货地国家代码
/// </summary>
public string USER_PLACERECEIPT_COUNTRY_CODE { get; set; }
/// <summary>
/// 用户录入收货地国家名称
/// </summary>
public string USER_PLACERECEIPT_COUNTRY_NAME { get; set; }
/// <summary>
/// 用户录入收货地行政名称
/// </summary>
public string USER_PLACERECEIPT_REGION_NAME { get; set; }
/// <summary>
/// 交货地国家名称
/// </summary>
public string PLACEDELIVERY_COUNTRY_NAME { get; set; }
/// <summary>
/// 交货地行政名称
/// </summary>
public string PLACEDELIVERY_REGION_NAME { get; set; }
/// <summary>
/// 用户录入交货地城市英文名称
/// </summary>
public string USER_PLACEDELIVERY_CITY { get; set; }
/// <summary>
/// 用户录入交货地UN地点代码
/// </summary>
public string USER_PLACEDELIVERY_UNLOC_CODE { get; set; }
/// <summary>
/// 用户录入交货地国家代码
/// </summary>
public string USER_PLACEDELIVERY_COUNTRY_CODE { get; set; }
/// <summary>
/// 用户录入交货地国家名称
/// </summary>
public string USER_PLACEDELIVERY_COUNTRY_NAME { get; set; }
/// <summary>
/// 用户录入交货地行政名称
/// </summary>
public string USER_PLACEDELIVERY_REGION_NAME { get; set; }
}
}

@ -17,7 +17,7 @@ namespace Myshipping.Application
public class TaskPODDischargeGateoutFullDetailInfo : TaskManageDbEntity
{
/// <summary>
/// VGM任务主键
/// 主键
/// </summary>
public string P_ID { get; set; }

@ -311,6 +311,12 @@ namespace Myshipping.Application.Service.BookingOrder
},
};
//排查怀疑这里是导致BC没有合约号胡的问题开启这个值看看
//if (model.isBookingPartOwnPrice)
//{
// bookingDto.bookingBody.mandatoryParties.isPriceOwnerFromServiceContractAccepted = true;
//}
bookingDto.bookingBody.transport = new MSKAPIBookingTransport
{
carrierCode = model.carrierCode,
@ -321,13 +327,15 @@ namespace Myshipping.Application.Service.BookingOrder
{
placeOfReceipt = new MSKAPIBookingRouteDetailsBase
{
UNLocationCode = model.placeOfReceiptUnLocCode,
cityName = model.placeOfReceiptCityName,
UNLocationCode = model.isSendNoSchedule ? model.userPlaceOfReceiptUnLocCode
: model.placeOfReceiptUnLocCode,
//cityName = model.placeOfReceiptCityName,
},
placeOfDelivery = new MSKAPIBookingRouteDetailsBase
{
UNLocationCode = model.placeOfDeliveryUnLocCode,
cityName = model.placeOfDeliveryCityName,
UNLocationCode = model.isSendNoSchedule ? model.userPlaceOfDeliveryUnLocCode
: model.placeOfDeliveryUnLocCode,
//cityName = model.placeOfDeliveryCityName,
},
selectedRoute = new MSKAPIBookingRoute
{
@ -347,13 +355,15 @@ namespace Myshipping.Application.Service.BookingOrder
},
startLocation = new MSKAPIBookingRouteDetailsBase
{
cityName = model.placeOfReceiptCityName,
UNLocationCode = model.placeOfReceiptUnLocCode
//cityName = model.placeOfReceiptCityName,
UNLocationCode = model.isSendNoSchedule ? model.userPlaceOfReceiptUnLocCode
: model.placeOfReceiptUnLocCode
},
endLocation = new MSKAPIBookingRouteDetailsBase
{
cityName = model.placeOfDeliveryCityName,
UNLocationCode = model.placeOfDeliveryUnLocCode
//cityName = model.placeOfDeliveryCityName,
UNLocationCode = model.isSendNoSchedule ? model.userPlaceOfDeliveryUnLocCode
: model.placeOfDeliveryUnLocCode
},
transportModeCode = model.transportMode
}
@ -362,6 +372,11 @@ namespace Myshipping.Application.Service.BookingOrder
}
};
if(!model.isSendNoSchedule)
{
bookingDto.bookingBody.transport.routeDetails.selectedRoute.routeScheduleId = model.carrierProductId;
}
bookingDto.bookingBody.cargo = new MSKAPIBookingCargo
{
commodityCode = model.commodityCode,
@ -613,6 +628,9 @@ namespace Myshipping.Application.Service.BookingOrder
if(!model.earliestDepartureDate.HasValue)
throw Oops.Bah($"预计离港日期必填");
if (!model.isSendNoSchedule && string.IsNullOrWhiteSpace(model.carrierProductId))
throw Oops.Bah($"船期信息不能为空,请查询船期信息");
if (model.isReefer)
{
if (!model.temperature.HasValue)
@ -973,6 +991,8 @@ namespace Myshipping.Application.Service.BookingOrder
.WhereIF(!string.IsNullOrWhiteSpace(QuerySearch.PriceOwnerCompanyPartyCode), t => t.PRICE_OWNER_COMPANY_PARTYCODE.Contains(QuerySearch.PriceOwnerCompanyPartyCode))
.WhereIF(!string.IsNullOrWhiteSpace(QuerySearch.PlaceReceiptCity), t => t.PLACERECEIPT_CITY.Contains(QuerySearch.PlaceReceiptCity) || t.PLACERECEIPT_UNLOC_CODE.Contains(QuerySearch.PlaceReceiptCity))
.WhereIF(!string.IsNullOrWhiteSpace(QuerySearch.PlaceDeliveryCity), t => t.PLACEDELIVERY_CITY.Contains(QuerySearch.PlaceDeliveryCity) || t.PLACEDELIVERY_UNLOC_CODE.Contains(QuerySearch.PlaceDeliveryCity))
.WhereIF(!string.IsNullOrWhiteSpace(QuerySearch.BookingReference), t => t.BOOKING_REFERENCE.Contains(QuerySearch.BookingReference))
.WhereIF(!string.IsNullOrWhiteSpace(QuerySearch.BookingCreator), t => t.CreatedUserName.Contains(QuerySearch.BookingCreator) || t.UpdatedUserName.Contains(QuerySearch.BookingCreator))
.OrderBy(entityOrderCol + (QuerySearch.descSort ? " desc " : " asc "))
.ToPagedListAsync(QuerySearch.PageNo, QuerySearch.PageSize);
@ -1237,5 +1257,38 @@ namespace Myshipping.Application.Service.BookingOrder
}).ExecuteCommandAsync();
}
#endregion
#region 批量发送
/// <summary>
/// 批量发送
/// </summary>
/// <param name="ids">马士基API订舱ID组</param>
/// <returns>返回执行结果消息</returns>
public async Task<string> BatchSend(long[] ids)
{
var list = await _bookingDeliveryRecordRep.AsQueryable()
.Where(a => ids.Contains(a.Id)).ToListAsync();
if (list.Count != ids.Length)
throw Oops.Oh("订舱数据获取失败,请确认选中的记录是否存在");
return string.Empty;
}
#endregion
#region 批量发送
/// <summary>
/// 批量发送
/// </summary>
/// <param name="id">马士基API订舱ID</param>
/// <param name="copyNum">需要复制生成记录</param>
/// <returns>返回执行结果消息</returns>
public async Task<string> BatchCopy(long id, int copyNum)
{
return string.Empty;
}
#endregion
}
}

@ -139,7 +139,26 @@ namespace Myshipping.Application
.Map(dest => dest.PRICE_OWNER_REFERENCE_NAME, src => src.priceOwnerReferenceName)
.Map(dest => dest.IS_REEFER, src => src.isReefer)
.Map(dest => dest.IS_SHIPPER_OWNED, src => src.isShipperOwned)
.Map(dest => dest.IS_IMPORT_RETURNED, src => src.isImportReturned);
.Map(dest => dest.IS_IMPORT_RETURNED, src => src.isImportReturned)
.Map(dest => dest.CARRIER_PRODUCT_ID, src => src.carrierProductId)
.Map(dest => dest.IS_SEND_NO_SCHEDULE, src => src.isSendNoSchedule)
.Map(dest => dest.PLACERECEIPT_COUNTRY_NAME, src => src.placeOfReceiptCountryName)
.Map(dest => dest.PLACERECEIPT_REGION_NAME, src => src.placeOfReceiptRegionName)
.Map(dest => dest.PLACEDELIVERY_COUNTRY_NAME, src => src.placeOfDeliveryCountryName)
.Map(dest => dest.PLACEDELIVERY_REGION_NAME, src => src.placeOfDeliveryRegionName)
.Map(dest => dest.USER_PLACEDELIVERY_CITY, src => src.userPlaceOfDeliveryCityName)
.Map(dest => dest.USER_PLACEDELIVERY_COUNTRY_CODE, src => src.userPlaceOfDeliveryCountryCode)
.Map(dest => dest.USER_PLACEDELIVERY_COUNTRY_NAME, src => src.userPlaceOfDeliveryCountryName)
.Map(dest => dest.USER_PLACEDELIVERY_UNLOC_CODE, src => src.userPlaceOfDeliveryUnLocCode)
.Map(dest => dest.USER_PLACEDELIVERY_REGION_NAME, src => src.userPlaceOfDeliveryRegionName)
.Map(dest => dest.USER_PLACERECEIPT_CITY, src => src.userPlaceOfReceiptCityName)
.Map(dest => dest.USER_PLACERECEIPT_COUNTRY_CODE, src => src.userPlaceOfReceiptCountryCode)
.Map(dest => dest.USER_PLACERECEIPT_COUNTRY_NAME, src => src.userPlaceOfReceiptCountryName)
.Map(dest => dest.USER_PLACERECEIPT_UNLOC_CODE, src => src.userPlaceOfReceiptUnLocCode)
.Map(dest => dest.USER_PLACERECEIPT_REGION_NAME, src => src.userPlaceOfReceiptRegionName);
config.ForType<BookingDeliveryRecord, MSKBookingDto>()
.Map(dest => dest.id, src => src.Id)
@ -189,7 +208,23 @@ namespace Myshipping.Application
.Map(dest => dest.priceOwnerReference, src => src.PRICE_OWNER_REFERENCE)
.Map(dest => dest.priceOwnerReferenceName, src => src.PRICE_OWNER_REFERENCE_NAME)
.Map(dest => dest.isShipperOwned, src => src.IS_SHIPPER_OWNED)
.Map(dest => dest.isImportReturned, src => src.IS_IMPORT_RETURNED);
.Map(dest => dest.isImportReturned, src => src.IS_IMPORT_RETURNED)
.Map(dest => dest.carrierProductId, src => src.CARRIER_PRODUCT_ID)
.Map(dest => dest.isSendNoSchedule, src => src.IS_SEND_NO_SCHEDULE)
.Map(dest => dest.placeOfReceiptCountryName, src => src.PLACERECEIPT_COUNTRY_NAME)
.Map(dest => dest.placeOfReceiptRegionName, src => src.PLACERECEIPT_REGION_NAME)
.Map(dest => dest.placeOfDeliveryCountryName, src => src.PLACEDELIVERY_COUNTRY_NAME)
.Map(dest => dest.placeOfDeliveryRegionName, src => src.PLACEDELIVERY_REGION_NAME)
.Map(dest => dest.userPlaceOfDeliveryCityName, src => src.USER_PLACEDELIVERY_CITY)
.Map(dest => dest.userPlaceOfDeliveryCountryCode, src => src.USER_PLACEDELIVERY_COUNTRY_CODE)
.Map(dest => dest.userPlaceOfDeliveryCountryName, src => src.USER_PLACEDELIVERY_COUNTRY_NAME)
.Map(dest => dest.userPlaceOfDeliveryUnLocCode, src => src.USER_PLACEDELIVERY_UNLOC_CODE)
.Map(dest => dest.userPlaceOfDeliveryRegionName, src => src.USER_PLACEDELIVERY_REGION_NAME)
.Map(dest => dest.userPlaceOfReceiptCityName, src => src.USER_PLACERECEIPT_CITY)
.Map(dest => dest.userPlaceOfReceiptCountryCode, src => src.USER_PLACERECEIPT_COUNTRY_CODE)
.Map(dest => dest.userPlaceOfReceiptCountryName, src => src.USER_PLACERECEIPT_COUNTRY_NAME)
.Map(dest => dest.userPlaceOfReceiptUnLocCode, src => src.USER_PLACERECEIPT_UNLOC_CODE)
.Map(dest => dest.userPlaceOfReceiptRegionName, src => src.USER_PLACERECEIPT_REGION_NAME);
config.ForType<MSKBookingCtnInfo, BookingDeliveryRecordCtn>()

@ -276,6 +276,86 @@ namespace Myshipping.Application
/// </summary>
public bool isImportReturned { get; set; }
/// <summary>
/// 查询船期ID
/// </summary>
public string carrierProductId { get; set; }
/// <summary>
/// 是否不使用船期表订舱
/// </summary>
public bool isSendNoSchedule { get; set; } = false;
/// <summary>
/// 收货地国家名称
/// </summary>
public string placeOfReceiptCountryName { get; set; }
/// <summary>
/// 收货地行政名称
/// </summary>
public string placeOfReceiptRegionName { get; set; }
/// <summary>
/// 交货地国家名称
/// </summary>
public string placeOfDeliveryCountryName { get; set; }
/// <summary>
/// 交货地行政名称
/// </summary>
public string placeOfDeliveryRegionName { get; set; }
/// <summary>
/// 用户录入收货地UN地点代码
/// </summary>
public string userPlaceOfReceiptUnLocCode { get; set; }
/// <summary>
/// 用户录入收货地城市英文名称
/// </summary>
public string userPlaceOfReceiptCityName { get; set; }
/// <summary>
/// 用户录入收货地国家代码
/// </summary>
public string userPlaceOfReceiptCountryCode { get; set; }
// <summary>
/// 用户录入收货地国家名称
/// </summary>
public string userPlaceOfReceiptCountryName { get; set; }
/// <summary>
/// 用户录入收货地行政名称
/// </summary>
public string userPlaceOfReceiptRegionName { get; set; }
/// <summary>
/// 用户录入交货地国家名称
/// </summary>
public string userPlaceOfDeliveryCountryName { get; set; }
/// <summary>
/// 用户录入交货地行政名称
/// </summary>
public string userPlaceOfDeliveryRegionName { get; set; }
/// <summary>
/// 用户录入交货地UN地点代码
/// </summary>
public string userPlaceOfDeliveryUnLocCode { get; set; }
/// <summary>
/// 用户录入交货地城市英文名称
/// </summary>
public string userPlaceOfDeliveryCityName { get; set; }
/// <summary>
/// 用户录入交货地国家代码
/// </summary>
public string userPlaceOfDeliveryCountryCode { get; set; }
/// <summary>
/// 箱型箱量列表
/// </summary>

@ -142,5 +142,15 @@ namespace Myshipping.Application
/// 目的地
/// </summary>
public string PlaceDeliveryCity { get; set; }
/// <summary>
/// 订舱号
/// </summary>
public string BookingReference { get; set; }
/// <summary>
/// 订舱人
/// </summary>
public string BookingCreator { get; set; }
}
}

@ -65,5 +65,20 @@ namespace Myshipping.Application
/// <param name="id">请求订舱ID</param>
/// <returns></returns>
Task Delete(long id);
/// <summary>
/// 批量发送
/// </summary>
/// <param name="ids">马士基API订舱ID组</param>
/// <returns>返回执行结果消息</returns>
Task<string> BatchSend(long[] ids);
/// <summary>
/// 批量发送
/// </summary>
/// <param name="id">马士基API订舱ID</param>
/// <param name="copyNum">需要复制生成记录</param>
/// <returns>返回执行结果消息</returns>
Task<string> BatchCopy(long id,int copyNum);
}
}

Loading…
Cancel
Save