Conditional multi row delete - action and pop up for each row?
Hello
I have form with standard Add and Remove buttons. The deletion is implemented calling MULTI_ROW_DELETE based on DELETE button.
In "Action When Button Clicked":
javascript:if($v('P2_BC_ID') == '0')
{
apex.confirm('Delete selected line?','MULTI_ROW_DELETE');
} else
{
apex.confirm('There is linked data. They will be deleted too! Delete anyway?','MULTI_ROW_DELETE');
}
From the message text is obvious what I am trying to do, but I could not find way how to calculate P2_BC_ID for each row? For each row checked I need to issue select into database and find out if there are linked data. If so, user can decide if to delete or not. So it means if user checked 5 lines, message should popup 5 times.
Any ideas how to implement such function?
Thanks & Regs
Ludek