当managedbean的生命周期是request时,慎用rendered属性于commandButton UIcomponent。
原因:
当点击button时,提交表单。 在服务器端 restore view, 这是可能由于参数传递的问题, rendered 的值为false, 这样绑定于commandButton uicomponent 的event, 找不到ui component,就不会被处理。
当ManagedBean的生命周期设置为request时,使用rendered属性于commandButton UI组件可能导致表单提交失败。原因是服务器端恢复视图时,rendered属性值可能变为false,导致事件无法正确绑定到UI组件。
当managedbean的生命周期是request时,慎用rendered属性于commandButton UIcomponent。
原因:
当点击button时,提交表单。 在服务器端 restore view, 这是可能由于参数传递的问题, rendered 的值为false, 这样绑定于commandButton uicomponent 的event, 找不到ui component,就不会被处理。

被折叠的 条评论
为什么被折叠?