For Advanced Table
1)Create Transient Attribute On View Object on which Advanced Table/Classic Table is based.
Name SelToDel
Type String
Updatable Always
2)In structure Right Click on Advanced Table --> New --> Multiple Selection
Under default multipleSelection1 update below .
View Attribute SelToDel
Text Actions (Optional)
3) Right Click multipleSelect1 --> New --> rowLayout
4) Right Click region1 --> New --> Item
Update below details
Id DelBtn
Item Style submitButton
Prompt Delete
You can add below piece of code in Controller(You need to Import your custom VORowImpl in CO)
or Best Practice is to add method in AM and call AM method from Controller.
if (pageContext.getParameter("DelBtn") != null)
{
System.out.println("Proceed Delete");
OAViewObject vo = (OAViewObject)am.findViewObject("XxFileBlobsVO1");
{
System.out.println("Proceed Delete");
OAViewObject vo = (OAViewObject)am.findViewObject("XxFileBlobsVO1");
Row row[] = vo.getAllRowsInRange();
for (int i=0;i<row.length;i++)
{
XxFileBlobsVORowImpl rowi = (XxFileBlobsVORowImpl)row[i];
if (rowi.getSelToDel()!= null && rowi.getSelToDel().equals("Y"))
{
oracle.jbo.domain.Number vFileId = (oracle.jbo.domain.Number)rowi.getFileId();
rowi.remove(); // Here you can call updates if reqd
System.out.println("Selected To Delete File Id "+vFileId);
}
}
am.invokeMethod("apply");
{
XxFileBlobsVORowImpl rowi = (XxFileBlobsVORowImpl)row[i];
if (rowi.getSelToDel()!= null && rowi.getSelToDel().equals("Y"))
{
oracle.jbo.domain.Number vFileId = (oracle.jbo.domain.Number)rowi.getFileId();
rowi.remove(); // Here you can call updates if reqd
System.out.println("Selected To Delete File Id "+vFileId);
}
}
am.invokeMethod("apply");
}
For more information
Hai can we write Multiple update code in processFormRequest
ReplyDeleteHi Vamshi,
ReplyDeleteYes. You can get handle of view object in process form request. Iterate and condi t ionally update rows.
Hi
DeleteHow can we create lov's for Advance table? i had created manual search and
normal table i had given parameters also but it was not updating
which was already exit in d2k form in d2k they called blocks i am struck at block values are not there at table but they use those blocks for logic purpose how can we call those in OAF?
hi i am new to OAF
Deletecan i Share my Form Code with you if are free it self.
ERPTREE is a leading oracle fuison HCM Training Institute. we offer this course through online we have great experience in succeeding students through online courses. we can calculate our performance through their honest comments in our sites in supporting our services. we have referral program so candidates can earn money through referral. you can share your live experience with other can generate you some money.
ReplyDeleteOracle Fusion HCM Online Training