简体   繁体   中英

xp:checkBox in edit mode does not match checked value from bean

on an xpage I have checkbox control with data-binding to a bean eg:

<xp:checkBox text="Agree" value="#{proposalBean.proposal.mailNotify}" checkedValue="YES"/>

In the back-end I load the value from a Notes doc. When I load the xpage I get the correct value, but when I edit the object the value turns to false. It seems that it cannot match the value from the bean ("YES") with the checkedValue.

Is there a bug and a workaround r should I switch to a checkboxgroup control?

I had to compute the readonly AND disabled property. I had only the disabled property computed.... :-?

readonly="#{javascript:!proposalBean.editable || proposalBean.locked}"
disabled="#{javascript:!proposalBean.editable || proposalBean.locked}"

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM