bpmax-cli 0.2.1-beta.74 → 0.2.1-beta.76

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.
@@ -0,0 +1,184 @@
1
+ {
2
+ "name": "项目详情环节处理",
3
+ "key": "project.detail.step-panel",
4
+ "intro": "",
5
+ "template": {
6
+ "version": 1,
7
+ "entry": {
8
+ "kind": "project-detail"
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": "project-detail",
158
+ "capability": "project.detail",
159
+ "context": "selectedProject",
160
+ "title": "项目详情"
161
+ },
162
+ {
163
+ "type": "step-form",
164
+ "capability": "step.form",
165
+ "context": "currentStep",
166
+ "title": "环节表单"
167
+ },
168
+ {
169
+ "type": "step-operation",
170
+ "capability": "step.operation",
171
+ "action": "submitStep",
172
+ "title": "环节操作"
173
+ }
174
+ ]
175
+ },
176
+ "dependencies": {
177
+ "capabilities": [
178
+ "project.detail",
179
+ "step.form",
180
+ "step.operation"
181
+ ]
182
+ }
183
+ }
184
+ }
@@ -0,0 +1,177 @@
1
+ {
2
+ "name": "项目列表快速处理",
3
+ "key": "project.list.quick-process",
4
+ "intro": "",
5
+ "template": {
6
+ "version": 1,
7
+ "entry": {
8
+ "kind": "project-list"
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": "project-table",
158
+ "capability": "project.table",
159
+ "query": "projects",
160
+ "title": "项目列表"
161
+ },
162
+ {
163
+ "type": "step-quick-process",
164
+ "capability": "step.quick-process",
165
+ "action": "submitStep",
166
+ "title": "快速处理"
167
+ }
168
+ ]
169
+ },
170
+ "dependencies": {
171
+ "capabilities": [
172
+ "project.table",
173
+ "step.quick-process"
174
+ ]
175
+ }
176
+ }
177
+ }
@@ -0,0 +1,191 @@
1
+ {
2
+ "name": "项目运营数据看板",
3
+ "key": "project.operations.dashboard",
4
+ "intro": "可交互的项目指标、状态分布、筛选列表和环节处理看板。",
5
+ "template": {
6
+ "version": 1,
7
+ "entry": {
8
+ "kind": "project-list"
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": "<main class=\"ops-dashboard\">\n <header class=\"dashboard-header\">\n <div>\n <p class=\"dashboard-eyebrow\">OPERATIONS / PAGE COMPOSITION</p>\n <h1>{{ template.name || '项目运营数据看板' }}</h1>\n <p class=\"dashboard-subtitle\">{{ template.intro || '用统一页面模板组合项目指标、状态分布和处理列表。' }}</p>\n </div>\n <div class=\"dashboard-actions\">\n <el-button class=\"dashboard-button\" type=\"primary\" :loading=\"dashboardRefreshing\" :disabled=\"dashboardRefreshing\" @click=\"refreshAll\">\n {{ dashboardRefreshing ? '刷新中…' : '刷新数据' }}\n </el-button>\n <el-button class=\"dashboard-button dashboard-button-muted\" plain @click=\"clearSelection\">清除选择</el-button>\n </div>\n </header>\n\n <div v-if=\"runtimeError\" class=\"dashboard-alert\" role=\"alert\">{{ runtimeError }}</div>\n\n <section class=\"dashboard-kpis\" aria-label=\"项目指标\">\n <article v-for=\"metric in dashboardMetrics\" :key=\"metric.key\" class=\"dashboard-kpi\" :class=\"'tone-' + metric.tone\">\n <span>{{ metric.label }}</span>\n <strong>{{ metric.value }}</strong>\n </article>\n </section>\n\n <section class=\"dashboard-charts\" aria-label=\"项目图表\">\n <page-chart chart-type=\"status-donut\" title=\"项目状态构成\" :rows=\"projectRows\" />\n <page-chart chart-type=\"owner-bar\" title=\"负责人项目量\" :rows=\"projectRows\" />\n <page-chart chart-type=\"project-graph\" title=\"项目关系图\" eyebrow=\"RELATION GRAPH\" :rows=\"projectRows\" />\n </section>\n\n <section class=\"dashboard-grid\">\n <article class=\"dashboard-panel dashboard-status-panel\">\n <div class=\"dashboard-panel-heading\"><div><p class=\"dashboard-overline\">DISTRIBUTION</p><h2>项目状态</h2></div><span>{{ formatNumber(projectRows.length) }} 项</span></div>\n <div class=\"dashboard-status-list\">\n <button v-for=\"status in statusRows\" :key=\"status.key\" type=\"button\" class=\"dashboard-status-row\" :class=\"{ 'is-active': filterStatus === status.key }\" @click=\"selectDashboardStatus(status.key)\">\n <span class=\"dashboard-status-label\"><i :class=\"'status-dot status-' + status.key\"></i>{{ status.label }}</span>\n <span class=\"dashboard-status-value\">{{ status.value }}</span>\n <span class=\"dashboard-progress\"><i :style=\"{ width: (Math.round(status.value / (projectRows.length || 1) * 100) + '%') }\"></i></span>\n </button>\n <p v-if=\"!statusRows.length\" class=\"dashboard-empty\">暂无状态数据</p>\n </div>\n </article>\n\n <article class=\"dashboard-panel dashboard-filter-panel\">\n <div class=\"dashboard-panel-heading\"><div><p class=\"dashboard-overline\">FILTERS</p><h2>筛选与选中项</h2></div></div>\n <label class=\"dashboard-label\" for=\"dashboard-status\">状态</label>\n <el-select id=\"dashboard-status\" v-model=\"filterStatus\" class=\"dashboard-control dashboard-element-control\" size=\"small\" placeholder=\"选择项目状态\" :popper-append-to-body=\"false\">\n <el-option v-for=\"status in statusOptions\" :key=\"status.key\" :label=\"status.label\" :value=\"status.key\" />\n </el-select>\n <label class=\"dashboard-label\" for=\"dashboard-keyword\">关键词</label>\n <el-input id=\"dashboard-keyword\" v-model=\"filterKeyword\" class=\"dashboard-control dashboard-element-control\" size=\"small\" clearable prefix-icon=\"el-icon-search\" placeholder=\"搜索项目名称或 ID\" />\n <label class=\"dashboard-label\" for=\"dashboard-owner\">负责人 ID</label>\n <el-input id=\"dashboard-owner\" v-model=\"filterOwner\" class=\"dashboard-control dashboard-element-control\" size=\"small\" clearable placeholder=\"按负责人 ID 筛选\" />\n <label class=\"dashboard-label\" for=\"dashboard-created-date\">创建日期</label>\n <el-date-picker id=\"dashboard-created-date\" v-model=\"filterCreatedDate\" class=\"dashboard-control dashboard-element-control\" size=\"small\" type=\"date\" format=\"yyyy-MM-dd\" value-format=\"yyyy-MM-dd\" clearable :popper-append-to-body=\"false\" placeholder=\"选择创建日期\" />\n <div v-if=\"selectedProject\" class=\"dashboard-selected\">\n <span>当前项目</span><strong>{{ selectedProject.name || selectedProject.title || selectedProject.id }}</strong>\n <small>{{ currentStep ? stepLabel(currentStep) : '没有唯一可处理环节' }}</small>\n </div>\n <p v-else class=\"dashboard-empty\">从列表选择项目后查看上下文。</p>\n </article>\n\n <article class=\"dashboard-panel dashboard-list-panel\">\n <div class=\"dashboard-panel-heading\"><div><p class=\"dashboard-overline\">PROJECT LIST</p><h2>项目列表</h2></div><span>{{ filteredProjectRows.length }} 个结果</span></div>\n <page-block\n v-for=\"(block, index) in blocks\"\n v-if=\"block.type === 'project-table'\"\n :key=\"'table-' + index\"\n :block=\"block\"\n :block-index=\"index\"\n :rows=\"filteredProjectRows\"\n :selected-project=\"selectedProject\"\n :current-step=\"currentStep\"\n :draft-comment=\"draftComment\"\n :action-busy=\"actionBusy\"\n :selected-project-ids=\"selectedProjectIds\"\n @select-project=\"selectProject\"\n @open-quick-process=\"openQuickProcess\"\n />\n </article>\n\n <article class=\"dashboard-panel dashboard-detail-panel\">\n <div class=\"dashboard-panel-heading\"><div><p class=\"dashboard-overline\">CONTEXT</p><h2>项目详情</h2></div></div>\n <page-block\n v-for=\"(block, index) in blocks\"\n v-if=\"block.type === 'project-detail'\"\n :key=\"'detail-' + 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 :selected-project-ids=\"selectedProjectIds\"\n @load-project-detail=\"loadProjectDetail\"\n />\n <p v-if=\"!selectedProject\" class=\"dashboard-empty\">选择列表中的项目查看详情。</p>\n </article>\n </section>\n\n <div v-if=\"quickProcessVisible\" class=\"dashboard-overlay\" role=\"dialog\" aria-modal=\"true\" aria-label=\"快速处理\">\n <section class=\"dashboard-drawer\">\n <div class=\"dashboard-drawer-heading\"><div><p class=\"dashboard-overline\">ACTION</p><h2>快速处理</h2></div><el-button class=\"dashboard-close\" plain @click=\"clearSelection\">关闭</el-button></div>\n <p v-if=\"selectedProject\" class=\"dashboard-drawer-project\">{{ 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=\"'action-' + 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 :selected-project-ids=\"selectedProjectIds\"\n @submit-step=\"submitStep\"\n @update-comment=\"draftComment = $event\"\n />\n <p v-if=\"!currentStep\" class=\"dashboard-empty\">当前项目没有唯一可处理环节。</p>\n </section>\n </div>\n</main>",
154
+ "style": ".ops-dashboard { min-height: 100%; padding: 24px 32px 48px; background: #f5f7fa; color: #1f2937; }\n.dashboard-header { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; }\n.dashboard-eyebrow, .dashboard-overline { margin: 0; color: #2563eb; font-size: 11px; font-weight: 700; letter-spacing: .12em; }\n.dashboard-header h1 { margin: 6px 0; font-size: 26px; letter-spacing: -.02em; }\n.dashboard-subtitle { max-width: 680px; margin: 0; color: #64748b; line-height: 1.6; }\n.dashboard-actions { display: flex; gap: 8px; flex-wrap: wrap; }\n.dashboard-button, .dashboard-close { min-height: 44px; padding: 9px 14px; border: 1px solid #2563eb; border-radius: 8px; background: #2563eb; color: #fff; cursor: pointer; }\n.dashboard-button-muted, .dashboard-close { border-color: #cbd5e1; background: #fff; color: #334155; }\n.dashboard-button:focus-visible, .dashboard-close:focus-visible, .dashboard-status-row:focus-visible { outline: 2px solid #93c5fd; outline-offset: 2px; }\n.dashboard-button:disabled { cursor: not-allowed; opacity: .55; }\n.dashboard-alert { margin-top: 16px; padding: 12px 16px; border: 1px solid #fecaca; border-radius: 10px; background: #fff1f2; color: #991b1b; }\n.dashboard-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 20px; }\n.dashboard-kpi { position: relative; min-height: 104px; padding: 16px 18px; box-sizing: border-box; border: 1px solid #e5e7eb; border-radius: 14px; background: #fff; overflow: hidden; }\n.dashboard-kpi:before { position: absolute; inset: 0 auto 0 0; width: 4px; content: ''; background: #2563eb; }\n.dashboard-kpi.tone-amber:before { background: #d97706; } .dashboard-kpi.tone-violet:before { background: #7c3aed; } .dashboard-kpi.tone-green:before { background: #16a34a; }\n.dashboard-kpi span { display: block; color: #64748b; font-size: 12px; } .dashboard-kpi strong { display: block; margin-top: 12px; font-size: 28px; font-variant-numeric: tabular-nums; } .dashboard-charts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 16px; }\n.dashboard-grid { display: grid; grid-template-columns: minmax(260px, .8fr) minmax(260px, .8fr) minmax(460px, 1.8fr); gap: 16px; margin-top: 16px; align-items: start; }\n.dashboard-charts .page-composition-chart { min-width: 0; }\n.dashboard-panel { min-width: 0; padding: 20px; border: 1px solid #e5e7eb; border-radius: 14px; background: #fff; }\n.dashboard-list-panel { grid-column: 1 / -1; } .dashboard-detail-panel { grid-column: 1 / -1; }\n.dashboard-panel-heading, .dashboard-drawer-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 16px; }\n.dashboard-panel-heading h2, .dashboard-drawer-heading h2 { margin: 4px 0 0; font-size: 17px; } .dashboard-panel-heading > span { color: #64748b; font-size: 12px; }\n.dashboard-status-list { display: grid; gap: 4px; } .dashboard-status-row { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; min-height: 52px; padding: 8px 0; border: 0; border-bottom: 1px solid #f1f5f9; background: transparent; color: #334155; text-align: left; cursor: pointer; }\n.dashboard-status-row.is-active .dashboard-status-label, .dashboard-status-row:hover .dashboard-status-label { color: #2563eb; } .dashboard-status-label { display: flex; gap: 8px; align-items: center; }\n.dashboard-status-value { font-variant-numeric: tabular-nums; font-weight: 600; } .dashboard-progress { grid-column: 1 / -1; display: block; height: 5px; border-radius: 999px; background: #e2e8f0; overflow: hidden; } .dashboard-progress i { display: block; height: 100%; border-radius: inherit; background: #60a5fa; }\n.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #94a3b8; } .status-2, .status-6, .status-pending { background: #d97706; } .status-3, .status-processing { background: #7c3aed; } .status-4, .status-completed, .status-done { background: #16a34a; }\n.dashboard-label { display: block; margin: 12px 0 6px; color: #475569; font-size: 12px; font-weight: 600; } .dashboard-control { width: 100%; min-height: 42px; box-sizing: border-box; padding: 9px 10px; border: 1px solid #cbd5e1; border-radius: 8px; background: #fff; color: #1f2937; } .dashboard-element-control { min-height: 32px; padding: 0; } .dashboard-element-control.el-select, .dashboard-element-control.el-date-editor { display: block; } .dashboard-element-control .el-input__inner, .dashboard-element-control.el-input .el-input__inner { min-height: 32px; height: 32px; border-color: #cbd5e1; border-radius: 6px; background: #fff; color: #1f2937; } .dashboard-element-control .el-input__inner:focus { border-color: #2563eb; }\n.dashboard-control:focus { border-color: #2563eb; outline: 2px solid #bfdbfe; outline-offset: 1px; } .dashboard-selected { margin-top: 20px; padding: 12px; border-radius: 10px; background: #eff6ff; } .dashboard-selected span, .dashboard-selected small { display: block; color: #475569; font-size: 12px; } .dashboard-selected strong { display: block; margin: 5px 0; }\n.dashboard-empty { margin: 0; color: #64748b; font-size: 13px; } .dashboard-overlay { position: fixed; inset: 0; z-index: 20; display: flex; justify-content: flex-end; background: rgba(15, 23, 42, .32); } .dashboard-drawer { width: min(520px, 100vw); height: 100%; box-sizing: border-box; padding: 24px; overflow: auto; background: #fff; } .dashboard-drawer-project { margin: 0 0 20px; font-weight: 600; }\n@media (max-width: 1024px) { .dashboard-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .dashboard-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .dashboard-list-panel, .dashboard-detail-panel { grid-column: 1 / -1; } }\n@media (max-width: 1024px) { .dashboard-charts .page-composition-chart:last-child { grid-column: 1 / -1; } }\n@media (max-width: 720px) { .ops-dashboard { padding: 16px 16px 32px; } .dashboard-header { flex-direction: column; } .dashboard-kpis, .dashboard-charts, .dashboard-grid { grid-template-columns: 1fr; } .dashboard-list-panel, .dashboard-detail-panel { grid-column: auto; } }",
155
+ "blocks": [
156
+ {
157
+ "type": "project-table",
158
+ "capability": "project.table",
159
+ "query": "projects",
160
+ "title": "项目列表"
161
+ },
162
+ {
163
+ "type": "project-detail",
164
+ "capability": "project.detail",
165
+ "context": "selectedProject",
166
+ "title": "项目详情"
167
+ },
168
+ {
169
+ "type": "step-form",
170
+ "capability": "step.form",
171
+ "context": "currentStep",
172
+ "title": "环节表单"
173
+ },
174
+ {
175
+ "type": "step-operation",
176
+ "capability": "step.operation",
177
+ "action": "submitStep",
178
+ "title": "环节操作"
179
+ }
180
+ ]
181
+ },
182
+ "dependencies": {
183
+ "capabilities": [
184
+ "project.table",
185
+ "project.detail",
186
+ "step.form",
187
+ "step.operation"
188
+ ]
189
+ }
190
+ }
191
+ }