@qingflow-tech/qingflow-cli 1.1.61-beta.3 → 1.1.61-beta.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/package.json +1 -1
- package/pyproject.toml +1 -1
- package/skills/qingflow-cli/SKILL.md +2 -0
- package/skills/qingflow-cli/reference/builder/30-schema-fields.md +13 -0
- package/skills/qingflow-cli/reference/builder/70-portal.md +37 -16
- package/skills/qingflow-cli/reference/data/README.md +38 -0
- package/skills/qingflow-cli/reference/examples/portal/portal_apply_v1alpha1.example.json +100 -0
- package/skills/qingflow-cli/reference/examples/portal/portal_sections_all_types.example.json +6 -7
- package/src/qingflow_mcp/app_form_validator.py +20 -3
- package/src/qingflow_mcp/builder_facade/app_form.py +137 -17
- package/src/qingflow_mcp/builder_facade/models.py +164 -13
- package/src/qingflow_mcp/builder_facade/portals_schema.py +397 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/manifest.json +14 -1
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/complete.json +49 -9
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/address.json +27 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/ai_content_classification.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/ai_content_extraction.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/ai_content_generation.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/ai_document_parsing.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/ai_image_generation.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/ai_image_recognition.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/ai_machine_translation.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/ai_text_summary.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/amount.json +2 -2
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/attachment.json +27 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/date_duration.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/embed_field.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/image_select.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/location.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/number.json +2 -2
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/ocr.json +146 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/q_linker.json +2 -2
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/relation.json +27 -0
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/fields/subtable.json +29 -2
- package/src/qingflow_mcp/builder_facade/schemas/app_form/v1alpha1/summary.json +20 -7
- package/src/qingflow_mcp/builder_facade/schemas/portals/manifest.json +59 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/complete.json +1397 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/components/carousel.json +193 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/components/chart.json +643 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/components/favourite.json +203 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/components/filter.json +268 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/components/grid.json +265 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/components/link.json +131 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/components/task.json +199 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/components/text.json +123 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/components/view.json +196 -0
- package/src/qingflow_mcp/builder_facade/schemas/portals/v1alpha1/summary.json +800 -0
- package/src/qingflow_mcp/builder_facade/service.py +1104 -71
- package/src/qingflow_mcp/cli/commands/builder.py +114 -5
- package/src/qingflow_mcp/public_surface.py +2 -0
- package/src/qingflow_mcp/server_app_builder.py +32 -1
- package/src/qingflow_mcp/solution/compiler/icon_utils.py +73 -0
- package/src/qingflow_mcp/solution/executor.py +5 -2
- package/src/qingflow_mcp/tools/ai_builder_tools.py +110 -12
- package/src/qingflow_mcp/tools/portal_tools.py +4 -54
- package/src/qingflow_mcp/tools/portal_writer.py +59 -0
- package/src/qingflow_mcp/tools/solution_tools.py +2 -0
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://qingflow.com/schemas/builder/portals/v1alpha1/components/favourite.json",
|
|
4
|
+
"title": "Qingflow Builder Portals Section · favourite (v1alpha1)",
|
|
5
|
+
"portalFavouriteSectionDescription": "门户收藏组件(favourite)的详细配置专项 Schema。获取命令:qingflow builder portal schema --schema-kind favourite(MCP: portal_schema(schema_kind=\"favourite\"))。本 Schema 校验 sections[] 中单个 favourite 区块(自包含,可直接交给 JSON Schema 校验器);后端 DashComponentInfo.type=7。整门户声明走 summary/complete 档。",
|
|
6
|
+
"$defs": {
|
|
7
|
+
"Position": {
|
|
8
|
+
"type": "object",
|
|
9
|
+
"additionalProperties": false,
|
|
10
|
+
"positionShapeDescription": "网格位置。PC 是 24 列网格(cols≤24),mobile 是 6 列网格(cols≤6);同行组件共享同一 y 与 rows,一行 cols 合计 24。mobile 可省略(缺省与 pc 同布局)。平铺别名 pc_x/pc_y/pc_w/pc_h、mobile_* 也接受,归一为本结构。标准行高:指标卡 rows=5、BI 图表 rows=7、数据视图 rows=11、业务入口 rows=4。",
|
|
11
|
+
"properties": {
|
|
12
|
+
"pc": {
|
|
13
|
+
"$ref": "#/$defs/PositionDetail"
|
|
14
|
+
},
|
|
15
|
+
"mobile": {
|
|
16
|
+
"$ref": "#/$defs/PositionDetail"
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"PositionDetail": {
|
|
21
|
+
"type": "object",
|
|
22
|
+
"additionalProperties": false,
|
|
23
|
+
"positionDetailShapeDescription": "单端位置:x=列偏移、y=行偏移、cols=占宽、rows=占高。",
|
|
24
|
+
"properties": {
|
|
25
|
+
"x": {
|
|
26
|
+
"type": [
|
|
27
|
+
"integer",
|
|
28
|
+
"null"
|
|
29
|
+
],
|
|
30
|
+
"minimum": 0
|
|
31
|
+
},
|
|
32
|
+
"y": {
|
|
33
|
+
"type": [
|
|
34
|
+
"integer",
|
|
35
|
+
"null"
|
|
36
|
+
],
|
|
37
|
+
"minimum": 0
|
|
38
|
+
},
|
|
39
|
+
"cols": {
|
|
40
|
+
"type": [
|
|
41
|
+
"integer",
|
|
42
|
+
"null"
|
|
43
|
+
],
|
|
44
|
+
"minimum": 1
|
|
45
|
+
},
|
|
46
|
+
"rows": {
|
|
47
|
+
"type": [
|
|
48
|
+
"integer",
|
|
49
|
+
"null"
|
|
50
|
+
],
|
|
51
|
+
"minimum": 1
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
"x-backend": "DashPosition.pc / DashPosition.mobile"
|
|
55
|
+
},
|
|
56
|
+
"FavouriteConfig": {
|
|
57
|
+
"type": "object",
|
|
58
|
+
"additionalProperties": false,
|
|
59
|
+
"favouriteConfigShapeDescription": "收藏组件配置。",
|
|
60
|
+
"properties": {
|
|
61
|
+
"show_title": {
|
|
62
|
+
"type": "boolean",
|
|
63
|
+
"default": true,
|
|
64
|
+
"favouriteShowTitleShapeDescription": "是否显示收藏标题。别名 beingShowTitle。",
|
|
65
|
+
"x-backend": "ComponentFavouriteConfig.beingShowTitle"
|
|
66
|
+
},
|
|
67
|
+
"enabled": {
|
|
68
|
+
"type": "boolean",
|
|
69
|
+
"favouriteEnabledShapeDescription": "收藏组件是否启用。别名 beingUsing。",
|
|
70
|
+
"x-backend": "ComponentFavouriteConfig.beingUsing"
|
|
71
|
+
},
|
|
72
|
+
"items": {
|
|
73
|
+
"type": "array",
|
|
74
|
+
"favouriteItemsShapeDescription": "收藏条目(用户级收藏为主,声明面预置初始条目;ordinal 缺省按数组顺序)。",
|
|
75
|
+
"items": {
|
|
76
|
+
"$ref": "#/$defs/FavouriteItem"
|
|
77
|
+
},
|
|
78
|
+
"x-backend": "ComponentFavouriteConfig.items(ComponentFavouriteItemInfo)"
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
},
|
|
82
|
+
"FavouriteItem": {
|
|
83
|
+
"type": "object",
|
|
84
|
+
"additionalProperties": false,
|
|
85
|
+
"required": [
|
|
86
|
+
"title"
|
|
87
|
+
],
|
|
88
|
+
"favouriteItemShapeDescription": "单个收藏条目。",
|
|
89
|
+
"properties": {
|
|
90
|
+
"title": {
|
|
91
|
+
"type": "string",
|
|
92
|
+
"favouriteItemTitleShapeDescription": "条目标题。",
|
|
93
|
+
"x-backend": "ComponentFavouriteItemInfo.title"
|
|
94
|
+
},
|
|
95
|
+
"item_type": {
|
|
96
|
+
"type": "integer",
|
|
97
|
+
"favouriteItemTypeShapeDescription": "条目类型。别名 type。",
|
|
98
|
+
"x-backend": "ComponentFavouriteItemInfo.type"
|
|
99
|
+
},
|
|
100
|
+
"link_key": {
|
|
101
|
+
"type": "string",
|
|
102
|
+
"favouriteItemLinkKeyShapeDescription": "目标资源 key(应用/门户 key)。",
|
|
103
|
+
"x-backend": "ComponentFavouriteItemInfo.linkKey"
|
|
104
|
+
},
|
|
105
|
+
"link_id": {
|
|
106
|
+
"type": "integer",
|
|
107
|
+
"favouriteItemLinkIdShapeDescription": "目标资源 id。",
|
|
108
|
+
"x-backend": "ComponentFavouriteItemInfo.linkId"
|
|
109
|
+
},
|
|
110
|
+
"icon_url": {
|
|
111
|
+
"type": "string",
|
|
112
|
+
"favouriteItemIconShapeDescription": "条目图标 url。别名 iconUrl。",
|
|
113
|
+
"x-backend": "ComponentFavouriteItemInfo.iconUrl"
|
|
114
|
+
},
|
|
115
|
+
"jump_mode": {
|
|
116
|
+
"type": "integer",
|
|
117
|
+
"favouriteItemJumpModeShapeDescription": "跳转方式。",
|
|
118
|
+
"x-backend": "ComponentFavouriteItemInfo.jumpMode"
|
|
119
|
+
},
|
|
120
|
+
"ordinal": {
|
|
121
|
+
"type": "integer",
|
|
122
|
+
"favouriteItemOrdinalShapeDescription": "排序序号。",
|
|
123
|
+
"x-backend": "ComponentFavouriteItemInfo.ordinal"
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
},
|
|
127
|
+
"Section": {
|
|
128
|
+
"type": "object",
|
|
129
|
+
"additionalProperties": false,
|
|
130
|
+
"required": [
|
|
131
|
+
"title",
|
|
132
|
+
"source_type",
|
|
133
|
+
"favourite"
|
|
134
|
+
],
|
|
135
|
+
"properties": {
|
|
136
|
+
"title": {
|
|
137
|
+
"type": "string",
|
|
138
|
+
"minLength": 1,
|
|
139
|
+
"sectionTitleShapeDescription": "组件标题(渲染在组件头部)。",
|
|
140
|
+
"x-backend": "组件标题(DashChartInfo.title / gridConfig.gridTitle 等)"
|
|
141
|
+
},
|
|
142
|
+
"source_type": {
|
|
143
|
+
"const": "favourite",
|
|
144
|
+
"sourceTypeConstDescription": "组件类型固定为 favourite(收藏);后端 type 整数见 x-backend。",
|
|
145
|
+
"x-backend": "DashComponentInfo.type(favourite)"
|
|
146
|
+
},
|
|
147
|
+
"role": {
|
|
148
|
+
"type": "string",
|
|
149
|
+
"roleShapeDescription": "组件角色标注(编排辅助,如 metric=指标卡;影响布局预设的排布与行高)。别名 zone/section_role。"
|
|
150
|
+
},
|
|
151
|
+
"position": {
|
|
152
|
+
"$ref": "#/$defs/Position"
|
|
153
|
+
},
|
|
154
|
+
"style_config": {
|
|
155
|
+
"type": "object",
|
|
156
|
+
"styleConfigSectionDescription": "组件级样式(受控键集;键白名单以 ws40013 dataset 实测形态校准,未经校准的键会被拒绝)。别名 dash_style_config/dashStyleConfigBO。",
|
|
157
|
+
"x-backend": "DashComponentInfo.dashStyleConfigBO(DashStyleConfigBO)"
|
|
158
|
+
},
|
|
159
|
+
"favourite": {
|
|
160
|
+
"$ref": "#/$defs/FavouriteConfig",
|
|
161
|
+
"favouritePropDescription": "收藏配置(必填)。"
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
},
|
|
166
|
+
"$ref": "#/$defs/Section",
|
|
167
|
+
"x-qingflow-detail-query": {
|
|
168
|
+
"currentKind": "favourite",
|
|
169
|
+
"tool": "portal_schema",
|
|
170
|
+
"cli": "qingflow builder portal schema --schema-kind favourite",
|
|
171
|
+
"argument": "schema_kind",
|
|
172
|
+
"detailQueryDescription": "本文件是 收藏组件的自包含专项 Schema(内联全部引用定义,可独立交给 JSON Schema 校验器)。chart/view/grid/filter/text/link/carousel/task/favourite 各组件专项 Schema分别经 qingflow builder portal schema --schema-kind <类型> 获取。整门户声明用 qingflow builder portal schema --schema-kind summary|complete 获取;回读既有门户用 qingflow builder portal get --dash-key K --schema-kind complete。",
|
|
173
|
+
"readSources": {
|
|
174
|
+
"chartIds": "已有图表 id 用 chart 面读取;内联创建直接在 chart 键声明。",
|
|
175
|
+
"viewKeys": "视图唯一键用 qingflow builder views get --app-key APP 回读。"
|
|
176
|
+
}
|
|
177
|
+
},
|
|
178
|
+
"examples": [
|
|
179
|
+
{
|
|
180
|
+
"title": "常用入口",
|
|
181
|
+
"source_type": "favourite",
|
|
182
|
+
"position": {
|
|
183
|
+
"pc": {
|
|
184
|
+
"x": 12,
|
|
185
|
+
"y": 11,
|
|
186
|
+
"cols": 12,
|
|
187
|
+
"rows": 8
|
|
188
|
+
}
|
|
189
|
+
},
|
|
190
|
+
"favourite": {
|
|
191
|
+
"show_title": true,
|
|
192
|
+
"items": [
|
|
193
|
+
{
|
|
194
|
+
"title": "设备台账",
|
|
195
|
+
"item_type": 1,
|
|
196
|
+
"link_key": "APP_KEY_DEVICE",
|
|
197
|
+
"jump_mode": 1
|
|
198
|
+
}
|
|
199
|
+
]
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
]
|
|
203
|
+
}
|
|
@@ -0,0 +1,268 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://qingflow.com/schemas/builder/portals/v1alpha1/components/filter.json",
|
|
4
|
+
"title": "Qingflow Builder Portals Section · filter (v1alpha1)",
|
|
5
|
+
"portalFilterSectionDescription": "门户筛选组件(filter)的详细配置专项 Schema。获取命令:qingflow builder portal schema --schema-kind filter(MCP: portal_schema(schema_kind=\"filter\"))。本 Schema 校验 sections[] 中单个 filter 区块(自包含,可直接交给 JSON Schema 校验器);后端 DashComponentInfo.type=6。整门户声明走 summary/complete 档。",
|
|
6
|
+
"$defs": {
|
|
7
|
+
"Position": {
|
|
8
|
+
"type": "object",
|
|
9
|
+
"additionalProperties": false,
|
|
10
|
+
"positionShapeDescription": "网格位置。PC 是 24 列网格(cols≤24),mobile 是 6 列网格(cols≤6);同行组件共享同一 y 与 rows,一行 cols 合计 24。mobile 可省略(缺省与 pc 同布局)。平铺别名 pc_x/pc_y/pc_w/pc_h、mobile_* 也接受,归一为本结构。标准行高:指标卡 rows=5、BI 图表 rows=7、数据视图 rows=11、业务入口 rows=4。",
|
|
11
|
+
"properties": {
|
|
12
|
+
"pc": {
|
|
13
|
+
"$ref": "#/$defs/PositionDetail"
|
|
14
|
+
},
|
|
15
|
+
"mobile": {
|
|
16
|
+
"$ref": "#/$defs/PositionDetail"
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"PositionDetail": {
|
|
21
|
+
"type": "object",
|
|
22
|
+
"additionalProperties": false,
|
|
23
|
+
"positionDetailShapeDescription": "单端位置:x=列偏移、y=行偏移、cols=占宽、rows=占高。",
|
|
24
|
+
"properties": {
|
|
25
|
+
"x": {
|
|
26
|
+
"type": [
|
|
27
|
+
"integer",
|
|
28
|
+
"null"
|
|
29
|
+
],
|
|
30
|
+
"minimum": 0
|
|
31
|
+
},
|
|
32
|
+
"y": {
|
|
33
|
+
"type": [
|
|
34
|
+
"integer",
|
|
35
|
+
"null"
|
|
36
|
+
],
|
|
37
|
+
"minimum": 0
|
|
38
|
+
},
|
|
39
|
+
"cols": {
|
|
40
|
+
"type": [
|
|
41
|
+
"integer",
|
|
42
|
+
"null"
|
|
43
|
+
],
|
|
44
|
+
"minimum": 1
|
|
45
|
+
},
|
|
46
|
+
"rows": {
|
|
47
|
+
"type": [
|
|
48
|
+
"integer",
|
|
49
|
+
"null"
|
|
50
|
+
],
|
|
51
|
+
"minimum": 1
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
"x-backend": "DashPosition.pc / DashPosition.mobile"
|
|
55
|
+
},
|
|
56
|
+
"FilterConfig": {
|
|
57
|
+
"type": "object",
|
|
58
|
+
"additionalProperties": false,
|
|
59
|
+
"required": [
|
|
60
|
+
"groups"
|
|
61
|
+
],
|
|
62
|
+
"filterConfigShapeDescription": "筛选组件配置。筛选语义 raw/unstable,不建议作为主自动化路径;条件明细为受控透传(键集以 ws40013 dataset 实测形态定稿)。",
|
|
63
|
+
"properties": {
|
|
64
|
+
"graphs": {
|
|
65
|
+
"type": "array",
|
|
66
|
+
"filterGraphsShapeDescription": "筛选作用的图表引用(为空表示作用于全部图表)。",
|
|
67
|
+
"items": {
|
|
68
|
+
"$ref": "#/$defs/FilterGraphRef"
|
|
69
|
+
},
|
|
70
|
+
"x-backend": "ComponentFilter.graphList(GraphVO.graphKey/graphName/graphType)"
|
|
71
|
+
},
|
|
72
|
+
"groups": {
|
|
73
|
+
"type": "array",
|
|
74
|
+
"minItems": 1,
|
|
75
|
+
"filterGroupsShapeDescription": "筛选规则组。",
|
|
76
|
+
"items": {
|
|
77
|
+
"$ref": "#/$defs/FilterGroup"
|
|
78
|
+
},
|
|
79
|
+
"x-backend": "ComponentFilter.filterConfig(List<FilterConfig>)"
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
},
|
|
83
|
+
"FilterGraphRef": {
|
|
84
|
+
"type": "object",
|
|
85
|
+
"additionalProperties": false,
|
|
86
|
+
"filterGraphRefShapeDescription": "受筛选作用的图表引用;chart_key 或 chart_name 至少一个。",
|
|
87
|
+
"anyOf": [
|
|
88
|
+
{
|
|
89
|
+
"required": [
|
|
90
|
+
"chart_key"
|
|
91
|
+
]
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"required": [
|
|
95
|
+
"chart_name"
|
|
96
|
+
]
|
|
97
|
+
}
|
|
98
|
+
],
|
|
99
|
+
"properties": {
|
|
100
|
+
"chart_key": {
|
|
101
|
+
"type": "string",
|
|
102
|
+
"filterGraphKeyShapeDescription": "图表 key。别名 chartKey/graphKey。",
|
|
103
|
+
"x-backend": "GraphVO.graphKey"
|
|
104
|
+
},
|
|
105
|
+
"chart_name": {
|
|
106
|
+
"type": "string",
|
|
107
|
+
"filterGraphNameShapeDescription": "图表名称。别名 graphName。",
|
|
108
|
+
"x-backend": "GraphVO.graphName"
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
},
|
|
112
|
+
"FilterGroup": {
|
|
113
|
+
"type": "object",
|
|
114
|
+
"additionalProperties": false,
|
|
115
|
+
"required": [
|
|
116
|
+
"items"
|
|
117
|
+
],
|
|
118
|
+
"filterGroupShapeDescription": "筛选规则组。",
|
|
119
|
+
"properties": {
|
|
120
|
+
"group_id": {
|
|
121
|
+
"type": "integer",
|
|
122
|
+
"filterGroupIdShapeDescription": "组 id(更新已有组时锚定;缺省新建)。",
|
|
123
|
+
"x-backend": "FilterConfig.filterGroupId"
|
|
124
|
+
},
|
|
125
|
+
"name": {
|
|
126
|
+
"type": "string",
|
|
127
|
+
"filterGroupNameShapeDescription": "组名称。",
|
|
128
|
+
"x-backend": "FilterConfig.filterGroupName"
|
|
129
|
+
},
|
|
130
|
+
"items": {
|
|
131
|
+
"type": "array",
|
|
132
|
+
"minItems": 1,
|
|
133
|
+
"filterGroupItemsShapeDescription": "组内筛选项。",
|
|
134
|
+
"items": {
|
|
135
|
+
"$ref": "#/$defs/FilterItem"
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
},
|
|
140
|
+
"FilterItem": {
|
|
141
|
+
"type": "object",
|
|
142
|
+
"additionalProperties": false,
|
|
143
|
+
"required": [
|
|
144
|
+
"name"
|
|
145
|
+
],
|
|
146
|
+
"filterItemShapeDescription": "单个筛选项(绑定一个字段)。",
|
|
147
|
+
"properties": {
|
|
148
|
+
"item_id": {
|
|
149
|
+
"type": "integer",
|
|
150
|
+
"filterItemIdShapeDescription": "筛选项 id(更新锚定)。",
|
|
151
|
+
"x-backend": "FilterGroupConfig.filterItemId"
|
|
152
|
+
},
|
|
153
|
+
"name": {
|
|
154
|
+
"type": "string",
|
|
155
|
+
"filterItemNameShapeDescription": "筛选项名称。",
|
|
156
|
+
"x-backend": "FilterGroupConfig.filterItemName"
|
|
157
|
+
},
|
|
158
|
+
"conditions": {
|
|
159
|
+
"type": "array",
|
|
160
|
+
"filterItemConditionsShapeDescription": "筛选条件(受控透传;条件表达式键集以 dataset 实测形态定稿后开放规范键)。",
|
|
161
|
+
"x-backend": "FilterGroupConfig.filterCondition(List<FilterCondition>)"
|
|
162
|
+
},
|
|
163
|
+
"default_judge_type": {
|
|
164
|
+
"type": "integer",
|
|
165
|
+
"filterItemDftJudgeTypeShapeDescription": "默认比较符。",
|
|
166
|
+
"x-backend": "FilterGroupConfig.dftJudgeType"
|
|
167
|
+
},
|
|
168
|
+
"default_values": {
|
|
169
|
+
"type": "array",
|
|
170
|
+
"filterItemDftValuesShapeDescription": "默认比较值(受控透传)。",
|
|
171
|
+
"x-backend": "FilterGroupConfig.dftJudgeValue(List<AnswerValue>)"
|
|
172
|
+
},
|
|
173
|
+
"filter_type": {
|
|
174
|
+
"type": "string",
|
|
175
|
+
"filterItemTypeShapeDescription": "筛选项交互类型(受控枚举,dataset 校准)。",
|
|
176
|
+
"x-backend": "FilterGroupConfig.filterType"
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
"Section": {
|
|
181
|
+
"type": "object",
|
|
182
|
+
"additionalProperties": false,
|
|
183
|
+
"required": [
|
|
184
|
+
"title",
|
|
185
|
+
"source_type",
|
|
186
|
+
"config"
|
|
187
|
+
],
|
|
188
|
+
"properties": {
|
|
189
|
+
"title": {
|
|
190
|
+
"type": "string",
|
|
191
|
+
"minLength": 1,
|
|
192
|
+
"sectionTitleShapeDescription": "组件标题(渲染在组件头部)。",
|
|
193
|
+
"x-backend": "组件标题(DashChartInfo.title / gridConfig.gridTitle 等)"
|
|
194
|
+
},
|
|
195
|
+
"source_type": {
|
|
196
|
+
"const": "filter",
|
|
197
|
+
"sourceTypeConstDescription": "组件类型固定为 filter(筛选);后端 type 整数见 x-backend。",
|
|
198
|
+
"x-backend": "DashComponentInfo.type(filter)"
|
|
199
|
+
},
|
|
200
|
+
"role": {
|
|
201
|
+
"type": "string",
|
|
202
|
+
"roleShapeDescription": "组件角色标注(编排辅助,如 metric=指标卡;影响布局预设的排布与行高)。别名 zone/section_role。"
|
|
203
|
+
},
|
|
204
|
+
"position": {
|
|
205
|
+
"$ref": "#/$defs/Position"
|
|
206
|
+
},
|
|
207
|
+
"style_config": {
|
|
208
|
+
"type": "object",
|
|
209
|
+
"styleConfigSectionDescription": "组件级样式(受控键集;键白名单以 ws40013 dataset 实测形态校准,未经校准的键会被拒绝)。别名 dash_style_config/dashStyleConfigBO。",
|
|
210
|
+
"x-backend": "DashComponentInfo.dashStyleConfigBO(DashStyleConfigBO)"
|
|
211
|
+
},
|
|
212
|
+
"config": {
|
|
213
|
+
"$ref": "#/$defs/FilterConfig",
|
|
214
|
+
"filterConfigPropDescription": "筛选配置(必填,groups 非空)。"
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
},
|
|
219
|
+
"$ref": "#/$defs/Section",
|
|
220
|
+
"x-qingflow-detail-query": {
|
|
221
|
+
"currentKind": "filter",
|
|
222
|
+
"tool": "portal_schema",
|
|
223
|
+
"cli": "qingflow builder portal schema --schema-kind filter",
|
|
224
|
+
"argument": "schema_kind",
|
|
225
|
+
"detailQueryDescription": "本文件是 筛选组件的自包含专项 Schema(内联全部引用定义,可独立交给 JSON Schema 校验器)。chart/view/grid/filter/text/link/carousel/task/favourite 各组件专项 Schema分别经 qingflow builder portal schema --schema-kind <类型> 获取。整门户声明用 qingflow builder portal schema --schema-kind summary|complete 获取;回读既有门户用 qingflow builder portal get --dash-key K --schema-kind complete。",
|
|
226
|
+
"readSources": {
|
|
227
|
+
"chartIds": "已有图表 id 用 chart 面读取;内联创建直接在 chart 键声明。",
|
|
228
|
+
"viewKeys": "视图唯一键用 qingflow builder views get --app-key APP 回读。"
|
|
229
|
+
}
|
|
230
|
+
},
|
|
231
|
+
"examples": [
|
|
232
|
+
{
|
|
233
|
+
"title": "数据筛选",
|
|
234
|
+
"source_type": "filter",
|
|
235
|
+
"position": {
|
|
236
|
+
"pc": {
|
|
237
|
+
"x": 0,
|
|
238
|
+
"y": 0,
|
|
239
|
+
"cols": 24,
|
|
240
|
+
"rows": 3
|
|
241
|
+
}
|
|
242
|
+
},
|
|
243
|
+
"config": {
|
|
244
|
+
"graphs": [
|
|
245
|
+
{
|
|
246
|
+
"chart_key": "CHART_KEY_1001"
|
|
247
|
+
},
|
|
248
|
+
{
|
|
249
|
+
"chart_name": "故障类型分布"
|
|
250
|
+
}
|
|
251
|
+
],
|
|
252
|
+
"groups": [
|
|
253
|
+
{
|
|
254
|
+
"name": "默认组",
|
|
255
|
+
"items": [
|
|
256
|
+
{
|
|
257
|
+
"name": "报修日期",
|
|
258
|
+
"default_judge_type": 1,
|
|
259
|
+
"default_values": [],
|
|
260
|
+
"filter_type": "dateRange"
|
|
261
|
+
}
|
|
262
|
+
]
|
|
263
|
+
}
|
|
264
|
+
]
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
]
|
|
268
|
+
}
|