update订单状态和枪口状态

This commit is contained in:
YAS\29473
2025-06-19 16:36:25 +08:00
parent 2a1babb9c9
commit f316be9071
2 changed files with 26 additions and 2 deletions

View File

@@ -1,5 +1,6 @@
package com.jsowell.common.enums.ykc;
import java.util.Objects;
/**
* order_basic_info表 order_status字段
* 订单状态(0-未启动1-充电中2-待结算3-待补缴4-异常5-可疑6-订单完成7-超时关闭)
@@ -48,4 +49,21 @@ public enum OrderStatusEnum {
}
return "";
}
// 中电联订单状态转化
public static Integer convertToNewStatus(String orderStatus) {
if (Objects.equals(orderStatus , IN_THE_CHARGING.value)) {
return 2; // 充电中
} else if (Objects.equals(orderStatus , ORDER_COMPLETE.value)) {
return 4; // 充电完成
} else if (Objects.equals(orderStatus , NOT_START.value)) {
return 1; // 启动中
} else if (Objects.equals(orderStatus , STAY_SETTLEMENT.value) || Objects.equals(orderStatus , STAY_RETROACTIVE_AMOUNT.value)) {
return 3; // 停止中
} else {
return 5; // 未知
}
}
}