Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I want to use JavaScript code to trigger a workflow and populate the required variables, it triggers the workflow but still pops up a window requiring me to manually fill in the variables! #1728

Open
ddd0819 opened this issue May 17, 2024 · 2 comments

Comments

@ddd0819
Copy link

ddd0819 commented May 17, 2024

I want to use JavaScript code to trigger a workflow and populate the required variables, it triggers the workflow but still pops up a window requiring me to manually fill in the variables!
how can I specify the variables through JavaScript code?

here is my JavaScript code:

window.dispatchEvent(new CustomEvent('automa:execute-workflow', {detail: { publicId: '123456789',data: {variables: {search_key: 'hello',total: 10,filter_time:'2024-01-01',filter_like:0,filter_fans:0}}}}));

@ddd0819
Copy link
Author

ddd0819 commented May 17, 2024

The problem has been solved, I misunderstood the meaning, I thought the variable will be automatically filled into my pop-up window to help me fill in the corresponding variable value, it turns out that it is also necessary to get the value of the variable through JavaScript.

@lslcoded
Copy link

get the value of the variable through JavaScript.

how get the value of the variable through JavaScript ? thnk you tell me how to get

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants