jiangping
2023-12-18 98e52a2d1a05276e11d2e5c99ec05e670228fbd6
server/dmvisit_service/src/main/java/com/doumee/core/utils/Constants.java
@@ -66,6 +66,8 @@
    public static  boolean DEALING_HK_IMG = false;
    public static  boolean DEALING_HK_ORG = false;
    public static  boolean DEALING_HK_USER = false;
    public static  boolean DEALING_HK_VISIT = false;
    public static  boolean DEALING_HK_EMPOWER = false;
    // ERP接口配置
    public static final String ERP_CONFIG = "ERP_CONFIG";
    // ERP ACCESS_KEY
@@ -85,10 +87,22 @@
    try {
        birthday = dateFormat.parse(birthdayString);
    } catch (Exception e) {
        throw new RuntimeException(e);
//        throw new RuntimeException(e);
    }
    return  birthday;
}
    public static  Integer   getSexByCardNo(String idCard){
        if(idCard ==null || idCard.length()<17){
            return null;
        }
        String str = idCard.substring(16, 17); // 截取身份证号的前六位数字作为出生日期
        try {
            Integer num  = Integer.parseInt(str);
            return  (num % 2 !=0) ? 1:2 ;
        } catch (Exception e) {
        }
        return  null;
    }
    /**
     *   判断是否为有效车牌号