package com.reyun.model;

import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.IdClass;
import javax.persistence.Transient;
import javax.validation.constraints.NotNull;

import java.util.List;

/**
 * description:
 *
 * @author nolan
 * @date 25/12/2017
 */
@Entity
@IdClass(SyDicItemPK.class)
public class SyDicItem
{
    @NotNull
    @Id
    private String itemCode;
    @NotNull
    private String itemValue;
    @NotNull
    private Integer itemOrder;
    @NotNull
    private Integer itemLevel;
    private String itemPid;
    @NotNull
    @Id
    private String dicCode;
    @Transient
    private List<SyDicItem> child;

    public String getItemCode() {
        return itemCode;
    }

    public void setItemCode(String itemCode) {
        this.itemCode = itemCode;
    }

    public String getItemValue() {
        return itemValue;
    }

    public void setItemValue(String itemValue) {
        this.itemValue = itemValue;
    }

    public Integer getItemOrder() {
        return itemOrder;
    }

    public void setItemOrder(Integer itemOrder) {
        this.itemOrder = itemOrder;
    }

    public Integer getItemLevel() {
        return itemLevel;
    }

    public void setItemLevel(Integer itemLevel) {
        this.itemLevel = itemLevel;
    }

    public String getItemPid() {
        return itemPid;
    }

    public void setItemPid(String itemPid) {
        this.itemPid = itemPid;
    }

    public String getDicCode() {
        return dicCode;
    }

    public void setDicCode(String dicCode) {
        this.dicCode = dicCode;
    }

    public List<SyDicItem> getChild() {
        return child;
    }

    public void setChild(List<SyDicItem> child) {
        this.child = child;
    }
}
