use of org.openforis.collect.designer.component.SchemaTreeModelCreator in project collect by openforis.
the class SchemaVM method buildTreeModel.
protected void buildTreeModel() {
CollectSurvey survey = getSurvey();
if (survey == null) {
// TODO session expired...?
} else {
TreeViewType viewType = TreeViewType.valueOf(selectedTreeViewType.toUpperCase());
SurveyObjectTreeModelCreator modelCreator;
switch(viewType) {
case ENTRY:
modelCreator = new UITreeModelCreator(selectedVersion, null, false, true, currentLanguageCode);
break;
default:
modelCreator = new SchemaTreeModelCreator(selectedVersion, null, false, true, currentLanguageCode);
}
treeModel = modelCreator.createModel(selectedRootEntity);
}
}
Aggregations