diff options
author | Melissa Zhang <mzhang19096@gmail.com> | 2020-07-30 15:38:44 -0700 |
---|---|---|
committer | Melissa Zhang <mzhang19096@gmail.com> | 2020-07-30 15:38:44 -0700 |
commit | 3d02d928ad869b9157019aec356e2f1ea2ce47d6 (patch) | |
tree | 00c9ccb1b5487f145b7512d4531757731781249b /src/client/views/collections/CollectionTreeView.tsx | |
parent | ba8549220295d03fb7eb7d7d31c90af72b30b1a6 (diff) | |
parent | a9ec139961b0262698851cd7e2dd3430a0acddd7 (diff) |
merge with master
Diffstat (limited to 'src/client/views/collections/CollectionTreeView.tsx')
-rw-r--r-- | src/client/views/collections/CollectionTreeView.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/collections/CollectionTreeView.tsx b/src/client/views/collections/CollectionTreeView.tsx index 651357e5d..705871a6f 100644 --- a/src/client/views/collections/CollectionTreeView.tsx +++ b/src/client/views/collections/CollectionTreeView.tsx @@ -100,8 +100,8 @@ class TreeView extends React.Component<TreeViewProps> { childDocList(field: string) { const layout = Doc.LayoutField(this.doc) instanceof Doc ? Doc.LayoutField(this.doc) as Doc : undefined; return ((this.props.dataDoc ? DocListCast(this.props.dataDoc[field]) : undefined) || // if there's a data doc for an expanded template, use it's data field - (layout ? Cast(layout[field], listSpec(Doc)) : undefined) || // else if there's a layout doc, display it's fields - Cast(this.doc[field], listSpec(Doc))) as Doc[]; // otherwise use the document's data field + (layout ? DocListCast(layout[field]) : undefined) || // else if there's a layout doc, display it's fields + DocListCast(this.doc[field])) as Doc[]; // otherwise use the document's data field } @computed get childDocs() { return this.childDocList(this.fieldKey); } @computed get childLinks() { return this.childDocList("links"); } |