Merge pull request #1043 from automatisch/list-shared-drives-for-updated-files
feat(google-drive): list shared drives for updated files trigger
This commit is contained in:
@@ -13,7 +13,7 @@ export default defineTrigger({
|
|||||||
type: 'dropdown' as const,
|
type: 'dropdown' as const,
|
||||||
required: false,
|
required: false,
|
||||||
description:
|
description:
|
||||||
'The drive to use. If nothing is selected, then your personal Google Drive will be used.',
|
'The Google Drive where your file resides. If nothing is selected, then your personal Google Drive will be used.',
|
||||||
variables: false,
|
variables: false,
|
||||||
source: {
|
source: {
|
||||||
type: 'query',
|
type: 'query',
|
||||||
|
@@ -4,9 +4,9 @@ const newFiles = async ($: IGlobalVariable) => {
|
|||||||
const params = {
|
const params = {
|
||||||
pageToken: undefined as unknown as string,
|
pageToken: undefined as unknown as string,
|
||||||
orderBy: 'createdTime desc',
|
orderBy: 'createdTime desc',
|
||||||
q: `mimeType!='application/vnd.google-apps.folder'`,
|
|
||||||
fields: '*',
|
fields: '*',
|
||||||
pageSize: 1000,
|
pageSize: 1000,
|
||||||
|
q: `mimeType!='application/vnd.google-apps.folder'`,
|
||||||
driveId: $.step.parameters.driveId,
|
driveId: $.step.parameters.driveId,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@@ -8,6 +8,25 @@ export default defineTrigger({
|
|||||||
description:
|
description:
|
||||||
'Triggers when a file is updated in a specific folder (but not its subfolder).',
|
'Triggers when a file is updated in a specific folder (but not its subfolder).',
|
||||||
arguments: [
|
arguments: [
|
||||||
|
{
|
||||||
|
label: 'Drive',
|
||||||
|
key: 'driveId',
|
||||||
|
type: 'dropdown' as const,
|
||||||
|
required: false,
|
||||||
|
description:
|
||||||
|
'The Google Drive where your file resides. If nothing is selected, then your personal Google Drive will be used.',
|
||||||
|
variables: false,
|
||||||
|
source: {
|
||||||
|
type: 'query',
|
||||||
|
name: 'getDynamicData',
|
||||||
|
arguments: [
|
||||||
|
{
|
||||||
|
name: 'key',
|
||||||
|
value: 'listDrives',
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
label: 'Folder',
|
label: 'Folder',
|
||||||
key: 'folderId',
|
key: 'folderId',
|
||||||
|
@@ -18,6 +18,7 @@ const updatedFiles = async ($: IGlobalVariable) => {
|
|||||||
fields: '*',
|
fields: '*',
|
||||||
pageSize: 1000,
|
pageSize: 1000,
|
||||||
q,
|
q,
|
||||||
|
driveId: $.step.parameters.driveId,
|
||||||
};
|
};
|
||||||
|
|
||||||
do {
|
do {
|
||||||
|
Reference in New Issue
Block a user