diff options
| author | bobzel <zzzman@gmail.com> | 2021-02-18 16:45:32 -0500 |
|---|---|---|
| committer | bobzel <zzzman@gmail.com> | 2021-02-18 16:45:32 -0500 |
| commit | a2abfb07b783769094414c39e300b88c31cfc450 (patch) | |
| tree | 9a66211fe5249d5c7d08b59caa2d4e3e200a9325 /src/client/views/collections/CollectionTreeView.tsx | |
| parent | 0d59f6bc23c755c4eab2503add28699f5a5b1992 (diff) | |
added preliminary cookie mechanism for making documents appear after focusing on a document which sets a cookie. converted catalog to new "file system" tree view.
Diffstat (limited to 'src/client/views/collections/CollectionTreeView.tsx')
| -rw-r--r-- | src/client/views/collections/CollectionTreeView.tsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/views/collections/CollectionTreeView.tsx b/src/client/views/collections/CollectionTreeView.tsx index 092606fdf..7beb76fdc 100644 --- a/src/client/views/collections/CollectionTreeView.tsx +++ b/src/client/views/collections/CollectionTreeView.tsx @@ -72,9 +72,9 @@ export class CollectionTreeView extends CollectionSubView<Document, Partial<coll SelectionManager.DeselectAll(); if (result.length !== value.length) { const ind = targetDataDoc[this.props.fieldKey].indexOf(doc); + const prev = ind && targetDataDoc[this.props.fieldKey][ind - 1]; targetDataDoc[this.props.fieldKey] = new List<Doc>(result); if (ind > 0) { - const prev = targetDataDoc[this.props.fieldKey][ind - 1]; FormattedTextBox.SelectOnLoad = prev[Id]; const prevView = DocumentManager.Instance.getDocumentView(prev, this.props.CollectionView); prevView?.select(false); |
