Skip to main content

plan_count

Function plan_count 

Source
pub fn plan_count(
    schema_name: &str,
    registry: &Registry,
    filter: Option<&Value>,
    ctx: Option<&Context>,
) -> Result<Value, String>
Expand description

统计数量(对应 JS count):filter 为 nullish 时用 {}

R1:owner(read=creator) 场景下,count 必须注入 createdBy = ctx.userId, 否则非 admin 用户 count 会越权统计全表(E-08)。