Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
e5d8dd7ddb
2 changed files with 6 additions and 2 deletions
|
|
@ -353,6 +353,10 @@ public class OrderCurrencyListener extends QueueConsumer implements Initializing
|
||||||
for (Long orderId : payload.getIds()) {
|
for (Long orderId : payload.getIds()) {
|
||||||
SOrders sOrder = sOrdersImdg.getSingleObjectByID(orderId);
|
SOrders sOrder = sOrdersImdg.getSingleObjectByID(orderId);
|
||||||
OrderCurrency orderCurrency = orderCurrencyImdg.getSingleObjectByID(orderId);
|
OrderCurrency orderCurrency = orderCurrencyImdg.getSingleObjectByID(orderId);
|
||||||
|
if (orderCurrency == null) {
|
||||||
|
log.warn("OrderCurrency[{}] not found", orderId);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
OrderStatus status = resolveStatusByImportState(sOrder.getState());
|
OrderStatus status = resolveStatusByImportState(sOrder.getState());
|
||||||
if (status == null) {
|
if (status == null) {
|
||||||
continue;
|
continue;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ import java.io.IOException;
|
||||||
import java.nio.charset.StandardCharsets;
|
import java.nio.charset.StandardCharsets;
|
||||||
import java.nio.file.Files;
|
import java.nio.file.Files;
|
||||||
import java.nio.file.Path;
|
import java.nio.file.Path;
|
||||||
import java.time.LocalTime;
|
import java.time.LocalDateTime;
|
||||||
import java.time.format.DateTimeFormatter;
|
import java.time.format.DateTimeFormatter;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Optional;
|
import java.util.Optional;
|
||||||
|
|
@ -119,7 +119,7 @@ public class TaskListener extends QueueConsumer implements InitializingBean {
|
||||||
Collection<OrderCurrency> orders = imdgQueryService.getClccOrderCurrencyIds();
|
Collection<OrderCurrency> orders = imdgQueryService.getClccOrderCurrencyIds();
|
||||||
String content = orderCurrencyTriExportService.exportToTri(orders);
|
String content = orderCurrencyTriExportService.exportToTri(orders);
|
||||||
Path fileName = storagePath.resolve(String.format("KS_TS_ORDERS_%s.tri",
|
Path fileName = storagePath.resolve(String.format("KS_TS_ORDERS_%s.tri",
|
||||||
LocalTime.now().format(formatter)));
|
LocalDateTime.now().format(formatter)));
|
||||||
Files.writeString(fileName, content, StandardCharsets.UTF_8);
|
Files.writeString(fileName, content, StandardCharsets.UTF_8);
|
||||||
kafkaSender.sendRequestToQueue(Consts.SDOR_FIX_TASK, req.getRequestPayload());
|
kafkaSender.sendRequestToQueue(Consts.SDOR_FIX_TASK, req.getRequestPayload());
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue