asp*_*rin 8 javascript jsf oracle-adf
到目前为止,我已按照文档设法获得了按钮的click事件.我现在正在努力的是以编程方式触发ADF组件的click事件.
源代码如下:
<af:showDetailItem id="pane1" text="Panel Label 1" disclosed="true">
<af:commandButton text="commandButton 1" id="cb1">
<af:clientListener method="showNext" type="action" />
</af:commandButton>
</af:showDetailItem>
<af:showDetailItem id="pane2" text="Panel Label 2">
<af:commandButton text="commandButton 2" id="cb2">
<af:clientListener method="showNext" type="action" />
</af:commandButton>
</af:showDetailItem>
<af:showDetailItem id="pane3" text="Panel Label 3">
<af:commandButton text="commandButton 3" id="cb3">
<af:clientListener method="showNext" type="action" />
</af:commandButton>
</af:showDetailItem>
Run Code Online (Sandbox Code Playgroud)
使用Javascript
function showNext(evt){
var src = evt.getSource();
var showDetailItemNode = src.getParent(); // targets the showDetailItem tag
/* how do I trigger the click event of this node */
}
Run Code Online (Sandbox Code Playgroud)
所以我基本上想要实现的是,当点击按钮#cb1时,我想模拟showDetailItem#pane1的click事件,依此类推......
| 归档时间: |
|
| 查看次数: |
1221 次 |
| 最近记录: |