|
|
|
@ -4,9 +4,11 @@ import cn.hutool.core.collection.CollUtil;
|
|
|
|
|
import cn.hutool.core.util.StrUtil;
|
|
|
|
|
import com.github.pagehelper.PageInfo;
|
|
|
|
|
import com.glxp.api.annotation.AuthRuleAnnotation;
|
|
|
|
|
import com.glxp.api.annotation.Log;
|
|
|
|
|
import com.glxp.api.common.enums.ResultEnum;
|
|
|
|
|
import com.glxp.api.common.res.BaseResponse;
|
|
|
|
|
import com.glxp.api.common.util.ResultVOUtils;
|
|
|
|
|
import com.glxp.api.constant.BusinessType;
|
|
|
|
|
import com.glxp.api.constant.ConstantStatus;
|
|
|
|
|
import com.glxp.api.controller.BaseController;
|
|
|
|
|
import com.glxp.api.entity.auth.InvBusUserEntity;
|
|
|
|
@ -106,6 +108,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
//新增业务-立即提交
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@PostMapping("warehouse/inout/submitBiz")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.UPDATE)
|
|
|
|
|
public BaseResponse submitBiz(@RequestBody AddOrderRequest addOrderRequest) {
|
|
|
|
|
|
|
|
|
|
//校验单据是否已完成
|
|
|
|
@ -140,6 +143,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
//新增扫码单据-立即提交
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@PostMapping("warehouse/inout/submitCodes")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.UPDATE)
|
|
|
|
|
public BaseResponse submitCodes(@RequestBody AddOrderRequest addOrderRequest) {
|
|
|
|
|
|
|
|
|
|
//校验单据是否已完成
|
|
|
|
@ -162,6 +166,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
//新增业务单据,新增扫码单据,等待校验-草稿保存
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@PostMapping("warehouse/inout/saveOrderWeb")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.UPDATE)
|
|
|
|
|
public BaseResponse saveOrderWeb(@RequestBody AddOrderRequest addOrderRequest) {
|
|
|
|
|
IoOrderEntity orderEntity = new IoOrderEntity();
|
|
|
|
|
if (StrUtil.isEmpty(addOrderRequest.getAction()))
|
|
|
|
@ -191,6 +196,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
//等待校验-立即提交
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@PostMapping("warehouse/inout/submitOrderWeb")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.UPDATE)
|
|
|
|
|
public BaseResponse submitOrderWeb(@RequestBody AddOrderRequest addOrderRequest) {
|
|
|
|
|
|
|
|
|
|
//校验单据是否已完成
|
|
|
|
@ -239,6 +245,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
//未校验单据删除
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@PostMapping("udiwms/inout/order/delete")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.DELETE)
|
|
|
|
|
public BaseResponse deletById(@RequestBody DeleteRequest deleteRequest) {
|
|
|
|
|
orderService.deleteByBillNo(deleteRequest.getBillNo());
|
|
|
|
|
orderDetailBizService.deleteByOrderId(deleteRequest.getBillNo());
|
|
|
|
@ -252,6 +259,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
//已验收单据删除、单据编辑删除等
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@PostMapping("udiwms/inout/order/finish/delete")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.DELETE)
|
|
|
|
|
public BaseResponse deleteById(@RequestBody DeleteRequest deleteRequest) {
|
|
|
|
|
List<String> delBillNos = new ArrayList<>();
|
|
|
|
|
if (CollUtil.isNotEmpty(deleteRequest.getBillNos())) {
|
|
|
|
@ -274,6 +282,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
//单据编辑,条码减一
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@PostMapping("udiwms/inout/code/finish/delete")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.DELETE)
|
|
|
|
|
public BaseResponse deleteCodeById(@RequestBody IoCodeEntity codeEntity) {
|
|
|
|
|
orderService.deleteInvCode(codeEntity.getOrderId(), codeEntity.getCode());
|
|
|
|
|
return ResultVOUtils.success("删除成功!");
|
|
|
|
@ -282,6 +291,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
//已验收单据撤回
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@GetMapping("/udiwms/inout/order/received/rollback")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.UPDATE)
|
|
|
|
|
public BaseResponse rollbackOrder(String billNo) {
|
|
|
|
|
if (StrUtil.isBlank(billNo)) {
|
|
|
|
|
return ResultVOUtils.error(ResultEnum.PARAM_VERIFY_FALL);
|
|
|
|
@ -305,6 +315,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
//已校验单据撤回到等待处理
|
|
|
|
|
@AuthRuleAnnotation("")
|
|
|
|
|
@GetMapping("/udiwms/inout/order/unReceive/rollback")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.UPDATE)
|
|
|
|
|
public BaseResponse rollUnReceivebackOrder(String billNo) {
|
|
|
|
|
if (StrUtil.isBlank(billNo)) {
|
|
|
|
|
return ResultVOUtils.error(ResultEnum.PARAM_VERIFY_FALL);
|
|
|
|
@ -435,6 +446,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
* @return
|
|
|
|
|
*/
|
|
|
|
|
@PostMapping("/udiwms/inout/order/updateOrderInfo")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.UPDATE)
|
|
|
|
|
public BaseResponse updateOrderInfo(@RequestBody OrderEditRequest orderEditRequest) {
|
|
|
|
|
if (null == orderEditRequest || CollUtil.isEmpty(orderEditRequest.getOrderIds())) {
|
|
|
|
|
return ResultVOUtils.error(ResultEnum.PARAM_VERIFY_FALL);
|
|
|
|
@ -471,6 +483,7 @@ public class IoOrderController extends BaseController {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@PostMapping("/udiwms/inout/order/updateOrderDetailBiz")
|
|
|
|
|
@Log(title = "单据管理", businessType = BusinessType.UPDATE)
|
|
|
|
|
public BaseResponse updateOrderDetailBiz(@RequestBody IoOrderDetailBizEntity ioOrderDetailBizEntity) {
|
|
|
|
|
if (null == ioOrderDetailBizEntity) {
|
|
|
|
|
return ResultVOUtils.error(ResultEnum.PARAM_VERIFY_FALL);
|
|
|
|
|