Create ADF popup for value change event(For select one choice component).

Add popup and add dialog to inside of the popup,then select popup and add value for binding attribute in mine
#{pageFlowScope.popupBean.myPop}.
private RichPopup myPop = new RichPopup();
public void selectOneChoiceEvent(ValueChangeEvent valueChangeEvent) {
RichPopup.PopupHints ph = new RichPopup.PopupHints();
myPop.show(ph);
}
public void setMyPop(RichPopup myPop) {
this.myPop = myPop;
}
public RichPopup getMyPop() {
return myPop;
}

Oracle ADF - Add new custom attribute for view object using Expression

Oracle ADF Client-side Validators

Oracle ADF Association sample for Department and Employee

Tuesday, March 29, 2011

Get view object row values using iterator by backing bean class

(1)Assume iterator include with page(drag VO from DataControl to design area as table) or added to pagedef.xml

(2)Add manage bean to your taskflow or faces-config
<managed-bean-name>ManagedTest</managed-bean-name>
<managed-bean-class>view.managed.TestBean</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
<managed-property>
<property-name>bindingContainer</property-name>
<property-class>oracle.adf.model.binding.DCBindingContainer</property-class>
<value>#{bindings}</value>

(3)Now you can access bindings from bean class.

Iterator has to be added in PageDef.xml . This is example code for managed bean:

import oracle.adf.model.binding.DCBindingContainer;
import oracle.adf.model.binding.DCIteratorBinding;
import oracle.jbo.Row;

public class TestBean {

private DCBindingContainer bindingContainer;

public String getIterValues(){
DCBindingContainer bc = getBindingContainer();
DCIteratorBinding iterator = bc.findIteratorBinding("DeparmentVOIterator");
Row r = iterator.getCurrentRow();
String deptnme = (String)r.getAttribute("DepartmentName");
System.out.println(deptnme );
return null;
}

public void setBindingContainer(DCBindingContainer bindingContainer) {
this.bindingContainer = bindingContainer;
}

public DCBindingContainer getBindingContainer() {
return bindingContainer;
}
}

No comments:

Post a Comment