You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
using DS.Module.Core;
|
|
|
|
|
using DS.WMS.Core.TaskPlat.Dtos;
|
|
|
|
|
using DS.WMS.Core.TaskPlat.Entity;
|
|
|
|
|
using DS.WMS.Core.TaskPlat.Interface;
|
|
|
|
|
using Microsoft.AspNetCore.Mvc;
|
|
|
|
|
|
|
|
|
|
namespace DS.WMS.TaskApi.Controllers;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 任务台分配设置维护接口
|
|
|
|
|
/// </summary>
|
|
|
|
|
public class TaskAllocationController : ApiController
|
|
|
|
|
{
|
|
|
|
|
private readonly ITaskAllocationService taskAllocationService;
|
|
|
|
|
|
|
|
|
|
public TaskAllocationController(ITaskAllocationService taskAllocationService)
|
|
|
|
|
{
|
|
|
|
|
this.taskAllocationService = taskAllocationService;
|
|
|
|
|
}
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 获取任务分配列表
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="carrierId">船公司Id(可选)</param>
|
|
|
|
|
[HttpGet("GetList")]
|
|
|
|
|
public async Task<DataResult<TaskAllocationtSetQueryListDto>> GetList(long? carrierId)
|
|
|
|
|
{
|
|
|
|
|
var result = await taskAllocationService.GetList(carrierId);
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 获取任务分配列表中已存在的船公司列表(用于查询)
|
|
|
|
|
/// </summary>
|
|
|
|
|
[HttpGet("GetContainsCarrierList")]
|
|
|
|
|
public async Task<DataResult<List<CarrierInfoDto>>> GetContainsCarrierList()
|
|
|
|
|
{
|
|
|
|
|
var result = await taskAllocationService.GetContainsCarrierList();
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 保存任务分配设置
|
|
|
|
|
/// </summary>
|
|
|
|
|
[HttpPost("Save")]
|
|
|
|
|
public async Task<DataResult> Save([FromBody] TaskAllocationtSetSaveDto saveDto)
|
|
|
|
|
{
|
|
|
|
|
var result = await taskAllocationService.Save(saveDto);
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
}
|