package com.yfd.platform.constant;

import java.time.LocalDateTime;

/**
 *
 * @Date: 2023/3/3 17:40
 * @Description: 常量类
 */
public class Constant {
    public static LocalDateTime now =LocalDateTime.now();
    public static final String LOGIN = "login:";
    public static final String TOKEN = "token:";
    public static final String USER_ID = "userid";
    public static final String DATE_TIME_FORMAT = "yyyy-MM-dd HH:mm:ss";
    /**
     * 用户登录
     */
    public static final String USER_LOGIN = "system-login:";
    public static final String CODE_KEY = "code-key-";

    public static final String ROBOT_SEND_CODE = "robotSendCode-";
    public static final String CLOUD_SEND_CODE = "cloudHSendCode-";

    public static final String SYSTEM_MESSAGE_SUCCESS = "server connected success";
    /**
     * 验证码失效时间
     */
    public static final long CODE_EXPIRATION_TIME = 1000 * 60 * 2;

    /**
     * 用于IP定位转换
     */
    public static final String REGION = "内网IP|内网IP";
    /**
     * win 系统
     */
    public static final String WIN = "win";

    /**
     * mac 系统
     */
    public static final String MAC = "mac";

    /**
     * Redis Const
     * 设备录像信息90天时长
     */
    public static final String REDIS_RECORD_TIMES_PRE = "DEVICERECORDTIMES_";

    /**
     * 常用接口
     */
    public static class Url {

        // IP归属地查询
        // public static final String IP_URL = "http://whois.pconline.com
        // .cn/ipJson.jsp?ip=%s&json=true";
        public static final String IP_URL = "http://whois.pconline.com" +
                ".cn/ipJson.jsp?ip=%s&json=true";
    }
}
