aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--solr-8.3.1/server/solr/dash/conf/schema.xml7
-rw-r--r--solr-8.3.1/server/solr/dash/conf/solrconfig.xml2
-rw-r--r--src/client/util/SearchUtil.ts2
-rw-r--r--src/server/websocket.ts2
4 files changed, 6 insertions, 7 deletions
diff --git a/solr-8.3.1/server/solr/dash/conf/schema.xml b/solr-8.3.1/server/solr/dash/conf/schema.xml
index 47aa56787..a0496444b 100644
--- a/solr-8.3.1/server/solr/dash/conf/schema.xml
+++ b/solr-8.3.1/server/solr/dash/conf/schema.xml
@@ -44,11 +44,10 @@
<fieldType name="pdouble" class="solr.DoublePointField"/>
<field name="string" type="string" indexed="true" stored="true" uninvertible="true"/>
- <field name="text" type="text" indexed="true" stored="false" uninvertible="false" multiValued="true"/>
+ <field name="DEFAULT" type="text" indexed="true" stored="false" uninvertible="false" multiValued="true"/>
<field name="id" type="string" indexed="true" stored="true" uninvertible="false" required="true"/>
<field name="_version_" type="plong" indexed="true" stored="true"/>
<field name="proto" type="string" indexed="true" stored="true" uninvertible="false" />
- <field name="_height" type="pdouble" indexed="true" stored="true" uninvertible="false" docValues="true"/>
<dynamicField name="*_s" type="string" indexed="true" stored="true" uninvertible="false" docValues="true"/>
<dynamicField name="*_t" type="text" indexed="true" stored="true" uninvertible="false" docValues="false"/>
@@ -59,10 +58,10 @@
<dynamicField name="*_b" type="boolean" indexed="true" stored="true" uninvertible="false" docValues="false"/>
<dynamicField name="*_a" type="text" indexed="true" stored="false" uninvertible="false" docValues="false" multiValued="true"/>
- <copyField source="*_t" dest="*_s"/>
-
<!-- <field name="_height" type="pdouble" indexed="true" stored="true" uninvertible="false" docValues="true"/> -->
+ <copyField source="*_t" dest="*_s"/>
+ <copyField source="*_t" dest="DEFAULT"/>
<copyField source="*_t" dest="*_a"/>
<copyField source="*_n" dest="*_a"/>
</schema>
diff --git a/solr-8.3.1/server/solr/dash/conf/solrconfig.xml b/solr-8.3.1/server/solr/dash/conf/solrconfig.xml
index 60f06f57f..705029368 100644
--- a/solr-8.3.1/server/solr/dash/conf/solrconfig.xml
+++ b/solr-8.3.1/server/solr/dash/conf/solrconfig.xml
@@ -696,7 +696,7 @@
<lst name="defaults">
<str name="echoParams">explicit</str>
<int name="rows">8</int>
- <str name="df">text</str>
+ <str name="df">DEFAULT</str>
<!-- Default search field
<str name="df">text</str>
-->
diff --git a/src/client/util/SearchUtil.ts b/src/client/util/SearchUtil.ts
index f916ac44a..483ce3196 100644
--- a/src/client/util/SearchUtil.ts
+++ b/src/client/util/SearchUtil.ts
@@ -37,7 +37,7 @@ export namespace SearchUtil {
export async function Search(query: string, returnDocs: boolean, options: SearchParams = {}) {
query = query || "*"; //If we just have a filter query, search for * as the query
const rpquery = Utils.prepend("/dashsearch");
- const replacedQuery = query.replace(/type_t:([^ )])/, (substring, arg) => `{!join from=id to=proto_i}type_t:${arg}`);
+ const replacedQuery = query.replace(/type_t:([^ )])/g, (substring, arg) => `{!join from=id to=proto_i}type_t:${arg}`);
const gotten = await rp.get(rpquery, { qs: { ...options, /* sort: "lastModified_d desc", */ q: replacedQuery } });
const result: IdSearchResult = gotten.startsWith("<") ? { ids: [], docs: [], numFound: 0, lines: [] } : JSON.parse(gotten);
if (!returnDocs) {
diff --git a/src/server/websocket.ts b/src/server/websocket.ts
index 18c5ece98..ec351c283 100644
--- a/src/server/websocket.ts
+++ b/src/server/websocket.ts
@@ -203,7 +203,7 @@ export namespace WebSocket {
Database.Instance.update(newValue.id, newValue, () =>
socket.broadcast.emit(MessageStore.SetField.Message, newValue));
if (newValue.type === Types.Text) { // if the newValue has sring type, then it's suitable for searching -- pass it to SOLR
- Search.updateDocument({ id: newValue.id, data: (newValue as any).data });
+ Search.updateDocument({ id: newValue.id, data: { set: (newValue as any).data } });
}
}