|
|
|
package com.glxp.api.controller.inout;
|
|
|
|
|
|
|
|
import com.github.pagehelper.PageInfo;
|
|
|
|
import com.glxp.api.common.res.BaseResponse;
|
|
|
|
import com.glxp.api.common.util.ResultVOUtils;
|
|
|
|
import com.glxp.api.controller.BaseController;
|
|
|
|
import com.glxp.api.req.inout.FilterIoCodeRequest;
|
|
|
|
import com.glxp.api.res.inout.IoCodeResponse;
|
|
|
|
import com.glxp.api.service.inout.IoCodeService;
|
|
|
|
import org.springframework.web.bind.annotation.GetMapping;
|
|
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
|
import java.util.List;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 单据正式码表接口
|
|
|
|
*/
|
|
|
|
@RestController
|
|
|
|
public class IoCodeController extends BaseController {
|
|
|
|
|
|
|
|
@Resource
|
|
|
|
private IoCodeService ioCodeService;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 查询单据正式码表数据
|
|
|
|
*
|
|
|
|
* @param filterIoCodeRequest
|
|
|
|
* @return
|
|
|
|
*/
|
|
|
|
@GetMapping("/udiwms/inout/code/filterList")
|
|
|
|
public BaseResponse filterList(FilterIoCodeRequest filterIoCodeRequest) {
|
|
|
|
List<IoCodeResponse> list = ioCodeService.filterList(filterIoCodeRequest);
|
|
|
|
PageInfo<IoCodeResponse> pageInfo = new PageInfo<>(list);
|
|
|
|
return ResultVOUtils.page(pageInfo);
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 根据单据号查询正式码表数据
|
|
|
|
*
|
|
|
|
* @param orderId
|
|
|
|
* @return
|
|
|
|
*/
|
|
|
|
@GetMapping("/udiwms/inout/code/findByOrderId")
|
|
|
|
public BaseResponse findAllByOrderId(String orderId) {
|
|
|
|
FilterIoCodeRequest filterIoCodeRequest = new FilterIoCodeRequest();
|
|
|
|
filterIoCodeRequest.setOrderId(orderId);
|
|
|
|
List<IoCodeResponse> list = ioCodeService.filterList(filterIoCodeRequest);
|
|
|
|
PageInfo<IoCodeResponse> pageInfo = new PageInfo<>(list);
|
|
|
|
return ResultVOUtils.success(pageInfo);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|