Fix EntityAttribute dataclass to include name, type, and options fields
This commit is contained in:
@@ -67,12 +67,19 @@ class EntityAttribute:
|
||||
"""实体属性值"""
|
||||
id: str
|
||||
entity_id: str
|
||||
template_id: str
|
||||
value: str
|
||||
template_id: Optional[str] = None
|
||||
name: str = "" # 属性名称
|
||||
type: str = "text" # 属性类型
|
||||
value: str = ""
|
||||
options: List[str] = None # 选项列表
|
||||
template_name: str = "" # 关联查询时填充
|
||||
template_type: str = "" # 关联查询时填充
|
||||
created_at: str = ""
|
||||
updated_at: str = ""
|
||||
|
||||
def __post_init__(self):
|
||||
if self.options is None:
|
||||
self.options = []
|
||||
|
||||
@dataclass
|
||||
class AttributeHistory:
|
||||
|
||||
Reference in New Issue
Block a user