使用PrimeFaces“的RequestContext更新另一个页面的组件 [英] Using PrimeFaces' RequestContext to update a component in another page

查看:220
本文介绍了使用PrimeFaces“的RequestContext更新另一个页面的组件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我发现PrimeFaces的RequestContext#更新我发现它非常有用。

I've discovered PrimeFaces' RequestContext#update and I've found it very useful.

现在我希望它更新一个组成部分,这不是谁被称为豆在页面上。

Now I want it to update a component that's NOT on the page who called the bean.

有没有办法告诉给的RequestContext#更新这是需要更新的部分是另一页上?

Is there any way to tell to RequestContext#update that the component that need to be updated is on another page?

是这样的: RequestContext.getCurrentInstance()更新(downloads.xhtml,:downloadPanel)

推荐答案

如果您导航回正是页面时操作方法结束这是唯一可能的。这使得否则没有意义反正作为的RequestContext 仅适用于当前请求。

That's only possible if you navigate back to exactly that page when the action method finishes. It makes otherwise no sense anyway as the RequestContext applies to the current request only.

这篇关于使用PrimeFaces“的RequestContext更新另一个页面的组件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆