package com.hdkj.lt.core.sys.model.dto;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModel;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import java.util.ArrayList;
import java.util.List;

@ApiModel("设备组织机构树")
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
public class OrgTreeDto {

    private String id;

    private Long struId;

    private String name;

    @JsonIgnore
    @JSONField(serialize = false)
    private Long parentId;

    private String orgCode;

    private String organType;

    private Boolean isLeaf;

    private String majCode;

    private String parentOrganType;

    private List<OrgTreeDto> children = new ArrayList<>();

}
