|
|
using Microsoft.AspNetCore.Mvc;
|
|
|
using Myshipping.Application.Entity;
|
|
|
using Myshipping.Application.Event;
|
|
|
using Myshipping.Application.Service.BookingSlot.Dto;
|
|
|
using System.Collections.Generic;
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
namespace Myshipping.Application
|
|
|
{
|
|
|
public interface IBookingSlotService
|
|
|
{
|
|
|
Task<long> ApiReceive(BookingSlotBaseApiDto dto);
|
|
|
Task<BookingSlotBaseSaveOutput> Detail(long id);
|
|
|
Task<List<BookingSlotBaseWithCtnDto>> GetAvailableSlots(BookingSlotBaseDto input);
|
|
|
|
|
|
/// <summary>
|
|
|
/// 查询可用的舱位及箱子列表
|
|
|
/// </summary>
|
|
|
/// <param name="slotInput">筛选条件1:舱位信息、箱型</param>
|
|
|
/// <param name="slotIdListInput">筛选条件2:舱位主键列表</param>
|
|
|
/// <returns>可用的舱位列表(含可用的箱子列表)</returns>
|
|
|
Task<List<BookingSlotBaseWithCtnDto>> GetAvailableSlots(BookingSlotBaseDto slotInput = null, List<long> slotIdListInput = null);
|
|
|
|
|
|
/// <summary>
|
|
|
/// 检查指定订舱记录,是否可以引入舱位列表
|
|
|
/// </summary>
|
|
|
/// <param name="slots">待引入的舱位列表</param>
|
|
|
/// <param name="bookingOrderId">待关联的订舱记录</param>
|
|
|
/// <returns>(指定订舱记录是否已经引入过舱位数据,现有舱位及箱子是否满足需求,提示信息)</returns>
|
|
|
Task<(bool isExists, bool isEnough, string message)> CheckImportSlots(List<BookingSlotBaseWithCtnDto> slots, long bookingOrderId);
|
|
|
|
|
|
/// <summary>
|
|
|
/// 为指定订舱记录引入舱位信息
|
|
|
/// </summary>
|
|
|
/// <param name="slots">待引入的舱位列表</param>
|
|
|
/// <param name="bookingOrderId">待关联的订舱记录</param>
|
|
|
/// <param name="isCheck">是否进行剩余量检查</param>
|
|
|
/// <returns>(是否成功,提示消息)</returns>
|
|
|
Task<(bool isSuccess, string message)> ImportSlots(List<BookingSlotBaseWithCtnDto> slots, long bookingOrderId, bool isCheck);
|
|
|
|
|
|
Task<dynamic> PageStock(BookingSlotStockPageInput input);
|
|
|
Task RefreshStock(BookingSlotStockUpdateModel input);
|
|
|
Task<BookingSlotBaseSaveOutput> Save(BookingSlotBaseSaveInput input);
|
|
|
|
|
|
/// <summary>
|
|
|
/// 获取附件
|
|
|
/// </summary>
|
|
|
/// <param name="id">舱位主键</param>
|
|
|
/// <returns>返回附件列表</returns>
|
|
|
Task<List<BookingFile>> GetFile(long id);
|
|
|
|
|
|
/// <summary>
|
|
|
/// 分页查询订舱舱位
|
|
|
/// </summary>
|
|
|
/// <param name="input"></param>
|
|
|
/// <returns></returns>
|
|
|
Task<dynamic> Page(BookingSlotBasePageInput input);
|
|
|
}
|
|
|
} |