mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-21 11:35:12 +08:00
新增 甬城泊车相关接口、controller
This commit is contained in:
66
jsowell-common/src/main/java/com/jsowell/common/enums/thirdparty/ThirdPartyOperatorIdEnum.java
vendored
Normal file
66
jsowell-common/src/main/java/com/jsowell/common/enums/thirdparty/ThirdPartyOperatorIdEnum.java
vendored
Normal file
@@ -0,0 +1,66 @@
|
||||
package com.jsowell.common.enums.thirdparty;
|
||||
|
||||
import com.jsowell.common.util.StringUtils;
|
||||
|
||||
/**
|
||||
* TODO
|
||||
*
|
||||
* @author Lemon
|
||||
* @Date 2023/11/8 9:11:55
|
||||
*/
|
||||
public enum ThirdPartyOperatorIdEnum {
|
||||
LIAN_LIAN_PLATFORM("1", "425010765"),
|
||||
ZHONG_DIAN_LIAN_PLATFORM("2", "14405899X"),
|
||||
JIANG_SU_PLATFORM("3", "726079387"),
|
||||
YONG_CHENG_BO_CHE("4", "330205020"),
|
||||
|
||||
;
|
||||
private String type;
|
||||
|
||||
private String OperatorId;
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void setType(String type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public String getOperatorId() {
|
||||
return OperatorId;
|
||||
}
|
||||
|
||||
public void setOperatorId(String operatorId) {
|
||||
OperatorId = operatorId;
|
||||
}
|
||||
|
||||
ThirdPartyOperatorIdEnum(String type, String operatorId) {
|
||||
this.type = type;
|
||||
OperatorId = operatorId;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据 type 获取 operatorId
|
||||
*
|
||||
* @param type 编码
|
||||
* @return operatorId
|
||||
*/
|
||||
public static String getOperatorIdByType(String type) {
|
||||
for (ThirdPartyOperatorIdEnum item : ThirdPartyOperatorIdEnum.values()) {
|
||||
if (StringUtils.equals(item.getType(), type)) {
|
||||
return item.getOperatorId();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public static String getTypeByOperatorId(String operatorId) {
|
||||
for (ThirdPartyOperatorIdEnum item : ThirdPartyOperatorIdEnum.values()) {
|
||||
if (StringUtils.equals(item.getOperatorId(), operatorId)) {
|
||||
return item.getType();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -47,7 +47,7 @@ public enum ThirdPlatformTypeEnum {
|
||||
* @param code 编码
|
||||
* @return 停止原因描述
|
||||
*/
|
||||
public static String getMsgByCode(String code) {
|
||||
public static String getLabelByCode(String code) {
|
||||
for (ThirdPlatformTypeEnum item : ThirdPlatformTypeEnum.values()) {
|
||||
if (StringUtils.equals(item.getCode(), code)) {
|
||||
return item.getLabel();
|
||||
|
||||
Reference in New Issue
Block a user