package com.wms_main.controller.wcs;

import com.wms_main.model.dto.request.wcs.WcsVehicleInRequest;
import com.wms_main.model.dto.response.wcs.InTaskResp;
import com.wms_main.model.dto.response.wcs.WcsApiResponse;
import com.wms_main.service.controller.IWcsControllerService;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*;

/**
 * 给WCS调用的控制器
 */
@RestController
@ResponseBody
@CrossOrigin
@RequiredArgsConstructor
@RequestMapping("/wcs")
public class WcsController {

    private final IWcsControllerService wcsControllerService;

    @PostMapping("/requireInTask")
    public WcsApiResponse<InTaskResp> requireInTask(@RequestBody WcsVehicleInRequest request) {
        return wcsControllerService.requireInTask(request);
    }
}
