feat(editor): add automatic credential selection for new nodes (#2746)

*  implemented automatic credential selection in nodes

*  fixed implementation

*  fixed linter error

* 🔨 in progress, removed watching for auth type, added check for more then one existing credential

* 🔨 removed console log

* 🔨 changing auth method for one that have default credential

* 🔨 credentials will be set only at node creation time

* 🔨 fixed authentication parameter assigment for nodes that does not have it

*  better properties checking

* 🔨 improvements

* 🔨 extracted into function, fix issue with assigning hidden credentials

* remove console log

* fix bug with multiple creds

* fix defaults issue

* remove import

* simplify to just auth

* Revert "simplify to just auth"

042c9cc30fc84f2df493d5fb2aa082af4745cdda

* fix get

Co-authored-by: Mutasem <mutdmour@gmail.com>
This commit is contained in:
Michael Kret
2022-10-17 14:39:42 +03:00
committed by GitHub
parent 353a28bfe7
commit d31fbbba27
2 changed files with 71 additions and 11 deletions

View File

@@ -147,6 +147,7 @@ export default mixins(
return this.node.credentials || {};
},
},
methods: {
getCredentialOptions(type: string): ICredentialsResponse[] {
return (this.allCredentialsByType as Record<string, ICredentialsResponse[]>)[type].filter((credential) => {