Oracle APEX - Refresh parent page 1 (interactive report) after closing a another page 2 (page mode = Modal dialog) - oracle

I am trying to refresh the interactive report on a parent page 1 after updating page 2 which is a modal dialog page mode. The page should close automatically after clicking the submit button (managed by a dynamic action). currently I have "apex.navigation.dialog.close(true);" as the last sequence of Dynamic true action on the modal page 2.
I also created a DA on the parent page to execute javascript code "$('#myirr').trigger('apexrefresh'); "
where #myirr is the static ID of the interactive report i want refreshed automatically. This did not work for me. Please can anyone give me some advice? Thank you for your assistance.

Related

Access Page item's value in console of Modal page Oracle Apex 5.1

When the popup page is of normal page template I am able to access value of page item in console without error. But when page template is changed to modal dialog the page item value is null and I am getting error. Tried
apex.item("P12_item").getValue();
$v("P12_item");
In session state I am still able to view the value.! but error in console
What browser are you using? Usually, when you open a modal page, you need to change the context of your console so it can read the values of the items in the modal.
In Mozilla, for example, you can find the option here:
Context selection

How to redirect to previous page after clicking "ok" on the apex.confirm message box in oracle apex dynamic action

How to navigate back to the previous page after I hit ok on the confirm message box on apex. I used a dynamic action on the delete button but it only deletes the record not navigate back to the previous page. Is my code below correct?
if(apex.confirm(htmldb_delete_message,'DELETE') == true)
{
apex.navigation.redirect(window.history.back());
}
If you are using the default delete button that is created by the form creation wizard, then on the button properties you'll see that the button's behavior target is defined by a javascript which prompts a confirmation window. After the user hits "OK" on that window, the page is submitted so your delete process can execute.
Trying to execute a javascript code before that to force the navigation may be a bad idea and you would have to restructure your delete process to be processed at the right point
Try to create a branch (https://docs.oracle.com/cd/E59726_01/doc.50/e39147/nav_branch_using.htm#HTMDB25149) instead of using a dynamic action to navigate back to previous page. You can configure it to occur "after processing" and either manually set the page that you to go back to or use a hidden item to always go back to the page which the user came from as described in here: How do add a button to go back to another page in oracle apex interactive grid

Modal dialog - refresh the parent page on close modal dialog or submit button

Using Apex 5.1.3
I have everyting working, but I have a requreimet to refresh the entire page (parent page) on the close of the modal page or press submit button.
I have tried quite a few things in dynamic actions on the parent page etc, but nothing is working.
How can I get the parent page to fully refresh when the modal dialog is submitted and closed.
Your help would be most appreciated.
Regards,
Morshed
You could either place a branch after processing on your modal that redirects to the parent page, or create a dynamic action 'on dialog close' on the button/region that invokes the dialog page, which then submits/refreshes the page.
If you think 'nothing is working', put APEX in debug mode, open your browser console, and check if the dynamic actions are actually firing.

Refresh a Fusion block on click of a button wordpress Avada

I have some buttons on a page and on click of each button the page gets reload and the data changes. Now, I would like to refresh that particular fusion block only without reloading the page. The buttons are added to the page as a widget (with some valid reasons) and the fusion block is on the page itself. Would it be possible to achieve what I am looking for?

Wicket: Modal Windows and callback functionality

I have a modal window that shows a panel which contains a form that has some textfields and a submit button
on submit an insert into the database occurs and then I have some ajax behaviour that i want to activate on the modal windows containing page on click of the button.
So flow is at present:
click link
modal window appears
user fills out form
user submits form
form data persisted to db
modal window closes
I need it to do this in addition:
activate some ajax behaviour on the page that contains the panel
any help on how best to do this in the wicket way is appreciated.
I resolved this by passing an instance of the page containing the panel to the panel (i.e. - in the constructor), then calling a method on the page from the panel to perform the Ajax update.
I would be interested to see what others have done or to hear if there are issues with the approach I have taken.
Set up a WindowClose callback.
In the WicketStuff project called ModelX (Disclaimer: I'm the developer of that) I have created an IWindowClosedListener interface which has a method:
void windowClosed(Panel panel, AjaxRequestTarget target)
So then any Page or Panel that can open a modal that needs to do something when that modal is closed simply implements that interface and its windowClosed method gets called at the right time.

Resources