Class SuggestConstants
- java.lang.Object
-
- org.nuxeo.ecm.automation.features.SuggestConstants
-
public class SuggestConstants extends Object
Constants used to generate JSON for suggestion in operations.
-
-
Field Summary
Fields Modifier and Type Field Description static String
ABSOLUTE_LABEL
static String
COMPUTED_ID
static String
DEFAULT_KEY_SEPARATOR
static String
DEFAULT_LANG
static String
DIRECTORY_DEFAULT_LABEL_COL_NAME
static String
DIRECTORY_ORDER_FIELD_NAME
static String
DISPLAY_ICON
protected static Boolean
forceDisplayEmailInSuggestion
static String
GROUP_TYPE
static String
ICON
static String
ID
static String
LABEL
static String
LANG_TOKEN
static String
OBSOLETE_FIELD_ID
static String
PARENT_FIELD_ID
static String
PREFIXED_ID_KEY_NAME
static String
TYPE_KEY_NAME
static String
USER_TYPE
static String
WARN_MESSAGE_LABEL
-
Constructor Summary
Constructors Modifier Constructor Description protected
SuggestConstants()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
computeGroupLabel(Map<String,Object> obj, String groupId, String groupLabelField, boolean hideFirstLabel)
static void
computeUserGroupIcon(Map<String,Object> obj, boolean hideIcon)
static void
computeUserLabel(Map<String,Object> obj, String firstLabelField, String secondLabelField, String thirdLabelField, boolean hideFirstLabel, boolean hideSecondLabel, boolean hideThirdLabel, boolean displayEmailInSuggestion, String userId)
static String
getLabelFieldName(Schema schema, boolean dbl10n, String labelFieldName, String lang)
Compute the field name of the directory that holds the value that we want to display.protected static boolean
isForceDisplayEmailInSuggestion()
-
-
-
Field Detail
-
LANG_TOKEN
public static final String LANG_TOKEN
- See Also:
- Constant Field Values
-
ID
public static final String ID
- See Also:
- Constant Field Values
-
LABEL
public static final String LABEL
- See Also:
- Constant Field Values
-
ICON
public static final String ICON
- See Also:
- Constant Field Values
-
DEFAULT_LANG
public static final String DEFAULT_LANG
- See Also:
- Constant Field Values
-
USER_TYPE
public static final String USER_TYPE
- See Also:
- Constant Field Values
-
GROUP_TYPE
public static final String GROUP_TYPE
- See Also:
- Constant Field Values
-
TYPE_KEY_NAME
public static final String TYPE_KEY_NAME
- See Also:
- Constant Field Values
-
PREFIXED_ID_KEY_NAME
public static final String PREFIXED_ID_KEY_NAME
- See Also:
- Constant Field Values
-
forceDisplayEmailInSuggestion
protected static Boolean forceDisplayEmailInSuggestion
-
DISPLAY_ICON
public static final String DISPLAY_ICON
- See Also:
- Constant Field Values
-
PARENT_FIELD_ID
public static final String PARENT_FIELD_ID
- See Also:
- Constant Field Values
-
OBSOLETE_FIELD_ID
public static final String OBSOLETE_FIELD_ID
- See Also:
- Constant Field Values
-
ABSOLUTE_LABEL
public static final String ABSOLUTE_LABEL
- See Also:
- Constant Field Values
-
COMPUTED_ID
public static final String COMPUTED_ID
- See Also:
- Constant Field Values
-
WARN_MESSAGE_LABEL
public static final String WARN_MESSAGE_LABEL
- See Also:
- Constant Field Values
-
DIRECTORY_ORDER_FIELD_NAME
public static final String DIRECTORY_ORDER_FIELD_NAME
- See Also:
- Constant Field Values
-
DIRECTORY_DEFAULT_LABEL_COL_NAME
public static final String DIRECTORY_DEFAULT_LABEL_COL_NAME
- See Also:
- Constant Field Values
-
DEFAULT_KEY_SEPARATOR
public static final String DEFAULT_KEY_SEPARATOR
- See Also:
- Constant Field Values
-
-
Method Detail
-
computeGroupLabel
public static void computeGroupLabel(Map<String,Object> obj, String groupId, String groupLabelField, boolean hideFirstLabel)
-
computeUserGroupIcon
public static void computeUserGroupIcon(Map<String,Object> obj, boolean hideIcon)
-
computeUserLabel
public static void computeUserLabel(Map<String,Object> obj, String firstLabelField, String secondLabelField, String thirdLabelField, boolean hideFirstLabel, boolean hideSecondLabel, boolean hideThirdLabel, boolean displayEmailInSuggestion, String userId)
-
getLabelFieldName
public static String getLabelFieldName(Schema schema, boolean dbl10n, String labelFieldName, String lang)
Compute the field name of the directory that holds the value that we want to display.- Parameters:
schema
- the directory schemadbl10n
- are translations carried by directory fieldslabelFieldName
- the name or pattern of the fields that held valueslang
- the current language- Returns:
- the final field name where we pick up the value
- Throws:
IllegalArgumentException
- when cannot compute label field name- Since:
- 5.7.3
-
isForceDisplayEmailInSuggestion
protected static boolean isForceDisplayEmailInSuggestion()
-
-