this.assessableNodesList = nodeIdentList;
String[] hasScoreKeys = new String[] { Boolean.TRUE.toString(), Boolean.FALSE.toString() };
String[] hasScoreValues = new String[] { translate("scform.hasScore.yes"), translate("no") };
hasScore = new StaticSingleSelectionElement("scform.hasScore", hasScoreKeys, hasScoreValues);
addFormElement("hasScore", hasScore);
if (scoreCalculator != null && scoreCalculator.getSumOfScoreNodes() != null && scoreCalculator.getSumOfScoreNodes().size() > 0) {
hasScore.select(Boolean.TRUE.toString(), true);
} else {
hasScore.select(Boolean.FALSE.toString(), true); // default
}
// assessable child nodes
scoreNodeIdents = initNodeSelectionElement("scform.scoreNodeIndents", scoreCalculator, (scoreCalculator == null ? null
: scoreCalculator.getSumOfScoreNodes()), nodeIdentList);
addFormElement("scoreNodeIdents", scoreNodeIdents);
SpacerElement spacer = new SpacerElement(true, false);
addFormElement("spacer", spacer);
// passed configuration
String[] passedTypeKeys = new String[] { ScoreCalculator.PASSED_TYPE_NONE, ScoreCalculator.PASSED_TYPE_CUTVALUE,
ScoreCalculator.PASSED_TYPE_INHERIT };
String[] passedTypeValues = new String[] { translate("no"), translate("scform.passedtype.cutvalue"),
translate("scform.passedtype.inherit") };
passedType = new StaticSingleSelectionElement("scform.passedtype", passedTypeKeys, passedTypeValues);
addFormElement("passedType", passedType);
if (scoreCalculator != null && scoreCalculator.getPassedType() != null) {
passedType.select(scoreCalculator.getPassedType(), true);
} else {
passedType.select(ScoreCalculator.PASSED_TYPE_NONE, true); // default