| | |
| | | using Microsoft.AspNetCore.Http; |
| | | using Microsoft.AspNetCore.Authorization; |
| | | using Microsoft.AspNetCore.Http; |
| | | using Microsoft.AspNetCore.Mvc; |
| | | using WIDESEAWCS_Common; |
| | | using WIDESEAWCS_Core; |
| | | using WIDESEAWCS_DTO; |
| | | using WIDESEAWCS_DTO.WMS; |
| | | using WIDESEAWCS_ITaskInfoService; |
| | | |
| | | namespace WIDESEAWCS_Server.Controllers.AGV |
| | | { |
| | |
| | | [ApiController] |
| | | public class KLSAGVController : ControllerBase |
| | | { |
| | | private readonly ITaskService _taskService; |
| | | public KLSAGVController(ITaskService taskService) |
| | | { |
| | | _taskService = taskService; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// ä»»å¡ç¶ææ´æ° |
| | | /// </summary> |
| | | /// <param name="taskDTOs"></param> |
| | | /// <returns></returns> |
| | | [HttpPost, Route("UpdateTaskStatus"), AllowAnonymous] |
| | | public ReturnGALAXIS UpdateTaskStatus([FromBody] object TaskDTO) |
| | | { |
| | | ReturnGALAXIS returnGALAXIS = new ReturnGALAXIS(); |
| | | var take= _taskService.UpdateTaskStatus(TaskDTO, DeviceTypeEnum.GALAXIS); |
| | | if (take.Status) |
| | | { |
| | | returnGALAXIS.returnStatus = 0; |
| | | returnGALAXIS.msgTime=DateTime.Now.ToString(); |
| | | returnGALAXIS.returnInfo = ""; |
| | | } |
| | | else |
| | | { |
| | | returnGALAXIS.returnStatus=take.Code; |
| | | returnGALAXIS.msgTime=DateTime.Now.ToString(); |
| | | returnGALAXIS.returnInfo = take.Message; |
| | | } |
| | | |
| | | return returnGALAXIS; |
| | | } |
| | | } |
| | | } |