- Home [object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
- Getting started
- Use cases
-
API
- Object types
- Data types
-
Global constants
- Application
- ApplicationUserProfile
- ApplicationWithBatcher
- ApplicationWithParams
- BrandingSettings
- CompanyInfo
- Converter
- Directories
- Files
- HttpApiHandler
- HttpApiRequest
- ICache
- IStorage
- MailMessage
- Mailbox
- OrganisationStructure
- OrganisationStructureTree
- Portal
- PortalPageInfo
- PortalSettings
- Portals
- Process
- Processes
- ProductionSchedule
- Reminders
- Replacements
- Serial
- ServerCollection
- Service
- SignupUrlParams
- SystemCollections
- SystemCollectionsWithEvents
- SystemCollectionsWithFilterEvents
- Templater
- Translator
- UserGroups
- Users
- Watermarks
- Report
- Reports
- SR
- Work with apps
- Web requests
- Access permissions
- Document flow
- Live Chats
- “Code” widget
- Signatures
- Business calendars
- Integration with IP telephony
- Integration with email marketing services
Organizational chart object
Used to get the current org chart as a tree to create a new org chart tree or a new item or to save the configured tree as the current org chart.
const tree = await System.organisationStructure.fetchTree(); const newItem = System.organisationStructure.createItem('MArketing Director', OrganisationStructureItemType.Position); tree.getRoot(). addChild(newItem); const errs = await tree.validate(); if (errs.length === 0) { // Validation successful const sErrs = await System. organisationStructure.save(tree); }
Hierarchy
Methods
createItem
The method allows you to create a new item of the organizational chart.
Parameters
name: string
type: OrganisationStructureItemType
Returns OrganisationStructureItem
createTree
The method creates a new organizational chart tree.
Parameters
rootName: string
Returns OrganisationStructureTree
fetchTree
The method is used to load the current org chart tree.
const tree = await System.organisationStructure.fetchTree();
Returns Promise<OrganisationStructureTree>
save
The method saves the configured tree as the current org chart.
Before saving, the org chart will be automatically validated.
Parameters
tree: OrganisationStructureTree
Returns Promise<ErrorObject[]>
search
The method is used to perform search in the org chart.
You can use this method to filter, start extraction from a specific item, limit selection, sort, get the first result, or get the results page.
Example:
const position = await System.organisationStructure .search().where(position => position.name.eq('CEO')).first();
Returns OrganisationStructureSearch
Methods