首页龙虾技能列表 › pms-worklog — 技能工具

pms-worklog — 技能工具

v1.0.0

自动填写 PingCode/PMS 系统工时记录。支持批量填写多天的工时,自动登录、选择事项类型、填写事项、工时、日期和说明。

1· 217·0 当前·0 累计
by @ww12355·MIT-0
下载技能包
License
MIT-0
最后更新
2026/3/13
安全扫描
VirusTotal
无害
查看报告
OpenClaw
安全
medium confidence
The skill's code and instructions are consistent with its stated purpose (automating PingCode/PMS worklog entry); it requires Playwright + Node and asks the user to supply their PMS credentials, which matches the described behavior, but there are some minor operational and hygiene issues to be aware of before running it.
评估建议
This skill appears to do exactly what it says: control a Chrome browser via Playwright to log into your PingCode/PMS and submit worklog entries. Before running it: (1) review the full script to ensure there are no outbound network calls or telemetry (the visible code only manipulates the browser and saves local screenshots); (2) do not hardcode real credentials in the file — prefer exporting PMS_USERNAME/PMS_PASSWORD in your shell or a secure secrets store; (3) update screenshotDir and any user-...
详细分析 ▾
用途与能力
The name/description (auto-fill PingCode/PMS worklogs) align with the included script and SKILL.md: the script uses Playwright to log in, navigate the PMS site, fill fields, click UI elements, and save screenshots. Required binaries (node, npm) and the dependency on Playwright are proportional to this purpose.
指令范围
SKILL.md instructs running the included Playwright script and editing a clear configuration block with username/password, dates, work item, screenshot directory, etc. That is expected for this automation, but the instructions encourage placing credentials directly in the script (less secure) and reference hardcoded local paths (e.g., /Users/aispeech/.openclaw/...), which are environment-specific and may require user modification. The SKILL.md does not instruct reading unrelated system files or contacting endpoints outside the PMS site.
安装机制
There is no automated install spec (instruction-only), which is lower risk. The SKILL.md tells the user to npm install -g playwright and run 'playwright install chromium' — that will download browser binaries and requires network access. This install approach is typical for Playwright but the manual step should be noted by users before running.
凭证需求
The registry lists no required env vars, but the SKILL.md and script support using PMS_USERNAME and PMS_PASSWORD environment variables (recommended). That optional credential usage is proportional to the task. Be aware the script defaults to embedding credentials if the user edits the config block (insecure). The script saves screenshots to a user-specific path, which is expected but should be updated for other users.
持久化与权限
The skill does not request persistent platform privileges (always:false). It's an instruction-only/scripted skill that runs when invoked and does not modify other skills or system-wide agent settings.
安全有层次,运行前请审查代码。

License

MIT-0

可自由使用、修改和再分发,无需署名。

运行时依赖

无特殊依赖

版本

latestv1.0.02026/3/13

pms-worklog v1.0.0 - 首次发布:自动填写 PingCode/PMS 系统工时记录脚本。 - 支持批量填写多天工时,自动登录、选择事项类型、填写事项编号、工时、日期和说明。 - 提供命令行运行方法及 OpenClaw 集成方式。 - 支持环境变量配置账号信息,提升安全性。 - 运行后输出填写进度并保存截图,便于故障排查。

● 无害

安装命令 点击复制

官方npx clawhub@latest install pms-worklog
镜像加速npx clawhub@latest install pms-worklog --registry https://cn.clawhub-mirror.com

技能文档

功能

自动在 PingCode/PMS 系统中填写工时记录,支持:

  • 自动登录
  • 选择事项类型(工作项)
  • 填写事项编号并选择匹配项
  • 填写工时、日期、说明
  • 批量填写多天的工时

前置条件

  • 安装 Playwright:
npm install -g playwright
playwright install chromium
  • 确保系统已安装 Google Chrome

使用方法

方式 1:直接运行脚本

NODE_PATH=/Users/aispeech/.npm-global/lib/node_modules node ~/.openclaw/workspace/skills/pms-worklog/scripts/fill_worklog.js

方式 2:通过 OpenClaw 调用

exec: node ~/.openclaw/workspace/skills/pms-worklog/scripts/fill_worklog.js

配置

编辑脚本中的配置区域:

// ===== 配置区域 =====
const username = 'your_username@company.com';  // 你的 PMS 账号
const password = 'your_password';              // 你的 PMS 密码

const dates = ['2026-03-09', '2026-03-10', '2026-03-11']; // 填写日期

const workItem = 'IOTxxxxxx-xxxx'; // 事项编号 const hours = '8'; // 每天工时 const description = '工作内容说明'; // 工作说明

const pmsUrl = 'https://pms.aispeech.com.cn/workspace/workload/insight'; const screenshotDir = '/Users/aispeech/.openclaw/workspace'; // ===================

使用环境变量(推荐)

也可以将敏感信息放在环境变量中:

export PMS_USERNAME="your_username@company.com"
export PMS_PASSWORD="your_password"

然后在脚本中使用:

const username = process.env.PMS_USERNAME || 'default_user';
const password = process.env.PMS_PASSWORD || 'default_pass';

输出

脚本运行后会:

  • 在终端显示填写进度
  • 保存截图到配置的 screenshotDir/pms_png 目录:
- day1_filled.png - 填写完成截图 - day1_done.png - 提交成功截图 - day1_error.png - 提交失败截图(如有)

注意事项

  • 事项类型必须先选择:必须先选择"工作项"类型,再填写事项编号
  • 下拉列表需要等待:填写事项后需要等待 3 秒让下拉列表刷新
  • 必须点击选项:不能按回车确认,必须点击下拉列表中的选项
  • 网络要求:需要能访问 PMS 系统

故障排除

浏览器启动失败

# 确保 Chrome 已安装
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --version

# 重新安装 Playwright npm install -g playwright playwright install chromium

事项无法选择

  • 检查事项类型是否已选择为"工作项"
  • 增加等待时间(将 waitForTimeout(3000) 改为更长时间)
  • 检查事项编号是否正确

表单提交失败

  • 检查所有必填字段是否已填写
  • 查看 day*_error.png 截图确认错误信息

登录失败

  • 检查账号密码是否正确
  • 检查网络连接
  • 确认 PMS 系统可访问
数据来源:ClawHub ↗ · 中文优化:龙虾技能库
OpenClaw 技能定制 / 插件定制 / 私有工作流定制

免费技能或插件可能存在安全风险,如需更匹配、更安全的方案,建议联系付费定制

了解定制服务