apex.submit does not cause Interactive Grid refresh

373 Views Asked by At

On my page I am calling apex.submit("PROCESS1") from javascript. It executes the code of PROCESS1 process but the IG I have on the page does not get refreshed. After PROCESS1 executes I see the unchanged data in the grid and it only changes after I manually refresh the page. My understanding was that submit should refresh the IG on the page. What am I doing wrong?

2

There are 2 best solutions below

0
On

I wasn't able to reproduce the behaviour you described. I created an IG on the emp table and a button with name "PROCESS".

  • I opened the page with the IG
  • In a separate SQL Commands window I updated a single row in the emp table.
  • Then in the IG page, in the chrome dev tools console, I executed
apex.submit("PROCESS")

The page refreshes and the IG re-renders and shows the updated data. This is on 22.2.

0
On

Have you considered something like this, to explicitly tell it to A)lways refresh?

apex.submit( {
    request: "PROCESS1",
    reloadOnSubmit: "A",
} );

I found the reference here: https://docs.oracle.com/en/database/oracle/application-express/19.2/aexjs/apex.page.html#.submit