Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to execute a custom Webwork Action method after submitting form?

Seyid Aghayev November 3, 2020 edited

Hello, 

I am writing a plugin webwork with a post method inside a vm file, but cannot find anywhere a documentation about my problem. 

I want my function to execute when I press the submit button. It always executes the execute() method. I have found different sources, where it is said to use 

 

<form method="post" action="ActionName!methodName.jspa">

And when defining a method, using something like:

public String doMethodName()

 This did not work for me. Then I have found that command definitions are needed in atlassian-plugin.xml file. This also did not work. 

Can anyone guide me to the right direction with that or provide me with documentation about this "!" symbol usage with post method? 

Thank you

1 answer

2 votes
Seyid Aghayev November 4, 2020 edited

I have solved the problem by changing the default execute() method name to doExecute(). Now it does not run the execute() method and goes to the doMethodName() method. I don't know why this is not documented anywhere. Is there any information about usage of "!" symbol in form actions to execute my custom methods? I have found this solution in video tutorials and nothing in Atlassian documentation. 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
TAGS
AUG Leaders

Atlassian Community Events