fix(editor): Prevent running workflows using keyboard shortcuts if execution is disabled (#9644)

This commit is contained in:
Milorad FIlipović
2024-06-06 10:41:40 +02:00
committed by GitHub
parent 7aea8243fe
commit e9e3b254fe
2 changed files with 28 additions and 1 deletions

View File

@@ -1643,7 +1643,7 @@ export default defineComponent({
source: NODE_CREATOR_OPEN_SOURCES.TAB,
createNodeActive: !this.createNodeActive && !this.isReadOnlyRoute && !this.readOnlyEnv,
});
} else if (e.key === 'Enter' && ctrlModifier && !readOnly) {
} else if (e.key === 'Enter' && ctrlModifier && !readOnly && !this.isExecutionDisabled) {
void this.onRunWorkflow();
} else if (e.key === 'S' && shiftModifier && !readOnly) {
void this.onAddNodes({ nodes: [{ type: STICKY_NODE_TYPE }], connections: [] });