package cn.novalon.manage.common.exception;

public class ErrorCode {

    public static final String VALIDATION_PREFIX = "VALIDATION_";
    public static final String NOT_FOUND_PREFIX = "NOT_FOUND_";
    public static final String PERMISSION_PREFIX = "PERMISSION_";
    public static final String CONFLICT_PREFIX = "CONFLICT_";
    public static final String SYSTEM_PREFIX = "SYSTEM_";

    public static final String VALIDATION_REQUIRED = VALIDATION_PREFIX + "001";
    public static final String VALIDATION_INVALID_FORMAT = VALIDATION_PREFIX + "002";
    public static final String VALIDATION_INVALID_LENGTH = VALIDATION_PREFIX + "003";
    public static final String VALIDATION_INVALID_VALUE = VALIDATION_PREFIX + "004";

    public static final String NOT_FOUND_USER = NOT_FOUND_PREFIX + "001";
    public static final String NOT_FOUND_ROLE = NOT_FOUND_PREFIX + "002";
    public static final String NOT_FOUND_MENU = NOT_FOUND_PREFIX + "003";
    public static final String NOT_FOUND_DICTIONARY = NOT_FOUND_PREFIX + "004";

    public static final String PERMISSION_DENIED = PERMISSION_PREFIX + "001";
    public static final String PERMISSION_INSUFFICIENT = PERMISSION_PREFIX + "002";

    public static final String CONFLICT_DUPLICATE = CONFLICT_PREFIX + "001";
    public static final String CONFLICT_DUPLICATE_USER = CONFLICT_PREFIX + "002";
    public static final String CONFLICT_DUPLICATE_ROLE = CONFLICT_PREFIX + "003";
    public static final String CONFLICT_DUPLICATE_DICTIONARY = CONFLICT_PREFIX + "004";

    public static final String SYSTEM_INTERNAL_ERROR = SYSTEM_PREFIX + "001";
    public static final String SYSTEM_DATABASE_ERROR = SYSTEM_PREFIX + "002";
    public static final String SYSTEM_NETWORK_ERROR = SYSTEM_PREFIX + "003";
}
