- TableSpec 增字段 child_tables: &'static [(&'static str, &'static str)] - 18 个实体 spec 各自声明子表(Resource / Dataset 两条,其余 16 条空) - service/crud.rs 删掉按 api_name 分叉的 child_tables(),改读 spec.child_tables - 边界账本删掉已失效条目(CP3 crud.rs match spec.api_name)
34 lines
1.3 KiB
Rust
34 lines
1.3 KiB
Rust
//! `Resource` 的实体元数据(对位上游 `ssw.tdc.entity.ResourceEntity`)。
|
|
//!
|
|
//! 🔴 新建默认**停用** + `mountStatus = UNMOUNTED` —— 照抄上游 `ResourceServiceImpl:305-334`。
|
|
//!
|
|
//! 本文件只放**这一个**实体的 spec —— 通用元数据结构见 [`super::TableSpec`]。
|
|
|
|
use super::TableSpec;
|
|
|
|
/// 本实体的完整元数据(注册表唯一真源)。
|
|
pub const SPEC: TableSpec = TableSpec {
|
|
api_name: "Resource",
|
|
path: "/api/ssw/tdc/Resource",
|
|
table: "tdc_resource",
|
|
keyword_columns: &["f_name"],
|
|
filter_columns: &[
|
|
("datasourceId", "f_datasource_id"),
|
|
("resourceType", "f_resource_type"),
|
|
("category", "f_category"),
|
|
("classifyLevel", "f_classify_level"),
|
|
("sensitiveMark", "f_sensitive_mark"),
|
|
("status", "f_status"),
|
|
("sourceType", "f_source_type"),
|
|
],
|
|
tenant_column: Some("f_tenant_id"),
|
|
default_order_column: "f_creator_time",
|
|
extra_where: None,
|
|
no_create: None,
|
|
no_update: None,
|
|
no_delete: None,
|
|
frozen_columns: &[],
|
|
hidden_fields: &[],
|
|
child_tables: &[("fieldRules", "tdc_resource_field"), ("maskRules", "tdc_resource_mask_rule")],
|
|
};
|