diff --git a/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/TaskController.java b/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/MobileController.java index 729c33a..96a1a66 100644 --- a/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/TaskController.java +++ b/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/MobileController.java @@ -4,6 +4,8 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.toolkit.Wrappers; import io.swagger.annotations.Api; import org.jeecg.common.api.vo.Result; +import org.jeecg.modules.system.entity.SysDictItem; +import org.jeecg.modules.system.service.impl.SysDictItemServiceImpl; import org.jeecg.modules.wms.api.mobile.entity.TvTaskVo; import org.jeecg.modules.wms.task.taskHeader.entity.TaskDetail; import org.jeecg.modules.wms.task.taskHeader.entity.TaskHeader; @@ -18,19 +20,23 @@ import org.springframework.web.bind.annotation.RestController; import javax.annotation.Resource; import java.util.ArrayList; import java.util.Arrays; +import java.util.HashMap; import java.util.List; /** */ @Api(tags = "Mobile") @RestController -@RequestMapping("/api/mobile/task") -public class TaskController { +@RequestMapping("/api/mobile") +public class MobileController { @Resource private TaskHeaderServiceImpl taskHeaderService; @Resource + private SysDictItemServiceImpl sysDictItemService; + + @Resource private TaskDetailServiceImpl taskDetailService; @GetMapping("taskOfStation") @@ -40,6 +46,27 @@ public class TaskController { stationList = Arrays.asList(code.split(",")); } + HashMap<String, String> typeMap = new HashMap<>(); + typeMap.put("100", "整盘入库"); + typeMap.put("200", "补充入库"); + typeMap.put("300", "整盘出库"); + typeMap.put("400", "分拣出库"); + typeMap.put("500", "空容器入库"); + typeMap.put("600", "空容器出库"); + typeMap.put("700", "盘点"); + typeMap.put("800", "移库"); + typeMap.put("900", "出库查看"); + typeMap.put("1000", "换站"); + typeMap.put("1100", "空托盘组入库"); + typeMap.put("1200", "空托盘组出库"); + typeMap.put("1300", "空托盘组换站"); + + HashMap<String, String> statusMap = new HashMap<>(); + statusMap.put("1", "生成任务"); + statusMap.put("10", "下发任务"); + statusMap.put("50", "到达拣选台"); + statusMap.put("100", "任务完成"); + LambdaQueryWrapper<TaskHeader> hQuery = Wrappers.lambdaQuery(); hQuery.eq(TaskHeader::getStatus, QuantityConstant.TASK_STATUS_ARRIVED_STATION) .in(stationList.size() > 0, TaskHeader::getToPortCode, stationList); @@ -47,6 +74,8 @@ public class TaskController { List<TvTaskVo> list = new ArrayList<>(); for (TaskHeader header : headers) { + header.setUserdef1(typeMap.get(header.getTaskType().toString())); + header.setUserdef2(statusMap.get(header.getStatus().toString())); TvTaskVo vo = new TvTaskVo(); LambdaQueryWrapper<TaskDetail> dQuery = Wrappers.lambdaQuery(); dQuery.eq(TaskDetail::getTaskHeaderId, header.getId()); diff --git a/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/ReceiptController.java b/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/ReceiptController.java deleted file mode 100644 index b2283a7..0000000 --- a/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/ReceiptController.java +++ /dev/null @@ -1,23 +0,0 @@ -package org.jeecg.modules.wms.api.mobile.controller; - -import javax.annotation.Resource; - -import org.jeecg.modules.wms.api.mobile.service.IMobileService; -import org.jeecg.modules.wms.framework.controller.HuahengBaseController; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RestController; - -import io.swagger.annotations.Api; - -/** - * PDA入库接口,整合复用PC端service层接口 - */ -@Api(tags = "Mobile") -@RestController -@RequestMapping("/mobile/receipt") -public class ReceiptController extends HuahengBaseController { - - @Resource - private IMobileService mobileService; - -} diff --git a/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/ShipmentController.java b/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/ShipmentController.java deleted file mode 100644 index 49b7759..0000000 --- a/huaheng-wms-core/src/main/java/org/jeecg/modules/wms/api/mobile/controller/ShipmentController.java +++ /dev/null @@ -1,24 +0,0 @@ -package org.jeecg.modules.wms.api.mobile.controller; - -import javax.annotation.Resource; - -import org.jeecg.modules.wms.api.mobile.service.IMobileService; -import org.jeecg.modules.wms.framework.controller.HuahengBaseController; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RestController; - -import io.swagger.annotations.Api; - -/** - * * PDA出库接口,整合复用PC端service层接口 - */ -@Api(tags = "Mobile") -@RestController -@RequestMapping("/mobile/shipment") -public class ShipmentController extends HuahengBaseController { - - @Resource - private IMobileService mobileService; - - -}