同步代码
This commit is contained in:
parent
803efc7790
commit
355c61e32a
|
@ -20,6 +20,7 @@ import com.chint.infrastructure.constant.FSSCConstant;
|
||||||
import com.chint.infrastructure.constant.LegConstant;
|
import com.chint.infrastructure.constant.LegConstant;
|
||||||
import com.chint.infrastructure.util.BaseContext;
|
import com.chint.infrastructure.util.BaseContext;
|
||||||
import com.chint.infrastructure.util.PageResult;
|
import com.chint.infrastructure.util.PageResult;
|
||||||
|
import com.chint.interfaces.rest.user.UserHttpRequest;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.data.domain.Page;
|
import org.springframework.data.domain.Page;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
@ -32,7 +33,6 @@ import java.util.stream.Collectors;
|
||||||
import java.util.stream.Stream;
|
import java.util.stream.Stream;
|
||||||
|
|
||||||
import static com.chint.infrastructure.constant.SupplierNameConstant.SUPPLIER_C_TRIP;
|
import static com.chint.infrastructure.constant.SupplierNameConstant.SUPPLIER_C_TRIP;
|
||||||
import static com.chint.infrastructure.constant.SupplierNameConstant.SUPPLIER_L_Y;
|
|
||||||
|
|
||||||
@Service
|
@Service
|
||||||
public class OrderQuery {
|
public class OrderQuery {
|
||||||
|
@ -52,6 +52,9 @@ public class OrderQuery {
|
||||||
@Autowired
|
@Autowired
|
||||||
private UserRepository userRepository;
|
private UserRepository userRepository;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private UserHttpRequest userHttpRequest;
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private EstimateAdapter estimateAdapter;
|
private EstimateAdapter estimateAdapter;
|
||||||
|
|
||||||
|
@ -118,7 +121,6 @@ public class OrderQuery {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//执行普通分页查询
|
//执行普通分页查询
|
||||||
PageResult<RouteOrder> routeOrderPageResult = routeRepository.pageQuery(queryData);
|
PageResult<RouteOrder> routeOrderPageResult = routeRepository.pageQuery(queryData);
|
||||||
routeOrderPageResult.getRecords().forEach(order -> {
|
routeOrderPageResult.getRecords().forEach(order -> {
|
||||||
|
@ -169,7 +171,7 @@ public class OrderQuery {
|
||||||
}
|
}
|
||||||
|
|
||||||
public TripCallback queryTripCallbackData(OrderQueryData queryData) {
|
public TripCallback queryTripCallbackData(OrderQueryData queryData) {
|
||||||
User currentUser = BaseContext.getCurrentUser();
|
|
||||||
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
|
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
|
||||||
DateTimeFormatter simpleFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
DateTimeFormatter simpleFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
||||||
// RouteOrder routeOrder = routeRepository.findByFakeOrderNoAndSysCode(queryData.getBillcode(), queryData.getSysCode())
|
// RouteOrder routeOrder = routeRepository.findByFakeOrderNoAndSysCode(queryData.getBillcode(), queryData.getSysCode())
|
||||||
|
@ -177,10 +179,13 @@ public class OrderQuery {
|
||||||
RouteOrder routeOrder = routeRepository.queryById(queryData.getRouteId())
|
RouteOrder routeOrder = routeRepository.queryById(queryData.getRouteId())
|
||||||
.reloadStatus();
|
.reloadStatus();
|
||||||
List<Location> locationList = new ArrayList<>();
|
List<Location> locationList = new ArrayList<>();
|
||||||
|
User currentUser = userHttpRequest.loadUserInfo(
|
||||||
|
userRepository.findByUserEmployeeNo(routeOrder.getUserId())
|
||||||
|
);
|
||||||
List<Leg> legItems =
|
List<Leg> legItems =
|
||||||
orderDomainService.queryLocation(routeOrder.getLegItems());
|
orderDomainService.queryLocation(routeOrder.getLegItems());
|
||||||
|
|
||||||
|
|
||||||
legItems.forEach(leg -> {
|
legItems.forEach(leg -> {
|
||||||
if (!locationList.contains(leg.getOriginLocation())) {
|
if (!locationList.contains(leg.getOriginLocation())) {
|
||||||
locationList.add(leg.getOriginLocation());
|
locationList.add(leg.getOriginLocation());
|
||||||
|
|
Loading…
Reference in New Issue