diff --git a/src/main/java/com/chint/application/dtos/trip/ScheduleDetail.java b/src/main/java/com/chint/application/dtos/trip/ScheduleDetail.java index 2229ee18..1eb6d774 100644 --- a/src/main/java/com/chint/application/dtos/trip/ScheduleDetail.java +++ b/src/main/java/com/chint/application/dtos/trip/ScheduleDetail.java @@ -125,6 +125,10 @@ public class ScheduleDetail { private String amountTypeName; @JsonProperty("AmountTypeEnName") private String amountTypeEnName; + @JsonProperty("AmountDescription") + private String amountDescription; + @JsonProperty("amountDescription") + private String amountDescription2; @JsonProperty("ExpenseExplanation") private String expenseExplanation; @JsonProperty("OriginDescription") @@ -175,6 +179,17 @@ public class ScheduleDetail { return this; } + + public ScheduleDetailBuilder amountDescription(String amountDescription) { + scheduleDetail.setAmountDescription(amountDescription); + return this; + } + + public ScheduleDetailBuilder amountDescription2(String amountDescription2) { + scheduleDetail.setAmountDescription2(amountDescription2); + return this; + } + public ScheduleDetailBuilder originDescription(String originDescription) { scheduleDetail.setOriginDescription(originDescription); return this; diff --git a/src/main/java/com/chint/application/queryies/OrderQuery.java b/src/main/java/com/chint/application/queryies/OrderQuery.java index f0c16d39..ad80ab11 100644 --- a/src/main/java/com/chint/application/queryies/OrderQuery.java +++ b/src/main/java/com/chint/application/queryies/OrderQuery.java @@ -469,7 +469,16 @@ public class OrderQuery { scheduleDetailBuilder .locationList(locationList1.stream().map(LocationRes::copyFrom).toList()); } + + Integer amountType = legExtensionField.getAmountType(); + if (amountType != null && amountType.equals(LEG_OTHER_AMOUNT_TYPE_VISA)) { + scheduleDetailBuilder.amountDescription("类型:" + + legExtensionField.getExtension() + " 理由:" + + legExtensionField.getExpenseExplanation()); + } } + + return scheduleDetailBuilder .scheduleNum(leg.getLegNo()) .scheduleType(translateLegType(leg.getLegType())) diff --git a/src/main/java/com/chint/domain/aggregates/approval/ApprovalMethod.java b/src/main/java/com/chint/domain/aggregates/approval/ApprovalMethod.java new file mode 100644 index 00000000..52ce97bf --- /dev/null +++ b/src/main/java/com/chint/domain/aggregates/approval/ApprovalMethod.java @@ -0,0 +1,5 @@ +package com.chint.domain.aggregates.approval; + +public enum ApprovalMethod { + NOTIFY, APPROVE +} diff --git a/src/main/java/com/chint/domain/aggregates/approval/ApprovalProcess.java b/src/main/java/com/chint/domain/aggregates/approval/ApprovalProcess.java index c686360b..0e53a266 100644 --- a/src/main/java/com/chint/domain/aggregates/approval/ApprovalProcess.java +++ b/src/main/java/com/chint/domain/aggregates/approval/ApprovalProcess.java @@ -24,6 +24,8 @@ public abstract class ApprovalProcess { public ApprovalType approvalType; + private ApprovalMethod approvalMethod; + public ApprovalProcess(ApprovalPlatform bpmPlatform) { this.bpmPlatform = bpmPlatform; } @@ -99,7 +101,6 @@ public abstract class ApprovalProcess { // 通用的通知方法 public void notifyUser(String message) { - // 发送通知的逻辑 System.out.println("Notify user: " + message); } diff --git a/src/main/java/com/chint/domain/aggregates/approval/ApprovalRecord.java b/src/main/java/com/chint/domain/aggregates/approval/ApprovalRecord.java index 813ea91d..e3e5d203 100644 --- a/src/main/java/com/chint/domain/aggregates/approval/ApprovalRecord.java +++ b/src/main/java/com/chint/domain/aggregates/approval/ApprovalRecord.java @@ -63,6 +63,10 @@ public class ApprovalRecord implements Serializable { return 1; } + public static Integer notifyApprovalStatus() { + return 2; + } + public static Integer rejectApprovalStatus() { return -1; } @@ -74,6 +78,9 @@ public class ApprovalRecord implements Serializable { if (Objects.equals(this.approvalStatus, successApprovalStatus())) { return "已通过"; } + if (Objects.equals(this.approvalStatus, notifyApprovalStatus())) { + return "已知会"; + } if (Objects.equals(this.approvalStatus, rejectApprovalStatus())) { return "已驳回"; } diff --git a/src/main/java/com/chint/domain/service/supplier/SupplierServiceImpl.java b/src/main/java/com/chint/domain/service/supplier/SupplierServiceImpl.java index f871639a..0cee3975 100644 --- a/src/main/java/com/chint/domain/service/supplier/SupplierServiceImpl.java +++ b/src/main/java/com/chint/domain/service/supplier/SupplierServiceImpl.java @@ -297,7 +297,10 @@ public class SupplierServiceImpl implements SupplierService { orderEventType.equals(ORDER_EVENT_REFUND); } - private List handleSpecialEvent(OrderDetail orderDetail, OrderStatusChangeCommand command, Integer orderEventType, Object outOrderDetailData) { + private List handleSpecialEvent(OrderDetail orderDetail, + OrderStatusChangeCommand command, + Integer orderEventType, + Object outOrderDetailData) { // orderDetail.getExtensionDataByProductType(); //异步推送审批流 CompletableFuture.runAsync(() -> sendBPMAuditCommand(orderDetail, command, orderEventType)); diff --git a/src/main/java/com/chint/infrastructure/constant/LegConstant.java b/src/main/java/com/chint/infrastructure/constant/LegConstant.java index dd0a4dfb..638cd6f7 100644 --- a/src/main/java/com/chint/infrastructure/constant/LegConstant.java +++ b/src/main/java/com/chint/infrastructure/constant/LegConstant.java @@ -33,6 +33,8 @@ public class LegConstant { public static final String LEG_APPROVAL_STATUS_SUCCESS_NAME = "已通过"; public static final int LEG_APPROVAL_STATUS_REJECT = 3; public static final String LEG_APPROVAL_STATUS_REJECT_NAME = "已驳回"; + public static final int LEG_APPROVAL_STATUS_NOTIFY = 4; + public static final String LEG_APPROVAL_STATUS_NOTIFY_NAME = "已知会"; // 规划节点运输方式