You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
80 lines
1017 B
80 lines
1017 B
package com.hfkj.model;
|
|
|
|
import java.util.ArrayList;
|
|
import java.util.List;
|
|
|
|
public class CommonTreeModel {
|
|
|
|
private String text;
|
|
|
|
private Long id;
|
|
|
|
private Long pId;
|
|
|
|
private Integer showOnMobile;
|
|
|
|
private List<CommonTreeModel> nodes;
|
|
|
|
|
|
|
|
public Integer getShowOnMobile() {
|
|
return showOnMobile;
|
|
}
|
|
|
|
|
|
public void setShowOnMobile(Integer showOnMobile) {
|
|
this.showOnMobile = showOnMobile;
|
|
}
|
|
|
|
|
|
public String getText() {
|
|
return text;
|
|
}
|
|
|
|
|
|
public void setText(String text) {
|
|
this.text = text;
|
|
}
|
|
|
|
public Long getId() {
|
|
return id;
|
|
}
|
|
|
|
|
|
public void setId(Long id) {
|
|
this.id = id;
|
|
}
|
|
|
|
|
|
public Long getpId() {
|
|
return pId;
|
|
}
|
|
|
|
|
|
public void setpId(Long pId) {
|
|
this.pId = pId;
|
|
}
|
|
|
|
|
|
public List<CommonTreeModel> getNodes() {
|
|
return nodes;
|
|
}
|
|
|
|
|
|
public void setNodes(List<CommonTreeModel> nodes) {
|
|
this.nodes = nodes;
|
|
}
|
|
|
|
|
|
/**
|
|
* 添加子节点.
|
|
* @param child
|
|
*/
|
|
public void add(CommonTreeModel child) {
|
|
if (nodes == null) {
|
|
nodes = new ArrayList<>();
|
|
}
|
|
nodes.add(child);
|
|
}
|
|
|
|
}
|
|
|