@xuda.io/drive_module 1.1.892 → 1.1.894
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.js +8 -8
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -184,7 +184,7 @@ exports.get_drive_files = async function (req) {
|
|
|
184
184
|
|
|
185
185
|
const get_workspace_files = async function () {
|
|
186
186
|
const app_id_reference = await _common.get_project_app_id(app_id);
|
|
187
|
-
opt.selector = "workspace_drive";
|
|
187
|
+
opt.selector.docType = "workspace_drive";
|
|
188
188
|
|
|
189
189
|
// var opt = {
|
|
190
190
|
// selector: {
|
|
@@ -197,9 +197,9 @@ exports.get_drive_files = async function (req) {
|
|
|
197
197
|
// skip: from,
|
|
198
198
|
// };
|
|
199
199
|
|
|
200
|
-
if (date) {
|
|
201
|
-
|
|
202
|
-
}
|
|
200
|
+
// if (date) {
|
|
201
|
+
// opt.sort = [{ date_created: "desc" }];
|
|
202
|
+
// }
|
|
203
203
|
|
|
204
204
|
const ret = await db_module.find_app_couch_query(app_id, opt);
|
|
205
205
|
|
|
@@ -266,7 +266,7 @@ exports.get_drive_files = async function (req) {
|
|
|
266
266
|
return { code: 1, data: files };
|
|
267
267
|
};
|
|
268
268
|
const get_user_files = async function () {
|
|
269
|
-
opt.selector = "user_drive";
|
|
269
|
+
opt.selector.docType = "user_drive";
|
|
270
270
|
opt.uid = uid;
|
|
271
271
|
// var opt = {
|
|
272
272
|
// selector: {
|
|
@@ -280,9 +280,9 @@ exports.get_drive_files = async function (req) {
|
|
|
280
280
|
// skip: from,
|
|
281
281
|
// };
|
|
282
282
|
|
|
283
|
-
if (date) {
|
|
284
|
-
|
|
285
|
-
}
|
|
283
|
+
// if (date) {
|
|
284
|
+
// opt.sort = [{ date_created: "desc" }];
|
|
285
|
+
// }
|
|
286
286
|
|
|
287
287
|
const ret = await db_module.find_couch_query("xuda_drive", opt);
|
|
288
288
|
const file_doc = await db_module.get_couch_doc(
|