|
|
@@ -0,0 +1,53 @@
|
|
|
+package easydo.technology.controller;
|
|
|
+
|
|
|
+import easydo.technology.service.WarehouseOutboundService;
|
|
|
+import org.springframework.http.HttpStatus;
|
|
|
+import org.springframework.http.ResponseEntity;
|
|
|
+import org.springframework.web.bind.annotation.PostMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestBody;
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
+
|
|
|
+import javax.annotation.Resource;
|
|
|
+import java.util.HashMap;
|
|
|
+import java.util.Map;
|
|
|
+
|
|
|
+@RestController
|
|
|
+@RequestMapping("/warehouseOutbound")
|
|
|
+public class WarehouseOutboundController {
|
|
|
+
|
|
|
+ @Resource
|
|
|
+ private WarehouseOutboundService warehouseOutboundService;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 出库单主表分页查询
|
|
|
+ */
|
|
|
+ @PostMapping(value = "/getPage")
|
|
|
+ public Object getPage(@RequestBody(required = false) Map<String, Object> map) {
|
|
|
+ try {
|
|
|
+ if (map == null) {
|
|
|
+ map = new HashMap<>();
|
|
|
+ }
|
|
|
+ Map<String, Object> page = warehouseOutboundService.getOutboundPage(map);
|
|
|
+ return new ResponseEntity<>(page, HttpStatus.OK);
|
|
|
+ } catch (Exception e) {
|
|
|
+ return new ResponseEntity<>(HttpStatus.INTERNAL_SERVER_ERROR);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 出库单明细查询(不分页)
|
|
|
+ */
|
|
|
+ @PostMapping(value = "/getItemList")
|
|
|
+ public Object getItemList(@RequestBody(required = false) Map<String, Object> map) {
|
|
|
+ try {
|
|
|
+ if (map == null) {
|
|
|
+ map = new HashMap<>();
|
|
|
+ }
|
|
|
+ Object list = warehouseOutboundService.getOutboundItemList(map);
|
|
|
+ return new ResponseEntity<>(list, HttpStatus.OK);
|
|
|
+ } catch (Exception e) {
|
|
|
+ return new ResponseEntity<>(HttpStatus.INTERNAL_SERVER_ERROR);
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|