diff options
author | Tyler Schicke <tyler_schicke@brown.edu> | 2019-05-07 19:26:36 -0400 |
---|---|---|
committer | Tyler Schicke <tyler_schicke@brown.edu> | 2019-05-07 19:26:36 -0400 |
commit | 152fadbad5d3c4e9c452bb6a1ade543bd84c6416 (patch) | |
tree | c264d314010e5f9c1136443e3b8fc55e4a5b8167 /src/server/Search.ts | |
parent | 6683c5450eb25da291090091421e791bf0498aba (diff) |
Added copy fields to search to enable easier searching
Diffstat (limited to 'src/server/Search.ts')
-rw-r--r-- | src/server/Search.ts | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/src/server/Search.ts b/src/server/Search.ts index 4911edd1d..59bdd4803 100644 --- a/src/server/Search.ts +++ b/src/server/Search.ts @@ -5,34 +5,8 @@ import { thisExpression } from 'babel-types'; export class Search { public static Instance = new Search(); private url = 'http://localhost:8983/solr/'; - private client: any; - - constructor() { - console.log("Search Instantiated!"); - var SolrNode = require('solr-node'); - this.client = new SolrNode({ - host: 'localhost', - port: '8983', - core: 'dash', - protocol: 'http' - }); - var strQuery = this.client.query().q('text:test'); - - console.log(strQuery); - - // Search documents using strQuery - // client.search(strQuery, (err: any, result: any) => { - // if (err) { - // console.log(err); - // return; - // } - // console.log('Response:', result.response); - // }); - } - public async updateDocument(document: any) { - console.log("UPDATE: ", JSON.stringify(document)); return rp.post(this.url + "dash/update", { headers: { 'content-type': 'application/json' }, body: JSON.stringify([document]) |