feat: Allow hiding credential params on cloud (#6687)

This commit is contained in:
Iván Ovejero
2023-07-18 11:43:28 +02:00
committed by GitHub
parent 6887b4edea
commit 2af1c24ead
4 changed files with 12 additions and 0 deletions

View File

@@ -554,6 +554,10 @@ export default defineComponent({
return false; return false;
} }
if (parameter.displayOptions?.hideOnCloud && this.settingsStore.isCloudDeployment) {
return false;
}
if (parameter.displayOptions === undefined) { if (parameter.displayOptions === undefined) {
// If it is not defined no need to do a proper check // If it is not defined no need to do a proper check
return true; return true;

View File

@@ -28,6 +28,9 @@ export class GoogleSheetsOAuth2Api implements ICredentialType {
name: 'notice', name: 'notice',
type: 'notice', type: 'notice',
default: '', default: '',
displayOptions: {
hideOnCloud: true,
},
}, },
]; ];
} }

View File

@@ -29,6 +29,9 @@ export class GoogleSheetsTriggerOAuth2Api implements ICredentialType {
name: 'notice', name: 'notice',
type: 'notice', type: 'notice',
default: '', default: '',
displayOptions: {
hideOnCloud: true,
},
}, },
]; ];
} }

View File

@@ -1090,6 +1090,8 @@ export interface IDisplayOptions {
show?: { show?: {
[key: string]: NodeParameterValue[] | undefined; [key: string]: NodeParameterValue[] | undefined;
}; };
hideOnCloud?: boolean;
} }
export interface INodeProperties { export interface INodeProperties {