タイトルにあるように、この問題を数時間解決できません。有益な回答が得られることを願っています。ありがとうございます。
改札バージョン: 1.5.7
public class EvalSearcherPage extends MenuPage {
...
private Code selectedEvalChoice;
...
...
RadioChoice<Code> evalRadioChoice = new RadioChoice<Code>("evalRadioChoice", new PropertyModel<Code>(this, "selectedEvalChoice"), EVAL_CHOICES, new ChoiceRenderer<Code>(getLocaleColumn()));
evalRadioChoice.add(new AjaxFormComponentUpdatingBehavior("onchange") {
private static final long serialVersionUID = 1L;
@Override
protected void onUpdate(AjaxRequestTarget target) {
...
target.add(...);
}
});
evalChoiceForm.add(evalRadioChoice);
...
コンストラクター: EVAL_CHOICES は選択肢で埋められ、selectedEvalChoice はデフォルトの選択肢で埋められます
別の選択肢を選択したい瞬間まで、すべてがうまく機能します。その後、RadioChoice は null を selectedEvalChoice に保存します。
では、どこに問題があるのでしょうか。誰か助けてください。
ところで、selectedEvalChoice には getter と setter が実装されていますが、それは必要ないことを知りました。