weaver-work-cli 0.1.48 → 0.1.50
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/dist/chunks/{archive-oa-EDJDU3V4.js → archive-oa-57R2FYHV.js} +111 -12
- package/dist/chunks/{attachment-content-4KSNBPRO.js → attachment-content-EJYIOJPH.js} +3 -3
- package/dist/chunks/{chunk-FEP6ELMR.js → chunk-3NCFFHB2.js} +1 -1
- package/dist/chunks/chunk-5QYE52LG.js +223 -0
- package/dist/chunks/{chunk-3YV7PKRL.js → chunk-6QYNE6HE.js} +12 -212
- package/dist/chunks/{chunk-NBEWUR7L.js → chunk-6T53BSWZ.js} +158 -44
- package/dist/chunks/{chunk-OCYRVZGN.js → chunk-7AYQJSFY.js} +2 -2
- package/dist/chunks/{chunk-5B5JXTY2.js → chunk-7ECB22G3.js} +221 -30
- package/dist/chunks/{chunk-72MI3MBX.js → chunk-ATEXBEPD.js} +55 -15
- package/dist/chunks/{chunk-WMSAWAWZ.js → chunk-BFKLQLBK.js} +8 -8
- package/dist/chunks/{chunk-EFOUMXIX.js → chunk-HARQF5IP.js} +28 -28
- package/dist/chunks/{chunk-O6CMPO65.js → chunk-IW7A2IQY.js} +16 -146
- package/dist/chunks/chunk-JEQHNNSS.js +158 -0
- package/dist/chunks/{chunk-NK74RE5F.js → chunk-K67FODVC.js} +3 -3
- package/dist/chunks/{chunk-YLCYX7LE.js → chunk-KMRT7NAT.js} +18 -5
- package/dist/chunks/{chunk-BCACE6VV.js → chunk-MCZG6HPM.js} +3 -3
- package/dist/chunks/{chunk-SVFG6EMV.js → chunk-RYFRGTUV.js} +5 -5
- package/dist/chunks/{chunk-PSPOFLSU.js → chunk-WNJUGI2F.js} +1 -1
- package/dist/chunks/{chunk-R2HHLJNN.js → chunk-YB3AJYPY.js} +4 -4
- package/dist/chunks/{conflict-APGSD5E7.js → conflict-C4UDHCWV.js} +2 -2
- package/dist/chunks/{contract-N6P2HIIE.js → contract-VUC6JOPG.js} +464 -9
- package/dist/chunks/{create-flow-5TXFOC7X.js → create-flow-6OG2LYBD.js} +6 -6
- package/dist/chunks/data-QO7QWOIV.js +2525 -0
- package/dist/chunks/{employee-NOHNXC46.js → employee-DR5Y64TI.js} +2 -1
- package/dist/chunks/{env-B6GKA2J3.js → env-WP57TF2S.js} +2 -2
- package/dist/chunks/{factory-MFCKLUT6.js → factory-VUXI7N5C.js} +1 -1
- package/dist/chunks/{fna-ZVB2IILI.js → fna-ECOYBQYL.js} +328 -5
- package/dist/chunks/{group-chat-YE7WIBFO.js → group-chat-UQRGXILK.js} +3 -3
- package/dist/chunks/{hrm-UNKCCCGP.js → hrm-YGIR3HGF.js} +4 -2
- package/dist/chunks/{im-3RCNL5GT.js → im-TN2JYVGJ.js} +2 -2
- package/dist/chunks/{invoice-FXWH5GPO.js → invoice-E7GOITEU.js} +1 -1
- package/dist/chunks/{meeting-RYZV2JTQ.js → meeting-4BBLVAWM.js} +10 -10
- package/dist/chunks/{msg-parse-4GSQ2WTO.js → msg-parse-FPFVPMYI.js} +5 -1
- package/dist/chunks/org-NFE7X7FK.js +12 -0
- package/dist/chunks/{reception-VL6TKVAW.js → reception-QGPNTGHG.js} +526 -175
- package/dist/chunks/{recruit-stage-ERZD3ZNB.js → recruit-stage-FKWS5UQF.js} +66 -13
- package/dist/chunks/{registry-VWXWPVAG.js → registry-3UGIWH53.js} +4 -2
- package/dist/chunks/{registry-22O6UG4I.js → registry-5CRCN2TV.js} +10 -10
- package/dist/chunks/{registry-BUTEDK3C.js → registry-E5RQJVWN.js} +2 -2
- package/dist/chunks/{registry-7VZ6YJUF.js → registry-V4CHRQDI.js} +1 -1
- package/dist/chunks/{room-recommend-IMZPJMYB.js → room-recommend-AYR3UG7R.js} +4 -4
- package/dist/chunks/{schedule-SPPAHER2.js → schedule-JZEFIXUS.js} +4 -4
- package/dist/chunks/{workflow-WVEFJ6KC.js → workflow-3ZAF2J5E.js} +4 -4
- package/dist/index.js +16 -11
- package/dist/shortcuts/archive-oa/operations/contract-modules.js +57 -0
- package/dist/shortcuts/archive-oa/operations/contract.js +23 -8
- package/dist/shortcuts/archive-oa/operations/registry.js +4 -1
- package/dist/shortcuts/archive-oa/operations/shared.js +41 -5
- package/dist/shortcuts/contract/host.js +11 -0
- package/dist/shortcuts/contract/index.js +13 -0
- package/dist/shortcuts/contract/manifest.js +53 -0
- package/dist/shortcuts/contract/operations/performance.js +58 -7
- package/dist/shortcuts/contract/operations/quote.js +283 -1
- package/dist/shortcuts/contract/operations/registry.js +2 -0
- package/dist/shortcuts/contract/operations/save-recognize.js +151 -0
- package/dist/shortcuts/data/errors.js +64 -0
- package/dist/shortcuts/data/host.js +140 -0
- package/dist/shortcuts/data/index.js +429 -0
- package/dist/shortcuts/data/manifest.js +133 -0
- package/dist/shortcuts/data/operations/attend.js +62 -0
- package/dist/shortcuts/data/operations/conf.js +384 -0
- package/dist/shortcuts/data/operations/ds.js +686 -0
- package/dist/shortcuts/data/operations/field.js +68 -0
- package/dist/shortcuts/data/operations/index.js +65 -0
- package/dist/shortcuts/data/operations/module.js +383 -0
- package/dist/shortcuts/data/operations/noun.js +102 -0
- package/dist/shortcuts/data/operations/query.js +85 -0
- package/dist/shortcuts/data/operations/scene.js +235 -0
- package/dist/shortcuts/data/operations/shared.js +279 -0
- package/dist/shortcuts/ehr/recruit-stage/operations/interview-arrange.js +12 -5
- package/dist/shortcuts/ehr/recruit-stage/operations/resume-import.js +21 -13
- package/dist/shortcuts/ehr/recruit-stage/shared.js +57 -0
- package/dist/shortcuts/fna/host.js +4 -2
- package/dist/shortcuts/fna/manifest.js +14 -5
- package/dist/shortcuts/fna/operations/audit.js +334 -0
- package/dist/shortcuts/fna/operations/registry.js +2 -0
- package/dist/shortcuts/im/operations/at-mention.js +6 -3
- package/dist/shortcuts/im/operations/msg-parse.js +35 -5
- package/dist/shortcuts/im/operations/msg-sync.js +3 -1
- package/dist/shortcuts/im/operations/msg-write.js +57 -9
- package/dist/shortcuts/index.js +5 -0
- package/dist/shortcuts/invoice/manifest.js +1 -1
- package/dist/shortcuts/meeting/operations/eb/member-expand.js +200 -0
- package/dist/shortcuts/meeting/operations/from-group-chat.js +16 -2
- package/dist/shortcuts/meeting/operations/registry.js +2 -0
- package/dist/shortcuts/reception/constants.js +13 -6
- package/dist/shortcuts/reception/index.js +3 -1
- package/dist/shortcuts/reception/manifest.js +3 -2
- package/dist/shortcuts/reception/operations/ask.js +20 -2
- package/dist/shortcuts/reception/operations/compose.js +11 -0
- package/dist/shortcuts/reception/operations/doc.js +59 -0
- package/dist/shortcuts/reception/operations/docrender.js +25 -1
- package/dist/shortcuts/reception/operations/leads.js +31 -7
- package/dist/shortcuts/reception/operations/panels.js +86 -22
- package/dist/shortcuts/reception/operations/render.js +40 -0
- package/dist/shortcuts/reception/operations/restaurant.js +17 -4
- package/dist/shortcuts/recruit-stage/operations/interview-arrange.js +12 -5
- package/dist/shortcuts/recruit-stage/operations/resume-import.js +21 -13
- package/dist/shortcuts/recruit-stage/shared.js +57 -0
- package/dist/shortcuts/workflow/operations/read.js +58 -14
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.collect.js +140 -24
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.core.js +42 -14
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.js +4 -6
- package/docs/SKILL.md +2 -1
- package/docs/_catalog.md +4 -1
- package/docs/data.md +149 -0
- package/docs/fna.md +11 -4
- package/docs/reception.md +59 -5
- package/package.json +1 -1
- package/scripts/check-skill-sync.mjs +188 -0
- package/scripts/package-skill.mjs +17 -3
- package/skill-template/business-info.json +29 -1
- package/skill-template/domains/data.md +15 -0
- package/skill-template/domains/qiyecheng.md +4 -2
- package/skills/weaver-e10-archive-oa/SKILL.md +7 -6
- package/skills/weaver-e10-archive-oa/references/contract-search.md +83 -14
- package/skills/weaver-e10-archive-oa/references/disabled-capabilities.md +1 -1
- package/skills/weaver-e10-archive-oa/references/qys-contract-search.md +35 -11
- package/skills/weaver-e10-data/SKILL.md +118 -0
- package/skills/weaver-e10-data/references/config-center.md +90 -0
- package/skills/weaver-e10-data/references/datasource.md +136 -0
- package/skills/weaver-e10-data/references/scene-and-misc.md +82 -0
- package/skills/weaver-e10-jinchengda/SKILL.md +1 -1
- package/skills/weaver-e10-jinchengda/references/contract-action-card.md +5 -5
- package/skills/weaver-e10-jinchengda/references/contract-action-engine.md +1 -1
- package/skills/weaver-e10-jinchengda/references/contract-clause-library-crud.md +44 -2
- package/skills/weaver-e10-jinchengda/references/contract-command-index.md +2 -2
- package/skills/weaver-e10-jinchengda/references/contract-element-save-record.md +219 -0
- package/skills/weaver-e10-jinchengda/references/contract-field-extract-new-customer.md +50 -30
- package/skills/weaver-e10-jinchengda/references/contract-field-extract-other-flows.md +24 -15
- package/skills/weaver-e10-jinchengda/references/contract-flow-launch.md +1 -1
- package/skills/weaver-e10-jinchengda/references/contract-performance-query.md +96 -2
- package/skills/weaver-e10-jinchengda/references/contract-quote-to-contract.md +43 -0
- package/skills/weaver-e10-jinchengda/scripts/fill_plan.py +997 -0
- package/skills/weaver-e10-jinchengda/scripts/render_ebdf_list_card.py +265 -0
- package/skills/weaver-e10-jinchengda/scripts/validate_action_card.py +83 -0
- package/skills/weaver-e10-jinchengda/scripts/verify_docx_placeholders.py +118 -0
- package/skills/weaver-e10-meeting/SKILL.md +39 -7
- package/skills/weaver-e10-qiyecheng/SKILL.md +21 -7
- package/skills/weaver-e10-qiyecheng/references/ai-check-audit.md +104 -0
- package/skills/weaver-e10-qiyecheng/references/catalog.md +17 -3
- package/skills/weaver-e10-qiyecheng/references/source-manifest.json +136 -30
- package/skills/weaver-e10-reception-flow/SKILL.md +70 -19
- package/skills/weaver-e10-reception-flow/references/guide.md +5 -4
- package/skills/weaver-e10-reception-flow/scripts/render.py +5 -3
- package/skills/weaver-e10-recruit-stage/SKILL.md +1 -1
- package/skills/weaver-e10-recruit-stage/agents/openai.yaml +26 -6
- package/skills/weaver-e10-recruit-stage/references/recruit-arrange-interview.md +3 -3
- package/skills/weaver-e10-recruit-stage/references/recruit-output-links.md +6 -4
- package/skills/weaver-e10-recruit-stage/references/recruit-resume-import.md +3 -3
- package/skills/weaver-e10-recruit-stage/references/recruit-utterance-glossary.md +53 -11
- package/skills/weaver-e10-workflow/SKILL.md +2 -1
- package/skills/weaver-e10-workflow/references/todo-smart-convert.md +29 -6
- package/skills/weaver-e10-workflow/tools/todo-summary.cjs +162 -10
- package/skills/weaver-e10-yepiaotong/SKILL.md +10 -5
- package/skills/weaver-e10-yepiaotong/references/invoice-issuing-workflow.md +19 -32
- package/skills/weaver-e10-yepiaotong/references/invoice-reim.md +6 -45
- package/skills/weaver-e10-yepiaotong/references/reim-api-reference.md +5 -5
- package/skills/weaver-e10-yepiaotong/references/reim-examples.md +4 -37
- package/skills/weaver-e10-yepiaotong/references/reim-form-fill-rules.md +2 -2
- package/skills/weaver-e10-yepiaotong/references/reim-phone-subsidy-rules.md +4 -4
- package/skills/weaver-e10-yepiaotong/references/reim-workflow.md +22 -35
- package/skills/weaver-e10-yimiaoban/SKILL.md +8 -6
- package/skills/weaver-e10-yimiaoban/references/msg-read.md +20 -0
- package/skills/weaver-e10-yimiaoban/references/msg-write.md +7 -0
- package/skills/weaver-e10-yimiaoban/references/source-manifest.json +18 -15
- package/dist/chunks/{ebuilder-form-I5ZIX4WO.js → ebuilder-form-CBYI6CQ6.js} +4 -4
|
@@ -0,0 +1,265 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
# -*- coding: utf-8 -*-
|
|
3
|
+
"""render_ebdf_list_card.py — 业绩核算六菜单 ebdf 列表组件卡生成器(2026-11-10)
|
|
4
|
+
|
|
5
|
+
为什么要有这个脚本:
|
|
6
|
+
业绩核算六个菜单以前用 `open_web` 在外部浏览器视图打开,用户拿不到 E10 列表组件。
|
|
7
|
+
现在统一改为 ebdf 列表页组件卡(fill_form + e10 + sdkOptions),字段名与 pageId 容易抄错,
|
|
8
|
+
因此全部固化在脚本里,模型不再手写卡片。
|
|
9
|
+
|
|
10
|
+
用法:
|
|
11
|
+
python scripts/render_ebdf_list_card.py --menu 直销合同 --origin https://xxx.cn \
|
|
12
|
+
--title "我的合同" --com-param field_846297265322574070=叶通 --out card.json
|
|
13
|
+
|
|
14
|
+
--menu / --page-id 二选一:菜单名(含别名)或直接给 pageId
|
|
15
|
+
--origin 必填,scheme+host,不带路径/query,不含 {baseUrl}
|
|
16
|
+
--title 卡片标题,默认取菜单名
|
|
17
|
+
--call-id 默认 ebdf-list-<菜单>-<YYYYMMDDHHmm>-01
|
|
18
|
+
--com-param 可重复,形如 field_<字段id>=<值>
|
|
19
|
+
--com-params-json 直接给 comParams 对象(与 --com-param 互斥)
|
|
20
|
+
--out 输出文件;省略则打印到 stdout
|
|
21
|
+
--print 写出后同时打印
|
|
22
|
+
|
|
23
|
+
退出码:0 自检全过;1 参数或自检失败。
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
import argparse
|
|
27
|
+
import datetime
|
|
28
|
+
import io
|
|
29
|
+
import json
|
|
30
|
+
import re
|
|
31
|
+
import sys
|
|
32
|
+
|
|
33
|
+
# 菜单 -> pageId(2026-11-10 用户确认,勿改)
|
|
34
|
+
MENU_PAGES = {
|
|
35
|
+
"直销合同": "881124906081886244",
|
|
36
|
+
"直销业绩": "846297265322576586",
|
|
37
|
+
"合同收款": "846297265322576589",
|
|
38
|
+
"项目验收": "846297265322576590",
|
|
39
|
+
"渠道订单": "881210951456350225",
|
|
40
|
+
"渠道订单-商务": "881211329321197671",
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
ALIASES = {
|
|
44
|
+
"e-cology合同": "直销合同",
|
|
45
|
+
"e-cology 合同": "直销合同",
|
|
46
|
+
"合同数据": "直销合同",
|
|
47
|
+
"直销合同数据": "直销合同",
|
|
48
|
+
"业绩": "直销业绩",
|
|
49
|
+
"个人业绩": "直销业绩",
|
|
50
|
+
"机构业绩": "直销业绩",
|
|
51
|
+
"大区业绩": "直销业绩",
|
|
52
|
+
"团队业绩": "直销业绩",
|
|
53
|
+
"合同收款信息": "合同收款",
|
|
54
|
+
"收款": "合同收款",
|
|
55
|
+
"验收": "项目验收",
|
|
56
|
+
"项目验收数据": "项目验收",
|
|
57
|
+
"渠道订单数据": "渠道订单",
|
|
58
|
+
"e-office合同": "渠道订单",
|
|
59
|
+
"e-teams合同": "渠道订单",
|
|
60
|
+
"渠道协议": "渠道订单-商务",
|
|
61
|
+
"e-office协议订单": "渠道订单-商务",
|
|
62
|
+
"商务渠道订单": "渠道订单-商务",
|
|
63
|
+
"渠道订单商务": "渠道订单-商务",
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
FIELD_KEY = re.compile(r"^field_\d+$")
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
def die(msg):
|
|
70
|
+
sys.stderr.write("[FAIL] %s\n" % msg)
|
|
71
|
+
return 1
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
def resolve_menu(raw):
|
|
75
|
+
name = (raw or "").strip()
|
|
76
|
+
if name in MENU_PAGES:
|
|
77
|
+
return name, MENU_PAGES[name], ""
|
|
78
|
+
if name in ALIASES:
|
|
79
|
+
real = ALIASES[name]
|
|
80
|
+
return real, MENU_PAGES[real], ""
|
|
81
|
+
hits = [k for k in MENU_PAGES if name and (name in k or k in name)]
|
|
82
|
+
if len(hits) == 1:
|
|
83
|
+
return hits[0], MENU_PAGES[hits[0]], ""
|
|
84
|
+
return None, None, "未知菜单 %r,可选:%s" % (raw, "、".join(MENU_PAGES))
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
def clean_origin(raw):
|
|
88
|
+
origin = (raw or "").strip().rstrip("/")
|
|
89
|
+
if not origin:
|
|
90
|
+
raise ValueError("缺少 origin")
|
|
91
|
+
if "{baseUrl}" in origin:
|
|
92
|
+
raise ValueError("origin 仍是占位符 {baseUrl}")
|
|
93
|
+
if not re.match(r"^https?://[^/]+$", origin):
|
|
94
|
+
raise ValueError("origin 只能是 scheme+host,不能带路径、query 或用户信息")
|
|
95
|
+
return origin
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
def parse_com_params(pairs, raw_json):
|
|
99
|
+
if pairs and raw_json:
|
|
100
|
+
raise ValueError("--com-param 与 --com-params-json 只能二选一")
|
|
101
|
+
params = {}
|
|
102
|
+
if raw_json:
|
|
103
|
+
try:
|
|
104
|
+
params = json.loads(raw_json)
|
|
105
|
+
except Exception as exc:
|
|
106
|
+
raise ValueError("--com-params-json 不是合法 JSON:%s" % exc)
|
|
107
|
+
if not isinstance(params, dict):
|
|
108
|
+
raise ValueError("--com-params-json 必须是对象")
|
|
109
|
+
for item in pairs or []:
|
|
110
|
+
if "=" not in item:
|
|
111
|
+
raise ValueError("--com-param 需要 key=value,收到 %r" % item)
|
|
112
|
+
k, v = item.split("=", 1)
|
|
113
|
+
params[k.strip()] = v
|
|
114
|
+
out = {}
|
|
115
|
+
for k, v in params.items():
|
|
116
|
+
if not FIELD_KEY.match(str(k)):
|
|
117
|
+
raise ValueError("条件键必须是 field_<字段id>,收到 %r" % k)
|
|
118
|
+
out[str(k)] = v if isinstance(v, str) else str(v)
|
|
119
|
+
return out
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+
def build(menu, page_id, origin, title, call_id, com_params):
|
|
123
|
+
path = "/list/%s" % page_id
|
|
124
|
+
return {
|
|
125
|
+
"version": 1,
|
|
126
|
+
"callId": call_id,
|
|
127
|
+
"toolId": "fill_form",
|
|
128
|
+
"arguments": {
|
|
129
|
+
"type": "e10",
|
|
130
|
+
"title": title,
|
|
131
|
+
"src": "%s/sp/ebdfpage/list/%s" % (origin, page_id),
|
|
132
|
+
"sdkRenderType": "inline",
|
|
133
|
+
"sdkOptions": {
|
|
134
|
+
"compName": "ui.CorsComponent",
|
|
135
|
+
"routerType": "MemoryRouter",
|
|
136
|
+
"routerProps_pc": {"initialEntries": [path]},
|
|
137
|
+
"routerProps_mobile": {"initialEntries": [path]},
|
|
138
|
+
"params_pc": {
|
|
139
|
+
"app": "@weapp/ebdfpage",
|
|
140
|
+
"compName": "TableViewList",
|
|
141
|
+
"noMDialog": True,
|
|
142
|
+
},
|
|
143
|
+
"params_mobile": {
|
|
144
|
+
"app": "@weapp/ebdfpage",
|
|
145
|
+
"compName": "MTableViewList",
|
|
146
|
+
"noMDialog": True,
|
|
147
|
+
},
|
|
148
|
+
"params": {
|
|
149
|
+
"pageId": page_id,
|
|
150
|
+
"comParams": com_params,
|
|
151
|
+
},
|
|
152
|
+
},
|
|
153
|
+
},
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
def self_check(card, page_id):
|
|
158
|
+
"""按 validate_action_card.py 的 ebdf 分支逐项核对,返回问题列表。"""
|
|
159
|
+
bad = []
|
|
160
|
+
a = card.get("arguments") or {}
|
|
161
|
+
so = a.get("sdkOptions") or {}
|
|
162
|
+
pp = so.get("params_pc") or {}
|
|
163
|
+
pm = so.get("params_mobile") or {}
|
|
164
|
+
par = so.get("params") or {}
|
|
165
|
+
rpc = so.get("routerProps_pc") or {}
|
|
166
|
+
rmb = so.get("routerProps_mobile") or {}
|
|
167
|
+
|
|
168
|
+
if card.get("version") != 1:
|
|
169
|
+
bad.append("version != 1")
|
|
170
|
+
if card.get("toolId") != "fill_form":
|
|
171
|
+
bad.append("toolId != fill_form")
|
|
172
|
+
if not card.get("callId"):
|
|
173
|
+
bad.append("callId 为空")
|
|
174
|
+
if a.get("type") != "e10":
|
|
175
|
+
bad.append("arguments.type != e10")
|
|
176
|
+
if a.get("sdkRenderType") != "inline":
|
|
177
|
+
bad.append("sdkRenderType != inline")
|
|
178
|
+
if "width" in a:
|
|
179
|
+
bad.append("ebdf 列表卡不应带 arguments.width")
|
|
180
|
+
if not (a.get("src") or "").endswith("/sp/ebdfpage/list/%s" % page_id):
|
|
181
|
+
bad.append("src 与 pageId 不一致")
|
|
182
|
+
if so.get("compName") != "ui.CorsComponent":
|
|
183
|
+
bad.append("sdkOptions.compName != ui.CorsComponent")
|
|
184
|
+
if so.get("routerType") != "MemoryRouter":
|
|
185
|
+
bad.append("routerType != MemoryRouter")
|
|
186
|
+
if pp.get("app") != "@weapp/ebdfpage" or pp.get("compName") != "TableViewList":
|
|
187
|
+
bad.append("params_pc 组件不对")
|
|
188
|
+
if pm.get("app") != "@weapp/ebdfpage" or pm.get("compName") != "MTableViewList":
|
|
189
|
+
bad.append("params_mobile 组件不对")
|
|
190
|
+
if pp.get("noMDialog") is not True or pm.get("noMDialog") is not True:
|
|
191
|
+
bad.append("noMDialog 未同时为 true")
|
|
192
|
+
if par.get("pageId") != page_id:
|
|
193
|
+
bad.append("params.pageId 与 pageId 不一致")
|
|
194
|
+
want = ["/list/%s" % page_id]
|
|
195
|
+
if rpc.get("initialEntries") != want or rmb.get("initialEntries") != want:
|
|
196
|
+
bad.append("initialEntries 与 pageId 不一致")
|
|
197
|
+
cp = par.get("comParams")
|
|
198
|
+
if not isinstance(cp, dict):
|
|
199
|
+
bad.append("comParams 不是对象")
|
|
200
|
+
else:
|
|
201
|
+
for k, v in cp.items():
|
|
202
|
+
if not FIELD_KEY.match(k):
|
|
203
|
+
bad.append("comParams 键格式错误:%r" % k)
|
|
204
|
+
if not isinstance(v, str):
|
|
205
|
+
bad.append("comParams 值不是字符串:%r" % k)
|
|
206
|
+
return bad
|
|
207
|
+
|
|
208
|
+
|
|
209
|
+
def main():
|
|
210
|
+
ap = argparse.ArgumentParser(description="生成业绩核算 ebdf 列表组件卡")
|
|
211
|
+
ap.add_argument("--menu")
|
|
212
|
+
ap.add_argument("--page-id", dest="page_id")
|
|
213
|
+
ap.add_argument("--origin", required=True)
|
|
214
|
+
ap.add_argument("--title")
|
|
215
|
+
ap.add_argument("--call-id", dest="call_id")
|
|
216
|
+
ap.add_argument("--com-param", dest="com_params", action="append", default=[])
|
|
217
|
+
ap.add_argument("--com-params-json", dest="com_params_json")
|
|
218
|
+
ap.add_argument("--out")
|
|
219
|
+
ap.add_argument("--print", dest="do_print", action="store_true")
|
|
220
|
+
args = ap.parse_args()
|
|
221
|
+
|
|
222
|
+
if args.page_id:
|
|
223
|
+
page_id = args.page_id.strip()
|
|
224
|
+
if not re.match(r"^\d{6,}$", page_id):
|
|
225
|
+
return die("pageId 必须是数字串,收到 %r" % page_id)
|
|
226
|
+
menu = args.menu or page_id
|
|
227
|
+
else:
|
|
228
|
+
menu, page_id, err = resolve_menu(args.menu)
|
|
229
|
+
if err:
|
|
230
|
+
return die(err)
|
|
231
|
+
|
|
232
|
+
try:
|
|
233
|
+
origin = clean_origin(args.origin)
|
|
234
|
+
com_params = parse_com_params(args.com_params, args.com_params_json)
|
|
235
|
+
except ValueError as exc:
|
|
236
|
+
return die(str(exc))
|
|
237
|
+
|
|
238
|
+
title = (args.title or menu).strip()
|
|
239
|
+
if not title:
|
|
240
|
+
return die("title 不能为空")
|
|
241
|
+
stamp = datetime.datetime.now().strftime("%Y%m%d%H%M")
|
|
242
|
+
call_id = args.call_id or "ebdf-list-%s-%s-01" % (menu, stamp)
|
|
243
|
+
|
|
244
|
+
card = build(menu, page_id, origin, title, call_id, com_params)
|
|
245
|
+
bad = self_check(card, page_id)
|
|
246
|
+
if bad:
|
|
247
|
+
for b in bad:
|
|
248
|
+
sys.stderr.write("[FAIL] %s\n" % b)
|
|
249
|
+
return 1
|
|
250
|
+
|
|
251
|
+
text = json.dumps(card, ensure_ascii=False, indent=2)
|
|
252
|
+
if args.out:
|
|
253
|
+
with io.open(args.out, "w", encoding="utf-8", newline="\n") as f:
|
|
254
|
+
f.write(text + "\n")
|
|
255
|
+
if args.do_print or not args.out:
|
|
256
|
+
print(text)
|
|
257
|
+
sys.stderr.write(
|
|
258
|
+
"[PASS] %s / pageId=%s / comParams=%d / callId=%s\n"
|
|
259
|
+
% (menu, page_id, len(com_params), call_id)
|
|
260
|
+
)
|
|
261
|
+
return 0
|
|
262
|
+
|
|
263
|
+
|
|
264
|
+
if __name__ == "__main__":
|
|
265
|
+
sys.exit(main())
|
|
@@ -90,8 +90,85 @@ def extract_outer_json(text):
|
|
|
90
90
|
return None
|
|
91
91
|
|
|
92
92
|
|
|
93
|
+
EBDF_LIST_MARK = "/sp/ebdfpage/list/"
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
def check_outer_ebdf(obj):
|
|
97
|
+
"""ebdf 列表页组件卡(业绩核算六菜单):纯组件,不渲染自定义 HTML。
|
|
98
|
+
|
|
99
|
+
与动作卡的区别:没有 customParams.html,组件名在 params_pc / params_mobile,
|
|
100
|
+
带 noMDialog,且不写 arguments.width。
|
|
101
|
+
"""
|
|
102
|
+
a = obj.get("arguments") or {}
|
|
103
|
+
so = a.get("sdkOptions") or {}
|
|
104
|
+
pp = so.get("params_pc") or {}
|
|
105
|
+
pm = so.get("params_mobile") or {}
|
|
106
|
+
par = so.get("params") or {}
|
|
107
|
+
rpc = so.get("routerProps_pc") or {}
|
|
108
|
+
rmb = so.get("routerProps_mobile") or {}
|
|
109
|
+
|
|
110
|
+
def eq(actual, expect, item):
|
|
111
|
+
if actual == expect:
|
|
112
|
+
add(PASS, item)
|
|
113
|
+
else:
|
|
114
|
+
add(FAIL, item, "expected %r, got %r" % (expect, actual))
|
|
115
|
+
|
|
116
|
+
eq(obj.get("version"), 1, "outer.version == 1")
|
|
117
|
+
if obj.get("callId"):
|
|
118
|
+
add(PASS, "outer.callId present")
|
|
119
|
+
else:
|
|
120
|
+
add(FAIL, "outer.callId present", "missing or empty")
|
|
121
|
+
eq(obj.get("toolId"), "fill_form", "outer.toolId == fill_form")
|
|
122
|
+
eq(a.get("type"), "e10", "arguments.type == e10 (not browsertool)")
|
|
123
|
+
eq(a.get("sdkRenderType"), "inline", "arguments.sdkRenderType == inline")
|
|
124
|
+
if "width" in a:
|
|
125
|
+
add(FAIL, "ebdf list card has no arguments.width",
|
|
126
|
+
"got %r -> use client default" % a.get("width"))
|
|
127
|
+
else:
|
|
128
|
+
add(PASS, "ebdf list card has no arguments.width")
|
|
129
|
+
|
|
130
|
+
src = a.get("src") or ""
|
|
131
|
+
m = re.search(r"/sp/ebdfpage/list/(\d+)", src)
|
|
132
|
+
page_id = m.group(1) if m else ""
|
|
133
|
+
if page_id:
|
|
134
|
+
add(PASS, "arguments.src -> /sp/ebdfpage/list/<pageId>")
|
|
135
|
+
else:
|
|
136
|
+
add(FAIL, "arguments.src -> /sp/ebdfpage/list/<pageId>", "got %r" % src)
|
|
137
|
+
|
|
138
|
+
eq(so.get("compName"), "ui.CorsComponent", "sdkOptions.compName == ui.CorsComponent")
|
|
139
|
+
eq(so.get("routerType"), "MemoryRouter", "sdkOptions.routerType == MemoryRouter")
|
|
140
|
+
eq(pp.get("app"), "@weapp/ebdfpage", "params_pc.app == @weapp/ebdfpage")
|
|
141
|
+
eq(pp.get("compName"), "TableViewList", "params_pc.compName == TableViewList")
|
|
142
|
+
eq(pm.get("app"), "@weapp/ebdfpage", "params_mobile.app == @weapp/ebdfpage")
|
|
143
|
+
eq(pm.get("compName"), "MTableViewList", "params_mobile.compName == MTableViewList")
|
|
144
|
+
eq(pp.get("noMDialog"), True, "params_pc.noMDialog == true")
|
|
145
|
+
eq(pm.get("noMDialog"), True, "params_mobile.noMDialog == true")
|
|
146
|
+
eq(par.get("pageId"), page_id, "params.pageId matches src pageId")
|
|
147
|
+
|
|
148
|
+
want = ["/list/%s" % page_id] if page_id else []
|
|
149
|
+
eq(rpc.get("initialEntries"), want, "routerProps_pc.initialEntries == /list/<pageId>")
|
|
150
|
+
eq(rmb.get("initialEntries"), want, "routerProps_mobile.initialEntries == /list/<pageId>")
|
|
151
|
+
|
|
152
|
+
cp = par.get("comParams")
|
|
153
|
+
if cp is None:
|
|
154
|
+
add(WARN, "params.comParams absent (no preset filter)")
|
|
155
|
+
elif not isinstance(cp, dict):
|
|
156
|
+
add(FAIL, "params.comParams is an object", "got %s" % type(cp).__name__)
|
|
157
|
+
else:
|
|
158
|
+
bad_keys = [k for k in cp if not re.match(r"^field_\d+$", str(k))]
|
|
159
|
+
if bad_keys:
|
|
160
|
+
add(FAIL, "comParams keys are field_<fieldId>", "bad: %r" % bad_keys)
|
|
161
|
+
elif any(not isinstance(v, str) for v in cp.values()):
|
|
162
|
+
add(FAIL, "comParams values are strings", "non-string value found")
|
|
163
|
+
else:
|
|
164
|
+
add(PASS, "comParams keys/values ok (%d)" % len(cp))
|
|
165
|
+
return None
|
|
166
|
+
|
|
167
|
+
|
|
93
168
|
def check_outer(obj, has_placeholder):
|
|
94
169
|
a = obj.get("arguments") or {}
|
|
170
|
+
if EBDF_LIST_MARK in (a.get("src") or ""):
|
|
171
|
+
return check_outer_ebdf(obj)
|
|
95
172
|
so = a.get("sdkOptions") or {}
|
|
96
173
|
pp = so.get("params_pc") or {}
|
|
97
174
|
rp = so.get("routerProps_pc") or {}
|
|
@@ -257,6 +334,8 @@ E10_COMP_EXPECT = (
|
|
|
257
334
|
("/sp/contract/business/credit", "ContractCreditDetail"),
|
|
258
335
|
("/sp/contract/business/ai-contract", "AIContractV2"),
|
|
259
336
|
("/sp/contract/business/doc-compare", "AIDocCompare"),
|
|
337
|
+
("/sp/contract/terms-library", "ClauseLibraryPage"),
|
|
338
|
+
("/sp/ebdfpage/list/", "TableViewList"),
|
|
260
339
|
("/sp/workflow/flowpage/create/", "Comp.WffpRoute"),
|
|
261
340
|
("/sp/contract/xiaoe-list", "XiaoeList"),
|
|
262
341
|
)
|
|
@@ -284,6 +363,10 @@ def check_e10sdk_comp(js):
|
|
|
284
363
|
|
|
285
364
|
m_pc = re.search(r"params\s*:\s*\{[^{}]*?compName\s*:\s*'([^']+)'", seg)
|
|
286
365
|
pc = m_pc.group(1) if m_pc else None
|
|
366
|
+
if pc is None:
|
|
367
|
+
# ebdf 列表卡的组件名在 params_pc / params_mobile,不在 params
|
|
368
|
+
m_pc2 = re.search(r"params_pc\s*:\s*\{[^{}]*?compName\s*:\s*'([^']+)'", seg)
|
|
369
|
+
pc = m_pc2.group(1) if m_pc2 else None
|
|
287
370
|
|
|
288
371
|
expected = None
|
|
289
372
|
for path, comp in E10_COMP_EXPECT:
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
"""合同 docx 占位符残留校验(XML 全量 + python-docx 双向交叉验证)。
|
|
3
|
+
|
|
4
|
+
2026-11-10 新增。背景(真实事故):
|
|
5
|
+
只遍历 python-docx 的 paragraphs / tables 时,文本框 <w:txbxContent> 里的内容
|
|
6
|
+
完全遍历不到。实测《新客户购买合同模板》的合同标题 2 处就位于文本框内,
|
|
7
|
+
于是自检报告「残留 0」,实际文件里仍是 xxx公司协同办公系统(e-cology)…
|
|
8
|
+
—— 差一步就把带占位符的合同交付给客户。
|
|
9
|
+
|
|
10
|
+
用法:
|
|
11
|
+
python verify_docx_placeholders.py --docx <绝对路径>
|
|
12
|
+
python verify_docx_placeholders.py --docx <绝对路径> --expect "xxx公司" --expect "***"
|
|
13
|
+
python verify_docx_placeholders.py --docx <绝对路径> --title "客户全称协同办公系统(e-cology)软件产品及实施服务购买合同"
|
|
14
|
+
|
|
15
|
+
退出码:
|
|
16
|
+
0 = 全部通过(无残留,且交叉验证一致)
|
|
17
|
+
1 = 有残留 / 交叉验证不一致 / 文件不可读
|
|
18
|
+
"""
|
|
19
|
+
import argparse
|
|
20
|
+
import io
|
|
21
|
+
import json
|
|
22
|
+
import re
|
|
23
|
+
import sys
|
|
24
|
+
import zipfile
|
|
25
|
+
|
|
26
|
+
import docx
|
|
27
|
+
|
|
28
|
+
DEFAULT_PATTERNS = ['xxx公司', 'XXX公司', '***', '年 月 日', '年 月 日', '【】', '____', '{{', '}}']
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
def xml_full_text(path):
|
|
32
|
+
"""读取 word/ 下所有 xml(正文、页眉页脚、批注、脚注),去标签后拼成全文。
|
|
33
|
+
|
|
34
|
+
文本框 <w:txbxContent> 就在 document.xml 内,只要不去掉该节点就能覆盖到。
|
|
35
|
+
"""
|
|
36
|
+
buf = []
|
|
37
|
+
with zipfile.ZipFile(path) as z:
|
|
38
|
+
for name in z.namelist():
|
|
39
|
+
if not name.startswith('word/') or not name.endswith('.xml'):
|
|
40
|
+
continue
|
|
41
|
+
raw = z.read(name).decode('utf-8', 'ignore')
|
|
42
|
+
buf.append(re.sub(r'<[^>]+>', '', raw))
|
|
43
|
+
return '\n'.join(buf)
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
def docx_visible_text(path):
|
|
47
|
+
"""python-docx 能看到的文本(用于与 XML 全量结果交叉比对)。"""
|
|
48
|
+
d = docx.Document(path)
|
|
49
|
+
buf = [p.text for p in d.paragraphs]
|
|
50
|
+
for t in d.tables:
|
|
51
|
+
for row in t.rows:
|
|
52
|
+
for c in row.cells:
|
|
53
|
+
buf.append(c.text)
|
|
54
|
+
return '\n'.join(buf)
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
def main():
|
|
58
|
+
ap = argparse.ArgumentParser(description='合同 docx 占位符残留校验')
|
|
59
|
+
ap.add_argument('--docx', required=True)
|
|
60
|
+
ap.add_argument('--expect', action='append', default=None,
|
|
61
|
+
help='需要检查残留的占位文本,可多次传;缺省用内置集合')
|
|
62
|
+
ap.add_argument('--title', default=None, help='应出现的合同名称,用于校验标题替换完整')
|
|
63
|
+
ap.add_argument('--title-count', type=int, default=None,
|
|
64
|
+
help='合同名称的期望出现次数(模板通常为 2:封面 + 正文首行)')
|
|
65
|
+
args = ap.parse_args()
|
|
66
|
+
|
|
67
|
+
patterns = args.expect or DEFAULT_PATTERNS
|
|
68
|
+
|
|
69
|
+
try:
|
|
70
|
+
full = xml_full_text(args.docx)
|
|
71
|
+
visible = docx_visible_text(args.docx)
|
|
72
|
+
except Exception as exc: # noqa: BLE001
|
|
73
|
+
print(json.dumps({'ok': False, 'error': 'unreadable_docx', 'detail': str(exc)},
|
|
74
|
+
ensure_ascii=False))
|
|
75
|
+
return 1
|
|
76
|
+
|
|
77
|
+
residue = {}
|
|
78
|
+
for p in patterns:
|
|
79
|
+
n = full.count(p)
|
|
80
|
+
if n:
|
|
81
|
+
residue[p] = n
|
|
82
|
+
|
|
83
|
+
# 交叉验证:XML 全量计数必须 >= python-docx 可见计数;
|
|
84
|
+
# 若可见计数反而更大,说明遍历方式本身有问题,结果不可信。
|
|
85
|
+
cross = {}
|
|
86
|
+
inconsistent = []
|
|
87
|
+
for p in patterns:
|
|
88
|
+
x, v = full.count(p), visible.count(p)
|
|
89
|
+
cross[p] = {'xml': x, 'docx': v}
|
|
90
|
+
if v > x:
|
|
91
|
+
inconsistent.append(p)
|
|
92
|
+
|
|
93
|
+
title_hits = full.count(args.title) if args.title else None
|
|
94
|
+
title_ok = True
|
|
95
|
+
if args.title:
|
|
96
|
+
expect_n = args.title_count if args.title_count is not None else 2
|
|
97
|
+
title_ok = (title_hits == expect_n)
|
|
98
|
+
|
|
99
|
+
ok = (not residue) and (not inconsistent) and title_ok
|
|
100
|
+
|
|
101
|
+
out = {
|
|
102
|
+
'ok': ok,
|
|
103
|
+
'docx': args.docx,
|
|
104
|
+
'residue': residue,
|
|
105
|
+
'cross_check': cross,
|
|
106
|
+
'inconsistent': inconsistent,
|
|
107
|
+
'title': args.title,
|
|
108
|
+
'title_hits': title_hits,
|
|
109
|
+
'title_ok': title_ok,
|
|
110
|
+
'note': ('通过:无占位符残留' if ok else
|
|
111
|
+
'不通过:见 residue / inconsistent / title_ok'),
|
|
112
|
+
}
|
|
113
|
+
print(json.dumps(out, ensure_ascii=False, indent=2))
|
|
114
|
+
return 0 if ok else 1
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
if __name__ == '__main__':
|
|
118
|
+
sys.exit(main())
|
|
@@ -5,7 +5,7 @@ display_name_en: Weaver E10 Meeting Management
|
|
|
5
5
|
description: "泛微 E10 会议管理:查会议、预约建会(推荐会议室、查冲突与空闲时段)、改期/改地点/改参会人、取消删除、流程建会、会议室查询与推荐、生成邀请函、读取会议附件、回执签到、纪要与决议任务、参会二维码。详见 description_zh。"
|
|
6
6
|
description_zh: "泛微 E10 会议管理:查询会议与详情、预约建会(自动推荐会议室、检测参会人冲突与日程空闲、楼层定位)、改期/换地点/改参会人、取消删除、流程建会、生成邀请函(可自动写入表单文档字段)、会议室查询与推荐、纪要/议题/决议、附件读取、回执签到、参会二维码。认证与会话由 weaver-e10-shared 提供。"
|
|
7
7
|
description_en: "Weaver E10 meeting management: [Meetings] query today/week/my meetings and details, book meetings with automatic room recommendation, attendee conflict and calendar-availability checks (plus same-day alternative slots), reschedule / change room / change attendees, cancel, delete; flow-based booking with automatic invitation when the app only allows workflow creation; [Rooms] occupancy queries and smart recommendation by capacity, equipment and personal usage; [Invitation] generate invitation docx from real meeting data; [Content] list and read meeting/topic attachments and extract document text; receipts, sign-in, minutes, topics, decisions and decision tasks; [QR] render text into attendee/sign-in QR images. Auth and session are provided by weaver-e10-shared."
|
|
8
|
-
version: 2.55.
|
|
8
|
+
version: 2.55.15
|
|
9
9
|
author: 泛微网络科技股份有限公司
|
|
10
10
|
agent_created: true
|
|
11
11
|
requires:
|
|
@@ -17,8 +17,18 @@ cliHelp: "weaver-work-cli meeting --help"
|
|
|
17
17
|
|
|
18
18
|
# 泛微 E10 会议管理 Skill(双模式:标准版 + EB 版)
|
|
19
19
|
|
|
20
|
-
**CRITICAL —
|
|
21
|
-
|
|
20
|
+
**CRITICAL — 共享规则前置(按需触发)**:本技能默认不预读共享规则以省一轮调用,但**共享规则缺失即依赖缺失**:`weaver-work-cli` 未安装(`command not found`)、共享 skill `weaver-e10-shared` 读不到、或用户明确询问安装/认证/JSON 输出时,必须调用宿主提供的提问/确认弹框,向用户说明必须补齐 `weaver-work-cli` 与共享 skill `weaver-e10-shared`(不补齐本技能无法执行)及补齐计划,并把下面两条待执行命令原样完整展示在确认信息中;Agent 不能在未确认时自行安装。用户明确确认后,Agent 必须直接代为按顺序执行且每条仅执行一次,不得要求或引导用户手动执行:① 缺 CLI 时执行 `npm install -g weaver-work-cli`;② 再执行 `weaver-work-cli skills install shared --target-dir <SKILLS_ROOT>` 装回共享 skill,`<SKILLS_ROOT>` 取本 SKILL.md 所在目录的上一级绝对目录(即与本技能同级的 skills 根目录),**不要省略** `--target-dir`——省略会装进默认目录,导致本技能依然读不到共享规则。命令均成功后重新读取共享规则;仍读不到就停止并把结果报告用户,不得凭猜测继续。
|
|
21
|
+
|
|
22
|
+
**直接执行业务命令,不要先做"环境体检"。只有下面三种情况才读 [`../weaver-e10-shared/SKILL.md`](../weaver-e10-shared/SKILL.md)**:
|
|
23
|
+
① CLI 不存在 / 报 `command not found`;② CLI 报 `auth not found`、`session_expired` 且底层自动换票失败;③ 用户明确问安装、认证、JSON 输出格式。
|
|
24
|
+
⛔ 正常会话**不要**为了"确认环境"预先读 shared —— 会多一次工具调用和一轮思考(实测首轮 +5 秒)。
|
|
25
|
+
读不到 shared / CLI 缺失 = 依赖缺失:用宿主确认弹框告知用户,并把两条命令**原样展示**,经用户确认后由你代为执行(每条仅一次,不要让用户手敲):
|
|
26
|
+
① `npm install -g weaver-work-cli`;② `weaver-work-cli skills install shared --target-dir <SKILLS_ROOT>`(`<SKILLS_ROOT>` = 本文件所在目录的上一级,不能省 `--target-dir`)。执行后重读;仍读不到就停止并报告,不得凭猜继续。
|
|
27
|
+
`--is-connector`:用户级 Skill(条目标 `(user)`)不传;连接器级(标 `(connector)`)传 `true`,此时不要再写 `--profile` / `--base-url`。完整规则见 shared。
|
|
28
|
+
|
|
29
|
+
⛔ **已有会话时禁止确认登录**:不要执行 `auth xiaoe` / `auth status` / `auth login`。
|
|
30
|
+
CLI 能正常返回业务结果 = 登录有效;只有返回 `auth not found` / `session_expired`(且底层换票失败)才处理登录。
|
|
31
|
+
首轮直接调业务 operation(查占用用 `conflict.room`、建会用 `create.flow.prepare`),不要先"探一下环境"。
|
|
22
32
|
|
|
23
33
|
凭证边界:所有 E10 调用凭证一律由 `weaver-work-cli` 的登录托管凭据(`auth` 命令/profile 体系)提供,禁止硬编码任何密钥,禁止向用户索取 Cookie、ETEAMSID、Token 或密码。
|
|
24
34
|
已有 XiaoE 会话返回 `session_expired` 时,CLI 已在底层自动换票并重放一次;Agent 不得再执行登录命令、调用其他登录 Skill 或重复业务命令,只反馈最终错误。仅首次无会话或明确的 `auth not found` 才读取共享认证规则:XiaoE 执行一次 `weaver-work-cli auth xiaoe`,若返回 `xiaoe_credential_unavailable` 则停止;非 XiaoE 在取得真实 E10 域名后执行 `weaver-work-cli auth login --base-url "<用户确认的 E10 登录域名>" --agent_type "<当前智能体名称>"`。显式登录后写操作不得复用旧 continuation,必须重新 prepare 和确认。
|
|
@@ -33,6 +43,8 @@ cliHelp: "weaver-work-cli meeting --help"
|
|
|
33
43
|
**人数自动算**:用户说「他们来 X 人」→ 传 `crm_member_count: X`;说「我们 Y 人」但**没给姓名** → 传 `our_member_count: Y`,
|
|
34
44
|
**不要追问"另外几位是谁"**(用户明确要求:说了人数就按人数填)。总人数 = 我方 + 客户,CLI 自动算,不要手填 `total_member`。
|
|
35
45
|
只有用户直接说"总共 N 人"才传 `total_member: N`;用户主动给了姓名才放进 `hrm_members`。
|
|
46
|
+
✅ **"只有参会人数、没有参会人员名单"是完全合法的输入**(客户来访常见,甚至一个名字都没有):
|
|
47
|
+
按人数填、不要追问、不要提示"名单缺失",也不要因此卡住提交。
|
|
36
48
|
- **时间**:只说「上午 / 下午 / 晚上」→ 直接传 `{"dateFrom":"YYYY-MM-DD","time_slot":"上午"}`(上午 09:00–12:00 / 下午 13:00–18:00 / 晚上 18:00–21:00),**不要**再弹时段候选;连日期都没有时 `prepare` 会返回 `slot` 选项,用选项卡让用户点。
|
|
37
49
|
- **地点**:没指定 → CLI 按推荐算法**直接定一间**(说「3 楼 / 一楼」也直接取该层第一名),不要弹选择框;只有该时段无空闲房(`room_unavailable`)或显式 `askRoom: true` 才给候选。
|
|
38
50
|
**用户提了设备(投影仪/视频/白板)→ 必须传 `equipments:"投影"`**,让筛选在推荐阶段完成;⛔ 不许先按楼层选一间、再回头问用户"这间没有投影行不行"。
|
|
@@ -50,7 +62,7 @@ cliHelp: "weaver-work-cli meeting --help"
|
|
|
50
62
|
|
|
51
63
|
一句话:**能查的别问、能推的别让人填、要选的给选项卡**。
|
|
52
64
|
|
|
53
|
-
⛔
|
|
65
|
+
⛔ **一次预检就够,禁止重复预检**(历史事故见 pitfalls#P20):
|
|
54
66
|
- 拿到 `AWAITING_CONFIRMATION` 后,**直接 `apply`**,不要"再确认一遍时间/房间"重新 `prepare`;
|
|
55
67
|
- 只有用户改了四要素(时间/地点/参会人/客户)才重跑 `prepare`;
|
|
56
68
|
- 提交时优先传 **`continuationId`**(8 位短 id),不要手抄那串长 `continuation`——模型转述时容易截断,导致"凭证失效"再预检一次。
|
|
@@ -113,6 +125,21 @@ cliHelp: "weaver-work-cli meeting --help"
|
|
|
113
125
|
⛔ **禁止**「room.list 找 id → roomUsage.list 查占用」两步走:room.list 名称查询 4s、全天占用 9s,
|
|
114
126
|
再叠加反复翻页,就是你看到的 **6 次调用 / 92 秒**。
|
|
115
127
|
⛔ 也别先 `room.list` 确认房间存在——`conflict.room` 内部会解析,找不到会直接报错。
|
|
128
|
+
- **「我们部门所有人 / 某部门 / 某分部 / 模糊部门名」→ 一次 **(2.55.10):
|
|
129
|
+
\\n 返回 / (直接传给 )/ / 。
|
|
130
|
+
- 多个部门 → (并集去重);分部自动展开其下部门。
|
|
131
|
+
- 模糊名命中多个 → + :**做选项让用户点**,不要自己挑。
|
|
132
|
+
- 实测:命中缓存 <1s,首次 2~5s,分部(69 个部门)约 9s。
|
|
133
|
+
⛔ **禁止 不带条件**(会拉全公司分页,实测 51 秒);也不要先查全公司再本地筛。
|
|
134
|
+
- **「我们部门所有人 / 某部门 / 某分部 / 模糊部门名」→ 一次 `meeting.member.expand`**(2.55.10):
|
|
135
|
+
```bash
|
|
136
|
+
weaver-work-cli --json meeting run meeting.member.expand --input-json '{"keyword":"会议模块组"}'
|
|
137
|
+
```
|
|
138
|
+
返回 `members` / `membersCsv`(直接传给 `hrm_members`)/ `memberNames` / `ambiguous`。
|
|
139
|
+
- 多个部门 → `{"keywords":["会议模块组","产品研发中心"]}`(并集去重);分部自动展开其下部门。
|
|
140
|
+
- 模糊名命中多个 → `ambiguous:true` + `candidates`:**做成选项让用户点**,不要自己挑。
|
|
141
|
+
- 实测:缓存命中 <1s,首次 2~5s,分部(69 个部门)约 9s。
|
|
142
|
+
⛔ **禁止 `hrm.employee.query` 不带条件**(会拉全公司分页,实测 51 秒),也不要先查全公司再本地筛。
|
|
116
143
|
- 「今天的会议 / 下一个会」→ `meeting.eb.meeting.list`(`filterDate` 客户端过滤;接口 body 过滤实测不生效,不要现场试 body)。
|
|
117
144
|
- 「会议室占用 / 空闲 / 推荐」→ `meeting.eb.room.recommend`(按人数/常用/时段占用排序,带理由);
|
|
118
145
|
**带客户时**(用户话里出现「接待/招待/贵宾/客户来访」或传了 `crm_members`)会自动给接待类会议室
|
|
@@ -254,6 +281,7 @@ warnings 里会写「沿用你上次确认的…」——**看到这句就不要
|
|
|
254
281
|
| 决议 / 任务 | `eb.decision.list/detail/create/update/delete/publish`、`eb.decisionTask.list/update/create/delete`、`meeting.decision.notifyGroup` |
|
|
255
282
|
| 类型 / 应用设置 | `eb.type.list/create/delete`、`eb.baseSet.get`(建会时不用先查,`create.flow.prepare` 内部会读) |
|
|
256
283
|
| 邀请函 / 二维码 | `meeting.invitation.render`、`meeting.qrcode.render` |
|
|
284
|
+
| 人员 / 部门展开 | `meeting.member.expand`(部门/分部/模糊名 → 员工 id 列表,30 天缓存) |
|
|
257
285
|
| 详情页链接 | `meeting.link`(按 `type` 解析 objid,**禁止手工拼 URL**) |
|
|
258
286
|
| 一条命令跑完 | `meeting.pipeline.run`(群聊→纪要→文档→决议→任务→推群) |
|
|
259
287
|
|
|
@@ -338,7 +366,7 @@ warnings 里会写「沿用你上次确认的…」——**看到这句就不要
|
|
|
338
366
|
⛔ **CLI 不再建群**:ESB 已在流程提交时建群并发提醒,`create.flow` 默认**跳过建群**。
|
|
339
367
|
只有没有 ESB 的环境才传 `createGroupChat: true` 让 CLI 建群。别再提示用户"群已建好"。
|
|
340
368
|
|
|
341
|
-
✅ **邀请函默认自动生成并写进表单**:**只有关联了客户(`crm_members`
|
|
369
|
+
✅ **邀请函默认自动生成并写进表单**:**只有关联了客户(`crm_members` 非空)才生成**(用户明确:没有客户就不要要邀请函)。
|
|
342
370
|
关联客户时,`create.flow.prepare` 会自动(表单有「邀请函」Document 字段时)渲染 docx → 上传到文档中心(目录 300)→ 把 `[{id,name}]` 写进该字段,warnings 里会写
|
|
343
371
|
「邀请函已生成文档并写入表单:xxx(docId …)」。同会议名 30 分钟内复用同一篇文档,不会重复建。
|
|
344
372
|
⛔ **无客户时**:不生成文档、不在对话里贴邀请函正文、表单「邀请函」字段保持为空,也不要问用户"要不要邀请函"。
|
|
@@ -661,7 +689,11 @@ weaver-work-cli --json meeting run meeting.eb.meeting.create.flow.apply \
|
|
|
661
689
|
|
|
662
690
|
**必须遵守的几条**
|
|
663
691
|
|
|
664
|
-
-
|
|
692
|
+
- **信息齐全就直接提交,不要再插一轮"确认摘要"**(用户明确要求:该有的信息都有了,直接发流程表单):
|
|
693
|
+
名称 + 时间(明确,或"上午/下午/晚上"可按固定区间展开)+ 地点(明确,或可按推荐自动定)+ 参会人(明确,或默认本人)都齐、
|
|
694
|
+
且无冲突/无歧义 → **直接调 `create.flow.quick`**(默认 `submit_mode=browser`),把返回的 `finalMarkdown` 表单贴出来即可。
|
|
695
|
+
⛔ 不要再写一张"提交前请确认以下内容"的表等用户回"提交" —— **表单本身就是核对界面**。
|
|
696
|
+
只有这三种情况才走 `prepare` 并停下来问:① 缺关键要素(没说时间档 / 部门名或客户名有多个候选);② 有冲突需要用户拍板;③ 用户明确说"先给我看看 / 别提交"。
|
|
665
697
|
- **邀请函是预置函**:apply 后无论会议是否生成都有 `filePath` + `text`;`text` **必须全文贴在回复里**(⛔ 不要只说"没有邀请函"或只给路径)。审批通过后可用 `meeting.invitation.render --mtId` 出完整版。
|
|
666
698
|
- **邀请函文档自动写进表单**(2.52.0):表单有「邀请函」Document 字段时,prepare 会渲染 docx → 上传文档中心 → 写入 `[{id,name}]`,返回 `preview.invitationDoc`;同会议 7 天内复用同一篇。不想生成传 `invitation_doc: false`。
|
|
667
699
|
- **议程由你自己分析**(名称 + 内容 → 3~6 条,`安排|内容|时间`),传 `agenda`;会议有议题时以议题为准。
|
|
@@ -738,7 +770,7 @@ weaver-work-cli --json meeting run meeting.eb.room.recommend \
|
|
|
738
770
|
|
|
739
771
|
- 排序:**个人常用**(近 180 天我建会用过的)> 满足要求 > 容量贴合(不浪费大间)> 名称稳定;
|
|
740
772
|
- 硬过滤:`status=0`(封存的不推)、容量上下限、`nameKeyword`(会议室名称)、`mrType/roomAttr/equipmentsKeyword`、该时段已被占用(`includeBusy:true` 可一并返回并排在最后);
|
|
741
|
-
- **「某间会议室某时段有没有被占」→ 一次 `meeting.eb.conflict.room
|
|
773
|
+
- **「某间会议室某时段有没有被占」→ 一次 `meeting.eb.conflict.room`**:
|
|
742
774
|
```bash
|
|
743
775
|
weaver-work-cli --json meeting run meeting.eb.conflict.room \
|
|
744
776
|
--input-json '{"room_name":"317","beginDatetime":"2026-11-09 18:00","endDatetime":"2026-11-09 21:00"}'
|