|
@@ -524,14 +524,15 @@ public class OffSiteTransportationController extends BaseRESTfulController {
|
|
|
}
|
|
|
@GetMapping("/getCurrentLocation")
|
|
|
public RESTfulResult getCurrentLocation(@RequestParam("capcityNumber") String capcityNumber) throws Exception {
|
|
|
-// //判断是否自提
|
|
|
-// int count = offSiteTransportationService.isSelfMention(capcityNumber);
|
|
|
-// if (count==0){
|
|
|
- CurrentLocationResult currentLocationResult = routeService.getCurrentLocation(capcityNumber);
|
|
|
- return success(currentLocationResult);
|
|
|
-// }else {
|
|
|
-// return failed(-1);
|
|
|
-// }
|
|
|
+ //自提 且 运输订单未关闭的,不能查看
|
|
|
+ int isSelfMention = offSiteTransportationService.isSelfMention(capcityNumber);//是否自提,0为非自提
|
|
|
+ int isClose=offSiteTransportationService.isCloseOrder(capcityNumber);//是否关闭,0为未关闭
|
|
|
+ if (isSelfMention!=0 && isClose==0){
|
|
|
+ return failed(-1);
|
|
|
+ }else {
|
|
|
+ CurrentLocationResult currentLocationResult = routeService.getCurrentLocation(capcityNumber);
|
|
|
+ return success(currentLocationResult);
|
|
|
+ }
|
|
|
|
|
|
|
|
|
}
|