UNPKG

evmtools-node

Version:

このライブラリは、プライムブレインズ社で利用している「進捗管理ツール(Excel)」ファイルを読み込み、 プロジェクトの進捗状況や要員別の作業量を可視化するためのライブラリです。

261 lines (204 loc) 34 kB
<h1 align="center">Welcome to evmtools-node</h1> <p> <a href="#" target="_blank"> <img alt="License: ISC" src="https://img.shields.io/badge/License-ISC-yellow.svg" /> </a> <a href="https://twitter.com/masatomix" target="_blank"> <img alt="Twitter: masatomix" src="https://img.shields.io/twitter/follow/masatomix.svg?style=social" /> </a> </p> ## evmtools-node このライブラリは、プライムブレインズ社で利用している「進捗管理ツール(Excel)」ファイルを読み込み、 プロジェクトの進捗状況や要員別の作業量を可視化するためのライブラリです。 ### [サンプルサイト](https://masatomix.github.io/copy-utils-generator-webui/#/gamen3) WEBアプリ等で先のExcelファイルを読み書きできるように開発していますが、下記の通りコマンドラインから呼び出せるようにもしてあります。 ## コマンド ### プロジェクトの情報を表示・Excel出力する ```console $ npx pbevm-show-project --help Usage: npx pbevm-show-project [options] Options: --version Show version number [boolean] --path Excel file Path [string] [default: "./now.xlsm"] --help Show help [boolean] Examples: npx pbevm-show-project --path ./now.xlsm ``` 例: ```console $ npx pbevm-show-project --path ./now.xlsm プロジェクト名: now 開始日: 2025/07/01 終了日: 2025/08/26 基準日: 2025/07/25 タスク数:19件 先頭19行データ: ┌─────────┬───────┬────┬───────┬──────────────┬───────────┬──────────┬──────────────┬───────────────────┬─────┬─────┬─────┬───────────┬───────────┬───────────┬────────┬──────────────┬──────────────┬──────────────┬──────────────┬──────────────┐ │ (index) │ sharp │ id │ level │ name │ assignee │ workload │ progressRate │ scheduledWorkDays │ pv │ ev │ spi │ delayDays │ remarks │ parentId │ isLeaf │ 予定開始日 │ 予定終了日 │ 実績開始日 │ 実績終了日 │ 進捗応当日 │ ├─────────┼───────┼────┼───────┼──────────────┼───────────┼──────────┼──────────────┼───────────────────┼─────┼─────┼─────┼───────────┼───────────┼───────────┼────────┼──────────────┼──────────────┼──────────────┼──────────────┼──────────────┤ │ 0111'要件定義' │ undefined │ 414441 │ undefined │ undefined │ undefined │ false'2025/07/01''2025/07/04''2025/07/01''2025/07/04''' │ │ 1222'機能全体''要員A'414441 │ undefined │ undefined │ 1true'2025/07/01''2025/07/04''2025/07/01''2025/07/04''' │ │ 2331'設計' │ undefined │ 1511215151 │ undefined │ undefined │ undefined │ false'2025/07/07''2025/07/18''2025/07/04''2025/07/16''' │ │ 3442'機能1''要員A'315331 │ undefined │ undefined │ 3true'2025/07/07''2025/07/11''2025/07/07''2025/07/11''' │ │ 4552'機能2''要員A'215221 │ undefined │ undefined │ 3true'2025/07/07''2025/07/11''2025/07/04''2025/07/10''' │ │ 5662'機能3''要員B'515551 │ undefined │ undefined │ 3true'2025/07/14''2025/07/18''2025/07/04''2025/07/10''' │ │ 6772'機能4''要員A'515551 │ undefined │ undefined │ 3true'2025/07/14''2025/07/18''2025/07/14''2025/07/16''' │ │ 7881'開発' │ undefined │ 300.2512157.50.5-2 │ undefined │ undefined │ false'2025/07/21''2025/08/01''2025/07/21''''2025/07/27' │ │ 8992'機能1''要員A'100.110510.23 │ undefined │ 8true'2025/07/21''2025/08/01''2025/07/21''''2025/07/22' │ │ 910102'機能2''要員B'50.2102.510.42 │ undefined │ 8true'2025/07/21''2025/08/01''2025/07/21''''2025/07/23' │ │ 1011112'機能3''要員B'50.3102.51.50.61 │ undefined │ 8true'2025/07/21''2025/08/01''2025/07/21''''2025/07/24' │ │ 1112122'機能4''要員C'100.410540.80 │ undefined │ 8true'2025/07/21''2025/08/01''2025/07/21''''2025/07/25' │ │ 1213131'テスト' │ undefined │ 15019000 │ undefined │ undefined │ undefined │ false'2025/08/04''2025/08/22''''''' │ │ 1314142'単体テスト''要員A'5 │ undefined │ 5000 │ undefined │ undefined │ 13true'2025/08/04''2025/08/08''''''' │ │ 1415152'連結テスト''要員A'5 │ undefined │ 5000 │ undefined │ undefined │ 13true'2025/08/11''2025/08/15''''''' │ │ 1516162'総合テスト''要員A'5 │ undefined │ 5000 │ undefined │ undefined │ 13true'2025/08/18''2025/08/22''''''' │ │ 1617171'リリース' │ undefined │ 202000 │ undefined │ undefined │ undefined │ false'2025/08/25''2025/08/26''''''' │ │ 1718182'準備''要員C'1 │ undefined │ 1000 │ undefined │ undefined │ 17true'2025/08/25''2025/08/25''''''' │ │ 1819192'作業''要員C'1 │ undefined │ 1000 │ undefined │ undefined │ 17true'2025/08/26''2025/08/26''''''' │ └─────────┴───────┴────┴───────┴──────────────┴───────────┴──────────┴──────────────┴───────────────────┴─────┴─────┴─────┴───────────┴───────────┴───────────┴────────┴──────────────┴──────────────┴──────────────┴──────────────┴──────────────┘ プロジェクト情報 ┌─────────┬─────────────┬──────────────┬──────────────┬─────────────────┬────────────────────┬─────────────────────────┬─────────────────┬──────────────┬──────────────┬───────────────────┬─────────┬────────────────────┐ │ (index) │ projectName │ startDate │ endDate │ totalTasksCount │ totalWorkloadExcel │ totalWorkloadCalculated │ averageWorkload │ baseDate │ totalPvExcel │ totalPvCalculated │ totalEv │ spi │ ├─────────┼─────────────┼──────────────┼──────────────┼─────────────────┼────────────────────┼─────────────────────────┼─────────────────┼──────────────┼──────────────┼───────────────────┼─────────┼────────────────────┤ │ 0'now''2025/07/01''2025/08/26'1466664.714'2025/07/25'343426.50.7794117647058824 │ └─────────┴─────────────┴──────────────┴──────────────┴─────────────────┴────────────────────┴─────────────────────────┴─────────────────┴──────────────┴──────────────┴───────────────────┴─────────┴────────────────────┘ 要員ごと統計 ┌─────────┬──────────┬─────────────────┬────────────────────┬─────────────────────────┬─────────────────┬──────────────┬──────────────┬───────────────────┬─────────┬────────────────────┐ │ (index) │ assignee │ totalTasksCount │ totalWorkloadExcel │ totalWorkloadCalculated │ averageWorkload │ baseDate │ totalPvExcel │ totalPvCalculated │ totalEv │ spi │ ├─────────┼──────────┼─────────────────┼────────────────────┼─────────────────────────┼─────────────────┼──────────────┼──────────────┼───────────────────┼─────────┼────────────────────┤ │ 0'要員A'839394.875'2025/07/25'1919150.7894736842105263 │ │ 1'要員B'315155'2025/07/25'10107.50.75 │ │ 2'要員C'312124'2025/07/25'5540.8 │ └─────────┴──────────┴─────────────────┴────────────────────┴─────────────────────────┴─────────────────┴──────────────┴──────────────┴───────────────────┴─────────┴────────────────────┘ $ ls -lrt -rw-r--r-- 1 sysmgr sysmgr 468256 Jul 9 15:24 now.xlsm -rw-r--r-- 1 sysmgr sysmgr 50950 Jul 11 16:00 now-summary.xlsx <-上記情報 $ ``` ### 指定した期間における、指定した担当者のタスクを表示する ```console $ npx pbevm-show-pv --help Usage: npx pbevm-show-pv [options] Options: --version Show version number [boolean] --path Excel file Path [string] [default: "./now.xlsm"] --fromDate From Date [string] [default: "2025-07-01"] --toDate To Date [string] --assignee Assignee [string] --help Show help [boolean] Examples: npx pbevm-show-pv --path now.xlsm --fromDate 2025-07-07 --toDate 2025-07-11 --assignee '要員A' ``` 例: ``` $ npx pbevm-show-pv --path now.xlsm \ --fromDate 2025-07-07 \ --toDate 2025-07-11 \ --assignee '要員A' (toDate未指定時はfromDateの日のみ、assignee未指定時は全員) ┌─────────┬───────┬────┬───────┬─────────┬──────────┬──────────┬──────────────┬───────────────────┬────┬────┬─────┬───────────┬───────────┬──────────┬────────┬──────────────┬──────────────┬──────────────┬──────────────┬────────────┐ │ (index) │ sharp │ id │ level │ name │ assignee │ workload │ progressRate │ scheduledWorkDays │ pv │ ev │ spi │ delayDays │ remarks │ parentId │ isLeaf │ 予定開始日 │ 予定終了日 │ 実績開始日 │ 実績終了日 │ 進捗応当日 │ ├─────────┼───────┼────┼───────┼─────────┼──────────┼──────────┼──────────────┼───────────────────┼────┼────┼─────┼───────────┼───────────┼──────────┼────────┼──────────────┼──────────────┼──────────────┼──────────────┼────────────┤ │ 0442'機能1''要員A'315331 │ undefined │ undefined │ 3true'2025/07/07''2025/07/11''2025/07/07''2025/07/11''' │ │ 1552'機能2''要員A'215221 │ undefined │ undefined │ 3true'2025/07/07''2025/07/11''2025/07/04''2025/07/10''' │ └─────────┴───────┴────┴───────┴─────────┴──────────┴──────────┴──────────────┴───────────────────┴────┴────┴─────┴───────────┴───────────┴──────────┴────────┴──────────────┴──────────────┴──────────────┴──────────────┴────────────┘ $ ls -lrt -rw-r--r-- 1 sysmgr sysmgr 468256 Jul 9 15:24 now.xlsm -rw-r--r-- 1 sysmgr sysmgr 7183 Jul 11 16:07 now-pv.xlsx $ ``` ### 指定したファイル間のDIFFをとる ``` $ npx pbevm-diff --help Usage: npx pbevm-diff [options] Options: --version Show version number [boolean] --path Excel file Path [string] [default: "./now.xlsm"] --prevPath Excel file Path [string] [default: "./prev.xlsm"] --help Show help [boolean] Examples: npx pbevm-diff --path now.xlsm --prevPath prev.xlsm ``` 例: ``` $ npx pbevm-diff \ --path now.xlsm \ --prevPath prev.xlsm プロジェクトDiff ┌─────────┬─────────┬─────────┬────────┬────────┬───────────┬───────────┬───────────────┬────────────┬──────────────┬─────────┬──────────┐ │ (index) │ deltaPV │ deltaEV │ prevPV │ prevEV │ currentPV │ currentEV │ modifiedCount │ addedCount │ removedCount │ hasDiff │ finished │ ├─────────┼─────────┼─────────┼────────┼────────┼───────────┼───────────┼───────────────┼────────────┼──────────────┼─────────┼──────────┤ │ 03019.602.93022.5800truefalse │ └─────────┴─────────┴─────────┴────────┴────────┴───────────┴───────────┴───────────────┴────────────┴──────────────┴─────────┴──────────┘ 担当Diff ┌─────────┬──────────┬─────────┬─────────┬────────┬────────┬───────────┬───────────┬───────────────┬────────────┬──────────────┬─────────┬──────────┐ │ (index) │ assignee │ deltaPV │ deltaEV │ prevPV │ prevEV │ currentPV │ currentEV │ modifiedCount │ addedCount │ removedCount │ hasDiff │ finished │ ├─────────┼──────────┼─────────┼─────────┼────────┼────────┼───────────┼───────────┼───────────────┼────────────┼──────────────┼─────────┼──────────┤ │ 0'要員A'1510.600.41511400truefalse │ │ 1'要員B'10502.5107.5300truefalse │ │ 2'要員C'540054100truefalse │ └─────────┴──────────┴─────────┴─────────┴────────┴────────┴───────────┴───────────┴───────────────┴────────────┴──────────────┴─────────┴──────────┘ タスクDiff ┌─────────┬────┬─────────┬──────────────┬──────────┬──────────┬───────────────────┬─────────┬─────────┬────────┬────────┬───────────┬───────────┬──────────────────┬─────────────────────┬─────────┬─────────────────────┬───────────┬───────────┬────────────┬──────────┬─────────────┬──────────────────────────┬──────────────────────────┬──────────────────────────┬───────────────┬──────────────────┬─────────────┬───────────┐ │ (index) │ id │ name │ fullName │ assignee │ parentId │ deltaProgressRate │ deltaPV │ deltaEV │ prevPV │ prevEV │ currentPV │ currentEV │ prevProgressRate │ currentProgressRate │ hasDiff │ hasProgressRateDiff │ hasPvDiff │ hasEvDiff │ diffType │ finished │ isOverdueAt │ prevBaseDate │ currentBaseDate │ baseDate │ daysOverdueAt │ daysStrOverdueAt │ currentTask │ prevTask │ ├─────────┼────┼─────────┼──────────────┼──────────┼──────────┼───────────────────┼─────────┼─────────┼────────┼────────┼───────────┼───────────┼──────────────────┼─────────────────────┼─────────┼─────────────────────┼───────────┼───────────┼────────────┼──────────┼─────────────┼──────────────────────────┼──────────────────────────┼──────────────────────────┼───────────────┼──────────────────┼─────────────┼───────────┤ │ 04'機能1''設計/機能1''要員A'31330033 │ undefined │ 1truetruetruetrue'modified'truefalse2025-07-03T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ -14'14 日前' │ [TaskRow] │ [TaskRow] │ │ 15'機能2''設計/機能2''要員A'30.821.600.4220.21truetruetruetrue'modified'truefalse2025-07-03T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ -14'14 日前' │ [TaskRow] │ [TaskRow] │ │ 26'機能3''設計/機能3''要員B'30.552.502.5550.51truetruetruetrue'modified'truefalse2025-07-03T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ -7'7 日前' │ [TaskRow] │ [TaskRow] │ │ 37'機能4''設計/機能4''要員A'31550055 │ undefined │ 1truetruetruetrue'modified'truefalse2025-07-03T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ -7'7 日前' │ [TaskRow] │ [TaskRow] │ │ 49'機能1''開発/機能1''要員A'80.1510051 │ undefined │ 0.1truetruetruetrue'modified'falsefalse2025-07-03T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 7'7 日後' │ [TaskRow] │ [TaskRow] │ │ 510'機能2''開発/機能2''要員B'80.22.51002.51 │ undefined │ 0.2truetruetruetrue'modified'falsefalse2025-07-03T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 7'7 日後' │ [TaskRow] │ [TaskRow] │ │ 611'機能3''開発/機能3''要員B'80.32.51.5002.51.5 │ undefined │ 0.3truetruetruetrue'modified'falsefalse2025-07-03T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 7'7 日後' │ [TaskRow] │ [TaskRow] │ │ 712'機能4''開発/機能4''要員C'80.4540054 │ undefined │ 0.4truetruetruetrue'modified'falsefalse2025-07-03T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 2025-07-24T15:00:00.000Z │ 7'7 日後' │ [TaskRow] │ [TaskRow] │ └─────────┴────┴─────────┴──────────────┴──────────┴──────────┴───────────────────┴─────────┴─────────┴────────┴────────┴───────────┴───────────┴──────────────────┴─────────────────────┴─────────┴─────────────────────┴───────────┴───────────┴────────────┴──────────┴─────────────┴──────────────────────────┴──────────────────────────┴──────────────────────────┴───────────────┴──────────────────┴─────────────┴───────────┘ $ ls -lrt -rw-r--r-- 1 sysmgr sysmgr 463539 Jul 9 15:24 prev.xlsm -rw-r--r-- 1 sysmgr sysmgr 468256 Jul 9 15:24 now.xlsm -rw-r--r-- 1 sysmgr sysmgr 15937 Jul 11 16:14 now-diff.xlsx ``` ## Author 👤 **Masatomi KINO** <!-- * Twitter: [@masatomix](https://twitter.com/masatomix) --> * Github: [@masatomix](https://github.com/masatomix) ## 🤝 Contributing Contributions, issues and feature requests are welcome!<br />Feel free to check [issues page](https://github.com/masatomix/evmtools-node/issues). ## Show your support Give a ⭐️ if this project helped you! ## 改訂履歴 - 0.0.13 Diffのプロパティに工数(workload)を追加。 - 0.0.12 時系列の統計データを読み込む ProjectStatisticsCreator を追加。 - 0.0.11 指定した基準日のSPI/SV(EV-PV)を返すメソッドをTaskRowに追加。 - 0.0.10 内部処理の見直し(ログ関連)。 - 0.0.8 Projectに休日データを保持するプロパティを追加。Projectに日付を指定して祝日かを返すメソッドを追加。 - 0.0.7 内部のリファクタリング(キャッシュして処理改善) - 0.0.6 README.md(このファイル)を更新。Project#getTaskRows で、条件に合致するTaskRowを返すメソッドを追加 - 0.0.5 初回リリース(絶賛開発中) ## 🔧 Logger 設定のカスタマイズ このライブラリは `pino` を使ってログを出力しています。 ログ出力レベルやフォーマットを変更したい場合は、``config/default.json`` を作成して設定を記述してください。 ```json { "evmtools-node-logger": { "level": "warn", "moduleLogLevels": { "main": "info" }, "transport": { "target": "pino-pretty", "options": { "translateTime": "SYS:standard", "ignore": "id,hostname", "levelFirst": true } } } } ``` ``` "level": "warn", // 全体のログレベルを指定 "moduleLogLevels": // ソースごとにlevelを変えたい場合、この中に記述 "transport": // pino のtransport設定などを記述 "target": "pino-pretty", // この場合は npm install --save-dev pino-pretty すること ``` *** _This README was generated by [readme-md-generator](https://github.com/kefranabg/readme-md-generator)_