posted May 28, 2014, 11:56 AM by Kevin Cassidy
Child objects can be rendered in tree fashion using the 'Tree' behavior:
<div data-behavior="Tree" data-tree- options="{{
'object': 'Process',
'objectid':'1',
'keys': 'AssignedOrganizationID,ClientID',
'keysexclude': '',
'descendants': '',
'descendantsexclude': 'Message',
'childobject': 'Attachment',
'treetext': 'Click on a link to view related documents.'
}}" />
The options passed to the behavior comprise: - object: the parent used to populate the tree
- objectid: the parent id used to populate the tree
- keys: a comma delimited list of foreign keys to include in the tree navigation
- keysexclude: a comma delimited list of foreign keys to exclude in the tree navigation
- descendants: a comma delimited list of parents and children to include in the tree navigation
- descendantsexclude: a comma delimited list of parents and children to exclude in the tree navigation
- childobject: the objects to render in the tree results table
- treetext: help text used to instruct the user on how to use the tree
Use case: - Adding a message: display documents that can be drag-and-dropped to the message attachments panel
|
|