bpmax-cli 0.2.1-beta.9 → 0.2.1-beta.91
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 +30 -7
- package/dist/bin.js +45782 -12836
- package/dist/bin.js.map +1 -1
- package/package.json +12 -5
- package/scripts/install-skills.mjs +27 -60
- package/scripts/run-source-cli.mjs +145 -0
- package/skills/bpmax-ai-taskbook/SKILL.md +17 -1
- package/skills/bpmax-ai-taskbook/references/blueprint-taskbook-gates.md +141 -0
- package/skills/bpmax-ai-taskbook/references/taskbook-template.md +43 -3
- package/skills/bpmax-api-platform-editor/SKILL.md +24 -31
- package/skills/bpmax-api-platform-editor/agents/openai.yaml +2 -2
- package/skills/bpmax-api-platform-editor/references/platform-api-map.md +2 -2
- package/skills/bpmax-api-platform-editor/references/runtime-workflow.md +3 -3
- package/skills/bpmax-approval-matrix/SKILL.md +54 -2
- package/skills/bpmax-blueprint-doc-workflow/SKILL.md +38 -5
- package/skills/bpmax-blueprint-doc-workflow/references/blueprint-structure.md +24 -8
- package/skills/bpmax-blueprint-doc-workflow/references/business-language.md +74 -0
- package/skills/bpmax-blueprint-doc-workflow/references/per-flow-required-structure.md +13 -0
- package/skills/bpmax-blueprint-doc-workflow/references/review-and-confirmation-dialogue.md +70 -0
- package/skills/bpmax-blueprint-doc-workflow/references/sample-missing-modeling-review.xml +23 -0
- package/skills/bpmax-blueprint-doc-workflow/references/sample-missing-review-record.xml +72 -0
- package/skills/bpmax-blueprint-doc-workflow/references/sample-paragraph-flow-details.xml +27 -0
- package/skills/bpmax-blueprint-doc-workflow/references/sample-pass.xml +59 -35
- package/skills/bpmax-blueprint-doc-workflow/references/sample-system-identifier.xml +79 -0
- package/skills/bpmax-blueprint-doc-workflow/references/source-traceability-and-flow-modeling.md +115 -0
- package/skills/bpmax-blueprint-doc-workflow/scripts/lint_blueprint_doc.py +586 -5
- package/skills/bpmax-bug-reporting/SKILL.md +72 -0
- package/skills/bpmax-builder-shared/SKILL.md +1 -0
- package/skills/bpmax-builder-shared/configuration-impact-review.md +76 -0
- package/skills/bpmax-builder-shared/template_script_hard_rules.py +3 -1
- package/skills/bpmax-builder-shared/tests/test_template_script_hard_rules.py +16 -0
- package/skills/bpmax-business-skill/SKILL.md +3 -1
- package/skills/bpmax-cli/SKILL.md +46 -0
- package/skills/bpmax-config-latest/SKILL.md +4 -0
- package/skills/bpmax-console-template-editor/SKILL.md +113 -523
- package/skills/bpmax-console-template-editor/agents/openai.yaml +2 -2
- package/skills/bpmax-console-template-editor/references/full-detail-guide.md +45 -0
- package/skills/bpmax-console-template-editor/references/local-temp-workflow.md +13 -12
- package/skills/bpmax-console-template-editor/scripts/console_template_editor_common.py +299 -78
- package/skills/bpmax-console-template-editor/tests/test_console_template_editor.py +344 -30
- package/skills/bpmax-dataset-field-template-editor/SKILL.md +131 -594
- package/skills/bpmax-dataset-field-template-editor/references/full-detail-guide.md +570 -0
- package/skills/bpmax-dataset-field-template-editor/references/nested-field-patterns.md +8 -8
- package/skills/bpmax-dataset-field-template-editor/references/runtime-verified-field-page-shape.md +1 -1
- package/skills/bpmax-dataset-field-template-editor/scripts/dataset_field_editor_common.py +11 -77
- package/skills/bpmax-dataset-field-template-editor/scripts/export_dataset_field.py +4 -57
- package/skills/bpmax-dataset-field-template-editor/scripts/init_create_dataset_field.py +2 -0
- package/skills/bpmax-dataset-field-template-editor/scripts/inspect_dataset_field_runtime.py +4 -78
- package/skills/bpmax-dataset-field-template-editor/scripts/submit_dataset_field.py +3 -89
- package/skills/bpmax-dataset-field-template-editor/tests/test_dataset_field_editor.py +14 -0
- package/skills/bpmax-dataset-field-template-editor/tests/test_init_create_dataset_field.py +2 -0
- package/skills/bpmax-dataset-template-editor/SKILL.md +123 -778
- package/skills/bpmax-dataset-template-editor/references/dataset-script-runtime-matrix.md +11 -0
- package/skills/bpmax-dataset-template-editor/references/full-detail-guide.md +753 -0
- package/skills/bpmax-dataset-template-editor/references/runtime-gotchas.md +12 -0
- package/skills/bpmax-dataset-template-editor/references/ui-to-backend-field-map.md +1 -0
- package/skills/bpmax-dataset-template-editor/references/work-file-to-submit-mapping.md +2 -2
- package/skills/bpmax-dataset-template-editor/scripts/basic_table_audit.py +8 -1
- package/skills/bpmax-dataset-template-editor/scripts/dataset_editor_common.py +9 -90
- package/skills/bpmax-dataset-template-editor/scripts/export_dataset.py +8 -1
- package/skills/bpmax-dataset-template-editor/scripts/resolve_dataset.py +8 -1
- package/skills/bpmax-dataset-template-editor/scripts/submit_dataset.py +1 -2
- package/skills/bpmax-dataset-template-editor/scripts/verify_dataset_list.py +8 -1
- package/skills/bpmax-dataset-template-editor/scripts/verify_publish_health.py +8 -1
- package/skills/bpmax-dataset-template-editor/tests/test_dataset_editor.py +6 -40
- package/skills/bpmax-e2e-flow-config-orchestrator/SKILL.md +18 -4
- package/skills/bpmax-e2e-flow-config-orchestrator/agents/openai.yaml +2 -2
- package/skills/bpmax-e2e-flow-config-orchestrator/references/orchestration-matrix.md +13 -9
- package/skills/bpmax-e2e-flow-test-operator/SKILL.md +174 -546
- package/skills/bpmax-e2e-flow-test-operator/agents/openai.yaml +2 -3
- package/skills/bpmax-e2e-flow-test-operator/references/ai-test-suite.md +181 -15
- package/skills/bpmax-e2e-flow-test-operator/references/browser-action-dsl.md +169 -0
- package/skills/bpmax-e2e-flow-test-operator/references/browser-only-checkpoints.md +15 -7
- package/skills/bpmax-e2e-flow-test-operator/references/full-detail-guide.md +589 -0
- package/skills/bpmax-e2e-flow-test-operator/references/minimal-test-loop.md +12 -8
- package/skills/bpmax-e2e-flow-test-operator/references/negative-sale-api-matrix.md +4 -4
- package/skills/bpmax-e2e-flow-test-operator/references/profile-schema.md +1 -1
- package/skills/bpmax-e2e-flow-test-operator/references/state-schema.md +3 -1
- package/skills/bpmax-e2e-flow-test-operator/scripts/e2e_doc.py +7 -5
- package/skills/bpmax-e2e-flow-test-operator/scripts/e2e_state.py +2 -2
- package/skills/bpmax-e2e-flow-test-operator/scripts/flow_runner.py +5 -1
- package/skills/bpmax-e2e-flow-test-operator/tests/test_negative_sale_api_tools.py +71 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/SKILL.md +64 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/agents/openai.yaml +7 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/automation-generation-pipeline.md +33 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/autonomous-execution.md +40 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/batch-generation-and-execution.md +17 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/browser-action-runner.md +19 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/browser-recording-and-replay.md +95 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/form-script-generation.md +41 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/identity-and-failure-routing.md +92 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/multi-request-mutation.md +9 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/scenario-coverage-generation.md +17 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/scoped-execution.md +13 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/step-restartability-and-state.md +23 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/test-assets-and-evidence.md +9 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/test-data-and-selector-contract.md +51 -0
- package/skills/bpmax-e2e-flow-test-operator-v2/references/test-preflight-and-confirmation.md +32 -0
- package/skills/bpmax-filter-template-editor/SKILL.md +114 -551
- package/skills/bpmax-filter-template-editor/references/experience-coverage-matrix.md +18 -18
- package/skills/bpmax-filter-template-editor/references/filter-content-schema.md +21 -0
- package/skills/bpmax-filter-template-editor/references/filter-request-shape.md +29 -26
- package/skills/bpmax-filter-template-editor/references/filter-runtime-patterns.md +19 -2
- package/skills/bpmax-filter-template-editor/references/full-detail-guide.md +56 -0
- package/skills/bpmax-filter-template-editor/references/runtime-verified-filter-page-shape.md +10 -9
- package/skills/bpmax-filter-template-editor/scripts/filter_template_editor_common.py +7 -57
- package/skills/bpmax-filter-template-editor/tests/test_filter_template_editor.py +4 -48
- package/skills/bpmax-flow/SKILL.md +2 -0
- package/skills/bpmax-flow-detail-template-editor/SKILL.md +53 -0
- package/skills/bpmax-flow-template-editor/SKILL.md +140 -1137
- package/skills/bpmax-flow-template-editor/agents/openai.yaml +2 -2
- package/skills/bpmax-flow-template-editor/references/diff-strategy.md +3 -3
- package/skills/bpmax-flow-template-editor/references/editor-runtime-vs-draft.md +9 -9
- package/skills/bpmax-flow-template-editor/references/flow-template-api-workflow.md +9 -1
- package/skills/bpmax-flow-template-editor/references/full-detail-guide.md +1162 -0
- package/skills/bpmax-flow-template-editor/references/local-temp-workflow.md +1 -1
- package/skills/bpmax-flow-template-editor/references/message-card-professional-standard.md +234 -0
- package/skills/bpmax-flow-template-editor/references/payload-checklist.md +2 -0
- package/skills/bpmax-flow-template-editor/references/project-create-runtime-gotchas.md +17 -0
- package/skills/bpmax-flow-template-editor/references/requirement-to-node-mapping.md +8 -3
- package/skills/bpmax-flow-template-editor/references/runtime-verified-flow-detail-shape.md +7 -7
- package/skills/bpmax-flow-template-editor/references/runtime-verified-meta-fields.md +2 -2
- package/skills/bpmax-flow-template-editor/references/runtime-verified-node-fields.md +12 -2
- package/skills/bpmax-flow-template-editor/references/save-draft-request-shape.md +7 -23
- package/skills/bpmax-flow-template-editor/references/script-review-hard-rules.md +17 -0
- package/skills/bpmax-flow-template-editor/references/work-file-to-submit-mapping.md +1 -1
- package/skills/bpmax-flow-template-editor/tests/test_flow_template_editor.py +19 -75
- package/skills/bpmax-form-template-editor/SKILL.md +138 -1151
- package/skills/bpmax-form-template-editor/agents/openai.yaml +2 -2
- package/skills/bpmax-form-template-editor/references/dynamic-field-state.md +167 -0
- package/skills/bpmax-form-template-editor/references/form-template-api-workflow.md +51 -51
- package/skills/bpmax-form-template-editor/references/full-detail-guide.md +1115 -0
- package/skills/bpmax-form-template-editor/references/local-temp-workflow.md +4 -4
- package/skills/bpmax-form-template-editor/references/payload-checklist.md +3 -1
- package/skills/bpmax-form-template-editor/references/sub-form-patterns.md +6 -0
- package/skills/bpmax-form-template-editor/scripts/form_template_editor_common.py +8 -0
- package/skills/bpmax-form-template-editor/tests/test_form_template_editor.py +42 -19
- package/skills/bpmax-functional-test-design/LICENSE.upstream +24 -0
- package/skills/bpmax-functional-test-design/SKILL.md +80 -0
- package/skills/bpmax-functional-test-design/agents/openai.yaml +4 -0
- package/skills/bpmax-functional-test-design/references/bpmax-test-suite-output.md +95 -0
- package/skills/bpmax-functional-test-design/references/decision-table-testing.md +50 -0
- package/skills/bpmax-functional-test-design/references/domain-testing.md +43 -0
- package/skills/bpmax-functional-test-design/references/state-transition-testing.md +47 -0
- package/skills/bpmax-functional-test-design/references/technique-selection.md +38 -0
- package/skills/bpmax-functional-test-design/references/use-case-testing.md +55 -0
- package/skills/bpmax-group-model-editor/SKILL.md +24 -0
- package/skills/bpmax-home-portal-editor/SKILL.md +81 -0
- package/skills/bpmax-icon-catalog/SKILL.md +18 -0
- package/skills/bpmax-icon-catalog/agents/openai.yaml +4 -0
- package/skills/bpmax-icon-catalog/assets/ri-icons.json +3140 -0
- package/skills/bpmax-icon-catalog/references/source-contract.md +3 -0
- package/skills/bpmax-list-template-editor/SKILL.md +133 -466
- package/skills/bpmax-list-template-editor/agents/openai.yaml +2 -2
- package/skills/bpmax-list-template-editor/references/content-config-shape.md +16 -4
- package/skills/bpmax-list-template-editor/references/full-detail-guide.md +461 -0
- package/skills/bpmax-list-template-editor/references/list-template-api-workflow.md +6 -9
- package/skills/bpmax-list-template-editor/references/local-temp-workflow.md +1 -1
- package/skills/bpmax-list-template-editor/references/runtime-verified-workflow.md +50 -2
- package/skills/bpmax-list-template-editor/references/special-formats.md +5 -2
- package/skills/bpmax-list-template-editor/scripts/list_template_editor_common.py +9 -78
- package/skills/bpmax-memory-protocol/SKILL.md +7 -6
- package/skills/bpmax-nav-config-editor/SKILL.md +14 -17
- package/skills/bpmax-nav-config-editor/agents/openai.yaml +2 -2
- package/skills/bpmax-nav-config-editor/references/api-workflow.md +2 -2
- package/skills/bpmax-nav-config-editor/references/runtime-probing.md +11 -12
- package/skills/bpmax-page-composition-template-editor/SKILL.md +398 -0
- package/skills/bpmax-page-composition-template-editor/examples/presets/catalog.json +41 -0
- package/skills/bpmax-page-composition-template-editor/examples/presets/full-capability-workbench.json +294 -0
- package/skills/bpmax-page-composition-template-editor/examples/presets/project-detail-step-panel.json +184 -0
- package/skills/bpmax-page-composition-template-editor/examples/presets/project-list-quick-process.json +177 -0
- package/skills/bpmax-page-composition-template-editor/examples/presets/project-operations-dashboard.json +400 -0
- package/skills/bpmax-page-composition-template-editor/examples/presets/project-operations-visual-light.json +214 -0
- package/skills/bpmax-page-composition-template-editor/examples/presets/step-related-projects.json +184 -0
- package/skills/bpmax-page-composition-template-editor/references/resource-api.md +9 -0
- package/skills/bpmax-plugin-config/SKILL.md +55 -5
- package/skills/bpmax-project/SKILL.md +37 -1
- package/skills/bpmax-project-detail-template-editor/SKILL.md +13 -39
- package/skills/bpmax-project-detail-template-editor/agents/openai.yaml +2 -2
- package/skills/bpmax-role-editor/SKILL.md +11 -30
- package/skills/bpmax-shared/SKILL.md +19 -9
- package/skills/bpmax-team-editor/SKILL.md +27 -0
- package/skills/bpmax-ui-ux-audit/LICENSE.upstream +23 -0
- package/skills/bpmax-ui-ux-audit/SKILL.md +42 -0
- package/skills/bpmax-ui-ux-audit/agents/openai.yaml +4 -0
- package/skills/bpmax-ui-ux-audit/references/audit-framework.md +39 -0
- package/skills/bpmax-ui-ux-audit/references/bpmax-ux-findings.md +56 -0
- package/skills/bpmax-user/SKILL.md +33 -1
- package/skills/bpmax-user-mock-operator/SKILL.md +58 -56
- package/skills/bpmax-user-mock-operator/agents/openai.yaml +2 -2
- package/skills/bpmax-user-mock-operator/scripts/chrome_identity_bridge.mjs +1766 -0
- package/skills/bpmax-user-model-editor/SKILL.md +24 -0
- package/skills/bpmax-workspace-editor/SKILL.md +1 -0
- package/skills/form-control-library/references/form-template-submit-schema.md +3 -1
- package/skills/bpmax-user-mock-operator/scripts/switch_user_identity.py +0 -37
- package/skills/bpmax-user-mock-operator/scripts/user_mock_operator_common.py +0 -136
- package/skills/bpmax-user-mock-operator/tests/test_user_mock_operator.py +0 -138
package/skills/bpmax-page-composition-template-editor/examples/presets/step-related-projects.json
ADDED
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "环节关联项目",
|
|
3
|
+
"key": "step.related-projects",
|
|
4
|
+
"intro": "",
|
|
5
|
+
"template": {
|
|
6
|
+
"version": 1,
|
|
7
|
+
"entry": {
|
|
8
|
+
"kind": "step-process"
|
|
9
|
+
},
|
|
10
|
+
"contexts": {
|
|
11
|
+
"selectedProject": {
|
|
12
|
+
"source": "selected-row"
|
|
13
|
+
},
|
|
14
|
+
"currentStep": {
|
|
15
|
+
"source": "selectedProject",
|
|
16
|
+
"resolver": "current-step"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
"data": {
|
|
20
|
+
"queries": {
|
|
21
|
+
"projects": {
|
|
22
|
+
"engine": "es",
|
|
23
|
+
"resource": "/project/list",
|
|
24
|
+
"method": "POST",
|
|
25
|
+
"params": {
|
|
26
|
+
"data_set_key": "main",
|
|
27
|
+
"page": 1,
|
|
28
|
+
"page_size": 20,
|
|
29
|
+
"with_step": 1
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
"methods": {},
|
|
34
|
+
"actions": {
|
|
35
|
+
"resolveCurrentStep": {
|
|
36
|
+
"capability": "step.quick-process",
|
|
37
|
+
"schema": {
|
|
38
|
+
"required": [
|
|
39
|
+
"projectId"
|
|
40
|
+
],
|
|
41
|
+
"properties": {
|
|
42
|
+
"projectId": {
|
|
43
|
+
"type": "number"
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"submitStep": {
|
|
49
|
+
"capability": "step.operation",
|
|
50
|
+
"previewOnly": true,
|
|
51
|
+
"action": "approve",
|
|
52
|
+
"schema": {
|
|
53
|
+
"required": [
|
|
54
|
+
"projectId",
|
|
55
|
+
"stepId"
|
|
56
|
+
],
|
|
57
|
+
"properties": {
|
|
58
|
+
"projectId": {
|
|
59
|
+
"type": "number"
|
|
60
|
+
},
|
|
61
|
+
"stepId": {
|
|
62
|
+
"type": "number"
|
|
63
|
+
},
|
|
64
|
+
"comments": {
|
|
65
|
+
"type": "string"
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
"refresh": [
|
|
70
|
+
"projects"
|
|
71
|
+
]
|
|
72
|
+
},
|
|
73
|
+
"createProject": {
|
|
74
|
+
"capability": "project.create",
|
|
75
|
+
"previewOnly": true,
|
|
76
|
+
"action": "create",
|
|
77
|
+
"schema": {
|
|
78
|
+
"required": [
|
|
79
|
+
"name"
|
|
80
|
+
],
|
|
81
|
+
"properties": {
|
|
82
|
+
"name": {
|
|
83
|
+
"type": "string"
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
"refresh": [
|
|
88
|
+
"projects"
|
|
89
|
+
]
|
|
90
|
+
},
|
|
91
|
+
"updateProject": {
|
|
92
|
+
"capability": "project.form",
|
|
93
|
+
"previewOnly": true,
|
|
94
|
+
"action": "update",
|
|
95
|
+
"schema": {
|
|
96
|
+
"required": [
|
|
97
|
+
"projectId",
|
|
98
|
+
"name"
|
|
99
|
+
],
|
|
100
|
+
"properties": {
|
|
101
|
+
"projectId": {
|
|
102
|
+
"type": "number"
|
|
103
|
+
},
|
|
104
|
+
"name": {
|
|
105
|
+
"type": "string"
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
"refresh": [
|
|
110
|
+
"projects"
|
|
111
|
+
]
|
|
112
|
+
},
|
|
113
|
+
"exportProjects": {
|
|
114
|
+
"capability": "project.export",
|
|
115
|
+
"previewOnly": true,
|
|
116
|
+
"action": "export",
|
|
117
|
+
"schema": {
|
|
118
|
+
"required": [
|
|
119
|
+
"projectIds"
|
|
120
|
+
],
|
|
121
|
+
"properties": {
|
|
122
|
+
"projectIds": {
|
|
123
|
+
"type": "array"
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
},
|
|
128
|
+
"bulkEditProjects": {
|
|
129
|
+
"capability": "project.bulk-edit",
|
|
130
|
+
"previewOnly": true,
|
|
131
|
+
"action": "bulk-edit",
|
|
132
|
+
"schema": {
|
|
133
|
+
"required": [
|
|
134
|
+
"projectIds",
|
|
135
|
+
"status"
|
|
136
|
+
],
|
|
137
|
+
"properties": {
|
|
138
|
+
"projectIds": {
|
|
139
|
+
"type": "array"
|
|
140
|
+
},
|
|
141
|
+
"status": {
|
|
142
|
+
"type": "string"
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
},
|
|
146
|
+
"refresh": [
|
|
147
|
+
"projects"
|
|
148
|
+
]
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
},
|
|
152
|
+
"render": {
|
|
153
|
+
"template": "<section class=\"composition-shell\">\n <header class=\"composition-header\">\n <div>\n <p class=\"composition-eyebrow\">PAGE COMPOSITION</p>\n <h1>{{ template.name || '跨页面组合' }}</h1>\n <p>{{ template.intro || '由页面上下文和公开业务能力组合而成。' }}</p>\n </div>\n <button type=\"button\" class=\"composition-refresh\" :disabled=\"dashboardRefreshing\" @click=\"refreshAll\">\n {{ dashboardRefreshing ? '刷新中…' : '刷新数据' }}\n </button>\n </header>\n <div v-if=\"runtimeError\" class=\"composition-alert\" role=\"alert\">{{ runtimeError }}</div>\n <section v-for=\"(block, index) in blocks\" :key=\"block.type + '-' + index\" class=\"composition-section\">\n <div class=\"composition-section-heading\">\n <h2>{{ block.title || block.type }}</h2>\n <span>{{ block.capability || '' }}</span>\n </div>\n <page-block\n :block=\"block\"\n :block-index=\"index\"\n :rows=\"block.paginated ? paginatedProjectRows : queryRows(block.query || 'projects')\"\n :selected-project=\"selectedProject\"\n :current-step=\"currentStep\"\n :draft-comment=\"draftComment\"\n :action-busy=\"actionBusy\"\n :filter-status=\"filterStatus\"\n :filter-keyword=\"filterKeyword\"\n :status-options=\"statusOptions\"\n :pagination-page=\"paginationPage\"\n :pagination-page-size=\"paginationPageSize\"\n :project-count=\"projectCount\"\n :selected-project-ids=\"selectedProjectIds\"\n :step-logs=\"stepLogs\"\n :attachment-drafts=\"attachmentDrafts\"\n :report-metrics=\"dashboardMetrics\"\n @select-project=\"selectProject\"\n @select-step=\"selectStep\"\n @open-quick-process=\"openQuickProcess\"\n @load-project-detail=\"loadProjectDetail\"\n @submit-step=\"submitStep\"\n @update-comment=\"draftComment = $event\"\n @set-filter-status=\"filterStatus = $event\"\n @set-filter-keyword=\"filterKeyword = $event\"\n @set-page=\"setPage\"\n @create-project=\"createProject\"\n @submit-project-form=\"submitProjectForm\"\n @export-projects=\"exportProjects\"\n @bulk-edit-projects=\"bulkEditProjects\"\n @add-attachment=\"addAttachment\"\n @selection-change=\"setSelectedProjectIds\"\n />\n </section>\n <div v-if=\"quickProcessVisible\" class=\"composition-dialog\" role=\"dialog\" aria-modal=\"true\">\n <div class=\"composition-dialog-panel\">\n <div class=\"composition-dialog-heading\"><h2>快速处理</h2><button type=\"button\" @click=\"clearSelection\">关闭</button></div>\n <p v-if=\"selectedProject\">{{ selectedProject.name || selectedProject.title || ('项目 ' + selectedProject.id) }}</p>\n <page-block\n v-for=\"(block, index) in blocks\"\n v-if=\"block.type === 'step-form' || block.type === 'step-operation'\"\n :key=\"'dialog-' + block.type + '-' + index\"\n :block=\"block\"\n :block-index=\"index\"\n :selected-project=\"selectedProject\"\n :current-step=\"currentStep\"\n :draft-comment=\"draftComment\"\n :action-busy=\"actionBusy\"\n :filter-status=\"filterStatus\"\n :filter-keyword=\"filterKeyword\"\n :status-options=\"statusOptions\"\n :pagination-page=\"paginationPage\"\n :pagination-page-size=\"paginationPageSize\"\n :project-count=\"projectCount\"\n :selected-project-ids=\"selectedProjectIds\"\n :step-logs=\"stepLogs\"\n :attachment-drafts=\"attachmentDrafts\"\n :report-metrics=\"dashboardMetrics\"\n @submit-step=\"submitStep\"\n @update-comment=\"draftComment = $event\"\n />\n </div>\n </div>\n</section>",
|
|
154
|
+
"style": ".composition-shell { min-height: 100%; padding: 24px 32px; background: #f5f7fa; color: #1f2937; }\n.composition-header { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; padding: 20px 24px; background: #fff; border: 1px solid #e5e7eb; border-radius: 16px; }\n.composition-eyebrow { margin: 0; color: #2563eb; font-size: 11px; letter-spacing: .12em; font-weight: 700; }\n.composition-header h1 { margin: 6px 0; font-size: 24px; }\n.composition-header p:last-child { margin: 0; color: #64748b; }\n.composition-refresh, .composition-dialog-heading button { min-height: 40px; padding: 8px 14px; border: 1px solid #cbd5e1; border-radius: 8px; background: #fff; cursor: pointer; }\n.composition-alert { margin-top: 16px; padding: 12px 16px; border: 1px solid #fecaca; border-radius: 8px; background: #fff1f2; color: #991b1b; }\n.composition-section { margin-top: 16px; padding: 20px; background: #fff; border: 1px solid #e5e7eb; border-radius: 16px; }\n.composition-section-heading { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }\n.composition-section-heading h2 { margin: 0; font-size: 16px; }\n.composition-section-heading span { color: #64748b; font-size: 12px; }\n.composition-dialog { position: fixed; inset: 0; z-index: 20; display: flex; justify-content: flex-end; background: rgba(15, 23, 42, .32); }\n.composition-dialog-panel { width: min(520px, 100vw); height: 100%; overflow: auto; box-sizing: border-box; padding: 24px; background: #fff; }\n.composition-dialog-heading { display: flex; justify-content: space-between; align-items: center; }\n.composition-dialog-heading h2 { margin: 0; }\n@media (max-width: 720px) { .composition-shell { padding: 16px; } .composition-header { flex-direction: column; } }",
|
|
155
|
+
"blocks": [
|
|
156
|
+
{
|
|
157
|
+
"type": "step-form",
|
|
158
|
+
"capability": "step.form",
|
|
159
|
+
"context": "currentStep",
|
|
160
|
+
"title": "环节表单"
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
"type": "step-operation",
|
|
164
|
+
"capability": "step.operation",
|
|
165
|
+
"action": "submitStep",
|
|
166
|
+
"title": "环节操作"
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
"type": "project-table",
|
|
170
|
+
"capability": "project.table",
|
|
171
|
+
"query": "projects",
|
|
172
|
+
"title": "项目列表"
|
|
173
|
+
}
|
|
174
|
+
]
|
|
175
|
+
},
|
|
176
|
+
"dependencies": {
|
|
177
|
+
"capabilities": [
|
|
178
|
+
"step.form",
|
|
179
|
+
"step.operation",
|
|
180
|
+
"project.table"
|
|
181
|
+
]
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# Page-composition resource API
|
|
2
|
+
|
|
3
|
+
资源接口属于独立页面组合模板:
|
|
4
|
+
|
|
5
|
+
- `GET /api/page_composition_asset/:templateId`:按当前组织列出未删除资源。
|
|
6
|
+
- `POST /api/page_composition_asset/:templateId`:multipart `file` 上传并登记 MIME、大小、SHA-256、对象 URL 和模板归属。
|
|
7
|
+
- `DELETE /api/page_composition_asset/:assetId`:仅允许删除当前组织中未被模板 JSON 引用的资源。
|
|
8
|
+
|
|
9
|
+
后端允许的扩展名:png、jpg、jpeg、gif、webp、avif、css、less、js、mjs、json、woff、woff2、ttf;单文件大小为 1 byte 到 10 MB。资源表由 migration 创建:`think_page_composition_asset`。
|
|
@@ -1,20 +1,56 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: bpmax-plugin-config
|
|
3
3
|
version: 1.0.0
|
|
4
|
-
description:
|
|
4
|
+
description: Manage BPMAX plugin activation, plugin-scoped Agent skills, and plugin-owned configuration through typed bpmax-cli workflows.
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# BPMAX Plugin Config
|
|
8
8
|
|
|
9
|
-
Use this skill when a BPMAX task involves
|
|
9
|
+
Use this skill when a BPMAX task involves installing or activating a plugin, discovering its Agent Skill, or changing plugin-owned configuration.
|
|
10
|
+
|
|
11
|
+
## Distinguish the four plugin states
|
|
12
|
+
|
|
13
|
+
- **Installed** means the organization has the plugin package. It does not mean the plugin is active in any workspace.
|
|
14
|
+
- **Activated** means the installed plugin is effective in selected workspaces. Organization defaults are mandatory in every existing and future workspace and cannot be disabled from one workspace.
|
|
15
|
+
- **Skill installed** means the current Agent has the plugin's local instructions, lint, and config adapters. It does not activate the runtime plugin.
|
|
16
|
+
- **Configured** means plugin-owned business settings have been written after activation and Skill discovery. Activation does not create those settings.
|
|
17
|
+
|
|
18
|
+
## Activation flow
|
|
19
|
+
|
|
20
|
+
1. Read the centralized activation overview before changing anything:
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
bpmax-cli plugin activation overview --profile <profile> --format json
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
2. Choose one typed mutation scope and review its dry-run:
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
bpmax-cli plugin activation workspace set --workspace <workspace> --plugin <plugin_name> --profile <profile> --format json
|
|
30
|
+
bpmax-cli plugin activation plugin set-workspaces --plugin <plugin_name> --workspace <workspace> --profile <profile> --format json
|
|
31
|
+
bpmax-cli plugin activation defaults set --plugin <plugin_name> --profile <profile> --format json
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
3. After the user accepts the displayed scope, repeat the same command with `--confirm`. The CLI must submit through `config.plugin.activation.submit`, read back `config.plugin.activation.export`, and return `readback_confirmed: true`.
|
|
35
|
+
|
|
36
|
+
4. Only after effective activation is proven should the Agent install/update the plugin Skill and edit plugin-owned configuration.
|
|
37
|
+
|
|
38
|
+
## Automatic discovery
|
|
39
|
+
|
|
40
|
+
- `bpmax-cli` compares the platform manifest `sha256` with the profile/origin/agent-scoped local state. Do not rely on the semantic version alone; a plugin may publish corrected Skill content without changing `version`.
|
|
41
|
+
- The default `plugin_skill_update_policy=check` discovers updates and reports the exact next command. `prompt` also blocks dependent configuration work until the operator explicitly updates. `auto` updates official same-origin packages before dependent lint/build/submit. `off` disables update comparison; required plugin lint declaration discovery still runs.
|
|
42
|
+
- Configure the current profile with `bpmax-cli config set plugin_skill_update_policy check|prompt|auto|off --profile <profile> --format json`.
|
|
43
|
+
- Discovery runs after authorization/capability refresh and before plugin-dependent flow-template lint/build/submit. Results are cached for at most six hours.
|
|
44
|
+
- A locally modified or unowned Skill directory is `conflicted` and is never overwritten by automatic update. Both the Agent-visible copy and the profile-scoped lint/config adapter copy are hash-checked. An explicit `plugin skills update` may adopt a legacy unowned copy after the operator chooses to replace it.
|
|
45
|
+
- The install directory records `.bpmax-plugin-skill.json` with the source profile, origin, plugin, version, and hash. A running Agent may need a new task before it reloads updated instructions; CLI lint/adapters are effective immediately.
|
|
10
46
|
|
|
11
47
|
## Required Flow
|
|
12
48
|
|
|
13
|
-
1. Confirm the target profile and
|
|
14
|
-
2.
|
|
49
|
+
1. Confirm the target profile and origin from the user's context or existing `bpmax-cli` profile. Plugin Skill discovery is site-wide and is not bound to a BPMAX business workspace.
|
|
50
|
+
2. Check available and outdated plugin skills:
|
|
15
51
|
|
|
16
52
|
```bash
|
|
17
|
-
bpmax-cli plugin skills
|
|
53
|
+
bpmax-cli plugin skills check --profile <profile> --agent codex --format json
|
|
18
54
|
```
|
|
19
55
|
|
|
20
56
|
3. If the needed plugin skill is not installed locally, install it explicitly:
|
|
@@ -27,16 +63,30 @@ bpmax-cli plugin skills ensure <plugin_name> --profile <profile> --agent codex -
|
|
|
27
63
|
|
|
28
64
|
## Safety Rules
|
|
29
65
|
|
|
66
|
+
- Do not confuse plugin installation, workspace activation, local Skill installation, and plugin configuration.
|
|
67
|
+
- Never infer activation from an installed plugin row or a local Skill directory. Use `plugin activation overview`.
|
|
68
|
+
- A workspace mutation cannot remove an organization default plugin. Do not generate a single-workspace disable attempt for `default_active: true`.
|
|
69
|
+
- Setting organization defaults affects all existing and future workspaces. Always show the dry-run scope before using `--confirm`.
|
|
70
|
+
- A successful PUT is not completion. Require typed overview readback and report `submitted_readback_mismatch` as an unresolved remote mutation, not as success.
|
|
71
|
+
- Removing a plugin from organization defaults does not prove it is disabled in every workspace; inspect the returned effective workspace activation.
|
|
30
72
|
- Do not assume plugin installation also installed local Agent skills.
|
|
31
73
|
- Do not manually copy plugin skill folders unless `bpmax-cli plugin skills ensure` fails and the user explicitly approves a fallback.
|
|
32
74
|
- Treat `config.plugin.*` capabilities like other BPMAX configuration capabilities: they require an authorized profile and organization-admin configuration access.
|
|
33
75
|
- If `ensure` reports a checksum, name, version, or lint failure, stop and report the failure instead of using the package.
|
|
76
|
+
- If discovery reports `update_available`, `update_failed`, `not_installed`, `state_missing`, `conflicted`, or `checksum_unavailable`, do not continue plugin-dependent configuration with stale or unverifiable lint rules.
|
|
77
|
+
- If a flow contains plugin-like node arrays such as `*_triggers[]` but neither the platform nor local state provides a `flow-template-node` lint declaration, strict lint must fail instead of silently accepting the configuration.
|
|
78
|
+
- Preserve existing plugin extension fields when editing a flow. Never delete a remote `plugin_*` block merely because the platform or local installation has no matching lint declaration.
|
|
79
|
+
- On an exported existing flow with a remote `flow_type`, an unknown plugin extension whose every occurrence explicitly sets `enabled: false` is retained and reported as a warning; plugin-specific lint is skipped because the extension cannot execute.
|
|
80
|
+
- A new flow cannot use this compatibility path. Even a disabled unknown extension remains a hard error until the plugin publishes or installs its lint declaration.
|
|
81
|
+
- An enabled unknown extension, an extension without an explicit `enabled: false`, or a mix of enabled and disabled occurrences remains a hard error. Install its declared plugin skill or stop for a platform/plugin declaration fix before submit.
|
|
34
82
|
|
|
35
83
|
## Useful Commands
|
|
36
84
|
|
|
37
85
|
```bash
|
|
38
86
|
bpmax-cli plugin skills list --profile <profile> --format json
|
|
87
|
+
bpmax-cli plugin skills check --profile <profile> --agent codex --format json
|
|
39
88
|
bpmax-cli plugin skills ensure <plugin_name> --profile <profile> --agent codex --format json
|
|
40
89
|
bpmax-cli plugin skills update <plugin_name> --profile <profile> --agent codex --format json
|
|
41
90
|
bpmax-cli plugin skills state --profile <profile> --agent codex --format json
|
|
91
|
+
bpmax-cli plugin activation overview --profile <profile> --format json
|
|
42
92
|
```
|
|
@@ -66,6 +66,7 @@ CLI 返回 `handoff: true` 时,回复用户前必须全部满足:
|
|
|
66
66
|
- `reason: "form_template_requires_page_handoff"` 说明表单包含页面专属能力,例如流水号、自动初始化或复杂控件;必须把 handoff 链接发给用户,不能回复“项目已创建”
|
|
67
67
|
- 如果链接只有 `flow_type`,或既没有 `prefill_token` 也没有 `init_value`,不得发给用户;重新运行默认 `project create` 或报告无法生成预填链接
|
|
68
68
|
- 如果 CLI 没有返回 URL,不要自己拼 URL
|
|
69
|
+
- `prefill_context` 只说明 CLI 生成了预填 payload,不等于真实浏览器控件已经带出;CLI 返回 `browser_prefill_verified: false` 或 `prefill_verification_required: true` 时,必须打开真实创建页核对可见控件值,再把 handoff 视为可用。
|
|
69
70
|
- 如果需要检查 handoff token 是否还能被平台读取,使用 `bpmax-cli project handoff status --prefill-token <token> --format json`。即使返回 `ok: true`,也只代表 token 可读;`browser_verified: false` 时必须打开真实浏览器页面验证表单预填和提交结果。若返回 `supported: false`,说明当前平台不支持 token 状态查询。
|
|
70
71
|
|
|
71
72
|
### 禁止/例外
|
|
@@ -78,17 +79,49 @@ CLI 返回 `handoff: true` 时,回复用户前必须全部满足:
|
|
|
78
79
|
- `--unsafe-direct-create` 只允许本地专家调试旧行为;OpenClaw/Agent/BBS 永远不要使用
|
|
79
80
|
- 表单校验失败时修正字段 key/type/选项值,不要绕过校验重试
|
|
80
81
|
|
|
82
|
+
## 环节关联项目表单预填 handoff
|
|
83
|
+
|
|
84
|
+
当用户要为当前待办环节中展示的“关联项目表单”准备预填值时,只使用 typed 命令生成 handoff:
|
|
85
|
+
|
|
86
|
+
```bash
|
|
87
|
+
bpmax-cli project handoff step-form \
|
|
88
|
+
--project-id <project_id> \
|
|
89
|
+
--step-id <step_id> \
|
|
90
|
+
--json '{"form":{"<field_key>":"<value>"}}' \
|
|
91
|
+
--format json
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
硬门禁:
|
|
95
|
+
|
|
96
|
+
- 该能力只适用于当前用户尚未处理、仍可编辑,且流程节点开启 `enable_relate_project_form` 的环节。
|
|
97
|
+
- 必须使用表单模板内真实 field key;CLI 会读取关联项目表单 schema 并拒绝不存在或不兼容的字段。
|
|
98
|
+
- 禁止手写 `/projectContinue` URL、`prefill_token`、`target` 或直接调用 `/project_staging/prefill`。
|
|
99
|
+
- 最终回复只逐字使用 CLI 输出的 `reply_markdown`;没有该字段时才使用完整 `url`,不得截断、重组或删除查询参数。
|
|
100
|
+
- CLI 返回 `browser_prefill_verified: false` 或 `prefill_verification_required: true` 时,必须打开真实环节页确认可见项目表单控件已经带值;token 可读不等于页面预填成功。
|
|
101
|
+
- 该命令只预填关联项目表单,不提交表单、不完成环节,也不得声称环节已处理。
|
|
102
|
+
- 检查 token 状态时必须显式使用 step capability:
|
|
103
|
+
|
|
104
|
+
```bash
|
|
105
|
+
bpmax-cli project handoff status \
|
|
106
|
+
--prefill-token <token> \
|
|
107
|
+
--step-form \
|
|
108
|
+
--format json
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
- 状态查询固定走 query 参数协议;不要把 token 放到 URL path 上。
|
|
112
|
+
|
|
81
113
|
## 查询与链接命令
|
|
82
114
|
|
|
83
115
|
```bash
|
|
84
116
|
bpmax-cli project list --format table
|
|
85
|
-
bpmax-cli project get
|
|
117
|
+
bpmax-cli project get 1001 --format json
|
|
86
118
|
bpmax-cli project my-step --format table
|
|
87
119
|
bpmax-cli project my-step --flow-type flow802926525 --format json
|
|
88
120
|
bpmax-cli project my-step --key-of-flow-node 'flow802926525::1776572829122' --format json
|
|
89
121
|
bpmax-cli project my-step --workspace store_mgr --flow-type flow802926525 --format json
|
|
90
122
|
bpmax-cli project approval-context 1001 --step-id 2002 --format json
|
|
91
123
|
bpmax-cli project handoff status --prefill-token <token> --format json
|
|
124
|
+
bpmax-cli project handoff status --prefill-token <token> --step-form --format json
|
|
92
125
|
bpmax-cli project search --body @project-search-query.json --page 1 --page-size 20 --format json
|
|
93
126
|
bpmax-cli es project-search --body @project-search-query.json --page 1 --page-size 20 --format json
|
|
94
127
|
bpmax-cli step get 2002 --format json
|
|
@@ -129,10 +162,13 @@ bpmax-cli step submit <step_id> --project-id <project_id> --action approve --lab
|
|
|
129
162
|
|
|
130
163
|
- 概览优先 `project list`
|
|
131
164
|
- 按候选人姓名、表单字段、流程内关键词定位项目时,优先 `project search`;该命令会走 `huanpingtong-server` 的 `/api/project/list` ES 模式,由 huanpingtong 侧 API Key 和权限上下文转发到 bpmax-server `/project/list`
|
|
165
|
+
- `/project/list` 有两种分页契约:普通项目列表从 POST body 读取 `page/page_size`,包含 `data_set_id`、`data_set_key`、`query`、`is_select_all`、`_source` 或 `aggs` 的 ES 查询从 query params 读取。始终使用 `--page` / `--page-size`,由 CLI 自动按请求模式放置分页;不要手工猜测位置。扫描必须记录每页项目 ID,发现连续页 ID 完全相同或 raw rows 大于 unique rows 很多时,立即判定分页可能失效,不得给出“未命中”结论。
|
|
166
|
+
- `page` 和 `page_size` 必须是大于等于 1 的安全整数;CLI 会在 HTTP 前同时归一化命令参数和 body 中的数字字符串,空串、0、负数、小数和非数字都应本地失败。
|
|
132
167
|
- `es project-search` 只是兼容别名;新场景必须写 `project search`
|
|
133
168
|
- 不要向 `project search` 或 `es project-search` 传包含顶层 `body` 的 raw ES DTO;`huanpingtong-server` 没有公开 `/api/project/raw-es-search`,CLI 会在发请求前阻断
|
|
134
169
|
- 预算汇总、趋势分析等统计只能先使用 `/api/project/list` ES 模式能表达的查询体;确实需要 raw ES 聚合时,必须先让服务端增加明确公开接口,不能复用 `/api/project/<unknown>`
|
|
135
170
|
- 单项目详情走 `project get`
|
|
171
|
+
- `project get` 首选位置参数 `project get <id>`;为兼容旧自动化也接受 `project get --project-id <id>`,两者同时出现时必须一致。
|
|
136
172
|
- 待办相关优先 `project my-step`
|
|
137
173
|
- 待办需要限定流程时,用 `project my-step --flow-type <flow_type>`,不要先全量拉取再本地筛选
|
|
138
174
|
- 待办需要限定到流程节点时,用 `project my-step --key-of-flow-node '<flow_type>:<flow_key>:<flow_step_id>'`;流程 key 为空时保留中间冒号,例如 `flow802926525::1776572829122`
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: "bpmax-project-detail-template-editor"
|
|
3
|
-
description: "
|
|
3
|
+
description: "用于通过 bpmax-cli typed config 创建、编辑、启用和删除 BPMAX 项目详情模板。只要用户提到“新建项目详情模板”“编辑项目详情模板”“启用项目详情模板”“删除项目详情模板”“提交项目详情模板配置”“让 Codex 构造 flow_page_template type=2 接口数据”或等价表达,就应使用这个 skill。它覆盖列表检索、创建、编辑、启用、删除,以及可视化模式和高级 JSON 模式,统一走线上事实优先 + 本地 temp-file + 双确认 + typed CLI submit + 接口回读。"
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# BPMAX Project Detail Template Editor
|
|
@@ -19,13 +19,13 @@ description: "用于在 BPMAX 的项目详情模板页面中创建、编辑、
|
|
|
19
19
|
- 不得以历史脏配置、顺手修复、统一风格、编辑器自动补字段、方便调试为理由修改需求外配置。
|
|
20
20
|
|
|
21
21
|
## 何时使用
|
|
22
|
-
-
|
|
22
|
+
- 用户需要通过 bpmax-cli typed config 管理 BPMAX 项目详情模板。
|
|
23
23
|
- 用户要新建、编辑、启用或删除 `flow_page_template.type = 2` 的项目详情模板。
|
|
24
24
|
- 用户要按自然语言需求调整项目详情页模块、区域和顺序。
|
|
25
|
-
-
|
|
25
|
+
- 用户需要使用当前 CLI profile、capability 和线上回读结果完成配置闭环。
|
|
26
26
|
|
|
27
27
|
## 前置条件
|
|
28
|
-
-
|
|
28
|
+
- 先通过 CLI profile/capability 和目标参数确认以下任一对象:
|
|
29
29
|
- `.../w:<workspace>/project_detail_template?flow_type=<flow_type>&flow_key=<flow_key>`
|
|
30
30
|
- `.../w:<workspace>/project_detail_template/create?flow_type=<flow_type>&flow_key=<flow_key>`
|
|
31
31
|
- `.../w:<workspace>/project_detail_template/<id>?flow_type=<flow_type>&flow_key=<flow_key>`
|
|
@@ -82,12 +82,8 @@ description: "用于在 BPMAX 的项目详情模板页面中创建、编辑、
|
|
|
82
82
|
- 编辑运行态默认详情模板前,必须先解析真实数字 ID:
|
|
83
83
|
- 优先运行 `bpmax-cli config project-detail-template resolve-default --flow-type <flow_type> --flow-key "<flow_key>" --profile <profile> --format json`。
|
|
84
84
|
- 若只拿到本地 sysconfig UUID,先运行 `bpmax-cli config resolve-id --domain project-detail-template --uuid <uuid> --repo <sysconfig_repo> --profile <profile> --format json`。本地镜像可能只有 UUID 没有数字 ID;只有 `resolved_id` 是平台数字 ID 时才允许 export/submit。
|
|
85
|
-
-
|
|
86
|
-
|
|
87
|
-
- 审批/审核/确认/验收类节点,详情模板应以“项目详情”为主,不默认暴露当前环节表单填写模块。
|
|
88
|
-
- 打回修改、发起人补充等 `enable_relate_project_form=true` 的节点,应使用“只填写项目表单”的模板,且节点不应再额外挂独立 `form_template`。
|
|
89
|
-
- 纯系统自动化动作不要配置成单独需要用户进入处理的详情页;如果节点带子流程联动,应优先做系统等待/汇总页或禁止人工处理入口。
|
|
90
|
-
- 详情模板修改后的验收不能只看模板接口回读;还要回读绑定它的流程节点,确认 `step_detail_id`、`form_template`、`enable_relate_project_form` 与节点动作一致。
|
|
85
|
+
- `node.step_detail_id` 不属于本 skill 管理的 type=2 项目详情模板;它只能引用 type=6 环节详情模板,必须切换到 `bpmax-flow-template-editor` 和 `config step-detail-template` 完成配置与 lint。不得把 project-detail-template 的数字 ID 写入 `node.step_detail_id`。
|
|
86
|
+
- 项目详情模板修改后的验收应确认流程默认详情页解析与运行态展示;环节处理页的 `step_detail_id`、`form_template`、`enable_relate_project_form` 适配由环节详情模板门禁单独负责。
|
|
91
87
|
- 详情模块脚本默认查询口径:
|
|
92
88
|
- 前端模块脚本默认优先 `raw-es-search`
|
|
93
89
|
- 后端 helper 默认优先 `ctx.$esQuery(...)` 或已验证的 `rootUser` helper
|
|
@@ -116,21 +112,10 @@ description: "用于在 BPMAX 的项目详情模板页面中创建、编辑、
|
|
|
116
112
|
- 如果当前在 `/project_detail_template/<id>`,按编辑流程处理。
|
|
117
113
|
- 进入真正修改前,先按模板和模块语义检索一次 Mem0。
|
|
118
114
|
|
|
119
|
-
### 2.
|
|
120
|
-
-
|
|
121
|
-
-
|
|
122
|
-
|
|
123
|
-
- 当前页面最近一次同域接口请求头
|
|
124
|
-
- 必要时补看 `localStorage` / `sessionStorage`
|
|
125
|
-
- 默认把 Cookie 组装成:
|
|
126
|
-
|
|
127
|
-
```bash
|
|
128
|
-
export BPMAX_BASE_URL='https://<your-bpmax-host>'
|
|
129
|
-
export BPMAX_COOKIE_HEADER='foo=bar; baz=qux'
|
|
130
|
-
export BPMAX_WORKSPACE='store_mgr'
|
|
131
|
-
```
|
|
132
|
-
|
|
133
|
-
- `BPMAX_BASE_URL` 必须来自当前浏览器页面 origin 或最近一次同域请求的 origin。
|
|
115
|
+
### 2. 获取 CLI 上下文
|
|
116
|
+
- 使用当前 `bpmax-cli` profile、capability 和线上 readback 作为授权与事实来源。
|
|
117
|
+
- 不读取或复用浏览器 Cookie、浏览器存储、手工请求头或旧脚本环境变量。
|
|
118
|
+
- URL 只作为目标 flow/workspace/template 的定位线索;真实写入必须回到 typed CLI。
|
|
134
119
|
|
|
135
120
|
### 3. 先确认真实线上数据格式
|
|
136
121
|
- 编辑模式优先读取:
|
|
@@ -159,7 +144,7 @@ bpmax-cli config project-detail-template resolve-default \
|
|
|
159
144
|
--format json
|
|
160
145
|
```
|
|
161
146
|
|
|
162
|
-
- `resolved_id` 为空时,不得继续用 `--id 0`
|
|
147
|
+
- `resolved_id` 为空时,不得继续用 `--id 0` 猜测编辑;必须通过 typed CLI resolve/export 或配置列表接口确认目标模板。
|
|
163
148
|
- `bpmax-cli config project-detail-template export --id 0` 只能用于查看全局默认结构,不能作为某个流程的默认详情模板修改目标。
|
|
164
149
|
|
|
165
150
|
### 3.1 优先检索现有模板
|
|
@@ -176,24 +161,13 @@ bpmax-cli config project-detail-template resolve-default \
|
|
|
176
161
|
- 编辑已有模板:
|
|
177
162
|
|
|
178
163
|
```bash
|
|
179
|
-
|
|
180
|
-
[[ -x "$PYTHON_BIN" ]] || PYTHON_BIN=./.venv/bin/python
|
|
181
|
-
[[ -x "$PYTHON_BIN" ]] || PYTHON_BIN=python
|
|
182
|
-
|
|
183
|
-
"$PYTHON_BIN" .codex/skills/bpmax-project-detail-template-editor/scripts/export_project_detail_template.py \
|
|
184
|
-
--template-id 954573597 \
|
|
185
|
-
--workspace store_mgr \
|
|
186
|
-
--cookie-header "$BPMAX_COOKIE_HEADER"
|
|
164
|
+
bpmax-cli config project-detail-template export --id <template-id> --out .codex/tmp/project-detail-template-editor --profile <profile> --format json
|
|
187
165
|
```
|
|
188
166
|
|
|
189
167
|
- 基于线上样例创建 skeleton:
|
|
190
168
|
|
|
191
169
|
```bash
|
|
192
|
-
|
|
193
|
-
--create-skeleton \
|
|
194
|
-
--sample-template-id 954573597 \
|
|
195
|
-
--workspace store_mgr \
|
|
196
|
-
--cookie-header "$BPMAX_COOKIE_HEADER"
|
|
170
|
+
bpmax-cli config project-detail-template export --id <sample-template-id> --out .codex/tmp/project-detail-template-editor --profile <profile> --format json
|
|
197
171
|
```
|
|
198
172
|
|
|
199
173
|
- `stem` 规则固定为:
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
interface:
|
|
2
2
|
display_name: "BPMAX Project Detail Template Editor"
|
|
3
|
-
short_description: "
|
|
4
|
-
default_prompt: "使用 $bpmax-project-detail-template-editor
|
|
3
|
+
short_description: "通过 bpmax-cli typed config 创建、编辑、启用或删除 BPMAX 项目详情模板"
|
|
4
|
+
default_prompt: "使用 $bpmax-project-detail-template-editor 通过 bpmax-cli typed config 创建、编辑、启用或删除 BPMAX 项目详情模板,并用回读验证确认结果。"
|
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: "bpmax-role-editor"
|
|
3
|
-
description: "
|
|
3
|
+
description: "用于通过 bpmax-cli typed config 创建或编辑 BPMAX 角色。只要用户提到“配角色”“编辑角色权限”“新增角色”“改系统权限/自定义权限/流程权限/成员管理”“提交角色配置”或等价表达,就应使用这个 skill。它使用 typed CLI profile 和真实线上接口回读,走本地临时文件 + gate 检查 + typed CLI submit + 回读验收的闭环。"
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# BPMAX Role Editor
|
|
7
7
|
|
|
8
|
+
## 发现角色
|
|
9
|
+
|
|
10
|
+
使用 `bpmax-cli role list --profile <profile> --format json` 列出当前组织全部未删除角色,再选取 ID 进行配置导出。该只读命令复用 `config.role.export` capability,不要求本地配置工作区。
|
|
11
|
+
|
|
8
12
|
## 写入路径硬约束
|
|
9
13
|
- 执行前必须先运行 `bpmax-cli config adapters --format json` 核对 `role`;只有 `build_status` 和 `submit_status` 都是 `supported` 时才允许进入 build/submit。当前若显示 `blocked`,只能导出、编辑 work、lint 和形成变更建议,不得提交。
|
|
10
14
|
- 在 bpmax-cli npm 分发包中,真实远端写操作只能走 `bpmax-cli config role submit`。
|
|
@@ -19,7 +23,7 @@ description: "用于在 BPMAX 的角色配置页面创建或编辑角色。只
|
|
|
19
23
|
- 不得以历史脏配置、顺手修复、统一风格、编辑器自动补字段、方便调试为理由修改需求外配置。
|
|
20
24
|
|
|
21
25
|
## 何时使用
|
|
22
|
-
-
|
|
26
|
+
- 用户需要通过 bpmax-cli typed config 管理 BPMAX 角色配置。
|
|
23
27
|
- 用户要新建角色或编辑已有角色
|
|
24
28
|
- 用户要调整:
|
|
25
29
|
- 角色基础信息
|
|
@@ -66,19 +70,9 @@ description: "用于在 BPMAX 的角色配置页面创建或编辑角色。只
|
|
|
66
70
|
- 不要把“入口能不能看到”“筛选器默认条件”误当成角色列表权限;涉及服务端特殊数据可见性时,跳转到 [`bpmax-dataset-template-editor`](../bpmax-dataset-template-editor/SKILL.md) 的 `pre_process_script` 方法。
|
|
67
71
|
|
|
68
72
|
## 前置条件
|
|
69
|
-
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
- 当前工作区
|
|
73
|
-
- 默认环境变量:
|
|
74
|
-
|
|
75
|
-
```bash
|
|
76
|
-
export BPMAX_BASE_URL='https://<current-browser-origin>'
|
|
77
|
-
export BPMAX_COOKIE_HEADER='foo=bar; baz=qux'
|
|
78
|
-
export BPMAX_WORKSPACE='store_mgr'
|
|
79
|
-
```
|
|
80
|
-
|
|
81
|
-
- `BPMAX_BASE_URL` 优先使用当前浏览器页面 origin;如果没有显式提供,bpmax-builder-shared `base_url` 会按 [AGENTS.md](../../../AGENTS.md) 里的仓库默认 origin 兜底。
|
|
73
|
+
- 使用当前 `bpmax-cli` profile、capability 和线上 readback 作为授权与事实来源。
|
|
74
|
+
- 浏览器页面只用于只读验收角色可见性和权限表现;真实远端写入必须回到 `bpmax-cli config role submit`。
|
|
75
|
+
- 不读取或复用浏览器 Cookie、浏览器存储、手工请求头或旧脚本环境变量。
|
|
82
76
|
- 不要在 skill 文档或脚本里再写死任何项目环境域名。
|
|
83
77
|
|
|
84
78
|
## Mem0 协议
|
|
@@ -102,26 +96,13 @@ export BPMAX_WORKSPACE='store_mgr'
|
|
|
102
96
|
- 编辑已有角色:
|
|
103
97
|
|
|
104
98
|
```bash
|
|
105
|
-
|
|
106
|
-
[[ -x "$PYTHON_BIN" ]] || PYTHON_BIN=./.venv/bin/python
|
|
107
|
-
[[ -x "$PYTHON_BIN" ]] || PYTHON_BIN=python3
|
|
108
|
-
|
|
109
|
-
"$PYTHON_BIN" .codex/skills/bpmax-role-editor/scripts/export_role.py \
|
|
110
|
-
--role-id 895023449 \
|
|
111
|
-
--workspace store_mgr \
|
|
112
|
-
--cookie-header "$BPMAX_COOKIE_HEADER"
|
|
99
|
+
bpmax-cli config role export --id <role-id> --out .codex/tmp/role-editor --profile <profile> --format json
|
|
113
100
|
```
|
|
114
101
|
|
|
115
102
|
- 新建角色 skeleton:
|
|
116
103
|
|
|
117
104
|
```bash
|
|
118
|
-
|
|
119
|
-
--create-skeleton \
|
|
120
|
-
--workspace store_mgr \
|
|
121
|
-
--name "新角色" \
|
|
122
|
-
--key new_role \
|
|
123
|
-
--intro "角色说明" \
|
|
124
|
-
--cookie-header "$BPMAX_COOKIE_HEADER"
|
|
105
|
+
bpmax-cli config role export --create --out .codex/tmp/role-editor --profile <profile> --format json
|
|
125
106
|
```
|
|
126
107
|
|
|
127
108
|
### 2. 本地 work 文件
|
|
@@ -14,31 +14,41 @@ metadata:
|
|
|
14
14
|
|
|
15
15
|
## 命令发现
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
若提供了 `BPMAX_CLI_HOME`,必须优先使用该源码 checkout,不能因为 PATH 中存在旧版全局命令而回退。源码入口会在需要时自动构建,并在执行命令前把 bundled Skills 同步到当前源码版本:
|
|
18
18
|
|
|
19
19
|
```bash
|
|
20
|
-
|
|
20
|
+
node "$BPMAX_CLI_HOME/scripts/run-source-cli.mjs" --help
|
|
21
21
|
```
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
在 `bpmax-cli` 源码仓库内开发或联调时,先执行一次 `npm link`。之后 bare `bpmax-cli` 会链接到同一个源码入口,迁移脚本中的子进程也会自动使用当前源码:
|
|
24
24
|
|
|
25
25
|
```bash
|
|
26
|
-
|
|
26
|
+
npm link
|
|
27
|
+
bpmax-cli --version
|
|
27
28
|
```
|
|
28
29
|
|
|
29
|
-
|
|
30
|
+
若没有 `BPMAX_CLI_HOME`,才允许使用 PATH 中的已安装命令:
|
|
30
31
|
|
|
31
32
|
```bash
|
|
32
|
-
|
|
33
|
-
npm --prefix "$BPMAX_CLI_HOME" run build
|
|
33
|
+
bpmax-cli --help
|
|
34
34
|
```
|
|
35
35
|
|
|
36
|
-
后文默认直接写 `bpmax-cli
|
|
36
|
+
后文默认直接写 `bpmax-cli`。设置了 `BPMAX_CLI_HOME` 但没有执行 `npm link` 时,把所有命令前缀替换成:
|
|
37
37
|
|
|
38
38
|
```bash
|
|
39
|
-
node "$BPMAX_CLI_HOME/
|
|
39
|
+
node "$BPMAX_CLI_HOME/scripts/run-source-cli.mjs" ...
|
|
40
40
|
```
|
|
41
41
|
|
|
42
|
+
禁止在同一次迁移中混用源码 CLI、旧全局 CLI 和不同版本 Skills。开始迁移前必须确认 `--version` 与 `$BPMAX_CLI_HOME/package.json` 一致,且命令输出不再出现 Skills out-of-sync notice。
|
|
43
|
+
|
|
44
|
+
## Agent 更新通知
|
|
45
|
+
|
|
46
|
+
- 所有 Agent、OpenClaw、Aily、Codex 和自动化调用都必须读取 CLI 返回的 `_notice`,不能只读取业务字段。
|
|
47
|
+
- `_notice.update` 表示当前安装渠道存在更高版本;beta 安装跟踪 `beta`,稳定安装跟踪 `latest`。先展示 `current/latest/channel`,再执行返回的 `next_command`。
|
|
48
|
+
- `_notice.skills` 表示 bundled Skills 未安装或与 CLI 不匹配;必须先执行返回的 `next_command` 完成同步。
|
|
49
|
+
- JSON 对象中的通知位于 `_notice`;JSON 数组、NDJSON、table、pretty 和命令错误中的通知通过 stderr 输出。Agent 必须同时读取 stdout 和 stderr。
|
|
50
|
+
- 更新失败时停止后续配置提交和正式 E2E,并向用户展示结构化错误;不得静默忽略更新提示或继续使用旧 lint/Skill。
|
|
51
|
+
|
|
42
52
|
## 开始前检查
|
|
43
53
|
|
|
44
54
|
任何 BPMAX CLI 场景都先做两步。本地终端可直接运行;Agent/飞书/OpenClaw/Aily 等多用户运行时必须使用 `init` 返回的 `next_commands.profile_list` 和 `next_commands.auth_status`,不要裸跑共享配置命令:
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: bpmax-team-editor
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
description: "Use when creating or editing BPMAX teams and organization hierarchy through the bpmax-cli typed team adapter."
|
|
5
|
+
metadata:
|
|
6
|
+
requires:
|
|
7
|
+
bins: ["bpmax-cli"]
|
|
8
|
+
cliHelp: "bpmax-cli config team --help"
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# BPMAX Team Editor
|
|
12
|
+
|
|
13
|
+
先阅读 `../bpmax-shared/SKILL.md`。团队配置必须在已初始化的 BPMAX 配置目录中,通过 typed CLI 完成。
|
|
14
|
+
|
|
15
|
+
## 标准链路
|
|
16
|
+
|
|
17
|
+
1. `bpmax-cli config team export --id <id> --out <dir> --profile <profile> --format json`
|
|
18
|
+
2. 只修改 work 文件中的 `name`、`intro`、`parent_id`、`model_id`、`permission`、`admin_users` 或 `meta_form`;导出的 `platform_id` 必须原样保留。
|
|
19
|
+
3. 运行 `lint`、`build`,审阅 dry-run 后再 `submit --id <id> --confirm "submit team <id>"`。
|
|
20
|
+
4. 运行 `verify --id <id>`,确认父级、模型、权限和管理员回读一致。
|
|
21
|
+
|
|
22
|
+
## 硬门禁
|
|
23
|
+
|
|
24
|
+
- `parent_id` 不得指向自身;调整层级前必须确认目标父团队存在且不会形成环。
|
|
25
|
+
- 不得修改 `path`、`organization_id`、`platform_*`、`is_del`、时间戳等服务端或外部同步字段。已有 `platform_id` 是只读身份字段,删除或改变都会被 build/submit 硬阻断;create 也不得手工指定。
|
|
26
|
+
- 不得直接修改 `think_group` 文件代替 typed submit。
|
|
27
|
+
- 删除前必须确认没有子团队、成员或业务对象仍依赖该团队;平台拒绝时不得绕过。
|