Project

General

Profile

« Previous | Next » 

Revision 9020f8ff

Added by Katja Luther almost 2 years ago

ref #8776: add all terms of the hierarchy to the list of the treeDto

View differences:

cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/persistence/dto/TermNodeDto.java
44 44
    public static TermNodeDto fromNode(TermNode node, TermTreeDto treeDto){
45 45
        Assert.notNull(node, "Node should not be null");
46 46
        TermDto term = node.getTerm() != null?TermDto.fromTerm(node.getTerm()): null;
47
        if (treeDto != null){
48
            treeDto.addTerm(term);
49
        }
47 50
        TermNodeDto dto = new TermNodeDto(term, node.getParent() != null? node.getParent().getIndex(node): 0, treeDto != null? treeDto: TermTreeDto.fromTree((TermTree)node.getGraph()), node.getUuid(), node.treeIndex(), node.getPath());
48 51
        if (node.getParent() != null){
49 52
            dto.setParentUuid(node.getParent().getUuid());

Also available in: Unified diff