The full tree position of a system lookup table item is a combination of the following codes with underscores as delimiters:
•The full tree position of the lookup item's parent item.
•The partial tree position of the item.
In the following image, the Territory Type lookup table in contact records has the code of TERR. If Orange County has the partial tree position OCNT and Southern California has the partial tree position SOCA, the full tree position of Orange County is TERR_SOCA_OCNT.
Territory System Lookup Table
The following code samples provide examples of how you can use the tree position to retrieve a system lookup table item.
LookupItemService lookupItemService = platform.getLookupItemService();
// Retrieving the “Apple” item within the Fruits custom table CustomLookupItem apple = lookupItemService.getCustomLookupItemForTreePosition("FRUI_APPL");
// Retrieve all items in the Fruits custom table List<CustomLookupItem> fruits = lookupItemService.getCustomLookupItems("FRUI");
// Retrieving the “Mobile” item within the Phone Type system table; SystemLookupItem mobile = lookupItemService.getSystemLookupItemForTreePosition("PHON_MOBI"); |
The following table includes all system lookup tables, their associated LookupItemService method, and their unique codes. Use the unique code of each system lookup table at the beginning of the full tree position for a lookup table item. The table also lists API model interfaces associated with the lookup tables. If the lookup tables are not associated with a string field, the API class column does not apply.
Friendly name |
Associated LookupItemService method |
Associated API class |
Unique code |
Activity Item |
getActivityItems() |
N/A |
ACTI |
Address Type |
getContactAddressTypes() |
Address |
ADDR |
Contact Relation Type |
getContactRelationTypes() |
ContactRelation |
CONR |
Country Item |
getCountries() |
N/A |
COUN |
Email Type |
getContactEmailTypes() |
||
Fax Type |
getContactFaxNumberTypes() |
FaxNumber |
FAXX |
Internet Address Type |
getContactInternetAddressTypes() |
InternetAddress |
INET |
Invoice Rejection Reason |
getInvoiceRejectionReason() |
N/A |
INRR |
Phone Type |
getContactPhoneNumberTypes() |
PhoneNumber |
PHON |
Project Assignee Type |
getProjectAssigneeRoles() |
ProjectAssignee |
Unique code of the respective custom object definition. |
Project Relation Type |
getProjectRelationTypes() |
ProjectRelation |
PRJR |
Resource Type |
getAppointmentResourceTypes() |
N/A |
RESO |
Skill Type |
getContactSkillTypes() |
Skill |
SKIL |
Territory Type |
getContactTerritoryTypes() |
N/A |
TERR |
State Item |
getStatesForCountryCode() |
N/A |
STAT |