|
|
|
@ -16,44 +16,42 @@
|
|
|
|
|
*/ |
|
|
|
|
package com.logpm.warehouse.controller; |
|
|
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
|
|
|
|
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
|
|
|
|
import com.logpm.warehouse.dto.UpShelfOrderDTO; |
|
|
|
|
import com.logpm.warehouse.dto.UpdownTypeDTO; |
|
|
|
|
import com.logpm.warehouse.entity.WarehouseGoodsAllocationEntity; |
|
|
|
|
import com.logpm.warehouse.excel.WarehouseGoodsAllocationExcel; |
|
|
|
|
import com.logpm.warehouse.service.IWarehouseGoodsAllocationService; |
|
|
|
|
import com.logpm.warehouse.service.IWarehouseUpdownTypeService; |
|
|
|
|
import com.logpm.warehouse.vo.WarehouseGoodsAllocationVO; |
|
|
|
|
import com.logpm.warehouse.vo.WarehouseStockArticleCopyVO; |
|
|
|
|
import com.logpm.warehouse.vo.WarehouseVisCargo; |
|
|
|
|
import com.logpm.warehouse.vo.WarehouseVisualizationVO; |
|
|
|
|
import com.logpm.warehouse.wrapper.WarehouseGoodsAllocationWrapper; |
|
|
|
|
import io.swagger.annotations.Api; |
|
|
|
|
import io.swagger.annotations.ApiOperation; |
|
|
|
|
import io.swagger.annotations.ApiParam; |
|
|
|
|
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
|
|
|
|
import lombok.AllArgsConstructor; |
|
|
|
|
import javax.validation.Valid; |
|
|
|
|
|
|
|
|
|
import org.springblade.core.secure.BladeUser; |
|
|
|
|
import org.springblade.core.boot.ctrl.BladeController; |
|
|
|
|
import org.springblade.core.excel.util.ExcelUtil; |
|
|
|
|
import org.springblade.core.mp.support.Condition; |
|
|
|
|
import org.springblade.core.mp.support.Query; |
|
|
|
|
import org.springblade.core.secure.BladeUser; |
|
|
|
|
import org.springblade.core.tool.api.R; |
|
|
|
|
import org.springblade.core.tool.constant.BladeConstant; |
|
|
|
|
import org.springblade.core.tool.utils.DateUtil; |
|
|
|
|
import org.springblade.core.tool.utils.Func; |
|
|
|
|
import org.springblade.core.tool.utils.StringUtil; |
|
|
|
|
import org.springframework.web.bind.annotation.*; |
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
|
|
|
|
import com.logpm.warehouse.entity.WarehouseGoodsAllocationEntity; |
|
|
|
|
import com.logpm.warehouse.vo.WarehouseGoodsAllocationVO; |
|
|
|
|
import com.logpm.warehouse.excel.WarehouseGoodsAllocationExcel; |
|
|
|
|
import com.logpm.warehouse.wrapper.WarehouseGoodsAllocationWrapper; |
|
|
|
|
import com.logpm.warehouse.service.IWarehouseGoodsAllocationService; |
|
|
|
|
import org.springblade.core.boot.ctrl.BladeController; |
|
|
|
|
import org.springblade.core.tool.utils.DateUtil; |
|
|
|
|
import org.springblade.core.excel.util.ExcelUtil; |
|
|
|
|
import org.springblade.core.tool.constant.BladeConstant; |
|
|
|
|
import springfox.documentation.annotations.ApiIgnore; |
|
|
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
|
import java.util.Map; |
|
|
|
|
import javax.servlet.http.HttpServletResponse; |
|
|
|
|
import javax.validation.Valid; |
|
|
|
|
import java.util.List; |
|
|
|
|
import java.util.Map; |
|
|
|
|
import java.util.Objects; |
|
|
|
|
import java.util.stream.Collectors; |
|
|
|
|
import javax.servlet.http.HttpServletResponse; |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 货位 控制器 |
|
|
|
@ -156,11 +154,11 @@ public class WarehouseGoodsAllocationController extends BladeController {
|
|
|
|
|
@ApiOperation(value = "货位上架 订单上架", notes = "传入updownTypeDTO") |
|
|
|
|
public R uporder(@RequestBody UpdownTypeDTO updownTypeDTO) { |
|
|
|
|
List<UpShelfOrderDTO> upShelfOrderList = updownTypeDTO.getUpShelfOrderList(); |
|
|
|
|
String allocationCode = updownTypeDTO.getTargetAllocation(); |
|
|
|
|
if (upShelfOrderList.size()==0 || StringUtil.isBlank(allocationCode)){ |
|
|
|
|
Long allocationId = updownTypeDTO.getAllocationId(); |
|
|
|
|
if (upShelfOrderList.size()==0 || Objects.isNull(allocationId)){ |
|
|
|
|
return R.fail("参数不全"); |
|
|
|
|
} |
|
|
|
|
return warehouseUpdownTypeService.upShelfOrder(upShelfOrderList,allocationCode); |
|
|
|
|
return warehouseUpdownTypeService.upShelfOrder(upShelfOrderList,allocationId); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -173,8 +171,8 @@ public class WarehouseGoodsAllocationController extends BladeController {
|
|
|
|
|
public R upservice(@RequestBody UpdownTypeDTO updownTypeDTO) { |
|
|
|
|
//取出服务号
|
|
|
|
|
List<UpShelfOrderDTO> upShelfOrderList = updownTypeDTO.getUpShelfOrderList(); |
|
|
|
|
String allocationCode = updownTypeDTO.getTargetAllocation(); |
|
|
|
|
if (upShelfOrderList.size()==0 || StringUtil.isBlank(allocationCode)){ |
|
|
|
|
Long allocationId = updownTypeDTO.getAllocationId(); |
|
|
|
|
if (upShelfOrderList.size()==0 || Objects.isNull(allocationId)){ |
|
|
|
|
return R.fail("参数不全"); |
|
|
|
|
}else { |
|
|
|
|
List<String> ServiceNumberList = upShelfOrderList.stream().map(UpShelfOrderDTO::getServiceNumber).collect(Collectors.toList()); |
|
|
|
@ -182,7 +180,7 @@ public class WarehouseGoodsAllocationController extends BladeController {
|
|
|
|
|
upShelfOrderList = warehouseGoodsAllocationService.selectorderByServiceNumber(ServiceNumberList); |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
return warehouseUpdownTypeService.upShelfOrder(upShelfOrderList,allocationCode); |
|
|
|
|
return warehouseUpdownTypeService.upShelfOrder(upShelfOrderList,allocationId); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
@ -194,8 +192,8 @@ public class WarehouseGoodsAllocationController extends BladeController {
|
|
|
|
|
public R upPackage(@RequestBody UpdownTypeDTO updownTypeDTO) { |
|
|
|
|
//取出服务号
|
|
|
|
|
List<UpShelfOrderDTO> upShelfOrderList = updownTypeDTO.getUpShelfOrderList(); |
|
|
|
|
String allocationCode = updownTypeDTO.getTargetAllocation(); |
|
|
|
|
if (upShelfOrderList.size()==0 || StringUtil.isBlank(allocationCode)){ |
|
|
|
|
Long allocationId = updownTypeDTO.getAllocationId(); |
|
|
|
|
if (upShelfOrderList.size()==0 || Objects.isNull(allocationId)){ |
|
|
|
|
return R.fail("参数不全"); |
|
|
|
|
}else { |
|
|
|
|
List<String> ServiceNumberList = upShelfOrderList.stream().map(UpShelfOrderDTO::getServiceNumber).collect(Collectors.toList()); |
|
|
|
@ -203,7 +201,7 @@ public class WarehouseGoodsAllocationController extends BladeController {
|
|
|
|
|
upShelfOrderList = warehouseGoodsAllocationService.selectorderByServiceNumber(ServiceNumberList); |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
return warehouseUpdownTypeService.upShelfOrder(upShelfOrderList,allocationCode); |
|
|
|
|
return warehouseUpdownTypeService.upShelfOrder(upShelfOrderList,allocationId); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|