APEX 18.1
On an Interactive Grid Master Detail page, how can we add a custom action to the Row Actions menu to
- Get a value from one of the columns in the current record
- Ask user to confirm/cancel
- Send it to a server side process (stored procedure)
- Get an OUT parameter from the stored procedure
- Update the value of a (display only) column in the current row
https://apex.oracle.com/pls/apex/f?p=1855:35
Let's use the Master Detail page in the provided Sample Interactive Grid packaged app as a (contrived!) example.
I added a Display Only column to the master grid with the following
with dept as (
select DEPTNO,
DNAME,
LOC,
(select sum(sal) from eba_demo_ig_emp e where e.deptno = d.deptno) sal
from EBA_DEMO_IG_DEPT d
)
select
x.*,
case when sal > 10000 then '<span class="fa fa-smile-o"></span>' else '<span class="fa fa-frown-o"></span>' end status
from dept x
For each department, show the total salary of all employees and add a status column as an icon. I would like to add a custom action to the row action that gets the deptno, sends that to a server side process which does a top-secret calculation to adjust the salary of all employees in the department and returns the total salary which adjusts the smile/frown emoji on the row accordingly. Sorry, the example is a little contrived, just trying to have something to work with.
@"John Snyders-Oracle" This blog post shows to add a custom action to the row actions menu with a trivial example. How can the example be extended as described above?
I know you take the effort to update the blog post as the IG API rapidly evolves in every APEX release and Marko does an awesome job of aggregating up all the various IG tips & tricks, much appreciated.
Thanks