|
@@ -219,27 +219,44 @@ public class TmstruckReceiptResultController extends BaseRESTfulController {
|
|
@PostMapping("/getReceivingPhoto")
|
|
@PostMapping("/getReceivingPhoto")
|
|
public RESTfulResult getReceivingPhoto(@RequestParam String orderNumber) throws Exception {
|
|
public RESTfulResult getReceivingPhoto(@RequestParam String orderNumber) throws Exception {
|
|
List<Map<String,Object>> mapList = tmstruckReceiptResultService.getReceivingPhoto(orderNumber);
|
|
List<Map<String,Object>> mapList = tmstruckReceiptResultService.getReceivingPhoto(orderNumber);
|
|
-
|
|
|
|
|
|
+ Map<String,Object> result=new HashMap<>();
|
|
for(Map<String,Object> map:mapList){
|
|
for(Map<String,Object> map:mapList){
|
|
if(map.containsKey("resultEmptyContainerPhoto") && map.get("resultEmptyContainerPhoto")!=null){
|
|
if(map.containsKey("resultEmptyContainerPhoto") && map.get("resultEmptyContainerPhoto")!=null){
|
|
String resultEmptyContainerPhoto = (String) imageFileUtils.downloadFile(map.get("resultEmptyContainerPhoto").toString());
|
|
String resultEmptyContainerPhoto = (String) imageFileUtils.downloadFile(map.get("resultEmptyContainerPhoto").toString());
|
|
- map.put("resultEmptyContainerPhoto",resultEmptyContainerPhoto);
|
|
|
|
|
|
+ result.put("resultEmptyContainerPhoto",resultEmptyContainerPhoto);
|
|
}
|
|
}
|
|
if(map.containsKey("resultSignedNotePhoto") && map.get("resultSignedNotePhoto")!=null){
|
|
if(map.containsKey("resultSignedNotePhoto") && map.get("resultSignedNotePhoto")!=null){
|
|
String resultSignedNotePhoto = (String) imageFileUtils.downloadFile(map.get("resultSignedNotePhoto").toString());
|
|
String resultSignedNotePhoto = (String) imageFileUtils.downloadFile(map.get("resultSignedNotePhoto").toString());
|
|
- map.put("resultSignedNotePhoto",resultSignedNotePhoto);
|
|
|
|
|
|
+ result.put("resultSignedNotePhoto",resultSignedNotePhoto);
|
|
|
|
+ }
|
|
|
|
+ //追加的图片
|
|
|
|
+ if(map.containsKey("otherPhoto1") && map.get("otherPhoto1")!=null){
|
|
|
|
+ String resultSignedNotePhoto =(String) imageFileUtils.downloadFile(map.get("otherPhoto1").toString());
|
|
|
|
+ result.put("otherPhoto1",resultSignedNotePhoto);
|
|
|
|
+ }
|
|
|
|
+ if(map.containsKey("otherPhoto2") && map.get("otherPhoto2") !=null){
|
|
|
|
+ String resultSignedNotePhoto =(String) imageFileUtils.downloadFile(map.get("otherPhoto2").toString());
|
|
|
|
+ result.put("otherPhoto2",resultSignedNotePhoto);
|
|
|
|
+ }
|
|
|
|
+ if(map.containsKey("otherPhoto3") && map.get("otherPhoto3") !=null){
|
|
|
|
+ String resultSignedNotePhoto =(String) imageFileUtils.downloadFile(map.get("otherPhoto3").toString());
|
|
|
|
+ result.put("otherPhoto3",resultSignedNotePhoto);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
-
|
|
|
|
- return success(mapList.get(0));
|
|
|
|
|
|
+ return success(result);
|
|
}
|
|
}
|
|
@ApiOperation(value = "获取收货作业照片")
|
|
@ApiOperation(value = "获取收货作业照片")
|
|
@PostMapping("/getReceivingPhotoByUrl")
|
|
@PostMapping("/getReceivingPhotoByUrl")
|
|
public Map<String,Object> getReceivingPhotoByUrl(@RequestParam String orderNumber) throws Exception {
|
|
public Map<String,Object> getReceivingPhotoByUrl(@RequestParam String orderNumber) throws Exception {
|
|
List<Map<String,Object>> mapList = tmstruckReceiptResultService.getReceivingPhoto(orderNumber);
|
|
List<Map<String,Object>> mapList = tmstruckReceiptResultService.getReceivingPhoto(orderNumber);
|
|
Map<String,Object> mapvalue = null;
|
|
Map<String,Object> mapvalue = null;
|
|
- if (mapList!=null){
|
|
|
|
|
|
+ if (mapList!=null && mapList.size()>0){
|
|
|
|
+ //必选的图片
|
|
mapvalue=mapList.get(0);
|
|
mapvalue=mapList.get(0);
|
|
|
|
+ //追加的三张图片
|
|
|
|
+ if(mapList.get(1)!=null){
|
|
|
|
+ mapvalue.putAll(mapList.get(1));
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
return mapvalue;
|
|
return mapvalue;
|