@xuda.io/drive_module 1.1.1365 → 1.1.1367
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 +14 -5
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -1465,10 +1465,10 @@ export const run_drive_pending_ocr = async (req) => {
|
|
|
1465
1465
|
limit: 1,
|
|
1466
1466
|
};
|
|
1467
1467
|
|
|
1468
|
-
const user_drive_res = await find_contact_query(uid, opt);
|
|
1469
|
-
for await (let doc of user_drive_res.docs) {
|
|
1470
|
-
|
|
1471
|
-
}
|
|
1468
|
+
// const user_drive_res = await find_contact_query(uid, opt);
|
|
1469
|
+
// for await (let doc of user_drive_res.docs) {
|
|
1470
|
+
// await ocr_drive_file(null, doc);
|
|
1471
|
+
// }
|
|
1472
1472
|
|
|
1473
1473
|
let selector = {
|
|
1474
1474
|
docType: 'app',
|
|
@@ -1495,8 +1495,17 @@ export const run_drive_pending_ocr = async (req) => {
|
|
|
1495
1495
|
|
|
1496
1496
|
let app_res = await db_module.find_couch_query('xuda_master', app_opt);
|
|
1497
1497
|
|
|
1498
|
-
opt.selector.docType = 'workspace_drive';
|
|
1499
1498
|
for (let app of app_res.docs) {
|
|
1499
|
+
let opt = {
|
|
1500
|
+
selector: { docType: 'user_drive', ocr_stat: 1, stat: 3 },
|
|
1501
|
+
limit: 1,
|
|
1502
|
+
};
|
|
1503
|
+
|
|
1504
|
+
const user_drive_res = await db_module.find_app_couch_query(app._id, opt);
|
|
1505
|
+
for await (let doc of user_drive_res.docs) {
|
|
1506
|
+
await ocr_drive_file(app._id, doc);
|
|
1507
|
+
}
|
|
1508
|
+
opt.selector.docType = 'workspace_drive';
|
|
1500
1509
|
const app_drive_res = await db_module.find_app_couch_query(app._id, opt);
|
|
1501
1510
|
for await (let doc of app_drive_res.docs) {
|
|
1502
1511
|
await ocr_drive_file(app._id, doc);
|