aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/collections/ParentDocumentSelector.tsx
diff options
context:
space:
mode:
authorTyler Schicke <tyler_schicke@brown.edu>2019-07-15 17:20:40 -0400
committerTyler Schicke <tyler_schicke@brown.edu>2019-07-15 17:20:40 -0400
commitb72dfe96af4f87fa00e9d64ffded62d0a5ec0ea9 (patch)
treeabd9aeb26928a44dc7924f357e9f0557c9ae473d /src/client/views/collections/ParentDocumentSelector.tsx
parent89e0d0d3edd5385cab8859b1d0784251b4aac15b (diff)
Added filter query to search to better support type filtering
Diffstat (limited to 'src/client/views/collections/ParentDocumentSelector.tsx')
-rw-r--r--src/client/views/collections/ParentDocumentSelector.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/collections/ParentDocumentSelector.tsx b/src/client/views/collections/ParentDocumentSelector.tsx
index c0f489cd8..a97aa4f36 100644
--- a/src/client/views/collections/ParentDocumentSelector.tsx
+++ b/src/client/views/collections/ParentDocumentSelector.tsx
@@ -23,9 +23,9 @@ export class SelectorContextMenu extends React.Component<SelectorProps> {
async fetchDocuments() {
let aliases = (await SearchUtil.GetAliasesOfDocument(this.props.Document)).filter(doc => doc !== this.props.Document);
- const { docs } = await SearchUtil.Search(`data_l:"${this.props.Document[Id]}"`, true);
+ const { docs } = await SearchUtil.Search("", `data_l:"${this.props.Document[Id]}"`, true);
const map: Map<Doc, Doc> = new Map;
- const allDocs = await Promise.all(aliases.map(doc => SearchUtil.Search(`data_l:"${doc[Id]}"`, true).then(result => result.docs)));
+ const allDocs = await Promise.all(aliases.map(doc => SearchUtil.Search("", `data_l:"${doc[Id]}"`, true).then(result => result.docs)));
allDocs.forEach((docs, index) => docs.forEach(doc => map.set(doc, aliases[index])));
docs.forEach(doc => map.delete(doc));
runInAction(() => {