package com.ys.bdtp.adm.mvvm.model.db.entity.dict

import androidx.room.ColumnInfo
import androidx.room.Entity
import androidx.room.PrimaryKey

/**
 * 字典, 关系表
 *
 * @author bai
 *
 * @param id
 * @param code 关系编码
 * @param name 关系名称
 * @param graphCode 图编码
 * @param directional 方向
 * @param attribute 属性
 * @param fromObjType 指出
 * @param toObjType 指向
 * @param remark 备注 * @param valid 有效标识: 0 无效, 1 有效
 *
 */
@Entity(tableName = "relation_dict")
data class RelationDictEntity(
    @PrimaryKey val id: String,
    @ColumnInfo(name = "code") val code: String,                  // 关系编码
    @ColumnInfo(name = "name") val name: String,                  // 关系名
    @ColumnInfo(name = "graph_code") val graphCode: String,       // 图编码
    @ColumnInfo(name = "directional") val directional: Int?,      // 方向
    @ColumnInfo(name = "target_objs") val targetObjs: String?,    // 目标对象
    @ColumnInfo(name = "attribute") val attribute: String?,       // 属性
    @ColumnInfo(name = "fromObjType") val fromObjType: String?,
    @ColumnInfo(name = "toObjType") val toObjType: String?,
    @ColumnInfo(name = "remark") val remark: String?,
    @ColumnInfo(name = "valid") var valid: Int?,                   // 有效标识, // 1 正常 0 删除
)