ドライブのファイルの削除を実装
This commit is contained in:
parent
ad8aa1c179
commit
bd827f946a
8 changed files with 98 additions and 39 deletions
|
|
@ -37,10 +37,13 @@ module.exports = async (params, user, app) => {
|
|||
const sort = {
|
||||
_id: -1
|
||||
};
|
||||
|
||||
const query = {
|
||||
'metadata.userId': user._id,
|
||||
'metadata.folderId': folderId
|
||||
'metadata.folderId': folderId,
|
||||
'metadata.deletedAt': { $exists: false }
|
||||
} as any;
|
||||
|
||||
if (sinceId) {
|
||||
sort._id = 1;
|
||||
query._id = {
|
||||
|
|
@ -51,6 +54,7 @@ module.exports = async (params, user, app) => {
|
|||
$lt: untilId
|
||||
};
|
||||
}
|
||||
|
||||
if (type) {
|
||||
query.contentType = new RegExp(`^${type.replace(/\*/g, '.+?')}$`);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue