@xuda.io/drive_module 1.1.1456 → 1.1.1458

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.
Files changed (2) hide show
  1. package/index.mjs +11 -3
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -281,10 +281,11 @@ export const get_drive_files = async (req) => {
281
281
  const get_user_files = async () => {
282
282
  opt.selector.docType = 'user_drive';
283
283
  // opt.selector.uid = uid;
284
- const ret = await find_contact_query(uid, opt);
285
- const file_doc = await get_user_drive_file(uid, path.basename(file_path) || '/');
284
+ // const ret = await find_contact_query(uid, opt);
285
+ // const file_doc = await get_user_drive_file(uid, path.basename(file_path) || '/');
286
286
 
287
287
  const app_id = await get_account_default_project_id(uid);
288
+ const ret = await db_module.find_app_couch_query(app_id, opt);
288
289
  debugger;
289
290
  return {
290
291
  code: 1,
@@ -1443,10 +1444,17 @@ export const check_drive_file = async (req, job_id, headers, file_obj) => {
1443
1444
  }
1444
1445
  case 'user': {
1445
1446
  selector.docType = 'user_drive';
1446
- const user_drive_res = await find_contact_query(uid, {
1447
+
1448
+ // const user_drive_res = await find_contact_query(uid, {
1449
+ // selector,
1450
+ // limit: 99,
1451
+ // });
1452
+ const app_id = await get_account_default_project_id(uid);
1453
+ const user_drive_res = await db_module.find_app_couch_query(app_id, {
1447
1454
  selector,
1448
1455
  limit: 99,
1449
1456
  });
1457
+
1450
1458
  if (user_drive_res.docs.length) {
1451
1459
  return {
1452
1460
  code: -764,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xuda.io/drive_module",
3
- "version": "1.1.1456",
3
+ "version": "1.1.1458",
4
4
  "description": "Xuda Drive Server Module",
5
5
  "main": "index.mjs",
6
6
  "dependencies": {