@xuda.io/ai_module 1.1.3545 → 1.1.3547
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.mjs +19 -0
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -1759,6 +1759,7 @@ export const get_ai_chats = async function (req, job_id, headers) {
|
|
|
1759
1759
|
reference_id: '',
|
|
1760
1760
|
},
|
|
1761
1761
|
limit: limit || 9999,
|
|
1762
|
+
skip: skip || 0,
|
|
1762
1763
|
};
|
|
1763
1764
|
|
|
1764
1765
|
if (archived) {
|
|
@@ -1776,6 +1777,24 @@ export const get_ai_chats = async function (req, job_id, headers) {
|
|
|
1776
1777
|
opt.selector.shared_from_uid = { $gt: null };
|
|
1777
1778
|
}
|
|
1778
1779
|
|
|
1780
|
+
if (search) {
|
|
1781
|
+
opt.selector = {
|
|
1782
|
+
...opt.selector,
|
|
1783
|
+
$or: [
|
|
1784
|
+
{
|
|
1785
|
+
title: {
|
|
1786
|
+
$regex: `(?i)${search}`,
|
|
1787
|
+
},
|
|
1788
|
+
},
|
|
1789
|
+
{
|
|
1790
|
+
_id: {
|
|
1791
|
+
$regex: `(?i)${search}`,
|
|
1792
|
+
},
|
|
1793
|
+
},
|
|
1794
|
+
],
|
|
1795
|
+
};
|
|
1796
|
+
}
|
|
1797
|
+
|
|
1779
1798
|
const app_id = await account_module.get_account_default_project_id(uid);
|
|
1780
1799
|
|
|
1781
1800
|
////// FROM - IN
|