Browse Source

add:wms接口

master
gengby 7 months ago
parent
commit
804ef3a786
  1. 15
      nladmin-system/nlsso-server/src/main/java/org/nl/acs/ext/wms/rest/WmsToAcsController.java
  2. 2
      nladmin-system/nlsso-server/src/main/java/org/nl/acs/ext/wms/service/AcsToWmsService.java
  3. 7
      nladmin-system/nlsso-server/src/main/java/org/nl/acs/ext/wms/service/WmsToAcsService.java
  4. 6
      nladmin-system/nlsso-server/src/main/java/org/nl/acs/ext/wms/service/impl/AcsToWmsServiceImpl.java

15
nladmin-system/nlsso-server/src/main/java/org/nl/acs/ext/wms/rest/WmsToAcsController.java

@ -5,6 +5,7 @@ package org.nl.acs.ext.wms.rest;
import cn.dev33.satoken.annotation.SaIgnore;
import com.alibaba.fastjson.JSONObject;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.nl.acs.ext.wms.data.one.CancelTaskRequest;
@ -45,6 +46,20 @@ public class WmsToAcsController {
return new ResponseEntity<>(wmstoacsService.cancelFromWms(reqs), HttpStatus.OK);
}
@PostMapping("/switchInOut")
@Log(value = "切换出入库模式")
@SaIgnore
public ResponseEntity<Object> switchInOut(@RequestBody JSONObject reqs) throws Exception {
return new ResponseEntity<>(wmstoacsService.switchInOut(reqs), HttpStatus.OK);
}
@PostMapping("/pinckStartStop")
@Log(value = "拣选工位启停")
@SaIgnore
public ResponseEntity<Object> pinckStartStop(@RequestBody JSONObject reqs) throws Exception {
return new ResponseEntity<>(wmstoacsService.pinkStartStop(reqs), HttpStatus.OK);
}

2
nladmin-system/nlsso-server/src/main/java/org/nl/acs/ext/wms/service/AcsToWmsService.java

@ -17,6 +17,8 @@ public interface AcsToWmsService {
public UnifiedResponse feedbackTaskStatusToWms(JSONArray arr);
public UnifiedResponse feedPinkStartStop(JSONObject req);
}

7
nladmin-system/nlsso-server/src/main/java/org/nl/acs/ext/wms/service/WmsToAcsService.java

@ -1,6 +1,7 @@
package org.nl.acs.ext.wms.service;
import com.alibaba.fastjson.JSONObject;
import org.nl.acs.ext.wms.data.one.*;
import java.util.List;
@ -31,9 +32,7 @@ public interface WmsToAcsService {
CancelTaskResponse cancelFromWms(List<CancelTaskRequest> reqs) throws Exception;
JSONObject switchInOut(JSONObject reqs);
JSONObject pinkStartStop(JSONObject reqs);
}

6
nladmin-system/nlsso-server/src/main/java/org/nl/acs/ext/wms/service/impl/AcsToWmsServiceImpl.java

@ -37,5 +37,11 @@ public class AcsToWmsServiceImpl implements AcsToWmsService {
return LmsHttpUtil.sendPostRequest(addressDto.getMethods_url(), arr, null);
}
@Override
public UnifiedResponse feedPinkStartStop(JSONObject req) {
AddressDto addressDto = addressService.findByCode("feedPinkStartStop");
return LmsHttpUtil.sendPostRequest(addressDto.getMethods_url(), req, null);
}
}

Loading…
Cancel
Save