weaver-work-cli 0.1.62 → 0.1.63
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-S2VKZWQ3.js → archive-BLDYBZDX.js} +5 -4
- package/dist/chunks/{archive-oa-HEDSIUUY.js → archive-oa-3GJ3TWXR.js} +5 -4
- package/dist/chunks/{asset-HYH4W357.js → asset-AFXJN4CK.js} +5 -4
- package/dist/chunks/{asset-idle-N7REBNGL.js → asset-idle-VUJXWGWJ.js} +5 -4
- package/dist/chunks/{attachment-content-VYYA75FR.js → attachment-content-VMJA7NSQ.js} +3 -3
- package/dist/chunks/{blog-SLMZZICV.js → blog-EREB35VU.js} +5 -4
- package/dist/chunks/{caizhilian-RV43KKBT.js → caizhilian-ATM2JO5S.js} +5 -5
- package/dist/chunks/{calendar-DMVZ4OLY.js → calendar-E26ZIH7S.js} +5 -4
- package/dist/chunks/{chunk-6XSSAUNW.js → chunk-4OB22YKE.js} +48 -12
- package/dist/chunks/{chunk-UBGWIXU3.js → chunk-5CY37VLS.js} +131 -38
- package/dist/chunks/{chunk-EGANE35F.js → chunk-6G2JARDK.js} +1 -1
- package/dist/chunks/{chunk-WIWDVETN.js → chunk-6VCQLZXE.js} +75 -76
- package/dist/chunks/{chunk-E5YD5JWR.js → chunk-BY3WDJO5.js} +1 -1
- package/dist/chunks/{chunk-IW7A2IQY.js → chunk-C4YQJFZV.js} +43 -15
- package/dist/chunks/{chunk-BQYX2UX5.js → chunk-C5PIGPGX.js} +5 -3
- package/dist/chunks/{chunk-UBRWONP4.js → chunk-EOZHSNND.js} +2 -2
- package/dist/chunks/{chunk-UQFPF4EX.js → chunk-G3ZM57PD.js} +2 -2
- package/dist/chunks/{chunk-XT77MP54.js → chunk-GOBNIGWS.js} +410 -24
- package/dist/chunks/{chunk-KY3R42RS.js → chunk-GQK6WLOS.js} +5 -3
- package/dist/chunks/{chunk-BIA2NKUG.js → chunk-HEJPVXD3.js} +5 -5
- package/dist/chunks/{chunk-ILALC2N6.js → chunk-I4C2KR2G.js} +1 -1
- package/dist/chunks/{chunk-YI2YMW5N.js → chunk-IGICM3WJ.js} +2 -2
- package/dist/chunks/chunk-IN6NXQ26.js +680 -0
- package/dist/chunks/{chunk-VBFBMM7G.js → chunk-LOVAIGM2.js} +387 -70
- package/dist/chunks/{chunk-H6YOMI3U.js → chunk-OMAGCLUE.js} +5 -3
- package/dist/chunks/{chunk-VNYOUAWV.js → chunk-QAMIIFP6.js} +11 -11
- package/dist/chunks/{chunk-QBDXJS2W.js → chunk-QZYKZ7MQ.js} +16 -8
- package/dist/chunks/{chunk-V2LASYKO.js → chunk-RR45ELVE.js} +30 -24
- package/dist/chunks/{chunk-NRYDJN4J.js → chunk-RV2JAA5I.js} +89 -8
- package/dist/chunks/{chunk-TEZHIB6T.js → chunk-SDPC7BG2.js} +5 -3
- package/dist/chunks/{chunk-T2KVJFWJ.js → chunk-SHBDXEUE.js} +4 -7
- package/dist/chunks/{chunk-P6TXQK75.js → chunk-THMBDCRA.js} +5 -3
- package/dist/chunks/chunk-TJN4PIYO.js +47 -0
- package/dist/chunks/{chunk-DTCQFTHW.js → chunk-TNFIUZ4H.js} +3 -3
- package/dist/chunks/{chunk-JFAWZX53.js → chunk-UPVAQJKS.js} +282 -131
- package/dist/chunks/{chunk-KXJA42EA.js → chunk-WPBZQVLS.js} +1 -1
- package/dist/chunks/{conflict-GFJRS6I7.js → conflict-AMNTM3FV.js} +2 -2
- package/dist/chunks/{contract-U3ZGNRWB.js → contract-PLO2V2NO.js} +2333 -4426
- package/dist/chunks/{cowork-EX7PKIDK.js → cowork-FZAXE6FO.js} +5 -4
- package/dist/chunks/{create-flow-EJZD434E.js → create-flow-2DAUN7HU.js} +16 -6
- package/dist/chunks/{data-FOODGAMF.js → data-7NXMWET4.js} +3 -3
- package/dist/chunks/{ebuilder-form-I2EOKODG.js → ebuilder-form-DEYHX6M7.js} +4 -4
- package/dist/chunks/{ehr-TE4RFNID.js → ehr-QQH2DYYA.js} +244 -151
- package/dist/chunks/{employee-DR5Y64TI.js → employee-PGMY6NI6.js} +1 -1
- package/dist/chunks/{entry-mode-ZOLSXEGX.js → entry-mode-2JTVEKMP.js} +3 -3
- package/dist/chunks/{env-TID5NFR6.js → env-2JZMXC6I.js} +2 -2
- package/dist/chunks/{esb-7L6MHYLB.js → esb-I5ZFHJUK.js} +8 -8
- package/dist/chunks/{factory-OG7BPMH5.js → factory-XIATYHU6.js} +1 -1
- package/dist/chunks/{fna-6V2ENR3Y.js → fna-3V2TL6B2.js} +5 -4
- package/dist/chunks/{group-chat-5DKPWIHL.js → group-chat-CVYUZCOQ.js} +3 -3
- package/dist/chunks/{host-TJ5VVHM7.js → host-4DP7C7YQ.js} +4 -4
- package/dist/chunks/{host-3DLYA54R.js → host-4KQCAEWA.js} +4 -4
- package/dist/chunks/{host-ONZC6AE7.js → host-4X2F3JPQ.js} +4 -4
- package/dist/chunks/{host-OGBHL75G.js → host-BD7NAM33.js} +4 -4
- package/dist/chunks/{host-VTPAWDZV.js → host-CBONEAZS.js} +4 -4
- package/dist/chunks/{host-GOJHHTPY.js → host-L37QVNIV.js} +4 -4
- package/dist/chunks/{hrm-2N7NFQDZ.js → hrm-OL3IKN7C.js} +6 -6
- package/dist/chunks/{im-XCH47ZBN.js → im-YXQWUF3R.js} +4 -4
- package/dist/chunks/{invoice-5KJ7T774.js → invoice-4WY32PR2.js} +4 -4
- package/dist/chunks/{jiuchuanhui-PL6DRPBM.js → jiuchuanhui-L6SHLONH.js} +5 -4
- package/dist/chunks/{lazy-dispatch-UATEN7H7.js → lazy-dispatch-OYE6QV24.js} +5 -5
- package/dist/chunks/{mail-Q7Z4CQ4D.js → mail-PZV2KNRU.js} +5 -4
- package/dist/chunks/{meeting-5E3BNARL.js → meeting-6SOBCC6N.js} +16 -15
- package/dist/chunks/{minute-doc-NXRE5C77.js → minute-doc-KSJSJNOH.js} +4 -4
- package/dist/chunks/{okr-3O3XNYOK.js → okr-B76FW5M2.js} +5 -4
- package/dist/chunks/{operations-EZWG72FH.js → operations-YOMEGFLV.js} +5 -5
- package/dist/chunks/{performance-Y7CPNSOR.js → performance-4VBKUPFO.js} +5 -4
- package/dist/chunks/{plan-BLGPZF5M.js → plan-HBNZRQTI.js} +5 -4
- package/dist/chunks/{project-6MZMLJMP.js → project-IV6FWK74.js} +5 -4
- package/dist/chunks/{reception-F2VT2X52.js → reception-BR5YURT6.js} +3 -3
- package/dist/chunks/{recruit-stage-4ETIBMIW.js → recruit-stage-4HQ6OGXT.js} +654 -336
- package/dist/chunks/{registry-I4DVPDMU.js → registry-7LICMV5J.js} +12 -12
- package/dist/chunks/{registry-3FYSWV3U.js → registry-JFQEFC7E.js} +3 -3
- package/dist/chunks/{registry-3UGIWH53.js → registry-JMNOXRST.js} +2 -2
- package/dist/chunks/{registry-7RS74TCK.js → registry-MZJQX65Q.js} +5 -5
- package/dist/chunks/{room-recommend-GWCVKCXW.js → room-recommend-43GLLE7Y.js} +4 -4
- package/dist/chunks/{schedule-6AN63MJQ.js → schedule-ZQ42BEW6.js} +4 -4
- package/dist/chunks/{smart-extract-SR4SJJKN.js → smart-extract-QKAEAZGM.js} +3 -3
- package/dist/chunks/{workflow-KF7FA2UQ.js → workflow-6HV7H5PC.js} +10 -7
- package/dist/index.js +34 -34
- package/dist/internal/e10/auth/commands.js +21 -1
- package/dist/internal/e10/auth/xiaoe.js +6 -2
- package/dist/internal/e10/auth-recovery.js +28 -2
- package/dist/internal/e10/request-runtime.js +15 -3
- package/dist/internal/e10/request-trace.js +65 -0
- package/dist/shortcuts/contract/data/metric-catalog.js +149 -0
- package/dist/shortcuts/contract/index.js +14 -39
- package/dist/shortcuts/contract/manifest.js +115 -270
- package/dist/shortcuts/contract/operations/compare-report.js +437 -0
- package/dist/shortcuts/contract/operations/compare.js +2 -0
- package/dist/shortcuts/contract/operations/first-screen.js +96 -207
- package/dist/shortcuts/contract/operations/flow.js +19 -1
- package/dist/shortcuts/contract/operations/{card-ebdf-list.js → ledger-card.js} +98 -25
- package/dist/shortcuts/contract/operations/ledger.js +315 -1
- package/dist/shortcuts/contract/operations/metrics.js +93 -0
- package/dist/shortcuts/contract/operations/modeltext.js +3 -3
- package/dist/shortcuts/contract/operations/page.js +8 -4
- package/dist/shortcuts/contract/operations/performance.js +53 -0
- package/dist/shortcuts/contract/operations/quote-recognize.js +289 -0
- package/dist/shortcuts/contract/operations/quote-submit.js +264 -0
- package/dist/shortcuts/contract/operations/recommend.js +42 -1
- package/dist/shortcuts/contract/operations/registry.js +16 -23
- package/dist/shortcuts/contract/operations/{card-risk-report.js → review-report.js} +24 -114
- package/dist/shortcuts/contract/operations/review.js +33 -167
- package/dist/shortcuts/contract/operations/save-recognize.js +173 -43
- package/dist/shortcuts/contract/operations/triage.js +13 -6
- package/dist/shortcuts/contract/operations/{template.js → type-clause-read.js} +10 -25
- package/dist/shortcuts/contract/operations/upload.js +17 -11
- package/dist/shortcuts/contract/prewarm-cache.js +6 -2
- package/dist/shortcuts/contract/prewarm.js +33 -23
- package/dist/shortcuts/contract/recommend-cache.js +191 -0
- package/dist/shortcuts/ehr/operations/recruit-interview-overview.js +85 -62
- package/dist/shortcuts/ehr/operations/recruit-position.js +21 -13
- package/dist/shortcuts/ehr/operations/recruit-short-cache.js +59 -0
- package/dist/shortcuts/ehr/operations/recruit-tag.js +17 -11
- package/dist/shortcuts/ehr/operations/recruit-write.js +118 -70
- package/dist/shortcuts/ehr/operations/recruit.js +338 -121
- package/dist/shortcuts/hrm/operations/employee.js +64 -17
- package/dist/shortcuts/hrm/operations/resolve.js +419 -369
- package/dist/shortcuts/im/host.js +38 -22
- package/dist/shortcuts/meeting/operations/eb/conflict.js +60 -2
- package/dist/shortcuts/meeting/operations/eb/create-flow.js +116 -7
- package/dist/shortcuts/meeting/operations/eb/create-form-link.js +380 -0
- package/dist/shortcuts/meeting/operations/eb/index.js +2 -0
- package/dist/shortcuts/meeting/operations/eb/room-recommend.js +1 -3
- package/dist/shortcuts/recruit-stage/batch-store.js +44 -0
- package/dist/shortcuts/recruit-stage/context.js +75 -9
- package/dist/shortcuts/recruit-stage/manifest.js +1 -1
- package/dist/shortcuts/recruit-stage/operations/jd-create.js +33 -22
- package/dist/shortcuts/recruit-stage/operations/list.js +187 -37
- package/dist/shortcuts/recruit-stage/operations/registry.js +2 -0
- package/dist/shortcuts/recruit-stage/operations/resume-import.js +231 -313
- package/dist/shortcuts/recruit-stage/operations/search.js +5 -5
- package/dist/shortcuts/recruit-stage/operations/tag.js +286 -0
- package/dist/shortcuts/workflow/endpoints.js +2 -0
- package/dist/shortcuts/workflow/operations/form.js +12 -15
- package/dist/shortcuts/workflow/operations/read.js +8 -8
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoListRows.js +3 -2
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.collect.js +7 -6
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.core.js +4 -3
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.group.js +1 -0
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.js +33 -6
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.prepareQuery.js +153 -0
- package/dist/shortcuts/workflow/operations/todoSmartConvert/workflowClarification.js +232 -0
- package/dist/shortcuts/workflow/operations.js +5 -0
- package/docs/contract.md +2 -2
- package/docs/e10-auth.md +28 -0
- package/docs/ehr.md +1 -1
- package/package.json +1 -1
- package/skills/weaver-e10-hrm/SKILL.md +3 -3
- package/skills/weaver-e10-hrm/references/employee.md +13 -2
- package/skills/weaver-e10-jinchengda/SKILL.md +237 -347
- package/skills/weaver-e10-jinchengda/references/contract-agent-entry.md +7 -14
- package/skills/weaver-e10-jinchengda/references/contract-ai-assistant.md +21 -12
- package/skills/weaver-e10-jinchengda/references/contract-ai-review.md +109 -185
- package/skills/weaver-e10-jinchengda/references/contract-clause-insert.md +12 -4
- package/skills/weaver-e10-jinchengda/references/contract-clause-library-crud.md +28 -20
- package/skills/weaver-e10-jinchengda/references/contract-clause-recommender.md +12 -17
- package/skills/weaver-e10-jinchengda/references/contract-clause-reference-save.md +7 -13
- package/skills/weaver-e10-jinchengda/references/contract-command-index.md +21 -12
- package/skills/weaver-e10-jinchengda/references/contract-compare-report-template.html +10 -18
- package/skills/weaver-e10-jinchengda/references/contract-compare-report.md +18 -17
- package/skills/weaver-e10-jinchengda/references/contract-credit-page.md +114 -61
- package/skills/weaver-e10-jinchengda/references/contract-disabled-capabilities.md +8 -2
- package/skills/weaver-e10-jinchengda/references/contract-doc-compare.md +73 -104
- package/skills/weaver-e10-jinchengda/references/contract-doc-triage.md +32 -37
- package/skills/weaver-e10-jinchengda/references/contract-element-extract.md +12 -10
- package/skills/weaver-e10-jinchengda/references/contract-element-save-record.md +70 -82
- package/skills/weaver-e10-jinchengda/references/contract-execution-rules.md +37 -33
- package/skills/weaver-e10-jinchengda/references/contract-field-extract-new-customer.md +94 -27
- package/skills/weaver-e10-jinchengda/references/contract-field-extract-other-flows.md +5 -5
- package/skills/weaver-e10-jinchengda/references/contract-flow-launch.md +9 -15
- package/skills/weaver-e10-jinchengda/references/contract-ledger-catalog.md +9 -4
- package/skills/weaver-e10-jinchengda/references/contract-ledger-query-playbook.md +59 -32
- package/skills/weaver-e10-jinchengda/references/contract-ledger-rules.md +7 -5
- package/skills/weaver-e10-jinchengda/references/contract-modeltext-library.md +21 -13
- package/skills/weaver-e10-jinchengda/references/contract-multi-file.md +13 -13
- package/skills/weaver-e10-jinchengda/references/contract-object-detect.md +6 -5
- package/skills/weaver-e10-jinchengda/references/contract-open-web-pages.md +250 -0
- package/skills/weaver-e10-jinchengda/references/contract-performance-query.md +11 -20
- package/skills/weaver-e10-jinchengda/references/contract-quote-to-contract.md +203 -54
- package/skills/weaver-e10-jinchengda/references/contract-request-status.md +4 -11
- package/skills/weaver-e10-jinchengda/references/contract-request-write.md +11 -17
- package/skills/weaver-e10-jinchengda/references/contract-signing-subjects.md +11 -17
- package/skills/weaver-e10-jinchengda/references/contract-subject-create.md +5 -11
- package/skills/weaver-e10-jinchengda/references/contract-template-recommend.md +56 -7
- package/skills/weaver-e10-jinchengda/references/contract-workflow-discovery.md +10 -16
- package/skills/weaver-e10-jinchengda/references/orchestration.md +31 -33
- package/skills/weaver-e10-jucailin/SKILL.md +6 -7
- package/skills/weaver-e10-jucailin/agents/openai.yaml +52 -0
- package/skills/weaver-e10-jucailin/references/recruit-interview-overview.md +8 -6
- package/skills/weaver-e10-jucailin/references/recruit-read.md +4 -0
- package/skills/weaver-e10-jucailin/references/recruit-screening-to-interview-sop.md +2 -2
- package/skills/weaver-e10-jucailin/references/recruit-write.md +4 -4
- package/skills/weaver-e10-meeting/SKILL.md +83 -531
- package/skills/weaver-e10-meeting/references/commands-table.md +61 -0
- package/skills/weaver-e10-meeting/references/create-commands.md +136 -0
- package/skills/weaver-e10-meeting/references/create-flow.md +3 -1
- package/skills/weaver-e10-meeting/references/create-guardrails.md +14 -8
- package/skills/weaver-e10-meeting/references/custom-fields.md +40 -0
- package/skills/weaver-e10-meeting/references/eb-contracts.md +60 -0
- package/skills/weaver-e10-meeting/references/invitation.md +69 -0
- package/skills/weaver-e10-meeting/references/minutes-pipeline.md +119 -0
- package/skills/weaver-e10-meeting/references/pitfalls.md +1 -1
- package/skills/weaver-e10-meeting/references/room-recommend.md +88 -0
- package/skills/weaver-e10-recruit-stage/SKILL.md +317 -266
- package/skills/weaver-e10-recruit-stage/agents/openai.yaml +22 -27
- package/skills/weaver-e10-recruit-stage/references/env-ziyong.md +1 -1
- package/skills/weaver-e10-recruit-stage/references/recruit-arrange-interview.md +30 -27
- package/skills/weaver-e10-recruit-stage/references/recruit-capability-check.md +2 -6
- package/skills/weaver-e10-recruit-stage/references/recruit-edit-interview-feedback.md +12 -10
- package/skills/weaver-e10-recruit-stage/references/recruit-interview-not-attended.md +2 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-jd-create.md +23 -19
- package/skills/weaver-e10-recruit-stage/references/recruit-jd-template.md +3 -1
- package/skills/weaver-e10-recruit-stage/references/recruit-list-candidate.md +18 -16
- package/skills/weaver-e10-recruit-stage/references/recruit-list-interview.md +25 -23
- package/skills/weaver-e10-recruit-stage/references/recruit-match-candidates.md +10 -10
- package/skills/weaver-e10-recruit-stage/references/recruit-resolve-metadata.md +2 -2
- package/skills/weaver-e10-recruit-stage/references/recruit-resume-import-batch.md +11 -11
- package/skills/weaver-e10-recruit-stage/references/recruit-resume-import.md +150 -85
- package/skills/weaver-e10-recruit-stage/references/recruit-resume-parse.md +14 -18
- package/skills/weaver-e10-recruit-stage/references/recruit-search-by-tag.md +1 -1
- package/skills/weaver-e10-recruit-stage/references/recruit-tag-recommend.md +173 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-tag-taxonomy.json +76 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-urge-feedback.md +3 -1
- package/skills/weaver-e10-recruit-stage/references/recruit-utterance-glossary.md +2 -2
- package/skills/weaver-e10-workflow/SKILL.md +49 -32
- package/skills/weaver-e10-workflow/references/todo-dialogue.md +67 -34
- package/skills/weaver-e10-workflow/references/todo-smart-convert.md +65 -51
- package/skills/weaver-e10-workflow/references/workflow-agent-entry.md +18 -11
- package/skills/weaver-e10-workflow/references/workflow-create.md +2 -2
- package/skills/weaver-e10-workflow/references/workflow-memory.md +19 -37
- package/skills/weaver-e10-workflow/references/workflow-query.md +25 -22
- package/skills/weaver-e10-workflow/references/workflow-view.md +1 -1
- package/skills/weaver-e10-workflow/tools/todo-summary.cjs +318 -110
- package/skills/weaver-e10-yimiaoban/SKILL.md +10 -10
- package/skills/weaver-e10-yimiaoban/references/person.md +1 -1
- package/skills/weaver-e10-yimiaoban/references/safety-boundaries.md +1 -1
- package/skills/weaver-e10-yimiaoban/references/source-manifest.json +9 -9
- package/dist/chunks/chunk-6QYNE6HE.js +0 -658
- package/dist/chunks/chunk-SHYQUBY3.js +0 -48
- package/dist/shortcuts/contract/operations/card-action.js +0 -1266
- package/dist/shortcuts/contract/operations/card-plan.js +0 -393
- package/dist/shortcuts/contract/operations/card.js +0 -232
- package/dist/shortcuts/contract/operations/compare-screen.js +0 -378
- package/dist/shortcuts/contract/operations/quote-to-contract.js +0 -495
- package/dist/shortcuts/contract/operations/quotescreen.js +0 -529
- package/dist/shortcuts/contract/operations/summary-validate.js +0 -293
- package/dist/shortcuts/contract/operations/summary.js +0 -187
- package/dist/shortcuts/ehr/recruit-stage/batch-store.js +0 -78
- package/dist/shortcuts/ehr/recruit-stage/context.js +0 -231
- package/dist/shortcuts/ehr/recruit-stage/continuation.js +0 -74
- package/dist/shortcuts/ehr/recruit-stage/errors.js +0 -65
- package/dist/shortcuts/ehr/recruit-stage/fs-scan.js +0 -165
- package/dist/shortcuts/ehr/recruit-stage/host.js +0 -109
- package/dist/shortcuts/ehr/recruit-stage/operations/interview-arrange.js +0 -1065
- package/dist/shortcuts/ehr/recruit-stage/operations/interview-feedback.js +0 -295
- package/dist/shortcuts/ehr/recruit-stage/operations/jd-create.js +0 -961
- package/dist/shortcuts/ehr/recruit-stage/operations/list.js +0 -431
- package/dist/shortcuts/ehr/recruit-stage/operations/registry.js +0 -50
- package/dist/shortcuts/ehr/recruit-stage/operations/resume-import.js +0 -1655
- package/dist/shortcuts/ehr/recruit-stage/operations/search.js +0 -158
- package/dist/shortcuts/ehr/recruit-stage/operations/types.js +0 -34
- package/dist/shortcuts/ehr/recruit-stage/runtime.js +0 -31
- package/dist/shortcuts/ehr/recruit-stage/school-tiers.json +0 -318
- package/dist/shortcuts/ehr/recruit-stage/shared.js +0 -887
- package/skills/weaver-e10-jinchengda/references/contract-action-card-template.html +0 -22
- package/skills/weaver-e10-jinchengda/references/contract-action-card.md +0 -554
- package/skills/weaver-e10-jinchengda/references/contract-action-engine.md +0 -279
- package/skills/weaver-e10-jinchengda/references/contract-card-render-internals.md +0 -483
- package/skills/weaver-e10-jinchengda/references/contract-template-selector.md +0 -46
- package/skills/weaver-e10-recruit-stage/lib/recruit-resume-photo.py +0 -194
|
@@ -365,6 +365,31 @@ function cacheDirFor(baseUrl) {
|
|
|
365
365
|
const home = process.env.WEAVER_WORK_CLI_HOME || process.env.WORK_CLI_HOME || resolve(homedir(), ".weaver-work-cli");
|
|
366
366
|
return join(home, "env-cache", "recruit-ops", host);
|
|
367
367
|
}
|
|
368
|
+
var CONTEXT_SNAPSHOT_TTL_MS = 12 * 60 * 60 * 1e3;
|
|
369
|
+
function snapshotPathFor(baseUrl) {
|
|
370
|
+
const url = new URL(baseUrl);
|
|
371
|
+
const host = url.hostname + (url.port ? `_${url.port}` : "");
|
|
372
|
+
return join(cacheDirFor(baseUrl), "..", "_recruit-stage", `context-snapshot-${host}.json`);
|
|
373
|
+
}
|
|
374
|
+
function readContextSnapshot(baseUrl) {
|
|
375
|
+
try {
|
|
376
|
+
const raw = JSON.parse(readFileSync(snapshotPathFor(baseUrl), "utf8"));
|
|
377
|
+
if (!raw?.at || raw.cacheVersion !== RECRUIT_CACHE_VERSION) return null;
|
|
378
|
+
if (Date.now() - raw.at > CONTEXT_SNAPSHOT_TTL_MS) return null;
|
|
379
|
+
if (!raw.resolved || !hasCriticalFields({ ...raw.resolved, appId: raw.appId })) return null;
|
|
380
|
+
return raw;
|
|
381
|
+
} catch {
|
|
382
|
+
return null;
|
|
383
|
+
}
|
|
384
|
+
}
|
|
385
|
+
function writeContextSnapshot(baseUrl, appId, resolved) {
|
|
386
|
+
try {
|
|
387
|
+
const path = snapshotPathFor(baseUrl);
|
|
388
|
+
mkdirSync(join(path, ".."), { recursive: true });
|
|
389
|
+
writeFileSync(path, JSON.stringify({ at: Date.now(), cacheVersion: RECRUIT_CACHE_VERSION, appId, resolved }), "utf8");
|
|
390
|
+
} catch {
|
|
391
|
+
}
|
|
392
|
+
}
|
|
368
393
|
function namesOf(field) {
|
|
369
394
|
if (!field) return null;
|
|
370
395
|
let arr;
|
|
@@ -442,11 +467,13 @@ async function fetchFormFields(host, appId, objId) {
|
|
|
442
467
|
async function resolveRecruitEnv(host, appId) {
|
|
443
468
|
const forms = {};
|
|
444
469
|
let tenantKey = "";
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
470
|
+
const tagEntries = Object.entries(RECRUIT_TAGS);
|
|
471
|
+
const tagResponses = await Promise.all(tagEntries.map(([, tag]) => host.request({
|
|
472
|
+
path: "/api/ebuilder/form/obj/getObjsByTag",
|
|
473
|
+
query: { appId, tag }
|
|
474
|
+
})));
|
|
475
|
+
tagEntries.forEach(([logic], idx) => {
|
|
476
|
+
const response = tagResponses[idx];
|
|
450
477
|
const entry = Array.isArray(response?.data) && response.data.length ? response.data[0] : null;
|
|
451
478
|
forms[logic] = {
|
|
452
479
|
objId: String(entry?.id || ""),
|
|
@@ -454,7 +481,7 @@ async function resolveRecruitEnv(host, appId) {
|
|
|
454
481
|
objName: entry?.objName || ""
|
|
455
482
|
};
|
|
456
483
|
if (!tenantKey && entry?.tenantKey) tenantKey = String(entry.tenantKey);
|
|
457
|
-
}
|
|
484
|
+
});
|
|
458
485
|
for (const logic of RECRUIT_CRITICAL_FORMS) {
|
|
459
486
|
if (forms[logic]?.objId) continue;
|
|
460
487
|
throw new RecruitContextError(
|
|
@@ -506,41 +533,50 @@ async function resolveRecruitEnv(host, appId) {
|
|
|
506
533
|
const dictObjId = forms.dictionary?.objId || "";
|
|
507
534
|
if (dictObjId && dictMenu) {
|
|
508
535
|
const size = 500;
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
536
|
+
const CONCURRENCY = 6;
|
|
537
|
+
const fetchDictPage = (pageNo2) => host.request({
|
|
538
|
+
path: `/api/ebuilder/form/list/getListDatas?passid=${dictObjId}&cid=${dictObjId}`,
|
|
539
|
+
body: {
|
|
540
|
+
current: pageNo2,
|
|
541
|
+
pageSize: size,
|
|
542
|
+
tableuid: randHex32(),
|
|
543
|
+
listId: dictMenu.listId,
|
|
544
|
+
searchParamData: { searchType: "3", type: "and" },
|
|
545
|
+
terminal: "PC",
|
|
546
|
+
browser: "Chrome",
|
|
547
|
+
requiredMatch: 1,
|
|
548
|
+
mapResult: 1,
|
|
549
|
+
recheckQuery: 1,
|
|
550
|
+
isFollow: 0,
|
|
551
|
+
isShareToMe: 0,
|
|
552
|
+
filterCondition: {},
|
|
553
|
+
cusMenuId: dictMenu.cusMenuId,
|
|
554
|
+
urlPageTitle: "\u6570\u636E\u5B57\u5178",
|
|
555
|
+
menuName: "\u6570\u636E\u5B57\u5178"
|
|
556
|
+
},
|
|
557
|
+
headers: { ebBusinessId: dictMenu.listId }
|
|
558
|
+
});
|
|
559
|
+
let pageNo = 1;
|
|
560
|
+
let reachedEnd = false;
|
|
561
|
+
while (!reachedEnd) {
|
|
562
|
+
const batchPages = Array.from({ length: CONCURRENCY }, (_, i) => pageNo + i);
|
|
563
|
+
const responses = await Promise.all(batchPages.map((p) => fetchDictPage(p)));
|
|
564
|
+
for (const response of responses) {
|
|
565
|
+
const rows = response?.data?.data || [];
|
|
566
|
+
for (const row of rows) {
|
|
567
|
+
const name = row.selection_name;
|
|
568
|
+
const optionId = row.form_data_id;
|
|
569
|
+
if (name && optionId) {
|
|
570
|
+
(dictByName[String(name)] ||= []).push(String(optionId));
|
|
571
|
+
dictRaw.push({ selection_name: String(name), option_id: String(optionId), dict_type: row.dict_type, browser_key: row.browser_key });
|
|
572
|
+
}
|
|
573
|
+
}
|
|
574
|
+
if (rows.length < size) {
|
|
575
|
+
reachedEnd = true;
|
|
576
|
+
break;
|
|
540
577
|
}
|
|
541
578
|
}
|
|
542
|
-
|
|
543
|
-
current += 1;
|
|
579
|
+
pageNo += CONCURRENCY;
|
|
544
580
|
}
|
|
545
581
|
}
|
|
546
582
|
let ebdDetailPageId = "";
|
|
@@ -553,41 +589,54 @@ async function resolveRecruitEnv(host, appId) {
|
|
|
553
589
|
const keyField = fmap.config_key || "";
|
|
554
590
|
const valueField = fmap.config || "";
|
|
555
591
|
if (keyField && valueField) {
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
592
|
+
const bizSize = 100;
|
|
593
|
+
const BIZ_CONCURRENCY = 6;
|
|
594
|
+
const fetchBizPage = (pageNo) => host.request({
|
|
595
|
+
path: `/api/ebuilder/form/list/getListDatas?passid=${bizConfig.objId}&cid=${bizConfig.objId}`,
|
|
596
|
+
body: {
|
|
597
|
+
current: pageNo,
|
|
598
|
+
pageSize: bizSize,
|
|
599
|
+
tableuid: randHex32(),
|
|
600
|
+
listId: bizConfigMenu.listId,
|
|
601
|
+
searchParamData: { searchType: "3", type: "and" },
|
|
602
|
+
terminal: "PC",
|
|
603
|
+
browser: "Chrome",
|
|
604
|
+
requiredMatch: 1,
|
|
605
|
+
mapResult: 1,
|
|
606
|
+
recheckQuery: 1,
|
|
607
|
+
isFollow: 0,
|
|
608
|
+
isShareToMe: 0,
|
|
609
|
+
filterCondition: {},
|
|
610
|
+
cusMenuId: bizConfigMenu.cusMenuId,
|
|
611
|
+
urlPageTitle: "\u4E1A\u52A1\u914D\u7F6E\u6620\u5C04\u8868",
|
|
612
|
+
menuName: "\u4E1A\u52A1\u914D\u7F6E\u6620\u5C04\u8868"
|
|
613
|
+
},
|
|
614
|
+
headers: { ebBusinessId: bizConfigMenu.listId }
|
|
615
|
+
});
|
|
616
|
+
let bizPageNo = 1;
|
|
617
|
+
let bizEnd = false;
|
|
618
|
+
while (!bizEnd) {
|
|
619
|
+
const batchPages = Array.from({ length: BIZ_CONCURRENCY }, (_, i) => bizPageNo + i);
|
|
620
|
+
const responses = await Promise.all(batchPages.map((p) => fetchBizPage(p)));
|
|
621
|
+
for (const response of responses) {
|
|
622
|
+
const rows = response?.data?.data || [];
|
|
623
|
+
if (!rows.length) {
|
|
624
|
+
bizEnd = true;
|
|
625
|
+
break;
|
|
626
|
+
}
|
|
627
|
+
for (const row of rows) {
|
|
628
|
+
if (String(row.config_key || "") === "28" && row.config) {
|
|
629
|
+
const match = String(row.config).match(/\/sp\/ebdpage\/view\/(\d+)/);
|
|
630
|
+
if (match) ebdDetailPageId = match[1];
|
|
631
|
+
}
|
|
632
|
+
if (String(row.config_key || "") === "-9999" && String(row.config) === "1") selfUse = "1";
|
|
633
|
+
}
|
|
634
|
+
if (rows.length < bizSize) {
|
|
635
|
+
bizEnd = true;
|
|
636
|
+
break;
|
|
586
637
|
}
|
|
587
|
-
if (String(row.config_key || "") === "-9999" && String(row.config) === "1") selfUse = "1";
|
|
588
638
|
}
|
|
589
|
-
|
|
590
|
-
current += 1;
|
|
639
|
+
bizPageNo += BIZ_CONCURRENCY;
|
|
591
640
|
}
|
|
592
641
|
}
|
|
593
642
|
} catch {
|
|
@@ -672,7 +721,7 @@ function createRecruitContextLoader() {
|
|
|
672
721
|
try {
|
|
673
722
|
const dir = cacheDirFor(baseUrl);
|
|
674
723
|
if (existsSync(dir)) {
|
|
675
|
-
const files = readdirSync(dir).filter((file) => file.endsWith(".json"));
|
|
724
|
+
const files = readdirSync(dir).filter((file) => file.endsWith(".json") && !file.startsWith("_"));
|
|
676
725
|
if (files.length === 1) {
|
|
677
726
|
appId = files[0].replace(/\.json$/, "");
|
|
678
727
|
diskCache = JSON.parse(readFileSync(join(dir, files[0]), "utf8"));
|
|
@@ -696,33 +745,57 @@ function createRecruitContextLoader() {
|
|
|
696
745
|
);
|
|
697
746
|
}
|
|
698
747
|
appId = String(appIds[0]);
|
|
699
|
-
const
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
if (process.env.WEAVER_CLI_DEBUG_CACHE) {
|
|
718
|
-
console.error("[recruit-context] \u7F13\u5B58\u843D\u76D8\u5931\u8D25:", error instanceof Error ? error.message : String(error));
|
|
748
|
+
const snapshot = readContextSnapshot(baseUrl);
|
|
749
|
+
if (snapshot && snapshot.appId === appId && !process.env.E10_RS_NO_CTX_SNAPSHOT) {
|
|
750
|
+
let tagStillMatches = false;
|
|
751
|
+
try {
|
|
752
|
+
const probe = await host.request({
|
|
753
|
+
path: "/api/ebuilder/form/obj/getObjsByTag",
|
|
754
|
+
query: { appId, tag: RECRUIT_TAGS.talent_pool }
|
|
755
|
+
});
|
|
756
|
+
const probeObjId = String((Array.isArray(probe?.data) && probe.data.length ? probe.data[0]?.id : "") || "");
|
|
757
|
+
tagStillMatches = !!probeObjId && probeObjId === String(snapshot.resolved?.forms?.talent_pool?.objId || "");
|
|
758
|
+
} catch {
|
|
759
|
+
tagStillMatches = false;
|
|
760
|
+
}
|
|
761
|
+
if (tagStillMatches) {
|
|
762
|
+
const adopted = { ...snapshot.resolved, cacheVersion: RECRUIT_CACHE_VERSION };
|
|
763
|
+
persistContextCache(baseUrl, appId, adopted);
|
|
764
|
+
memo.set(memoKey, adopted);
|
|
765
|
+
return adopted;
|
|
719
766
|
}
|
|
720
767
|
}
|
|
768
|
+
const resolved = await resolveRecruitEnv(host, appId);
|
|
769
|
+
persistContextCache(baseUrl, appId, { ...resolved, cacheVersion: RECRUIT_CACHE_VERSION });
|
|
770
|
+
writeContextSnapshot(baseUrl, appId, resolved);
|
|
721
771
|
memo.set(memoKey, resolved);
|
|
722
772
|
return resolved;
|
|
723
773
|
}
|
|
724
774
|
return { load };
|
|
725
775
|
}
|
|
776
|
+
function persistContextCache(baseUrl, appId, cache) {
|
|
777
|
+
try {
|
|
778
|
+
const dir = cacheDirFor(baseUrl);
|
|
779
|
+
mkdirSync(dir, { recursive: true });
|
|
780
|
+
writeFileSync(
|
|
781
|
+
join(dir, `${appId}.json`),
|
|
782
|
+
JSON.stringify({
|
|
783
|
+
__meta__: {
|
|
784
|
+
capturedAt: (/* @__PURE__ */ new Date()).toISOString().replace("T", " ").substring(0, 19),
|
|
785
|
+
note: "recruit-ops \u73AF\u5883\u53C2\u6570\u7F13\u5B58\uFF08weaver-work-cli \u8FD0\u884C\u65F6\u89E3\u6790\u4EA7\u7269\uFF0C\u4E0D\u542B\u8BA4\u8BC1\u5B57\u6BB5\uFF09"
|
|
786
|
+
},
|
|
787
|
+
envKey: `${dir.split(/[\\/]/).pop()}|${appId}`,
|
|
788
|
+
cacheVersion: RECRUIT_CACHE_VERSION,
|
|
789
|
+
...cache
|
|
790
|
+
}, null, 2),
|
|
791
|
+
"utf8"
|
|
792
|
+
);
|
|
793
|
+
} catch (error) {
|
|
794
|
+
if (process.env.WEAVER_CLI_DEBUG_CACHE) {
|
|
795
|
+
console.error("[recruit-context] \u7F13\u5B58\u843D\u76D8\u5931\u8D25:", error instanceof Error ? error.message : String(error));
|
|
796
|
+
}
|
|
797
|
+
}
|
|
798
|
+
}
|
|
726
799
|
function buildListBody(params) {
|
|
727
800
|
return {
|
|
728
801
|
current: params.current ?? 1,
|
|
@@ -747,21 +820,23 @@ function buildListBody(params) {
|
|
|
747
820
|
menuName: params.menuName
|
|
748
821
|
};
|
|
749
822
|
}
|
|
750
|
-
async function fetchListRows(host, objId, listId, body) {
|
|
823
|
+
async function fetchListRows(host, objId, listId, body, options = {}) {
|
|
824
|
+
const withCount = options.withCount !== false;
|
|
751
825
|
const countBody = { ...body };
|
|
752
826
|
delete countBody.current;
|
|
753
827
|
delete countBody.pageSize;
|
|
828
|
+
const countRequest = withCount ? host.request({
|
|
829
|
+
path: `/api/ebuilder/form/list/getListDataCount?passid=${objId}&cid=${objId}`,
|
|
830
|
+
body: countBody,
|
|
831
|
+
headers: { ebBusinessId: listId }
|
|
832
|
+
}).catch(() => null) : Promise.resolve(null);
|
|
754
833
|
const [listResponse, countResponse] = await Promise.all([
|
|
755
834
|
host.request({
|
|
756
835
|
path: `/api/ebuilder/form/list/getListDatas?passid=${objId}&cid=${objId}`,
|
|
757
836
|
body,
|
|
758
837
|
headers: { ebBusinessId: listId }
|
|
759
838
|
}),
|
|
760
|
-
|
|
761
|
-
path: `/api/ebuilder/form/list/getListDataCount?passid=${objId}&cid=${objId}`,
|
|
762
|
-
body: countBody,
|
|
763
|
-
headers: { ebBusinessId: listId }
|
|
764
|
-
}).catch(() => null)
|
|
839
|
+
countRequest
|
|
765
840
|
]);
|
|
766
841
|
const data = normalizePaged(listResponse).data;
|
|
767
842
|
const rawRows = data?.data || [];
|
|
@@ -861,11 +936,11 @@ var candidateSearch = {
|
|
|
861
936
|
const batch = pureIds.slice(index, index + 100);
|
|
862
937
|
try {
|
|
863
938
|
const response = await env.host.request({
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
939
|
+
method: "POST",
|
|
940
|
+
path: "/api/hrm/common/browser/destData/resource",
|
|
941
|
+
body: { browserMultiple: true, selectIds: batch.join(",") }
|
|
867
942
|
});
|
|
868
|
-
for (const user of response?.data?.
|
|
943
|
+
for (const user of response?.data?.data || []) {
|
|
869
944
|
if (user?.id != null) creatorNameMap[String(user.id)] = user.name || null;
|
|
870
945
|
}
|
|
871
946
|
} catch {
|
|
@@ -910,7 +985,11 @@ var candidateList = {
|
|
|
910
985
|
inputSchema: schemaOf({
|
|
911
986
|
type: { type: "string", enum: ["demand", "position", "entry", "offer", "interview", "candidate"], description: "\u5217\u8868\u7C7B\u578B" },
|
|
912
987
|
current: SCHEMA_ID,
|
|
913
|
-
pageSize: SCHEMA_ID
|
|
988
|
+
pageSize: SCHEMA_ID,
|
|
989
|
+
count: {
|
|
990
|
+
type: "boolean",
|
|
991
|
+
description: "\u662F\u5426\u989D\u5916\u53D1\u4E00\u6B21\u8BA1\u6570\u8BF7\u6C42\u53D6\u7CBE\u786E\u603B\u6570\u3002\u9ED8\u8BA4\uFF1A\u7B2C 1 \u9875\u53D6\u3001\u7FFB\u9875\u4E0D\u53D6\uFF08\u7701\u4E00\u6B21 RTT\uFF09\uFF1B\u4F20 false \u8FDE\u9996\u9875\u4E5F\u4E0D\u53D6\uFF08\u6B64\u65F6\u672C\u9875\u5DF2\u6EE1\u5219 total \u4E3A null\uFF0C\u5C5E\u65E2\u6709\u964D\u7EA7\u8BED\u4E49\uFF09"
|
|
992
|
+
}
|
|
914
993
|
}, { required: ["type"] }),
|
|
915
994
|
handler: async (args, env) => {
|
|
916
995
|
const type = typeof args.type === "string" ? args.type : "";
|
|
@@ -933,15 +1012,23 @@ var candidateList = {
|
|
|
933
1012
|
if (!formObjId) {
|
|
934
1013
|
throw new RecruitContextError("recruit_context_missing", `\u672A\u89E3\u6790\u5230\u300C${listType.title}\u300D\u5BF9\u5E94\u8868\u5355\uFF0C\u65E0\u6CD5\u67E5\u8BE2\u3002`);
|
|
935
1014
|
}
|
|
1015
|
+
const currentPage = toPositiveInt(args.current, "current") ?? 1;
|
|
936
1016
|
const body = buildListBody({
|
|
937
1017
|
listId: listParam.listId,
|
|
938
1018
|
cusMenuId: listParam.cusMenuId,
|
|
939
1019
|
menuName: listParam.menuName || listType.title,
|
|
940
1020
|
title: listType.title,
|
|
941
|
-
current:
|
|
1021
|
+
current: currentPage,
|
|
942
1022
|
pageSize: toNumber(args.pageSize, "pageSize") ?? 10
|
|
943
1023
|
});
|
|
944
|
-
const
|
|
1024
|
+
const withCount = args.count === false ? false : currentPage === 1;
|
|
1025
|
+
const { rows, displayRows, total, totalExact, totalNote } = await fetchListRows(
|
|
1026
|
+
env.host,
|
|
1027
|
+
formObjId,
|
|
1028
|
+
listParam.listId,
|
|
1029
|
+
body,
|
|
1030
|
+
{ withCount }
|
|
1031
|
+
);
|
|
945
1032
|
const outRows = rows.map((row) => {
|
|
946
1033
|
const cleaned = { form_data_id: row?.form_data_id || row?.id };
|
|
947
1034
|
for (const [key, value] of Object.entries(row || {})) {
|
|
@@ -1000,11 +1087,11 @@ function nameLike(value) {
|
|
|
1000
1087
|
if (!text || /^\d{16,}$/.test(text)) return null;
|
|
1001
1088
|
return text;
|
|
1002
1089
|
}
|
|
1003
|
-
async function
|
|
1090
|
+
async function resolveCurrentUser(host) {
|
|
1004
1091
|
try {
|
|
1005
1092
|
const session = await host.getSession();
|
|
1006
1093
|
const baseUrl = String(session?.baseUrl || "");
|
|
1007
|
-
if (!baseUrl) return
|
|
1094
|
+
if (!baseUrl) return null;
|
|
1008
1095
|
const resp = await fetch(
|
|
1009
1096
|
`${baseUrl}/api/baseserver/layout/teamsCheck?clientType=not_xinchuang&client=WEB&domainName=${encodeURIComponent(baseUrl)}`,
|
|
1010
1097
|
{
|
|
@@ -1022,9 +1109,13 @@ async function resolveCurrentUserName(host) {
|
|
|
1022
1109
|
);
|
|
1023
1110
|
const data = await resp.json().catch(() => ({}));
|
|
1024
1111
|
const cu = data.currentUser ?? data.data?.currentUser ?? null;
|
|
1025
|
-
|
|
1112
|
+
if (!cu) return null;
|
|
1113
|
+
const id = cu.id != null ? String(cu.id) : "";
|
|
1114
|
+
const name = String(cu.username ?? cu.name ?? "");
|
|
1115
|
+
if (!id && !name) return null;
|
|
1116
|
+
return { id, name };
|
|
1026
1117
|
} catch {
|
|
1027
|
-
return
|
|
1118
|
+
return null;
|
|
1028
1119
|
}
|
|
1029
1120
|
}
|
|
1030
1121
|
var interviewFeedbackTodo = {
|
|
@@ -1052,7 +1143,6 @@ var interviewFeedbackTodo = {
|
|
|
1052
1143
|
}
|
|
1053
1144
|
const pageSize = toNumber(args.pageSize, "pageSize") ?? 200;
|
|
1054
1145
|
const maxPages = toNumber(args.maxPages, "maxPages") ?? 5;
|
|
1055
|
-
const me = await resolveCurrentUserName(env.host);
|
|
1056
1146
|
const fields = cache.fields[form.objId] || {};
|
|
1057
1147
|
const fieldOpts = cache.field_options[form.objId] || {};
|
|
1058
1148
|
const statusOpts = fieldOpts[fields.union_status] || {};
|
|
@@ -1064,25 +1154,70 @@ var interviewFeedbackTodo = {
|
|
|
1064
1154
|
const statusOf = (row) => toCn(statusOpts, row?.union_status_key ?? row?.union_status);
|
|
1065
1155
|
const typeOf = (row) => toCn(typeOpts, row?.interview_type_key ?? row?.interview_type);
|
|
1066
1156
|
const interviewerOf = (row) => personNames(row?.interviewer);
|
|
1067
|
-
const
|
|
1157
|
+
const cu = await resolveCurrentUser(env.host);
|
|
1158
|
+
const me = cu?.name || "";
|
|
1159
|
+
const myId = cu?.id || "";
|
|
1160
|
+
const statusFieldId = fields.union_status || "";
|
|
1161
|
+
const interviewerFieldId = fields.interviewer || "";
|
|
1162
|
+
const pendingOptionId = Object.entries(statusOpts).find(([, cn]) => String(cn).trim() === "\u5F85\u53CD\u9988")?.[0] || "";
|
|
1163
|
+
const conditions = {};
|
|
1164
|
+
const serverFilters = [];
|
|
1165
|
+
if (statusFieldId && pendingOptionId) {
|
|
1166
|
+
const mark = "field_" + statusFieldId;
|
|
1167
|
+
conditions[mark] = [{ [mark]: [pendingOptionId], [mark + "_condition_type"]: "in" }];
|
|
1168
|
+
serverFilters.push("\u5F85\u53CD\u9988");
|
|
1169
|
+
}
|
|
1170
|
+
if (interviewerFieldId && myId) {
|
|
1171
|
+
const mark = "field_" + interviewerFieldId;
|
|
1172
|
+
conditions[mark] = [{ [mark]: [myId], [mark + "_condition_type"]: "in" }];
|
|
1173
|
+
serverFilters.push("\u9762\u8BD5\u5B98=\u6211");
|
|
1174
|
+
}
|
|
1175
|
+
const canServerFilter = serverFilters.length === 2;
|
|
1176
|
+
let scanned = [];
|
|
1177
|
+
let total = null;
|
|
1178
|
+
let totalExact = false;
|
|
1179
|
+
let totalNote;
|
|
1068
1180
|
let lastPageCount = 0;
|
|
1069
|
-
|
|
1070
|
-
const
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1181
|
+
if (canServerFilter) {
|
|
1182
|
+
const cap = Math.min(Math.max(pageSize, 1), 200);
|
|
1183
|
+
const maxScanPages = 5;
|
|
1184
|
+
for (let p = 1; p <= maxScanPages; p++) {
|
|
1185
|
+
const page = await fetchListRows(env.host, form.objId, listParam.listId, buildListBody({
|
|
1186
|
+
listId: listParam.listId,
|
|
1187
|
+
cusMenuId: listParam.cusMenuId,
|
|
1188
|
+
menuName: listParam.menuName || "\u9762\u8BD5\u7BA1\u7406",
|
|
1189
|
+
title: "\u9762\u8BD5\u7BA1\u7406",
|
|
1190
|
+
current: p,
|
|
1191
|
+
pageSize: cap,
|
|
1192
|
+
conditions
|
|
1193
|
+
}));
|
|
1194
|
+
const use = page.displayRows && page.displayRows.length ? page.displayRows : page.rows;
|
|
1195
|
+
scanned.push(...use);
|
|
1196
|
+
total = page.total;
|
|
1197
|
+
totalExact = page.totalExact;
|
|
1198
|
+
totalNote = page.totalNote;
|
|
1199
|
+
if (use.length < cap) break;
|
|
1200
|
+
if (total !== null && scanned.length >= total) break;
|
|
1201
|
+
}
|
|
1202
|
+
} else {
|
|
1203
|
+
for (let i = 0; i < maxPages; i++) {
|
|
1204
|
+
const body = buildListBody({
|
|
1205
|
+
listId: listParam.listId,
|
|
1206
|
+
cusMenuId: listParam.cusMenuId,
|
|
1207
|
+
menuName: listParam.menuName || "\u9762\u8BD5\u7BA1\u7406",
|
|
1208
|
+
title: "\u9762\u8BD5\u7BA1\u7406",
|
|
1209
|
+
current: i + 1,
|
|
1210
|
+
pageSize
|
|
1211
|
+
});
|
|
1212
|
+
const page = await fetchListRows(env.host, form.objId, listParam.listId, body);
|
|
1213
|
+
const use = page.displayRows && page.displayRows.length ? page.displayRows : page.rows;
|
|
1214
|
+
scanned.push(...use);
|
|
1215
|
+
lastPageCount = use.length;
|
|
1216
|
+
if (use.length < pageSize) break;
|
|
1217
|
+
}
|
|
1083
1218
|
}
|
|
1084
|
-
const pending = scanned.filter((row) => /待反馈/.test(statusOf(row)));
|
|
1085
|
-
const mineAll = me ? pending.filter((row) => interviewerOf(row).includes(me)) : [];
|
|
1219
|
+
const pending = canServerFilter ? scanned : scanned.filter((row) => /待反馈/.test(statusOf(row)));
|
|
1220
|
+
const mineAll = canServerFilter ? pending : me ? pending.filter((row) => interviewerOf(row).includes(me)) : [];
|
|
1086
1221
|
const mineAi = mineAll.filter((row) => /AI\s*面试/i.test(typeOf(row)));
|
|
1087
1222
|
const slim = (row) => ({
|
|
1088
1223
|
form_data_id: row?.form_data_id ?? row?.id ?? null,
|
|
@@ -1098,12 +1233,28 @@ var interviewFeedbackTodo = {
|
|
|
1098
1233
|
position_manage_id: row?.position_manage_id ?? null
|
|
1099
1234
|
});
|
|
1100
1235
|
const notes = [];
|
|
1101
|
-
if (!
|
|
1102
|
-
|
|
1103
|
-
|
|
1236
|
+
if (!canServerFilter) {
|
|
1237
|
+
const missing = [];
|
|
1238
|
+
if (!pendingOptionId) missing.push("\u300C\u5F85\u53CD\u9988\u300D\u679A\u4E3E id");
|
|
1239
|
+
if (!myId) missing.push("\u5F53\u524D\u7528\u6237 id");
|
|
1240
|
+
notes.push(`\u672A\u89E3\u6790\u5230 ${missing.join(" / ")}\uFF0C\u5DF2\u56DE\u9000\u4E3A\u5BA2\u6237\u7AEF\u7B5B\u9009\uFF08\u8F83\u6162\u3001\u4E14\u53D7\u7FFB\u9875\u4E0A\u9650\u5F71\u54CD\uFF09\uFF0C\u7ED3\u679C\u4EC5\u4F9B\u53C2\u8003`);
|
|
1241
|
+
if (lastPageCount >= pageSize && scanned.length >= pageSize * maxPages) {
|
|
1242
|
+
notes.push(`\u5DF2\u626B\u63CF ${scanned.length} \u6761\uFF08\u8FBE maxPages=${maxPages} \u4E0A\u9650\uFF09\uFF0C\u5982\u6000\u7591\u9057\u6F0F\u53EF\u52A0\u5927 maxPages`);
|
|
1243
|
+
}
|
|
1244
|
+
} else {
|
|
1245
|
+
notes.push("\u670D\u52A1\u7AEF\u5DF2\u6309\u300C\u5F85\u53CD\u9988 + \u5F53\u524D\u767B\u5F55\u4EBA\u4E3A\u9762\u8BD5\u5B98\u300D\u7B5B\u9009\uFF08commonSearchFields + in\uFF09\uFF0Ctotal \u4E3A\u8BE5\u6761\u4EF6\u4E0B\u7684\u7CBE\u786E\u6761\u6570");
|
|
1246
|
+
if (total !== null && scanned.length < total) {
|
|
1247
|
+
notes.push(`\u26A0\uFE0F \u4EC5\u53D6\u56DE ${scanned.length}/${total} \u6761\u5F85\u529E\uFF08\u53D7\u7FFB\u9875\u4E0A\u9650 5\xD7200=1000 \u7EA6\u675F\uFF09\uFF0C\u8BF7\u91CD\u67E5\u6216\u6309\u6761\u4EF6\u8FDB\u4E00\u6B65\u6536\u7A84`);
|
|
1248
|
+
}
|
|
1104
1249
|
}
|
|
1250
|
+
if (!me) notes.push("\u672A\u80FD\u89E3\u6790\u5F53\u524D\u767B\u5F55\u4EBA\u59D3\u540D\uFF08teamsCheck \u5931\u8D25\uFF09");
|
|
1105
1251
|
return ehrSuccess("ehr.recruit.interview.feedbackTodo", {
|
|
1106
1252
|
currentUser: me || null,
|
|
1253
|
+
currentUserId: myId || null,
|
|
1254
|
+
serverFiltered: canServerFilter,
|
|
1255
|
+
total,
|
|
1256
|
+
totalExact,
|
|
1257
|
+
...totalNote ? { totalNote } : {},
|
|
1107
1258
|
scanned: scanned.length,
|
|
1108
1259
|
myAiPendingFeedback: { count: mineAi.length, rows: mineAi.map(slim) },
|
|
1109
1260
|
myOtherPendingFeedback: {
|
|
@@ -7,8 +7,8 @@ import {
|
|
|
7
7
|
findCommonFreeSlots,
|
|
8
8
|
meetingEbConflictOperations,
|
|
9
9
|
runEbConflictCheck
|
|
10
|
-
} from "./chunk-
|
|
11
|
-
import "./chunk-
|
|
10
|
+
} from "./chunk-4OB22YKE.js";
|
|
11
|
+
import "./chunk-TNFIUZ4H.js";
|
|
12
12
|
import "./chunk-7BDPM5ST.js";
|
|
13
13
|
import "./chunk-UG5G54VL.js";
|
|
14
14
|
import "./chunk-BUSC6UAE.js";
|