Forums

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

how do I exit a dialog?

Maja Stach April 18, 2013

I'm writing a web-item plugin which triggers a dialog. the web-item is connected to a webwork action.

The pugin creates an Issue and would usually redirect to the new Issue. At first I didn't have a dialog and it worked perfectly. Now that I implemented the dialog it redirects to the new Issue INSIDE the dialog. How can I tell my plugin to close the dialog instead of showing the site inside it?

3 answers

0 votes
Maja Stach April 25, 2013

seriously I'm still desperate. I can't even find a Javascriptmethod that closes a dialog.

0 votes
Colin Goudie
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 21, 2013

For your actual question, can't you grab hold of the 'submit', or whatever equivalent button your populating your UI with, using JQuery and on that event close the dialog?

Maja Stach April 21, 2013

that should be possible, shouldn't it?

can you tell me how I exit the dialog using a button? I don't exactly have much experience with Javascript and HTML. Also is it possible to trigger the dialog closing event when pressing enter?

Colin Goudie
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 25, 2013

dialog.hide();

0 votes
Colin Goudie
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 21, 2013

Not answering your direct question but when I do dialogs they are all javascript but the dialog is populated via soy templates. The dialog itself grabs the data and communicates to the server via REST.

It's then trivial to save out the info via POSTs to a REST interface and close the dialog in success via javascript

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events