VideoTree.java 1.15 KB
package com.bsth.entity.video;

import lombok.Data;


import javax.persistence.Id;
import javax.persistence.Transient;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;


/**
 * @author liujun
 * @date 2024年06月27日 11:16
 */
@Data
public class VideoTree implements Serializable {

    private static final long serialVersionUID = 8270934502586526774L;
    /**
     * 公司ID、线路ID、汽车ID
     */
    @Transient
    private Object sourceId;
    /**
     * 编码(公司、线路、汽车)
     */

    @Id
    @Transient
    private Object id;
    /**
     * 公司名称、线路名称、汽车名称
     */
    @Transient
    private String text;
    /**
     * 类型:1为公司;2为线路;3为汽车
     */
    @Transient
    private Integer type;
    /**
     * 父节点
     */
    @Transient
    private Object parentId;

    @Transient
    private String icon;

    @Transient
    private List<VideoTree> children;

    private Map<String,Object> state;

    public VideoTree(){
        this.state = new HashMap<>();
        state.put("opened",true);
    }

}