mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 02:21:13 +00:00
feat(Google Drive Node): Add move to trash support (#3693)
* feat(Google Drive Node): Add move to trash support * ⚡ Improvements Co-authored-by: ricardo <ricardoespinoza105@gmail.com>
This commit is contained in:
@@ -915,6 +915,13 @@ export class GoogleDrive implements INodeType {
|
||||
default: false,
|
||||
description: 'Whether to set the \'keepForever\' field in the new head revision. This is only applicable to files with binary content in Google Drive. Only 200 revisions for the file can be kept forever. If the limit is reached, try deleting pinned revisions.',
|
||||
},
|
||||
{
|
||||
displayName: 'Move to Trash',
|
||||
name: 'trashed',
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
description: 'Whether to move a file to the trash. Only the owner may trash a file.',
|
||||
},
|
||||
{
|
||||
displayName: 'OCR Language',
|
||||
name: 'ocrLanguage',
|
||||
@@ -2498,6 +2505,10 @@ export class GoogleDrive implements INodeType {
|
||||
body.name = updateFields.fileName;
|
||||
}
|
||||
|
||||
if (updateFields.hasOwnProperty('trashed')) {
|
||||
body.trashed = updateFields.trashed;
|
||||
}
|
||||
|
||||
if (updateFields.parentId && updateFields.parentId !== '') {
|
||||
qs.addParents = updateFields.parentId;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user